Skip to content

Commit 6932d4c

Browse files
authored
Partial Postman rebrand (#231)
All environment variables are still Akita-branded, but we now recognize `POSTMAN_LC_AGENT_DISABLE_TELEMETRY` in addition to the existing `AKITA_DISABLE_TELEMETRY`.
1 parent bf2fd01 commit 6932d4c

File tree

24 files changed

+73
-69
lines changed

24 files changed

+73
-69
lines changed

.github/workflows/security-scan.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,6 @@ jobs:
1111
name: Security Scan Job
1212
uses: postmanlabs/gh-security-scan-workflow/.github/workflows/[email protected]
1313
with:
14-
imagename: akita-cli
14+
imagename: postman-lc-agent
1515
language: "['go']"
1616

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
*.dll
55
*.so
66
*.dylib
7-
akita-cli
7+
postman-lc-agent
88
bin/
99

1010
# Test binary, built with `go test -c`

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
export GO111MODULE = on
44

55
build: clean
6-
go build -o bin/akita .
6+
go build -o bin/postman-lc-agent .
77

88
clean:
99
go clean

apidump/apidump.go

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ const (
6363
)
6464

6565
const (
66-
subcommandOutputDelimiter = "======= _AKITA_SUBCOMMAND_ ======="
66+
subcommandOutputDelimiter = "======= _POSTMAN_SUBCOMMAND_ ======="
6767
)
6868

6969
type filterState string
@@ -394,7 +394,7 @@ func (a *apidump) RotateLearnSession(done <-chan struct{}, collectors []trace.Le
394394
printer.Errorf("Failed to create trace %s: %v\n", traceName, err)
395395
break
396396
}
397-
printer.Infof("Rotating to new trace on Akita Cloud: %v\n", traceName)
397+
printer.Infof("Rotating to new trace on Postman Cloud: %v\n", traceName)
398398
for _, c := range collectors {
399399
c.SwitchLearnSession(backendLrn)
400400
}
@@ -542,7 +542,7 @@ func (a *apidump) Run() error {
542542
if uri.ObjectType == nil {
543543
uri.ObjectType = akiuri.TRACE.Ptr()
544544
} else if !uri.ObjectType.IsTrace() {
545-
return errors.Errorf("%q is not an Akita trace URI", uri)
545+
return errors.Errorf("%q is not a Postman trace URI", uri)
546546
}
547547

548548
// Use a random object name by default.
@@ -580,7 +580,7 @@ func (a *apidump) Run() error {
580580
uri := a.Out.AkitaURI
581581
backendLrn, err = util.NewLearnSession(args.Domain, args.ClientID, a.backendSvc, uri.ObjectName, traceTags, nil)
582582
if err == nil {
583-
printer.Infof("Created new trace on Akita Cloud: %s\n", uri)
583+
printer.Infof("Created new trace on Postman Cloud: %s\n", uri)
584584
} else {
585585
var httpErr rest.HTTPError
586586
if ok := errors.As(err, &httpErr); ok && httpErr.StatusCode == 409 {
@@ -955,7 +955,7 @@ func createLocalCollector(interfaceName, outDir string, tags map[tags.Key]string
955955
}
956956

957957
// Check if we have permission to write to the directory.
958-
testFile := filepath.Join(outDir, "akita_test")
958+
testFile := filepath.Join(outDir, "postman_test")
959959
if err := ioutil.WriteFile(testFile, []byte{1}, 0644); err == nil {
960960
os.Remove(testFile)
961961
} else {

apidump/net.go

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ func showPermissionErrors(sampleError error) error {
4747
printer.Warningf("It might be that you are in a PaaS that disallows packet capture, or the local configuration has disabled that privilege by default.\n")
4848
return NewApidumpError(api_schema.ApidumpError_PCAPPermission, "Insufficient permissions in container.")
4949
} else {
50-
printer.Warningf("Although you are running as root, the Akita agent lacks the CAP_NET_RAW capability.\n")
50+
printer.Warningf("Although you are running as root, the Postman Live Collections Agent lacks the CAP_NET_RAW capability.\n")
5151
printer.Warningf("It might be that you are in a restricted environment which disallows packet capture, even as the root user.\n")
5252
return NewApidumpError(api_schema.ApidumpError_PCAPPermission, "Insufficient permissions.")
5353
}
@@ -63,23 +63,23 @@ func showPermissionErrors(sampleError error) error {
6363

6464
printer.Warningf(
6565
"The agent received \"Function not implemented\" when trying to read from your network interfaces. "+
66-
"This often indicates that the Akita agent was built for a different architecture than your host architecture. "+
67-
"This Akita agent binary was built for %s.\n",
66+
"This often indicates that the Postman Live Collections Agent was built for a different architecture than your host architecture. "+
67+
"This Postman Live Collections Agent binary was built for %s.\n",
6868
arch,
6969
)
7070

7171
if env.InDocker() {
7272
return NewApidumpErrorf(
7373
api_schema.ApidumpError_PCAPInterfaceNotImplemented,
7474
"Unable to read network interfaces. If your host architecture is not %s, try using "+
75-
"`docker pull --platform $YOUR_ARCHITECTURE docker.postman.com/postman-lc-agent:latest` to pull an Akita agent "+
75+
"`docker pull --platform $YOUR_ARCHITECTURE docker.postman.com/postman-lc-agent:latest` to pull a Postman Live Collections Agent "+
7676
"built for your architecture.",
7777
arch,
7878
)
7979
} else {
8080
return NewApidumpErrorf(
8181
api_schema.ApidumpError_PCAPInterfaceNotImplemented,
82-
"Unable to read network interfaces. If your host architecture is not %s, try using the Akita install script: `bash -c \"$(curl -L https://releases.akita.software/scripts/install_akita.sh)\"`",
82+
"Unable to read network interfaces. If your host architecture is not %s, try using the Postman Live Collections Agent install script: `bash -c \"$(curl -L https://releases.observability.postman.com/scripts/install-postman-lc-agent.sh)\"`",
8383
arch,
8484
)
8585
}

apidump/summary.go

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -133,10 +133,10 @@ func (s *Summary) printPortHighlights(top *client_telemetry.PacketCountSummary)
133133
if thisPort.TLSHello > 0 {
134134
printer.Stderr.Infof("TCP Port %5d: appears to contain a mix of encrypted and unencrypted traffic.\n", p)
135135
} else if thisPort.Unparsed > thisPort.TCPPackets*3/10 {
136-
printer.Stderr.Infof("TCP Port %5d: has an unusually high amount of traffic that Akita cannot parse.\n", p)
136+
printer.Stderr.Infof("TCP Port %5d: has an unusually high amount of traffic that Postman cannot parse.\n", p)
137137
}
138138
if thisPort.HTTP2Prefaces > 0 {
139-
printer.Stderr.Infof("TCP Port %5d: Contains HTTP/2 traffic (%d connections detected), which Akita cannot parse.\n", p, thisPort.HTTP2Prefaces)
139+
printer.Stderr.Infof("TCP Port %5d: Contains HTTP/2 traffic (%d connections detected), which Postman cannot parse.\n", p, thisPort.HTTP2Prefaces)
140140
}
141141
continue
142142
}
@@ -158,7 +158,7 @@ func (s *Summary) printPortHighlights(top *client_telemetry.PacketCountSummary)
158158

159159
// If we saw HTTP/2, report it.
160160
if thisPort.HTTP2Prefaces > 0 {
161-
printer.Stderr.Infof("TCP port %5d: %5d packets (%d%% of total), no HTTP/1.1 requests or responses, %d HTTP/2 connection attempts. Akita cannot currently parse HTTP/2.\n",
161+
printer.Stderr.Infof("TCP port %5d: %5d packets (%d%% of total), no HTTP/1.1 requests or responses, %d HTTP/2 connection attempts. Postman cannot currently parse HTTP/2.\n",
162162
p, thisPort.TCPPackets, pct, thisPort.HTTP2Prefaces)
163163
continue
164164
}
@@ -170,7 +170,8 @@ func (s *Summary) printPortHighlights(top *client_telemetry.PacketCountSummary)
170170
}
171171

172172
// XXX(cns): Not all metrics can be associated with a host. We currently have
173-
// HTTP requests and TLS handshakes.
173+
//
174+
// HTTP requests and TLS handshakes.
174175
func (s *Summary) printHostHighlights(top *client_telemetry.PacketCountSummary) {
175176
// Sort by HTTP traffic volume, then TLS handshake counts, both descending.
176177
// We do not have TCP packet counts for hosts.
@@ -300,7 +301,7 @@ func (s *Summary) PrintWarnings() {
300301
s.PrefilterSummary.Total().HTTPRequests)
301302
}
302303
if env.InDocker() && env.HasDockerInternalHostAddress() {
303-
printer.Stderr.Infof("If you're using macOS and your service is not running in a Docker container, try using the native Akita agent with `brew install akita-cli`. See docs.akita.software/docs/macos-local for details.\n")
304+
printer.Stderr.Infof("If you're using macOS and your service is not running in a Docker container, try using the native Postman Live Collections Agent with `brew install postman-lc-agent`.\n")
304305
}
305306
printer.Stderr.Errorf("%s 🛑\n\n", printer.Color.Red("No HTTP calls captured!"))
306307
return

apispec/har.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ func ProcessHAR(col trace.Collector, p string) (int, error) {
3131
if errs.TotalCount > 0 {
3232
entriesCount := len(harContent.Log.Entries)
3333
printer.Stderr.Warningf("Encountered errors with %d HAR file entries.\n", entriesCount-successCount)
34-
printer.Stderr.Warningf("Akita will ignore entries with errors and generate a spec from the %d entries successfully processed.\n", successCount)
34+
printer.Stderr.Warningf("Postman Live Insights will ignore entries with errors and generate a spec from the %d entries successfully processed.\n", successCount)
3535

3636
printer.Stderr.Warningf("Sample errors:\n")
3737
for _, e := range errs.Samples {

cmd/internal/apidump/apidump.go

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -196,12 +196,14 @@ func init() {
196196
&outFlag,
197197
"out",
198198
"The location to store the trace. Can be an AkitaURI or a local directory. Defaults to a trace on the Akita Cloud. Exactly one of --out or --project must be specified.")
199+
Cmd.Flags().MarkDeprecated("out", "For use by Akita users")
199200

200201
Cmd.Flags().StringVar(
201202
&serviceFlag,
202203
"project",
203204
"",
204205
"Your Akita project. Exactly one of --out or --project must be specified.")
206+
Cmd.Flags().MarkDeprecated("project", "For use by Akita users")
205207

206208
Cmd.Flags().StringVar(
207209
&postmanCollectionID,
@@ -263,7 +265,7 @@ func init() {
263265
&appendByTagFlag,
264266
"append-by-tag",
265267
false,
266-
"Add to the most recent Akita trace with matching tag.")
268+
"Add to the most recent trace with matching tag.")
267269
Cmd.Flags().MarkDeprecated("append-by-tag", "and is no longer necessary. All traces in a project are now combined into a single model. Please remove this flag.")
268270

269271
Cmd.Flags().StringSliceVar(
@@ -314,7 +316,7 @@ func init() {
314316
&pluginsFlag,
315317
"plugins",
316318
nil,
317-
"Paths of third-party Akita plugins. They are executed in the order given.",
319+
"Paths of third-party plugins. They are executed in the order given.",
318320
)
319321
Cmd.Flags().MarkHidden("plugins")
320322

cmd/internal/cmderr/checks.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ func RequirePostmanAPICredentials(explanation string) (string, error) {
3535
if env.InDocker() {
3636
printer.Infof("Please set the POSTMAN_API_KEY environment variables on the Docker command line.\n")
3737
} else {
38-
printer.Infof("Use the POSTMAN_API_KEY environment variables, or run 'akita login'.\n")
38+
printer.Infof("Use the POSTMAN_API_KEY environment variables, or run 'postman-lc-agent login'.\n")
3939
}
4040

4141
return "", AkitaErr{Err: errors.New("could not find an Postman API key to use")}

cmd/internal/ecs/add.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ const (
9696
defaultKeyIDName = akitaSecretPrefix + "api_key_id"
9797
defaultKeySecretName = akitaSecretPrefix + "api_key_secret"
9898

99-
// Akita agent image locations
99+
// Postman Live Collections Agent image locations
100100
akitaECRImage = "public.ecr.aws/akitasoftware/akita-cli"
101101
akitaDockerImage = "akitasoftware/cli"
102102
postmanECRImage = "docker.postman.com/postman-lc-agent"
@@ -486,7 +486,7 @@ func getTaskState(wf *AddWorkflow) (nextState optionals.Optional[AddWorkflowStat
486486
err = survey.AskOne(
487487
&survey.Select{
488488
Message: "Which task should Akita monitor?",
489-
Help: "Select the ECS task definition to modify. We will add the Akita agent as a sidecar to the task.",
489+
Help: "Select the ECS task definition to modify. We will add the Postman Live Collections Agent as a sidecar to the task.",
490490
Options: tasks,
491491
},
492492
&taskAnswer,
@@ -668,7 +668,7 @@ func (wf *AddWorkflow) showPlannedChanges() {
668668
defaultKeySecretName, wf.awsRegion)
669669
}
670670
}
671-
printer.Infof("Create a new version %d of task definition %q which includes the Akita agent as a sidecar.\n",
671+
printer.Infof("Create a new version %d of task definition %q which includes the Postman Live Collections Agent as a sidecar.\n",
672672
wf.ecsTaskDefinition.Revision+1, wf.ecsTaskDefinitionFamily)
673673
printer.Infof("Update service %q in cluster %q to the new task definition.\n",
674674
wf.ecsService, wf.ecsCluster)

0 commit comments

Comments
 (0)