feat: enable CloudWatch Transaction Search on deploy#512
Open
jesseturner21 wants to merge 9 commits intomainfrom
Open
feat: enable CloudWatch Transaction Search on deploy#512jesseturner21 wants to merge 9 commits intomainfrom
jesseturner21 wants to merge 9 commits intomainfrom
Conversation
After a successful deploy with agents, the CLI now checks if CloudWatch Application Signals (which powers Transaction Search) is enabled and auto-enables it via StartDiscovery when --yes is passed. A console URL is added to the next-steps output so users can view traces immediately. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Enable transaction search silently on every deploy (no confirmation needed)
- Full setup: Application Signals, CW Logs resource policy, CloudWatchLogs
destination, 100% indexing
- All operations are idempotent
- Add opt-out via ~/.agentcore/config.json: { "disableTransactionSearch": true }
- Remove visible deploy step — runs silently, warnings logged if setup fails
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…l rules The Default rule always exists — no need to list and loop. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…pt true Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
The trace link is already shown after invoke where it's actually useful. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
… transaction-search Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
After a successful deploy with agents, the CLI automatically enables CloudWatch Transaction Search in the target region. This sets up the full observability pipeline: Application Signals discovery, CloudWatch Logs resource policy for X-Ray, trace segment destination to CloudWatchLogs, and configurable indexing percentage (default 100%).
All operations are idempotent and safe to run on every deploy. The setup is non-blocking — failures are logged as warnings and never fail the deploy.
Configuration via
~/.agentcore/config.json:{ "disableTransactionSearch": true }{ "transactionSearchIndexingPercentage": 50 }Changes
src/cli/aws/transaction-search.ts— AWS client wrapper for Application SignalsStartDiscovery, CloudWatch Logs resource policy, X-Ray trace destination, and indexing rule configurationsrc/cli/operations/deploy/post-deploy-observability.ts— orchestration for the post-deploy transaction search setup with config-based opt-out and indexing percentagesrc/cli/aws/__tests__/transaction-search.test.ts— unit tests forenableTransactionSearchsrc/cli/operations/deploy/__tests__/post-deploy-observability.test.ts— unit tests forsetupTransactionSearchsrc/cli/commands/deploy/actions.ts— integrated post-deploy step (CLI path)src/cli/tui/screens/deploy/useDeployFlow.ts— integrated post-deploy step (TUI path)src/lib/schemas/io/cli-config.ts— addeddisableTransactionSearchandtransactionSearchIndexingPercentageconfig optionspackage.json— added@aws-sdk/client-application-signalsand@aws-sdk/client-xrayRelated Issue
Closes #
Documentation PR
N/A
Type of Change
Testing
How have you tested the change?
npm run test:unitandnpm run test:integnpm run typechecknpm run lintsrc/assets/, I rannpm run test:update-snapshotsand committed the updated snapshotsE2E verified on account 252624323091 (us-west-2): full deploy with Strands agent confirmed all four Transaction Search components enabled (Application Signals, resource policy, CloudWatchLogs destination, 100% indexing).
Checklist
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the
terms of your choice.