Repository navigation
fix(#756): answer ACM's DescribeCertificate through a projection, with dates as epoch seconds - #1354
Merged
Merged
Conversation
…h dates as epoch seconds describeCertificate handed the persisted ACMCertificate to the caller, so a consumer read AccountID, Region and ever_tagged, plus Tags, which API_CertificateDetail does not publish. It also rendered CreatedAt, IssuedAt, NotAfter and NotBefore as RFC3339 strings where awsJson1_1 publishes numbers (#1305), so a typed SDK could not decode it. It now answers emulator/acm_wire.go's acmCertificateOut with EpochSeconds dates. The stored record is unchanged. The projection's published CreatedAt joins check-wire-bookkeeping's exclusion list beside the record's. Two tests pinned the RFC3339 form: acm_plugin_test.go decoded into the stored record type, and the plugin time-controller test expected a quoted CreatedAt. Both now read the published shape. emulator/acm_wire_test.go drives all eight routed operations, tags the certificate first, and pins the dates on a frozen clock. check-wire-bookkeeping goes from 261 projected across 108 records to 264 across 109, and from 49 still reachable to 46. #756 and #1305 stay open: Redshift Data and Firehose remain in #1305.
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
This was referenced Oct 3, 2026
scttfrdmn
added a commit
that referenced
this pull request
Oct 3, 2026
…tion, with CreateTimestamp as epoch seconds (#1362) DescribeDeliveryStream answered FirehoseDeliveryStream whole: AccountId and Region, which API_DeliveryStreamDescription does not publish (#756), and Tags, which it does not publish either. It also answered CreateTimestamp as an RFC3339 string, which an awsJson1_1 SDK cannot decode (#1305). The new emulator/firehose_wire.go answers the five published members the record models, with the date as EpochSeconds. The stored record is unchanged. emulator/firehose_wire_test.go walks all six routed operations and pins CreateTimestamp as a number; firehose_plugin_test.go decodes the published shape rather than the record. check-wire-bookkeeping's #1305 note now records all three services as fixed. ACM was fixed by #1354, and Redshift Data already rendered numbers, as #1358's test pins. check-wire-bookkeeping goes from 290 projected across 124 records to 292 across 125, and from 20 still reachable to 18. Fixes #1305 #756 stays open.
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.
This is the seventh of ten PRs in #756's 3-line block, and the first of its four fixes. It also lands
#1305's ACM row.
The two defects at one site
describeCertificateansweredresponse{Certificate: ACMCertificate}, the persisted record:AccountID,Regionandever_tagged, plusTags. I verifiedtoday that
API_CertificateDetailpublishes noTags: a certificate's tags are read throughListTagsForCertificate.CreatedAt,IssuedAt,NotAfterandNotBeforerendered as RFC3339.CertificateDetailtypes all four asTimestampunderawsJson1_1, so a typed SDK could notdecode
DescribeCertificate.It now answers
acmCertificateOutfrom the newemulator/acm_wire.go, which has ten of the publishedmembers, with
EpochSecondsdates. The record sets all four dates on every certificate, and it is theonly writer, so none renders as
null. The stored record is unchanged.ListCertificatesalreadyanswered a three-member summary.
Two tests had pinned the defect
emulator/acm_plugin_test.godecoded the response intoemulator.ACMCertificate. Itstime.Timedates accepted the RFC3339 strings a real SDK rejects. It failed withcannot unmarshal number into … time.Timeonce the projection rendered numbers, and it now decodesthe published members.
TestPluginTimeController_EveryDefaultRegistrationCarriesTheSimulatedClockexpected ACM'sCreatedAtas a quoted RFC3339 string, while its ECR and ECS cases beside it already expect epochseconds for the same protocol. The ACM case now matches them. The API Gateway cases in the same test
still expect RFC3339, which is a separate question and not touched here.
The check's exclusion list
acmCertificateOut.CreatedAtis a published member whose Go name matches a bookkeeping field, so thecheck flagged it as new. It joins the exclusion list beside
ACMCertificate.CreatedAt, which is theecs_wire.gocase again: a projection carries every published member, so building one adds an entryof this kind. The list's header now says that ACM renders correctly, and that Redshift Data and
Firehose are what remain of #1305.
shellcheckis clean.The citation
emulator/acm_wire_test.godrives all eight routed operations:ever_taggedback first.Certificateto carry noTags.CreatedAt/IssuedAt/NotBeforeat1700000000.000, andNotAfteras alater number.
Negative controls (each run, then restored)
describeCertificatereverted to the record fails exactly/DescribeCertificate. It names$.Certificate.AccountID,.Regionand.ever_tagged, so the tag write is not vacuous.CreatedAtback totime.Timefails the epoch assertion.The ratchet
Verification
All of these pass:
make lint: 0 issues.make test: race,-count=1.docs-reference-check docs-versions version-check discarded-unmarshal-check wire-bookkeeping-check operation-catalog-check operation-docs-check.#756 and #1305 stay open. Redshift Data and Firehose remain in #1305, and it gets a comment once
this merges.