fix(cloudwatch): resolve selector credentials server-side - #7116
fix(cloudwatch): resolve selector credentials server-side#7116BillLeoutsakosvl346 wants to merge 1 commit into
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
ad5a672 to
0b8f18c
Compare
dd2f55c to
d53e574
Compare
fafded6 to
0486f57
Compare
d53e574 to
fdcd9e5
Compare
0486f57 to
17726cb
Compare
fdcd9e5 to
dabf11a
Compare
Greptile SummaryThe PR adds dedicated authenticated CloudWatch selector routes that resolve AWS configuration server-side and return name-only responses while preserving the existing runtime route contract.
Confidence Score: 5/5The PR appears safe to merge after its documented prerequisite branch is landed and the stack is rebased. The new selector paths authenticate and authorize workflow scope before resolving AWS configuration, validate resolved values before provider access, isolate caches through shared workflow and opaque dependency scopes, return only names, and preserve existing runtime pagination and response behavior.
|
| Filename | Overview |
|---|---|
| apps/sim/app/api/tools/cloudwatch/selector-log-groups/route.ts | Adds an authenticated, workflow-authorized selector endpoint that validates resolved AWS configuration, lists groups, returns names only, and destroys the client. |
| apps/sim/app/api/tools/cloudwatch/selector-log-streams/route.ts | Adds the corresponding scoped log-stream selector endpoint with strict output mapping and client cleanup. |
| apps/sim/app/api/tools/cloudwatch/utils.ts | Extracts the existing bounded log-group pagination and normalization behavior without changing the runtime response contract. |
| apps/sim/hooks/selectors/providers/cloudwatch/selectors.ts | Moves both selectors to server-resolved contracts and privacy-preserving scoped cache keys while requiring workflow context. |
| apps/sim/lib/api/contracts/selectors/cloudwatch.ts | Separates reference-friendly selector request schemas from resolved AWS validation and introduces strict name-only response contracts. |
Sequence Diagram
sequenceDiagram
participant UI as CloudWatch selector
participant Route as Selector API route
participant Auth as Authorized context resolver
participant AWS as CloudWatch Logs
UI->>Route: workflowId + literals/opaque references
Route->>Auth: principal + workflow scope + context
Auth-->>Route: authorized resolved AWS configuration
Route->>AWS: Describe log groups/streams
AWS-->>Route: provider records
Route-->>UI: strict name-only options
Reviews (1): Last reviewed commit: "fix(cloudwatch): resolve selector creden..." | Re-trigger Greptile
17726cb to
aeaa7ec
Compare
dabf11a to
50811d9
Compare
50811d9 to
2e55a45
Compare
Summary
Security behavior
{{KEY}}refetches without exposing its value.Focused coverage
Verification
git diff --checkpassed on the combined stack.Browser verification