fix(cloudwatch): paginate log selectors - #7360
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
There was a problem hiding this comment.
No issues found across 7 files
Confidence score: 5/5
- Automated review surfaced no issues in the provided summaries.
- No files require special attention.
Heads up: you’re close to your included review allowance. Set a flex budget so reviews don’t pause.
Re-trigger cubic
Greptile SummaryThe PR adds cursor-backed pagination to the CloudWatch log-group and log-stream selectors while retaining the existing 20-request aggregation window.
Confidence Score: 5/5The PR appears safe to merge; no concrete blocking or independently actionable non-blocking issue was identified. The cursor remains bound to stable search and log-group context across pagination, the returned token points to the next unconsumed provider page, and the existing request bound, credentials handling, abort propagation, and cleanup behavior remain intact.
|
| Filename | Overview |
|---|---|
| apps/sim/lib/internal/cloudwatch/client.ts | Extends bounded log-stream enumeration to accept and return an opaque continuation token without changing ordering, filtering, abort handling, or request limits. |
| apps/sim/tools/cloudwatch/listing.ts | Propagates continuation tokens through shared log-group and log-stream listing results while retaining client cleanup and the 20-page bound. |
| apps/sim/lib/selectors/server/providers/cloudwatch.ts | Maps selector cursors to CloudWatch tokens and returns the final provider token as the next selector cursor. |
| apps/sim/lib/selectors/manifest.ts | Marks both CloudWatch resource selectors as paginated. |
| apps/sim/tools/cloudwatch/listing.test.ts | Covers opaque input tokens and continuation after the twentieth aggregated provider page. |
Sequence Diagram
sequenceDiagram
participant UI as CloudWatch selector
participant Adapter as Selector adapter
participant Listing as Bounded listing helper
participant AWS as AWS CloudWatch Logs
UI->>Adapter: list(search, cursor?)
Adapter->>Listing: prefix + nextToken
loop Up to 20 requests
Listing->>AWS: Describe request(nextToken)
AWS-->>Listing: items + nextToken?
end
Listing-->>Adapter: aggregated items + final nextToken?
Adapter-->>UI: items + nextCursor?
opt More results
UI->>Adapter: list(search, nextCursor)
end
Reviews (1): Last reviewed commit: "fix(cloudwatch): paginate log selectors" | Re-trigger Greptile
Summary
No linked issue.
Type of Change
Testing
Focused tests cover opaque cursor input/output through page 20, stream log-group and prefix binding, selector cursor mapping, and paginated manifests. Existing runtime operation and executor contract tests pass unchanged.
Live high-cardinality AWS validation was not run because this environment has no AWS credentials or region configured.
Checklist
Screenshots/Videos
Not applicable; no UI changes.