Repository navigation
Conversation
cavanaug
marked this pull request as ready for review
October 20, 2026 06:56
Share record-data validation across both public PUT APIs and cover request-wide rejection without quota consumption. Restore delivery documentation, share throughput error text, and clarify status codes and quota behavior in the service docs.
Contributor
Author
|
Ok, this is now ready for merge after owner approval. |
This branch has not been deployed
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.
Summary
Adds opt-in Direct PUT throughput quotas to Firehose. The functional revisions
listed in the prior PR description and Cubic summary are implemented:
both an explicit account/region applied value and an enabled enforcement switch;
AWS defaults alone never throttle (
auto_scaling_defaultin introspection).PutRecordandPutRecordBatchshare per-stream-instance request,record, and decoded-byte accounting, resolved through one batched quota lookup
before taking Firehose locks. Internal Logs/SES/decoded handoffs stay unmetered.
excess forward into later one-second windows, without idle credits. Debt is
calculated from its last charge, so rejected retries cannot change fractional
recovery timing; the review-found decimal-rate bug has a RED/GREEN regression.
ServiceUnavailableException, messageSlow down.. Record/byte exhaustionreturns ordered HTTP 200 batch-entry failures and
FailedPutCount;PutRecorduses the same whole-call error for its rejected record.
SerializationException, before quota consumption or buffering.retention, and shutdown behavior. Applied values/account overrides persist;
usage and burst debt do not.
Firehose/Service Quotas documentation. SDK tests cover partial acceptance,
explicit failed-entry resubmission, default-limit bypass, decoded-byte charging,
SDK retries, and independently enforced same-name streams in two accounts.
The one-second accounting, burst carry-over, and dimension-to-error mapping are
local testing policies, not claims about AWS's unpublished throttling algorithm.
Skipping default limits is a local convenience, not a simulation of AWS scaling
latency. No live AWS load experiment was performed.
Post-review follow-up —
71d42171bAddresses the latest completeness, accuracy, and engineering review in one
follow-up commit, without rewriting the existing branch history:
Missing/null
Datareturns HTTP 400InvalidArgumentException; wrong-typedata or malformed base64 returns HTTP 400
SerializationException.batch entry. Rejected requests admit nothing and leave request, record, and
decoded-byte capacity available to a subsequent valid request. The existing
record/batch size limits and empty-record behavior are preserved.
stream_deliveryinvariant comment and shares throttle errorcode/message constants between whole-call and batch-entry responses.
vendored-model HTTP 503 discrepancy. Throttling remains HTTP 500; closed
admission during local shutdown remains HTTP 503 with its distinct message.
pages, and agent guidance for explicit auto-scaling quota values and regional
defaults. Documents the malformed-batch compatibility change and cross-service
lazy template timing; provider behavior itself is unchanged.
Follow-up verification
passed (710 total). These are fresh follow-up results; the earlier SDK and
conformance results below are historical and were not rerun in this follow-up.
firehose14 andfirehose_throughput11(25 total), against the rebuilt server. Official SDKs exercise supported
calls; malformed inputs are exercised through the raw JSON endpoint.
cargo clippy --workspace --all-targets -- -D warnings, formatting,documentation-count checks, and whitespace checks passed. Cargo still reports
the existing
proc-macro-error2future-incompatibility notice.important, or minor findings.
cargo test --workspaceis not green: it stopped at the sameunchanged API Gateway test already documented below,
data_plane::tests::vpc_link_proxy_resolves_target_nlb_and_attempts_connection.It received HTTP 504 instead of 502 after approximately 29 seconds.
Because this run was fail-fast, the remaining workspace suites did not run.
No unrelated assertions were relaxed and no tests were skipped to hide this.
This follow-up is not a claim that the complete workspace suite or required
CI/Cubic checks are green, and no merge was performed.
Verification before follow-up (
4d4014bea)Targeted unit suites: core 444, Firehose 189, Rust SDK 4, and Service
Quotas 76 passed (713 total, also passing with normal test concurrency),
including deterministic burst repayment,
concurrent admission, account/region/stream isolation, batched provider locking,
default bypass, reset/restore, internal handoffs and validation precedence.
Workspace Clippy with all targets and
-D warnings, formatting and whitespacechecks passed. The dependency
proc-macro-error2emits an existing Cargofuture-incompatibility notice, not a Clippy failure.
Conformance harness unit tests: 107 passed; official SDK Firehose conformance
integration tests: 6 passed.
TypeScript type-check and 13 Service Quotas client tests passed; Go vet passed.
Website: Zola 0.22.1 built 185 pages and 10 sections; documentation-count checks
passed.
A fresh final
cargo build --bin fakecloudpassed, followed by Firehose Smithyconformance against that rebuilt server: 416/416 variants, all 12 operations,
zero failures and crashes.
Independent review identified the fractional-retry bug described above; its
re-review confirms the fix and reports no remaining blocking findings.
Official AWS SDK E2E against the rebuilt final server: 87 passed across
firehose,firehose_throughput(11),servicequotas,firehose_buffering,firehose_persistence,firehose_gzip,firehose_snappy,firehose_compression_validation, andses_firehose_events.Complete workspace unit/doc-test run in CI scope with
--no-fail-fast:12,138 passed, 1 failed, 0 ignored, across 237 test/doc-test groups. The
single failure is the unchanged API Gateway test detailed below. This is not a
passing workspace suite.
Commands used for the major gates:
Workspace validation limitation
The workspace unit command (CI scope, excluding
fakecloud-e2e,fakecloud-conformance,fakecloud-tfacc, andfakecloud-parity) is not green.The unchanged API Gateway test
data_plane::tests::vpc_link_proxy_resolves_target_nlb_and_attempts_connectionexpects HTTP 502 for a connection refusal on localhost port 54321, but receives
HTTP 504 after its 29-second timeout in this environment. It reproduces alone,
including with proxy variables removed. No listener exists on that port, yet a
direct local connection also times out rather than refusing. This is outside the
Firehose change; no assertions were relaxed, tests skipped, or unrelated code
changed to manufacture a passing workspace result. Do not treat this PR as
merge-ready until required CI and Cubic checks are green.
Automated review status
Cubic's check for signed commit
4d4014bea5a9c0e760ec9a5847bc96ca1dd6a57bcompleted neutral, not an approval: the team's monthly review line limit has
been reached, so Cubic did not perform a fresh review. The independent code
review and re-review described above completed locally; they do not replace the
required Cubic check for merging.