feat: support project aware logging in runtime - #2271
Open
nborges-aws wants to merge 2 commits into
Open
Conversation
Contributor
|
Claude Security Review: no high-confidence findings. (run) |
Contributor
There was a problem hiding this comment.
AgentCore Harness Review
Verdict: Looks good
Clean refactor + feature. Highlights I checked:
src/core/observability.tsis split intoobservability/{runtime,insights,client,traces,types}.ts, and the oldObservabilityClient.resolveDeployedRuntime+handlers/runtime/resolveRuntimeTarget.tsare deleted with no remaining callers (git grep resolveDeployedRuntime|resolveRuntimeTarget|DeployedRuntimeonpr2271is empty). TheCoreObservabilityClientinterface moved tocore/observability/types.tsand is re-exported fromcore/observability/index.ts, andTestObservabilityClientwas trimmed to match — no dangling references.- The deleted
observability.test.tscoverage is preserved:runInsightsQueryandsanitizeQueryValueincore/observability/insights.test.ts,runtimeLogGroupincore/observability/runtime.test.ts, andlistTraces/getTracebehavior viahandlers/runtime/traces/traces.test.tsx. project log runtimeuses the sameprojectManager.resolveDeployedResourceseam asproject invoke, and pins the region off the resolved target rather than the ambient one.selectProjectResourcewas extended with anoperationstring and moved up tohandlers/project/selection.ts, and both invoke callers pass "invoke" — no stale imports.- The new
handlers/project/log/runtime.test.tsxsticks to the recommended pattern (real tempdir +ProjectSpecSchema.parse+ fakeProjectBackendat the domain seam, no fs mocks). Telemetry is emitted by the router'scli.command_runfor all commands, so the new subtree is instrumented automatically.
Nothing needs to change before merge.
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## refactor #2271 +/- ##
============================================
- Coverage 97.04% 96.93% -0.12%
============================================
Files 566 567 +1
Lines 39353 39231 -122
============================================
- Hits 38190 38027 -163
- Misses 1163 1204 +41 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
nborges-aws
force-pushed
the
project-logs
branch
from
September 10, 2026 19:06
3201f55 to
b8b8877
Compare
nborges-aws
added this pull request to stack #2274
September 10, 2026 19:06
Contributor
|
Claude Security Review: no high-confidence findings. (run) |
16 tasks
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
Adds project-scoped Runtime logging commands.
The command resolves a runtime from the current project into its deployed id and target region. The rest is delegated to the existing observability log search/tail implementation. Projects with only one configured runtime can omit
--name; projects with multiple runtimes are required to select one explicitly.This PR also makes the following updates to observability:
CoreObservabilityClientfrom runtime handler types into observabilityType of Change
Testing
How have you tested the change?
bun run test(3169 pass, 0 fail)npm run test:unitandnpm run test:integnpm run typechecknpm run lintsrc/assets/, I rannpm run test:update-snapshotsand committed the updated snapshotsChecklist
By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the
terms of your choice.