mirror of
https://github.com/floci-io/floci.git
synced 2026-11-23 06:00:46 -05:00
7dc514b52f2c96bdd1ea32ae64a02703f85be2aa
39
Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
eb0472fccc |
docs: fix stale image tags, release model, service nav and contributor checklists (#2980)
The getting-started and contributor docs had drifted from what the workflows and the code actually do: - quick-start and CONTRIBUTING pointed users at a `latest-jvm` image that the release pipeline never publishes; both now name the `-compat` image, and `make docs-check` greps the docs for any `-jvm` tag - the CONTRIBUTING branching model now matches the workflows: `main` is published as the nightly channel, a maintainer runs the Release Cut workflow to tag a release, and the tag triggers the publish; PR builds produce compat images but never publish them - README and the docs landing page carried a hand-maintained service count and a second copy of the service table, both stale; they now link to the Services Overview - the Service Matrix gains the ELB Classic row it was missing, with an `elb` alias so the check no longer resolves the Classic key to the v2 page, and check_service_matrix.py now also fails on a docs/services page that has no row - the README category table lists 16 documented services it omitted - mkdocs nav gains 11 service pages that were unreachable from the site, drops a duplicate CloudTrail entry, and the docs job now runs `mkdocs build --strict` with nav and link validation so a page without a nav entry fails CI - AGENTS.md, CONTRIBUTING.md and docs/contributing.md told contributors to register a service in ServiceRegistry, which has no registration API; all three now point at ResolvedServiceCatalog and list the config, storage, native-image, docs, tooling and compat-suite touchpoints a new service needs |
||
|
|
10192f05d5 |
feat(translate): add Amazon Translate mock service (#2879)
* feat(translate): add Amazon Translate mock service JSON 1.1 stub for Amazon Translate covering the three self-contained sync operations: TranslateText, TranslateDocument, ListLanguages. Follows the existing Comprehend/Textract stub pattern (stateless, echoes input, AI_MOCK_CONFIG override for TranslateText). - TranslateText echoes Text, enforces the 10,000-byte limit, allows any language pair; an auto source is reported back as en. - TranslateDocument echoes the base64 Content and enforces the English-pivot rule, the ContentType allow-list, valid base64, and the 100 KB cap (InvalidRequestException, matching the operation's error model). The encoded length is checked before decoding so an oversized payload cannot force a large allocation. - ListLanguages returns a fixed ~35-language catalog; DisplayLanguageCode is validated, pagination inputs are accepted but ignored. Untrusted request values are truncated before being echoed into error messages. * chore(translate): remove em-dashes per AGENTS.md style guide Replace em-dashes in the Translate doc page and Java comments with colons, commas, or periods, and the ellipsis in the error-message preview helper with "...". Addresses the Greptile review note on PR #2879. |
||
|
|
cf6fede453 |
feat(rekognition): add Amazon Rekognition sync image-analysis actions (#2706)
* feat(rekognition): add Amazon Rekognition sync image-analysis actions Implements DetectLabels, DetectFaces, DetectText, CompareFaces, and DetectModerationLabels as fixed AWS-shaped stub responses over the real JSON 1.1 wire protocol (X-Amz-Target: RekognitionService.*). Image/SourceImage/TargetImage input is required and validated (must specify Bytes or S3Object) but never decoded, matching the pattern already used for Textract's Document input. Content-listing operations (DetectLabels, DetectText) always return one canned entry, matching TextractService's stub precedent. Face and moderation operations (DetectFaces, CompareFaces, DetectModerationLabels) return empty results by default rather than fabricating biometric attributes or a moderation flag for content that was never analyzed, matching ComprehendService's PII-detection precedent. Face-collection persistence, custom-model training, live video (StreamProcessor), async video jobs, and Face Liveness sessions are out of scope for this PR. Closes #2705 * fix(rekognition): reject wrong-typed Bytes/S3Object as SerializationException requireImage() only checked field presence via hasNonNull(), so a wrong-typed Bytes (e.g. a number) or S3Object (e.g. a string) was silently accepted instead of rejected, same class of bug as the Comprehend Text/LanguageCode type-coercion fix. Bytes must now be textual and S3Object must be an object when present, both rejected as SerializationException (a shape/marshalling mismatch) otherwise. Content-level validation (well-formed base64 in Bytes, S3Object's Bucket/Name presence, rejecting both Bytes and S3Object together) is intentionally not added: S3Object has no required members in AWS's own model, and nothing in the model declares supplying both fields invalid — documented as intentional deviations. Addresses review feedback on #2706. |
||
|
|
5c1b69c45f |
feat(comprehend): add Amazon Comprehend sync text-analysis actions (#2674)
* feat(comprehend): add Amazon Comprehend sync text-analysis actions Implements DetectSentiment, DetectKeyPhrases, DetectDominantLanguage, DetectPiiEntities, and ContainsPiiEntities as fixed AWS-shaped stub responses over the real JSON 1.1 wire protocol (X-Amz-Target: Comprehend_20171127.*). Input validation (Text and LanguageCode required, LanguageCode checked against Comprehend's supported set) matches real API behavior and raises InvalidRequestException/UnsupportedLanguageException per botocore's declared error shapes. The async job/model-training surface (DocumentClassifier, EntityRecognizer, Flywheel, Dataset, Endpoint) and DetectEntities/ DetectSyntax are out of scope for this PR. Real (non-stub) detection logic is planned as a follow-up once this lands. Closes #2660 * fix(comprehend): restrict PII detection to en/es language codes DetectPiiEntities and ContainsPiiEntities were validated against the full 12-language set shared with DetectSentiment/DetectKeyPhrases, but AWS's own operation docs for DetectPiiEntitiesRequest.LanguageCode state PII detection only supports English (en) and Spanish (es). Split the allowlist so the two PII operations reject other languages with UnsupportedLanguageException, matching real Comprehend behavior. Addresses review feedback on #2674. * fix(comprehend): reject non-string Text/LanguageCode as SerializationException getStringField() coerced any JSON value via asText() instead of enforcing the modeled string type, so a numeric or boolean Text/ LanguageCode silently succeeded instead of being rejected. Reuses the codebase's existing SerializationException convention (see JsonErrorResponseUtils.createSerializationErrorResponse()) since a wrong-typed field is a shape/marshalling mismatch caught before business logic runs, distinct from a missing field (InvalidRequestException, a modeled business error). Scoped to ComprehendJsonHandler only. Addresses review feedback on #2674. |
||
|
|
d60bd6ead2 |
feat(route53resolver): add Route 53 Resolver with DNS Firewall domain lists (#2582)
* feat(route53resolver): AWS-managed DNS Firewall domain lists
New JSON 1.1 service exposing ListFirewallDomainLists with the four
AWS-managed domain lists, deterministic ids stable across restarts.
LZA's NetworkPrepStack Custom::ResolverManagedDomainList Lambda resolves
managed list ids by name and previously failed with UnknownOperation.
* feat(route53resolver): full-parity build-out (16 ops)
Adds firewall domain list CRUD, resolver endpoint CRUD, resolver rule
CRUD, and rule-association management, backed by four new
StorageBackend stores. The pre-existing deterministic AWS-managed
domain list logic (AWS_MANAGED_DOMAIN_LIST_NAMES, managedList(),
FirewallDomainList) is untouched -- LZA's bootstrap Lambda depends on
those ids being stable across calls.
Also fixes the JSON-1.1 dispatch case in AwsJson11Controller to pass
the account id through to the handler, matching every other service's
dispatch signature (route53resolver was the one holdout still calling
handle() with the old 3-arg signature).
* fix(config): declare route53resolver enabled toggle in both application.yml files
Upstream's ServiceConfigYamlCoverageTest requires every service config with an
enabled() toggle to declare it explicitly in both files; this branch predates
that test and fails it without the declaration.
* docs(route53resolver): register the generated action table
* fix(route53resolver): declare storageKey and storageMode on the service descriptor
The service persists four stores through StorageFactory, but its catalog
descriptor left storageKey and storageMode null, so it was invisible to
PersistentPathValidator's boot check and to per-service storage config
resolution. Mirror the organizations descriptor.
* fix(route53resolver): make creates idempotent on CreatorRequestId
CreateFirewallDomainList, CreateResolverEndpoint and CreateResolverRule
allocated a new resource on every call, so an LZA/CloudFormation retry of
the same CreatorRequestId left duplicates behind. Real AWS returns the
resource the token originally created. Dedupe per store, after the
operation's own validation so a replayed token cannot excuse a malformed
body; a blank or absent token still allocates.
* fix(route53resolver): give outbound resolver endpoints rslvr-out ids
Every CreateResolverEndpoint allocated an inbound-style rslvr-in- id
regardless of Direction, so an outbound endpoint carried an id AWS would
never issue. Key the prefix off Direction (INBOUND/INBOUND_DELEGATION ->
rslvr-in, OUTBOUND -> rslvr-out) and reject values outside the
ResolverEndpointDirection enum instead of silently defaulting to inbound.
* test(route53resolver): assert managed domain lists by name, not by count
ListFirewallDomainLists returns the four managed lists plus whatever
custom lists other tests in the run have created, so size()==4 and the
[0] index extraction were both order-dependent. Assert the four managed
names are present and pick the id by name. Also drop the call-site counts
from the 404-convention comment, which would go stale on any refactor.
* docs(route53resolver): correct the scoping limitation
The limitation claimed resources are visible regardless of the caller's
account. They are not: all four stores are created through StorageFactory,
which wraps every backend in AccountAwareStorageBackend, so keys are
prefixed with the calling credential's account id and both scan() and
keys() filter on that prefix. Region and VPC are what go unenforced, and
the AWS-managed lists are region-derived and globally visible by design.
* fix(route53resolver): validate Direction before the CreatorRequestId replay check
endpointIdPrefix ran only on the allocation path, so replaying a known
CreatorRequestId with an unrecognised Direction returned 200 and the
original endpoint instead of InvalidParametersException. Bind the prefix
right after the Direction is read, so every request is validated whether
or not it turns out to be a replay.
* fix(route53resolver): enforce the RuleType and ResolverEndpointType enums
CreateResolverRule stored any RuleType string it was given and UpdateResolverEndpoint
copied any ResolverEndpointType through, so Get/ListResolverRules and
GetResolverEndpoint reported values outside botocore's RuleTypeOption
(FORWARD/SYSTEM/RECURSIVE/DELEGATE) and ResolverEndpointType (IPV6/IPV4/DUALSTACK).
Both now reject with the same InvalidParametersException the Direction check uses.
* fix(route53resolver): reject an empty TargetIps list
The model pins TargetIps to list min 1; a present-but-empty array was
stored verbatim. Absent stays allowed for SYSTEM rules. Found by the
botocore-grounded review pipeline; the hand audit missed it.
* fix(route53resolver): make the CreatorRequestId replay check atomic
Two overlapping create retries with the same token could both pass the
replay scan before either put, persisting two resources with different
ids. The three create methods are now synchronized, making the
scan-then-put pair atomic on this ApplicationScoped singleton.
* fix(route53resolver): scope the CreatorRequestId replay to the request's region
replayOf matched purely on CreatorRequestId content across the whole
account-partitioned store, which carries no region in its keys. The same
account replaying a token in a second region got the first region's
resource and ARN back instead of the regional resource it asked for.
Route 53 Resolver is regional, so a token identifies one resource per
region: match the candidate's region too, taken from the ARN this service
builds rather than a stored field, so nothing new reaches the wire.
Also folds the two stacked javadoc blocks above replayOf into one; the
second was shadowing the first, which left the idempotency contract out
of the generated docs.
* docs: correct service count to 79 after the #2579 merge
The upstream/main merge (
|
||
|
|
715bab68e7 |
feat(networkfirewall): emulate AWS Network Firewall (#2580)
* feat: emulate AWS Network Firewall
* docs: register Network Firewall service
* feat(networkfirewall): add AssociateFirewallPolicy
Sets FirewallPolicyArn on the stored firewall, validating that both the
firewall and the policy exist. Round-trip covered by an integration test
(create -> associate -> describe shows the new policy ARN).
FirewallPolicyChangeProtection is not enforced; documented as a limitation.
* docs(networkfirewall): register the generated action table
* docs(networkfirewall): correct the service matrix protocol and action count
The Network Firewall row claimed JSON 1.1 with 25 actions; the service speaks
x-amz-json-1.0 and the generated action table lists 27.
* test(networkfirewall): assert list membership instead of positional indexes
hasSize(1) and [0] assertions coupled these tests to JUnit's method order and
to being the only resource in the store.
* fix(networkfirewall): declare the storage key and mode in the service catalog
The service persists four backends through StorageFactory, but its descriptor
left storageKey and storageMode null, so it was skipped by PersistentPathValidator
and by per-service storage configuration.
* fix(networkfirewall): reject DeleteFirewall when delete protection is enabled
AWS raises InvalidOperationException rather than deleting a protected firewall;
the emulator deleted it regardless of the flag it had already stored.
* fix(networkfirewall): give the subnet and AZ association ops real semantics
All four routed through updateFirewall, which copies request fields onto the
stored firewall wholesale. That ignored SubnetChangeProtection and
AvailabilityZoneChangeProtection, and a Disassociate call left the mappings it
was meant to remove in place. Associate now adds deduplicated mappings,
Disassociate removes the named ones, and either is rejected with
InvalidOperationException while the matching change protection is set.
DescribeFirewall only synthesises endpoints for a firewall created without
SubnetMappings, so draining every subnet now reports no sync states.
* fix(networkfirewall): name the resource kind in ResourceAlreadyExistsException
createNamed passed the response wrapper field, so a duplicate create reported
"RuleGroupResponse already exists" instead of "RuleGroup already exists".
* fix(networkfirewall): validate association requests before touching the firewall
mappingsOf() creates the mappings array on the live stored node, so it ran
before the request array was validated: a rejected DisassociateSubnets on a
firewall created without SubnetMappings left an empty array behind and
permanently suppressed the synthetic sync states in DescribeFirewall.
* fix(networkfirewall): name the resource kind in ResourceNotFoundException
describeNamed passed the response wrapper field as the kind, so a miss reported
"RuleGroupResponse not found". Same defect as the create path; the now-unused
responseField parameter goes with it.
* fix(networkfirewall): return the deleted firewall and its status from DeleteFirewall
AWS responds with {Firewall, FirewallStatus}; the emulator returned only the ARN
and name, so an SDK client parsed an empty response. The handler already had the
region in scope, so no controller change was needed.
* fix(networkfirewall): enforce modeled enums on rule group Type and logging config
Three modeled enums were read and stored without being checked.
CreateRuleGroup/UpdateRuleGroup Type: the model enumerates STATELESS, STATEFUL
and STATEFUL_DOMAIN. The prefix choice was a two-way branch, so every unmodelled
value (including a lowercase "stateful") silently fell through to the
stateful-rulegroup ARN and was persisted as a rule group AWS would have
rejected. The branch keeps its meaning deliberately: only STATELESS gets the
stateless prefix, and both stateful variants share stateful-rulegroup, matching
AWS. A test pins STATEFUL_DOMAIN to that prefix so the mapping is no longer
implicit.
UpdateLoggingConfiguration LogType (ALERT/FLOW/TLS) and LogDestinationType
(S3/CloudWatchLogs/KinesisDataFirehose): the LoggingConfiguration is stored
verbatim, so an unmodelled or wrongly-cased value was persisted and echoed back
by DescribeLoggingConfiguration. Enforced case-sensitively, as the model spells
them and as LZA's network-firewall construct sends them.
Rejections use InvalidRequestException, which both operations list.
* fix(networkfirewall): validate association requests before mutating stored mappings
mappingsOf handed back the live stored array (or installed one), so a
request with a valid mapping followed by an invalid one mutated the
firewall before the rejection. The mappings are now a detached copy,
validated in full, and attached only when storeAndRespond commits.
* fix(networkfirewall): whitelist mutable fields on the shared UpdateFirewall* path
The generic update loop copied every raw request field onto the stored
firewall, so an UpdateFirewallDescription request carrying SubnetMappings
or AvailabilityZoneMappings persisted them without the change-protection
checks the Associate/Disassociate ops enforce. The loop now copies only
the union of fields the six UpdateFirewall* operations actually model
(Description, the four protection flags, EnabledAnalysisTypes), matching
AWS dropping unmodeled request members.
* fix(networkfirewall): scope UpdateFirewall* to the invoked op's own field
The shared updateFirewall path copied any field present in the raw
request that appeared in the union of all UpdateFirewall* mutable
fields, regardless of which specific action was invoked. A plain
UpdateFirewallDescription request could therefore smuggle
DeleteProtection (or any other operation's field) past its own
dedicated operation and change-protection checks.
Each UpdateFirewall* operation models exactly one mutable field
(botocore 2020-11-12); replace the shared whitelist with a per-action
field map so a request only ever mutates the field its own action
models.
* fix(networkfirewall): default DeleteProtection/SubnetChangeProtection/FirewallPolicyChangeProtection to true
botocore's network-firewall 2020-11-12 model documents CreateFirewall as
initializing these three flags to TRUE when the caller omits them;
AvailabilityZoneChangeProtection is the lone exception, documented as
defaulting to FALSE (already correct). Floci defaulted all four to false,
so the enforcement code in firewallForChange/deleteFirewall was correct
but unreachable in the common case of an SDK/Terraform caller that omits
the flags entirely.
RED-first: createFirewall_withoutProtectionFlags_defaultsToProtected
failed against the old defaults (DeleteProtection false, expected true).
Existing tests that relied on the old false default to exercise
mutation paths now pass explicit false for the flags they don't intend
to test, matching how a real caller opts out of protection.
NetworkFirewallIntegrationTest: 27/27 green.
* fix(networkfirewall): flatten UpdateFirewall* response to the modelled shape
All six UpdateFirewall* operations shared updateFirewall(), which returned
firewallResponse()'s nested {Firewall, FirewallStatus} envelope -- the
CreateFirewall/DescribeFirewall shape. botocore 2020-11-12 models each
UpdateFirewall*Response as a flat {FirewallArn, FirewallName, <field>,
UpdateToken}, confirmed for all six ops (UpdateFirewallDescription,
UpdateFirewallDeleteProtection, UpdateSubnetChangeProtection,
UpdateFirewallPolicyChangeProtection, UpdateAvailabilityZoneChangeProtection,
UpdateFirewallAnalysisSettings). A typed SDK client got null back from every
modelled accessor.
RED-first: updateFirewallDeleteProtection_returnsTheFlatModelledShape failed
(FirewallArn/DeleteProtection/UpdateToken were all null at the top level;
present one level down inside Firewall). CreateFirewall/DescribeFirewall
still use firewallResponse() and are unaffected -- only the six Update*
callers changed. NetworkFirewallIntegrationTest: 28/28 green.
* fix(networkfirewall): omit optional update fields instead of echoing null
UpdateFirewallDescription and UpdateFirewallAnalysisSettings read the response
member back with path(), so a firewall created without Description or
EnabledAnalysisTypes serialised the resulting MissingNode as an explicit null.
Both members are optional on these ops (botocore 2020-11-12 marks no required
members on either), so the response now omits what was never set.
* docs: correct service count to 79 after the #2579 merge
The upstream/main merge (
|
||
|
|
2e843e9f23 |
feat(servicecatalog): emulate AWS Service Catalog with Control Tower Account Factory (#2585)
* feat: emulate AWS Service Catalog * docs: register Service Catalog service * feat(servicecatalog): full API parity for 55 operations Closes the entire botocore servicecatalog gap surface found by a full-manifest scan (56 ops; 55 landed, DescribeServiceAction escalated because no store exists for it and a single write op may not invent one). Each operation is dispatch-reachable, covered by a wire-level test asserting response values (not just status codes), and falsifiability-checked at method granularity. Tests are one class per operation family so falsification isolates per operation. Nine previously-unshipped bugs surfaced and fixed along the way, recorded as issues 0017-0025: wrong field names in describeConstraint, three incompatible service-action association keys across the single-op and batch-op pairs, a Type discriminator collision leaking phantom entries into ListServiceActions, the provisioned-product-plan family having no persistence at all, five cases of an operation returning a generated id (RecordId, CopyProductToken, plan ids) that nothing ever persisted, a hardcoded-empty ListConstraintsForPortfolio, and TerminateProvisionedProduct reporting the wrong RecordType. Limitations documented in docs/services/service-catalog.md. * chore: drop local-only bug-ledger files before upstream issues/0017-0025 are this fork's internal tracking, not something upstream has a convention for. * fix(config): restore EmrServerless config body lost in rebase The rebase onto upstream/main collided where both upstream and this branch declare a new service config interface sharing a trailing body; the EmrServerless interface was left open, so the file did not parse. * docs: state a single correct service count Collapse the duplicated claim left by the docs merge to one number matching the 74 services this branch registers. * fix(servicecatalog): adapt to upstream's Organizations model (OrganizationAccount, 5-arg createAccount) * docs(servicecatalog): register the generated action table * docs(servicecatalog): correct action descriptions after audit * docs(servicecatalog): name the real Control Tower catalog triggers * fix(servicecatalog): reject missing identifiers instead of failing with 500 Store lookups passed the request's identifier straight through to the backing map, so an operation called without its id parameter died on a null key and surfaced as InternalFailure. Guard the lookup helpers and name the missing parameter in an InvalidParametersException. * fix(servicecatalog): report a plan's own identifiers in its plan details DescribeProvisionedProductPlan and ListProvisionedProductPlans reused the plan's own id and provisioned-product name for ProvisionProductId and PlanName, so callers could never recover the product a plan targets or the plan's name. Read the distinct fields the plan already stores. * fix(servicecatalog): require ProvisionProduct to name a real product ProvisionProduct ignored ProductId and ProductName, so every request took the Control Tower Account Factory path: an unrecognised product id still created an Organizations member account and recorded it under the seeded Account Factory identifiers. Resolve the target product and its provisioning artifact first, reject what the catalog does not hold, and touch Organizations only when the request really names Account Factory. Other stored products now provision a plain record. Product and artifact resolution is shared with DescribeProvisioningParameters, which already validated a request the same way. * docs: state one service count and ProvisionProduct's validated behaviour docs/index.md still claimed 74 services while docs/services/index.md, the canonical matrix, listed 77. The Service Catalog page also described ProvisionProduct taking the Account Factory path for every request, which stopped being true once it started resolving the product it was given. * fix(servicecatalog): resolve ProductId by product id only requireProduct also matches provisioning-artifact ids, so ProvisionProduct with ProductId set to the Account Factory artifact id resolved the owning product and created an Organizations account. resolveProduct now does a strict id lookup; artifact ids in ProductId get ResourceNotFoundException. * fix(servicecatalog): enforce the modeled enums and AccountId format on stored values Five request members were read and stored, or used as a filter, without the constraint botocore pins on them: - Create/Update/DeletePortfolioShare built the share's store key from AccountId and OrganizationNode.Type unchecked, so a short account id or a node type outside OrganizationNodeType became a share DescribePortfolioShares reported back verbatim. - CreateProvisionedProductPlan accepted any PlanType and then described the plan as CLOUDFORMATION, the only member ProvisionedProductPlanType has. - CreateServiceAction stored any DefinitionType, likewise a one-member enum. - DescribePortfolioShares and ListOrganizationPortfolioAccess filtered on an unvalidated type, turning a typo into an empty result rather than an error. * fix(servicecatalog): enforce the PrincipalType enum on principal association The model pins PrincipalType to IAM or IAM_PATTERN; the value was stored verbatim. Found by the botocore-grounded review pipeline on its first sweep — the hand audit of the same service missed it. * fix(servicecatalog): reject an ambiguous ProductName on ProvisionProduct Product names are not unique keys, so first-match could resolve a user-created product carrying the Account Factory name — or vice versa — and either skip or wrongly enter the Organizations account workflow. More than one match now raises the modeled DuplicateResourceException. * fix(servicecatalog): keep a missing AccountEmail inside the Service Catalog model ProvisionProduct passed AccountEmail straight to Organizations, so omitting it surfaced Organizations' InvalidInputException — a shape absent from Service Catalog's model — to a servicecatalog client, which cannot deserialize it into a typed exception. Validate it on the Account Factory path and raise the service's own InvalidParametersException, matching how the createAccount failure a few lines below is already translated. A plain stored product needs no email, so the guard sits inside accountFactoryAccountId rather than at the top of provisionProduct; a test pins that provisioning a non-Account-Factory product without AccountEmail still succeeds. * fix(servicecatalog): refuse to delete a portfolio or product that is in use DeletePortfolio and DeleteProduct deleted the resource and then cascaded, removing every association naming the portfolio and every share keyed to it. AWS refuses the call instead — a portfolio with associated products, users, constraints, or shared accounts, and a product associated with a portfolio, are both ResourceInUseException — so what AWS makes a recoverable no-op was here unrecoverable data loss reported as 200. The scans that drove the cascade now detect the in-use condition. Every row AWS lists for a portfolio carries PortfolioId, so one scan covers products, principals and constraints alike; the portfolio cascade is gone because it is now unreachable. Tag-option associations key off ResourceId, are absent from AWS's list, and were never cleaned by the old cascade either, so nothing is orphaned that was not orphaned before. For a product only the portfolio association blocks, so its remaining associations are still cleaned up on delete. |
||
|
|
a2bd22d5f8 |
feat(ssoadmin): serve Identity Center ListInstances (#2581)
* feat(sso): serve Identity Center ListInstances under SWBExternalService
LZA's Custom::GetIdentityCenterInstanceMetadata Lambda calls SSO Admin
ListInstances (target prefix SWBExternalService., the service's AWS-internal
codename, cf. config's StarlingDoveService) and requires exactly one instance
with InstanceArn and IdentityStoreId. Previously no descriptor matched the
target, so the call died with UnknownOperationException. Identifiers are
fixed constants so they survive restarts — LZA persists them into SSM
parameters between stages.
* fix(config): declare ssoadmin enabled toggle in both application.yml files
Upstream's ServiceConfigYamlCoverageTest requires every service config with an
enabled() toggle to declare it explicitly in both files; this branch predates
that test and fails it without the declaration.
* docs(ssoadmin): defer the single-op handler from action-table generation
* docs(ssoadmin): alias the sso descriptor to the IAM page
* fix(ssoadmin): report the caller's account as OwnerAccountId and assert the unsupported-operation error type
* fix(ssoadmin): use UnknownOperationException for unrecognized actions
Matches this codebase's JSON 1.1 dispatch convention (ServiceQuotas, Network
Firewall, and others already use it) and is a real modelled shape unlike the
bare UnsupportedOperation string, which has no Exception suffix and isn't in
sso-admin's error model.
* docs: correct service count to 79 after the #2579 merge
The upstream/main merge (
|
||
|
|
f912c3b717 |
feat(servicequotas,ram): add Service Quotas and AWS RAM resource sharing (#2579)
* feat(servicequotas,ram): add Service Quotas and RAM sharing stub
Two Landing Zone Accelerator pipeline prerequisites:
- servicequotas: ListServiceQuotas/GetServiceQuota (+ AWS-default
variants) over JSON 1.1 with curated real quota codes for codebuild
and lambda, deterministic generated quotas for other services, and
offset-token pagination
- ram: EnableSharingWithAwsOrganization returning {returnValue: true}
* feat(ram): model resource shares with the reads LZA's TGW share flow needs
RamController previously registered only /enablesharingwithawsorganization;
every other restJson1 RAM path fell through to S3's /{bucket} template route
and returned an XML error the LZA Lambdas' JSON parser choked on
(SyntaxError: Unexpected token '<'). Adds CreateResourceShare,
GetResourceShares (SELF vs OTHER-ACCOUNTS visibility incl. org/OU
principals), GetResourceShareInvitations (always empty — organization
sharing auto-accepts, matching real AWS), and ListResources with RAM
resource-type derivation.
* fix(ram): show every non-owned share to OTHER-ACCOUNTS callers
Launched-container credentials resolve to the emulator default account,
so LZA's Custom::GetResourceShare Lambda never matches an account-ID
principal check for the account it actually runs in. Principal-based
visibility hid IPAM pool shares from the accepting NetworkVpcStack while
org-ARN shares (TGW) passed, failing Network_VPCs. The Lambda filters
client-side by owningAccountId + name, so returning all non-owned shares
is safe.
* feat(servicequotas): add RequestServiceQuotaIncrease
Persists the requested increase and returns a RequestedServiceQuotaChange
the subsequent Get/List operations can read back. Limitations documented in
docs/services/servicequotas.md.
* fix(config): restore EmrServerless config body lost in rebase
The rebase onto upstream/main collided where both upstream and this branch
declare a new service config interface sharing a trailing body; the
EmrServerless interface was left open, so the file did not parse.
* fix(ram): persist resource shares
* feat(ram): add principal associations and resource-share lifecycle
* fix(test): conform RAM storage test doubles to upstream StorageFactory API
e9826026 introduced SharedStorageFactory overriding StorageFactory.create with
the pre-upstream return type StorageBackend<String,V>; upstream now returns
AccountAwareStorageBackend<V>. Matches the template used by upstream's own
CodeBuildServicePersistenceTest.
* fix(ram): restrict resource-share mutations to the owning account
Every mutating RAM operation resolved the share ARN with a global
all-accounts scan, so any caller holding an ARN could rename, retag,
associate resources into, or delete another account's resource share.
Thread the caller's account into the mutation paths and resolve the
share only within it; a non-owner now gets the same
UnknownResourceException an unknown ARN gets, matching AWS, which
resolves share ARNs inside the caller's account. Read visibility under
OTHER-ACCOUNTS is unchanged.
* fix(ram): return 400 SerializationException for a malformed request body
An unparseable body left readTree throwing UncheckedIOException, which
escaped the controller and surfaced as a 500 InternalFailure. Reject it
with the modeled restJson1 client error instead.
* fix(config): restore the bedrock-agent-core-control enabled flag
A rebase left the key with a null body in both the main and test
application.yml, silently dropping the service's enabled flag.
* docs(servicequotas): fix the docs path in the consumer test javadoc
* docs: correct the service count and the Service Quotas and RAM matrix rows
docs/index.md still claimed 75 services and listed RAM under JSON 1.1;
the canonical count in docs/services/index.md is 78 and RAM speaks
restJson1. Bring the Service Quotas row up to its five handled actions
and the RAM row up to its twelve REST operations.
* docs(tooling): acknowledge the RAM controller in the docs registry
RAM's action table is hand-written and carries a method-and-path column
the generator does not emit, so register it as a deferred handler rather
than a rest-mode source.
* test(ram): cover owner mutation over HTTP and pin the non-owner error message
The ownership checks were asserted only against the service; nothing
exercised the caller account the controller now threads through, so a
mismatch between the identity stamped at create time and the one
resolved at delete time would have gone unnoticed. Select the existing
SELF assertion by share name, since the store is shared across the
class.
* docs(ram): generate the action table from the controller
The RAM table was hand-written and only acknowledged in the docs
registry, so the drift sentinel could never fire on it. Fold the method
and path into each description the way the FIS REST controller's doc
does, add the generator markers, and register the controller as a
rest-mode source. Also record that mutations are owner-only.
* fix(ram): enforce the modeled resourceOwner enum on the share read paths
GetResourceShares, ListPrincipals and ListResources all read resourceOwner and
fed it to a two-way visibility fork: "SELF" meant owned shares, and literally
anything else meant OTHER-ACCOUNTS. The model enumerates exactly SELF and
OTHER-ACCOUNTS, so a caller who sent "self" or "OTHER_ACCOUNTS" was silently
handed the inverse of what they asked for rather than the InvalidParameterException
AWS returns — an error all three operations list.
Validated at the three entry points rather than inside the per-share visibility
check, so the rejection does not depend on the store being non-empty.
* test(ram): cover the resourceOwner enum rejection on the HTTP path
The service-level test proved the check; this pins the wire behaviour LZA
actually exercises. RamController substitutes "SELF" via asText("SELF") only for
an absent or null resourceOwner, so a present-but-unmodelled value — including a
non-string that Jackson coerces — must still reach the service and surface as a
400 InvalidParameterException on all three read routes. The absent case is
asserted to still return 200, so the default is not silently changed.
* fix(ram): stop exposing the contents of a deleted resource share
ListResources and ListPrincipals reported a deleted share's resources
as AVAILABLE to non-owning consumers. Both now skip DELETED shares,
while GetResourceShares keeps returning the share with DELETED status,
matching the retention window real RAM applies.
* fix(ram): reject a malformed GetResourceShareInvitations body
The endpoint ignores its body semantically, but malformed JSON is a
client error: it now goes through readTree and answers the modeled 400
SerializationException instead of 200 with an empty list.
* fix(ram): reject mutations on DELETED resource shares
A deleted share stays readable via GetResourceShares for the retention
window, but real RAM treats it as terminal: update, associate,
disassociate, tag, untag, and a second delete all raise
UnknownResourceException. findOwnedShare now filters DELETED so every
mutation path resolves a deleted share the same as an unknown ARN.
* fix(ram): apply the GetResourceShares filters and advance lastUpdatedTime
Four response-fidelity gaps from the maintainer review, interleaved in
the same two files:
GetResourceShares read only resourceOwner, so name, resourceShareArns
and resourceShareStatus were silently dropped and a caller narrowing by
share name got every visible share back. All three are applied now, and
an unmodelled resourceShareStatus is rejected with
InvalidParameterException the way resourceOwner already is.
lastUpdatedTime never advanced: ResourceShare had no such field and
creationTime was echoed in its place, on the share node, on the
association rows, and on ListPrincipals. The field now exists and is
stamped in putForOwner, the single seam every create and mutation
already passes through. State written before the field existed reads
back with creationTime, which is correct for a share never mutated
since.
Shares also report the modeled featureSet (STANDARD — floci has no path
to produce a policy-derived share), and DeleteResourceShare echoes the
clientToken the caller sent, both of which the model carries.
* docs(ram): record the filter support and the unrouted-operation behavior
* fix(ram): require resourceOwner on the share read paths
GetResourceShares, ListPrincipals and ListResources all substituted
SELF for a missing resourceOwner, which the model marks required. That
answered a question the caller never asked, and answered it with the
caller's own shares rather than an error. All three now pass a missing
or null value to the validator that already rejected unmodelled ones,
so it surfaces as InvalidParameterException.
* docs(ram): name GetResourceShareAssociations in the fall-through note
Per review, the unrouted-operation note is more useful if it names the
operation Terraform's association resources read on every refresh, and
says the symptom is an S3 NoSuchBucket XML body rather than a
credentials problem.
* fix(ram): reject trailing tokens after a valid JSON body
Jackson's default readTree stops at the first complete value, so a body
like "{} not-json" parsed as an empty object and the request executed
instead of returning the modeled 400 SerializationException. Read with
FAIL_ON_TRAILING_TOKENS, the convention the JSON 1.0/1.1 controllers,
FIS, Signin and EventBridge already follow.
* fix(servicequotas): validate the ServiceCode shape
ServiceCode was only checked for emptiness. Because an unknown code
deliberately generates a quota catalog, that meant a caller typoing
"!!!" got three invented quotas back instead of an error. Validate
against the modeled [a-zA-Z][a-zA-Z0-9-]{1,63} and 63-character cap;
unknown-but-well-formed codes keep generating as before.
|
||
|
|
87e804492a |
feat(organizations): add AWS Organizations service (#2489)
* feat(organizations): add AWS Organizations service Implements the AWS Organizations control plane over JSON 1.1 (AWSOrganizationsV20161128.*): organizations and roots, the OU tree, member accounts, all policy types, tags, trusted service access, delegated administrators, the organization resource policy, and the invitation/handshake flow. Organizations is global and cross-account, so records are addressed through the explicit *ForAccount methods on AccountAwareStorageBackend rather than the request-context-derived get/put: a member account calling DescribeOrganization has a different request account than the one owning the data. The caller account is used for authorization instead — mutations are management-account only, members get read access to their own organization, and outsiders get AWSOrganizationsNotInUseException. Because Floci already resolves a 12-digit access key id to an account, an account created by CreateAccount is immediately usable as a caller identity against every other service. * fix(organizations): emit only AWS's handshake resource types Review feedback on #2489. The ORGANIZATION resource on an INVITE handshake was carrying a MASTER_ACCOUNT_ID child. HandshakeResourceType is a closed enum and that value is not in it, so the AWS SDK deserializes it as UNKNOWN_TO_SDK_VERSION rather than failing loudly. AWS's documented children are MASTER_EMAIL and MASTER_NAME; emit those instead. The javadoc already described the correct pair, so it was the code that deviated. Adds an integration test pinning the resource types against the enum so this cannot regress. Also from review: - POLICY_TYPES and EFFECTIVE_POLICY_TYPES are rendered into validation messages, but Set.of's iteration order is unspecified and salted per JVM run, so the same rejection could read differently between runs. Declare them as ordered Lists with companion Sets for O(1) membership. - listHandshakesForAccount called organizationById — itself a full scan — once per handshake. Build the orgId to management-account map once. |
||
|
|
bd3b5b427b |
docs: add MWAA to service matrix and correct service count (#2496)
MWAA already has a service page and is registered in the catalog, but the matrix at docs/services/index.md omitted it. Add the row and bump the headline count from 72 to 73. Fixes #2205 Signed-off-by: Vedant Madane <6527493+VedantMadane@users.noreply.github.com> |
||
|
|
04d120fdd5 |
feat(fis): add AWS FIS support (#2435)
* feat(fis): add AWS FIS support * refactor: add typed FIS persistence models * ci(fis): retrigger timed-out build * fix(fis): reject trailing JSON request bodies |
||
|
|
d78520d5cb |
feat(kinesisanalytics): add Managed Service for Apache Flink (Kinesis Analytics V2) (#1914)
* feat(kinesisanalytics): add Managed Service for Apache Flink (Kinesis Analytics V2)
Adds the kinesisanalyticsv2 service (X-Amz-Target KinesisAnalytics_20180523.*):
a control-plane state machine plus a real Apache Flink JobManager container spun up
as a sidecar on StartApplication, modeled on the AmazonMQ->RabbitMQ pattern.
- CreateApplication -> READY, StartApplication -> STARTING -> RUNNING via a readiness
poller, StopApplication -> READY, DeleteApplication -> removed
- Container image chosen from the requested RuntimeEnvironment (FLINK-1_15..1_20 ->
apache/flink:1.x) via KinesisAnalyticsRuntimes, with an optional operator override;
unsupported runtimes (SQL / Zeppelin) rejected with InvalidArgumentException
- Container naming via ContainerStorageHelper.resourceName (floci-kinesisanalytics-<name>)
- Registered in ResolvedServiceCatalog, dispatched by AwsJson11Controller; container
teardown wired into EmulatorLifecycle.onStop
- Tests: service + handler unit tests, @QuarkusTest integration, Java SDK compatibility test
- Docs: service page, services index, README, environment-variable reference
* fix(kinesisanalytics): enforce delete/update state and version/timestamp guards
Addresses review feedback (self-review + Greptile) on the Managed Flink service:
- DeleteApplication rejects a non-READY (RUNNING/STARTING) application with
ResourceInUseException; the caller must StopApplication first (Greptile P1)
- DeleteApplication validates the required CreateTimestamp against the stored value
- UpdateApplication validates CurrentApplicationVersionId (ConcurrentModificationException
on mismatch, InvalidArgumentException when absent)
- StopApplication error message reads 'RUNNING or STARTING' to match the guard
- Readiness poller @PreDestroy awaits termination (bounded) before returning so a
mid-flight write cannot race the shutdown storage flush
- Drop the unused Tags field from FlinkApplication (full tag support tracked as a follow-up)
- Compat test @AfterAll logs tolerated teardown failures (AGENTS.md) and stops before delete
Tests updated accordingly and verified live against the packaged jar.
* feat(kinesisanalytics): deploy and run the application JAR on the Flink cluster
Implements real job submission for Managed Service for Apache Flink, so the AWS
'deploy a JAR' flow actually runs the job (previously only a bare JobManager reached RUNNING):
- CreateApplication parses and stores ApplicationConfiguration (ApplicationCodeConfiguration
S3ContentLocation + ParallelismConfiguration); DescribeApplication echoes it back as
ApplicationConfigurationDescription
- StartApplication reads the JAR from Floci's local S3 (via S3Service), starts a JobManager plus a
TaskManager (sharing the JobManager network namespace for localhost RPC), then uploads and runs the
JAR via the Flink REST API (new FlinkRestClient); the app reaches RUNNING when the Flink job is RUNNING
- StopApplication cancels the job and tears down both containers
- Applications created without code still come up as a bare cluster
- Docs + README updated; unit tests for config round-trip; verified live end-to-end against the
packaged jar (S3 JAR -> RUNNING Flink job -> stop/delete cleanup)
Not yet emulated: EnvironmentProperties injection, snapshots/savepoints, in-place code updates.
* fix(kinesisanalytics): align Flink runtimes with AWS and add the 2.x line
The runtime map now mirrors the runtimes AWS Managed Service for Apache Flink actually offers:
- Add FLINK-2_0 / 2_1 / 2_2 / 2_3 -> apache/flink:2.0/2.1/2.2/2.3 (the Flink 2.x line; FLINK-2_2 is in
the AWS SDK RuntimeEnvironment enum and the whole 2.x line has published apache/flink images)
- Remove FLINK-1_16 / FLINK-1_17 -> AWS does not offer these runtimes, so Floci should reject them too
rather than accept versions real AWS refuses
Supported set: FLINK-1_15, 1_18, 1_19, 1_20, 2_0, 2_1, 2_2, 2_3. Tests + docs + README updated.
* test(kinesisanalytics): cover both Flink 1.18 and 2.3 in the SDK compat test
Refactor the single-runtime compat test into an abstract ordered lifecycle run against two
runtimes, so the suite guards both the Flink 1.x and 2.x lines (Flink 2.0 changed the config
system and boots slower):
- AbstractKinesisAnalyticsV2LifecycleTest: PER_CLASS instance state + the create->start->RUNNING->
list->stop->unsupported->delete lifecycle, parameterized on an abstract runtime()
- KinesisAnalyticsV2Flink118Test (FLINK-1_18) and KinesisAnalyticsV2Flink23Test (FLINK-2_3)
- FLINK-2_3 is passed as a string (newer than the pinned SDK 2.44.14 enum) and asserted via
runtimeEnvironmentAsString(); RUNNING wait bumped to 300s for Flink 2.x's slower boot
Verified live: both subclasses boot real apache/flink:1.18 and :2.3 clusters and reach RUNNING
(0 skipped). CI now exercises two clusters; both skip gracefully when Docker is unavailable.
* fix(kinesisanalytics): preserve AwsException from a bad application-code S3 location
StartApplication's catch(RuntimeException) wrapped every failure from startCluster into
InternalFailureException (HTTP 500) — including the AwsException that readJar throws when the
application-code S3 object is missing/empty/unreadable. A client's bad S3 code location therefore
surfaced as a 500 server error instead of the intended InvalidArgumentException (400).
Now AwsException propagates as-is (preserving its error code and message); only unexpected
RuntimeExceptions (e.g. Docker unavailable) become InternalFailureException. Addresses Greptile P1.
* feat(kinesisanalytics): add resource tagging (TagResource/UntagResource/ListTagsForResource)
Adds Tags support to CreateApplication plus TagResource, UntagResource, and
ListTagsForResource, dispatched as regular JSON1.1 actions under the same
KinesisAnalytics_20180523 target prefix as every other action — verified
against the real botocore kinesisanalyticsv2 model that this API has no
separate REST tagging endpoint (protocol is pure "json"/1.1 with all
operations on POST /), unlike REST-JSON services (EKS, MWAA) that use the
shared /tags/{arn} controller.
Tags is a list of {Key, Value} objects on the wire (not a map), same shape
MemoryDB's handler already uses for its own tagging actions; mirrored that
parse/build pattern rather than the map-shaped TagHandler interface. Tags
are stored on FlinkApplication but, matching the real API, never echoed in
ApplicationDetail (CreateApplication/DescribeApplication) — only
ListTagsForResource returns them. TagResource enforces AWS's 50
user-defined-tag ceiling (TooManyTagsException) on both CreateApplication
and TagResource.
docs/services/kinesisanalytics.md's action table is auto-generated from the
handler source (tools/docs/regen_action_docs.py) — regenerated it and filled
in the three new rows' hand-written descriptions.
* feat(kinesisanalytics): inject EnvironmentProperties into the Flink cluster
CreateApplication now accepts ApplicationConfiguration.EnvironmentProperties
.PropertyGroups and writes them to /etc/flink/application_properties.json in
both the JobManager and TaskManager containers before the job runs — the
same well-known path and JSON shape (a list of {PropertyGroupId, PropertyMap}
objects, matching the AWS API's own PropertyGroups shape) real Managed
Service for Apache Flink uses, so a JAR written against
KinesisAnalyticsRuntime.getApplicationProperties() picks them up unmodified
against Floci. DescribeApplication echoes them back under
ApplicationConfigurationDescription.EnvironmentPropertyDescriptions
.PropertyGroupDescriptions.
/etc/flink does not exist in the stock apache/flink image, and the
container's non-root "flink" user (uid 9999) can't create it directly under
/etc (confirmed live: mkdir -p /etc/flink fails with permission denied as
that user). The fix, also verified live: name the tar entry
"flink/application_properties.json" and extract into the existing /etc
rather than targeting /etc/flink directly — the daemon-level copy API can
create the missing subdirectory as part of unpacking the archive even
though the in-container user couldn't, landing as root:root 775 (so it's
still world-readable by the flink user). A real apache/flink:1.18 container
was used to verify both the failure mode and the fix before writing the
Java implementation.
* feat(kinesisanalytics): add application snapshot (savepoint) support
Adds CreateApplicationSnapshot/DescribeApplicationSnapshot/ListApplicationSnapshots/
DeleteApplicationSnapshot. Triggers a real Flink savepoint of the running job and
polls it to completion the same way StartApplication polls job readiness. Snapshot
files land on a persistent named Docker volume mounted at /opt/flink/savepoints in
the JobManager container, so they survive a Stop/Start cycle; the volume is only
removed on DeleteApplication.
* feat(kinesisanalytics): support in-place application code updates
UpdateApplication with a new ApplicationCodeConfigurationUpdate (or
ParallelismConfigurationUpdate) now redeploys onto an already-running application
without tearing down its JobManager/TaskManager containers: the current job is
cancelled and the new JAR is uploaded and run on the same cluster, transitioning
RUNNING -> STARTING -> RUNNING the same way StartApplication submits a fresh job.
Updating a READY application just stores the new code location for the next
StartApplication. Attaching code to a running bare cluster for the first time is
not yet supported and is rejected with InvalidRequestException.
* fix(kinesisanalytics): use AWS's documented generic InternalFailure code
startApplication and updateApplication's redeploy-code path threw an invented
"InternalFailureException" for unexpected Docker provisioning failures — not a
shape kinesisanalyticsv2's model declares (no operation in this API declares any
5xx shape at all). AWS documents "InternalFailure" (no "Exception" suffix, HTTP
500) as the generic error common to every service's API; it's also already the
default used elsewhere in this codebase (JsonErrorResponseUtils, KMS, Pricing,
SES, CloudControl, EventBridge, and others).
* feat(kinesisanalytics): add CreateApplicationPresignedUrl and SnapshotsEnabled
CreateApplicationPresignedUrl returns a URL to the running application's Flink
Dashboard (UrlType: FLINK_DASHBOARD_URL only; Zeppelin/Studio isn't supported).
Floci has no real session/proxy layer for this, so it returns the JobManager
container's own REST/dashboard URL directly, while still validating UrlType and
SessionExpirationDurationInSeconds against AWS's documented constraints.
ApplicationSnapshotConfiguration.SnapshotsEnabled (default true, matching real
AWS) is now honored on CreateApplication and toggleable via UpdateApplication's
ApplicationSnapshotConfigurationUpdate; CreateApplicationSnapshot rejects the
request with InvalidRequestException while disabled.
* fix(kinesisanalytics): persist flinkJobId as soon as the job is submitted
The readiness poller only called putApplication when advanceToRunning reported
RUNNING, not when it merely assigned flinkJobId after submitting the job (which
returns false until the job state catches up). pendingJars — a separate,
in-process-only cache — is already cleared by that point, so an emulator
restart between job submission and reaching RUNNING would leave the
application stuck: no persisted flinkJobId to resume polling, and no cached
JAR left to resubmit.
|
||
|
|
aadc93e306 |
feat(rum): add CloudWatch RUM app-monitor service (#1797)
* feat(rum): add CloudWatch RUM app-monitor service
Adds a minimal CloudWatch RUM service (restJson1) covering the app-monitor
lifecycle — CreateAppMonitor, GetAppMonitor, UpdateAppMonitor, DeleteAppMonitor,
ListAppMonitors — backed by an in-memory store.
Previously restJson1 RUM requests (e.g. POST /appmonitor) fell through to the S3
path-style catch-all (@Path("/{bucket}")) and returned an XML error that
restJson1 SDKs (and the CDK AwsCustomResource used for RUM AppMonitor custom
resources) cannot parse. Literal /appmonitor and /appmonitors paths take JAX-RS
precedence over S3's /{bucket} template (the same mechanism eks/mq use), so the
routes win with no extra routing wiring.
Verified with aws-cli 2.33.18 against a dev-mode emulator: CreateAppMonitor
returns an Id, GetAppMonitor/ListAppMonitors round-trip, DeleteAppMonitor then
GetAppMonitor returns ResourceNotFoundException.
* fix(rum): make monitor updates atomic
* fix(rum): align app monitor lifecycle with AWS
* chore: retry flaky Node compatibility check
* fix(rum): address app-monitor review feedback
---------
Co-authored-by: abanna <abanna@users.noreply.github.com>
|
||
|
|
97b64a1d3b |
feat: add AWS Lightsail emulation (#1583)
* feat(lightsail): add AWS Lightsail emulation * fix(lightsail): align error responses with AWS * fix(lightsail): address review edge cases * fix(lightsail): reject attached disk reattach * fix(lightsail): reject static ip reattach * fix: register lightsail docs handler |
||
|
|
e4ee6dd7de |
docs: correct service count to 68 and add missing IoT and S3 Vectors entries (#1716)
The documented count stayed at 66 while the catalog grew to 68 status-visible services: S3 Vectors (#1435) and IoT Core/IoT Data (#1359) were merged without services-matrix rows, so the Amazon MQ bump (#1642) was applied to an already stale number. Adds the three missing matrix rows, links the existing iot.md page, creates the missing s3vectors.md page, and updates the count in the README, docs/index.md, and docs/services/index.md. 68 is the catalog's status-visible service count, with IoT Core and IoT Data counted separately per the AppConfig/AppConfigData precedent. |
||
|
|
188854f2df |
feat(amazonmq): add Amazon MQ broker control plane backed by RabbitMQ (#1642)
* feat(amazonmq): add Amazon MQ broker control plane for RabbitMQ
* feat(amazonmq): provision RabbitMQ container with rollback
Back a broker with a real rabbitmq:3-management container, following the
MSK/ElastiCache container-manager pattern.
- RabbitMqManager starts the container, publishes AMQP (5672) and
management (15672) ports, and resolves the broker endpoints
- Service branches on the mock flag; real brokers stay
CREATION_IN_PROGRESS until a readiness poller observes the management
API answering, then flip to RUNNING
- Rollback on failed provisioning: the manager removes the half-built
container and the broker is persisted as CREATION_FAILED
- @PreDestroy stops containers on shutdown; DeleteBroker stops and
removes the container and its storage
Readiness probes the management UI root (no auth) to avoid RabbitMQ's
loopback-only guest user over Docker port mapping.
* feat(amazonmq): seed broker admin user and reject ActiveMQ-only User API
Amazon MQ's standalone User API (CreateUser/DescribeUser/ListUsers/
DeleteUser) applies only to ActiveMQ brokers; AWS rejects it for RabbitMQ
and directs callers to the RabbitMQ web console. CreateBroker now requires
exactly one broker user (validated against AWS password rules) which is
seeded into the container via RABBITMQ_DEFAULT_USER/PASS, sidestepping
RabbitMQ's loopback-only guest restriction.
* test(amazonmq): SDK compatibility test against live RabbitMQ broker
Adds AmazonMqTest exercising the real container path via the AWS SDK MqClient:
CreateBroker provisions a rabbitmq:3-management container, the broker
transitions to RUNNING once its management API answers, endpoints are
published, the ActiveMQ-only User API is rejected, and DeleteBroker tears the
container down. Uses JUnit Assumptions to skip cleanly when Docker is absent.
* fix(amazonmq): harden error handling, persistence, and shutdown teardown
- Redact the provisioning failure 500: log the cause, return a generic AWS
error envelope instead of leaking e.getMessage() (which can be null).
- Add @JsonIgnoreProperties(ignoreUnknown = true) to Broker, MqUser, and
BrokerInstance so old persisted snapshots survive field changes.
- Wire RabbitMQ container teardown into EmulatorLifecycle.onStop() via
RabbitMqManager.stopAll(), alongside the other container managers; the
service @PreDestroy now only stops the readiness poller.
* docs(amazonmq): add Amazon MQ service page and bump service count to 66
Adds docs/services/amazonmq.md, lists Amazon MQ in the services overview and
README service tables, and updates the "65 -> 66 AWS services" count across
docs/index.md, docs/services/index.md, and README.md.
* fix(amazonmq): reject RebootBroker unless the broker is RUNNING
RebootBroker unconditionally set the broker to RUNNING, so a non-RUNNING
broker (e.g. CREATION_FAILED, which has no backing container) was silently
promoted to RUNNING and never reconciled by the readiness poller. AWS allows
RebootBroker only on a broker in the RUNNING state; guard it and return a 400
otherwise, matching the Amazon MQ API ("You can reboot only a broker with the
RUNNING status").
* fix(amazonmq): close readiness-probe connection and log tolerated failures
isReady() opened an HttpURLConnection but never disconnected it; since the
probe runs every 2s per pending broker this leaked sockets. Disconnect in a
finally block, and log the tolerated failure at debug with broker/URL context
(AGENTS.md: no empty catch; avoid noise in hot paths) instead of swallowing it.
* fix(amazonmq): tear down broker container by deterministic name after restart
containerId is in-memory bookkeeping (intentionally not persisted, since the
Broker model is serialized straight to DescribeBroker and must not leak it).
After an emulator restart it is null, so stopContainer() previously returned
early and left the container running. It now falls back to the deterministic
container name (floci-amazonmq-{brokerId}) so an explicit DeleteBroker still
removes a container left over from a previous run. Documented the field and
added RabbitMqManagerTest covering both the id and name-fallback paths.
* fix(amazonmq): keep admin password in-memory only and fail loudly if absent
The admin password is a secret used solely to seed the RabbitMQ container at
create time. Persisting it (to make it survive a restart) would write the
credential in cleartext to amazonmq-brokers.json, which the project's security
rule prohibits. It stays in-memory only via @JsonIgnore; startContainer (the
only consumer, called from CreateBroker) now throws if the password is absent
rather than seeding a null credential. Added MqUserTest asserting the password
is never serialized and round-trips to null.
* fix(amazonmq): persist broker volumeId/accountId/containerId without leaking them
These internal fields were @JsonIgnore'd, so they were absent from
amazonmq-brokers.json. After a restart in persistent mode volumeId was null
(removeBrokerStorage could not locate the named volume, leaking it) and
accountId was null (the readiness poller wrote brokers via the non-account-aware
path). Unlike the admin password, these are not secrets, so they should persist.
Remove @JsonIgnore so they round-trip through storage, and build the
DescribeBroker response explicitly in the controller so they are still never
exposed to clients (matches MskCluster, which persists volumeId/containerId).
Adds BrokerTest (round-trip) and asserts the describe response omits them.
|
||
|
|
efacb37130 |
feat: Adds initial Elastic Beanstalk Query API support to Floci. (#1362)
* feat: add Elastic Beanstalk query API support feat: add Elastic Beanstalk query API support * fix(elasticbeanstalk): configure native-image runtime initialization * fix(elasticbeanstalk): align missing parameter errors and add application ARN * test(elasticbeanstalk): add Java SDK compatibility coverage |
||
|
|
3f314dcb4e |
feat(codepipeline): add AWS CodePipeline emulation (#1469)
* feat(codepipeline): add AWS CodePipeline emulation * fix(codepipeline): align webhook and rollback response shapes |
||
|
|
d77f11abbb |
docs(docdb): document DocumentDB service (#1386)
* docs(docdb): document DocumentDB service * docs(docdb): clarify data endpoint port is from DescribeDBClusters * docs: align AWS service count to 56 across docs and README --------- Signed-off-by: Hector Ventura <hectorvent@gmail.com> Co-authored-by: Hector Ventura <hectorvent@gmail.com> |
||
|
|
717769857b |
docs: correct service count to 58 and add EMR, WAF v2, CloudTrail pages (#1398)
Reconcile inconsistent service counts (55/54/41) to 58 distinct services across the README, docs index, services overview, and the LocalStack migration guide. Add the missing per-service pages and Service Matrix rows for EMR, WAF v2, and CloudTrail, and wire them into the mkdocs nav and README service tables. |
||
|
|
022436eaae | feat(batch): add AWS Batch service support (#1332) | ||
|
|
e063ac18ee |
feat(rds-data): add RDS Data API support (#1262)
* feat(rds-data): add RDS Data API support * fix(rds-data): harden Data API validation * fix(rds-data): harden review findings |
||
|
|
446697ec71 |
docs: add AWS Cloud Map service docs, fix service count, add analytics (#1221)
Document AWS Cloud Map (servicediscovery), which was implemented but never documented, and reconcile related documentation drift: - Add docs/services/cloudmap.md covering all 22 operations, config, examples - Bump headline service count from 52 to 53 across README and docs - Add Cloud Map to the canonical service matrix, README tables, and docs index - Backfill mkdocs nav with Cloud Map and 7 existing-but-unlisted service docs - Backfill condensed tables with services missing from them (Transcribe, Resource Groups Tagging, Neptune, EventBridge Pipes, CloudFront) - Add Umami analytics tracking via a Material theme override (overrides/main.html) |
||
|
|
4446404288 |
feat(appsync): Phase 2 — Schema Registry, Model Fixes, CRUDL completion & AWS Scalars (#1185)
* build: add graphql-java dependency
* feat(appsync): add and extend data models for Phase 2
- Add AdditionalAuthenticationProvider, DomainName, ChannelNamespace, ApiAssociation models
- Add 14 fields to GraphqlApi (apiType, visibility, owner, etc.)
- Change additionalAuthenticationProviders from raw maps to typed list
- Add 6 fields to Resolver (resolverArn, cachingConfig, maxBatchSize, etc.)
- Add dataSourceArn to DataSource
- Rename FunctionConfiguration.arn to functionArn
* feat(appsync): add service and controller changes for Phase 2
* feat(appsync): add service and controller changes for Phase 2
* test(appsync): add Phase 2 integration tests
Add ~60 new tests for:
- Model completeness (new fields, ARNs, functionArn rename)
- Domain names CRUDL + associate/disassociate
- Channel namespaces CRUDL + update
- Merged API associations CRUDL
- Enhanced metrics
- Schema registry parsing with AWS scalars and extensions
- Directive registration (aws_api_key, aws_subscribe, deprecated, unknown)
- Edge cases (null auth providers, maxBatchSize 0, cleanup on delete)
* test(appsync): add AWS scalar unit tests
Test all 17 AWS scalars:
- All registered in AppSyncScalarRegistry
- AWSDateTime, AWSJSON, AWSEmail parse valid/invalid values
- AWSTimestamp and AWSShort range validation
- AWSURL and AWSPhone format validation
* test(appsync): add SDK compatibility tests for Phase 2
Validate that the AWS SDK Java v2 can read:
- dataSourceArn() on CreateDataSource response
- resolverArn() on CreateResolver response
- functionArn() on CreateFunction response
- BadRequestException on invalid schema creation
* docs(appsync): add Phase 2 operations, schema registry, and AWS scalars documentation
- Add Domain Names, Channel Namespaces, Merged API Associations, Enhanced Metrics
- Document AWS scalar types (17 scalars with validation rules)
- Document AppSync directives (8 directives with locations)
- Update Not Implemented section with future phase references
- Add CLI examples for domain names and channel namespaces
- Update cascade delete to include channel namespaces and domain associations
* docs: add AppSync to service tables, env vars, storage config, and SDK README
- README.md: add AppSync to category table, detailed notes, and architecture diagram
- docs/index.md: add AppSync to supported services table, fix count to 52
- docs/configuration/environment-variables.md: add FLOCI_SERVICES_APPSYNC_ENABLED
- docs/configuration/advanced/application-yml.md: add appsync config block
- docs/configuration/storage.md: add AppSync per-service storage override
- compatibility-tests/sdk-test-java/README.md: add AppSyncTest to services table
* fix(appsync): reuse ObjectMapper and fix AWSJSON serialize for non-string values
AWSJSON scalar was creating a new ObjectMapper on every parseValue() call. serialize() used toString() which produces invalid JSON for Map/JsonNode results.
* fix(appsync): strip string literals and comments before unknown directive validation
The regex @(\w+) incorrectly flagged @ mentions inside GraphQL string literals and comments as unknown directives.
* fix(appsync): prevent silent overwrite on creates, validate required fields and input values
- Add existence checks on createDataSource, createResolver, createType,
createChannelNamespace, createMergedApiAssociation (→ ConflictException 409)
- Validate authenticationType is required on createGraphqlApi
- Validate typeName is required on createResolver
- Validate dataSourceName exists on createResolver and createFunction
- Prevent associateApi from silently overwriting existing association
- Enforce API key limit (max 2 per API)
- Fix expires parsing to accept ISO 8601 strings, throw on invalid values
- Fix castInt overflow detection
- Fix updateApiKey expires validation (was silently swallowing errors)
- Change InvalidNextTokenException to BadRequestException (AWS standard)
- Fix maxResults=0 to return empty page
- Fix getIntrospectionSchema to throw 404 instead of returning null
- Fix tags with null values (was producing literal string "null")
* test(appsync): fix cascade delete test to create data source before function, align with new validation
* refactor(appsync): remove dead code and unused hasSchema()
- Delete AppSyncDirectiveRegistry.java (100 lines, never used)
- Delete DirectiveValidator.java (45 lines, never called)
- Remove hasSchema() from SchemaRegistry (never called)
* fix(appsync): scalar null-safety, type validation, and DNS resolution
- Add null checks to 5 serialize() methods (AWS_TIMESTAMP, AWS_LONG,
AWS_INTEGER, AWS_BOOLEAN, AWS_FLOAT) to prevent NPE
- Fix AWS_TIMESTAMP parseValue() ClassCastException on String input
- Replace InetAddress.getByName() with regex in AWS IPAddress to
prevent DNS resolution (SSRF concern)
- AWSBoolean now rejects non-boolean values (matches AppSync behavior)
* refactor(appsync): centralize directive definitions in AppSyncDirective enum
- Add AppSyncDirective enum as single source of truth for directive
names and SDL definitions
- Update AppSyncSchemaParser to use enum instead of duplicated strings
- Eliminates 3 sources of truth (validateNoUnknownDirectives Set,
injectDirectiveDefinitions SDL, and formerly AppSyncDirectiveRegistry)
* perf(appsync): cache scalarMap in AppSyncScalarRegistry
- Initialize scalarMap once in constructor as unmodifiableMap
- Avoids recreating HashMap on every call (was called twice per
schema parse)
* test(appsync): add tests for scalar fixes and behavior changes
- Add tests for null-safety in serialize() (5 scalars)
- Add test for AWSTimestamp parseValue with String input
- Add tests for AWSIPAddress regex validation (IPv4, IPv6, invalid)
- Add tests for AWSBoolean rejecting non-boolean values
- Add test for scalarMap caching
* test(sdk): add AWS scalars schema creation test
Verifies that schemas with AWS scalar types (AWSDateTime, AWSJSON,
AWSIPAddress, AWSBoolean) parse correctly via the SDK.
* fix(appsync): correct API paths to match AWS documentation
- Channel namespaces: /v1/ → /v2/, channelnamespaces → channelNamespaces
- Domain association: /apis → /apiassociation
- Remove ListApiAssociations (not a real AppSync operation)
- Remove GetEnhancedMetricsConfig (not a real AppSync operation)
- Rename Merged API Association to Source API Association with correct paths:
- AssociateSourceGraphqlApi: POST /v1/mergedApis/{id}/sourceApiAssociations
- GetSourceApiAssociation: GET /v1/mergedApis/{id}/sourceApiAssociations/{id}
- ListSourceApiAssociations: GET /v1/apis/{apiId}/sourceApiAssociations
- DisassociateSourceGraphqlApi: DELETE /v1/mergedApis/{id}/sourceApiAssociations/{id}
* feat(appsync): add SourceApiAssociation models
Add SourceApiAssociation, SourceApiAssociationConfig, and
SourceApiAssociationSummary models to support merged/source API
association operations per AWS AppSync API Reference.
* feat(appsync): add ChannelNamespace support models
Add AuthMode, HandlerConfig, HandlerConfigs, Integration, and
LambdaConfig models for ChannelNamespace handler configuration
per AWS AppSync API Reference.
* fix(appsync): fix ApiAssociation and ChannelNamespace models
ApiAssociation: remove source/merged API fields, keep only domain
association fields (apiId, associationStatus, deploymentDetail,
domainName) per AWS AppSync API Reference.
ChannelNamespace: add missing fields (channelNamespaceArn,
codeHandlers, created, handlerConfigs, lastModified,
publishAuthModes, subscribeAuthModes, tags) per AWS docs.
* feat(appsync): add missing service methods and fix response models
- associateApi now returns full ApiAssociation object
- createMergedApiAssociation returns SourceApiAssociation
- createSourceApiAssociation returns SourceApiAssociation
- getSourceApiAssociation validates mergedApiId
- listSourceApiAssociations returns SourceApiAssociationSummary
- Add updateSourceApiAssociation method
- Add deleteMergedApiAssociation method
- ChannelNamespace: populate arn, timestamps on create/update
* feat(appsync): fix response formats and add missing endpoints
- associateMergedGraphqlApi: response key apiAssociation → sourceApiAssociation
- disassociateSourceGraphqlApi: returns 200 + body (not 204)
- associateApi: returns full ApiAssociation from service
- Add POST /v1/mergedApis/{id}/sourceApiAssociations/{assocId} (UpdateSourceApiAssociation)
- Add DELETE /v1/sourceApis/{id}/mergedApiAssociations/{assocId} (DisassociateMergedGraphqlApi)
* test(appsync): fix and add integration tests for new endpoints
- Fix associateSourceGraphqlApi: use mergedApiId and sourceApiAssociationStatus
- Fix deleteSourceApiAssociation: expect 200 with body (not 204)
- Add updateDomainName test
- Add associateMergedGraphqlApi test
- Add updateSourceApiAssociation test
- Add disassociateMergedGraphqlApi test
* test(appsync): add SDK tests for missing operations
- Add updateDomainName test
- Add associateMergedGraphqlApi test
- Add updateSourceApiAssociation test
- Add disassociateMergedGraphqlApi test
- Fix test ordering for new domain tests
|
||
|
|
59befa3077 |
docs: add light/dark logo branding, mkdocs theming, and README badges (#1150)
Replicate the floci-gcp light/dark logo treatment with AWS orange dots, add mkdocs branding/theming with header and logo assets, and add shields.io badges to the README (release, build, docker, license, stars). |
||
|
|
96a6fa6517 |
feat(config): add AWS Config service emulation (#934)
* feat(config): add AWS Config service emulation (#913) * docs: add AWS Config service page and align service counts across all docs Add docs/services/config.md with all 20 supported actions, CLI examples, and configuration reference. Add 5 services that had doc pages but were missing from the service matrix (Textract, Pricing, Cost Explorer, CUR, BCM Data Exports). Reconcile service count to 51 across README, docs/index.md, and docs/services/index.md. |
||
|
|
c444da222c | Release 1.5.13 | ||
|
|
b84d205b89 |
feat: Glue Schema Registry support (#621)
* feat(glue): add Glue Schema Registry support * Move Glue SDK coverage to compatibility tests * Align protobuf compatibility expectations * Resolve services index merge conflict * Remove unused Lombok compatibility dependency * Serialize Glue schema registry timestamps as strings * Tighten Glue schema registry name validation * Avoid duplicate schema registry index rebuild * Limit schema registry in-memory constructor visibility * Clone Glue tables before resolving schema references * Align Glue schema registry response shapes * Extract Glue schema version resolver helper Both validateSchemaReference and withResolvedSchemaReference duplicated the latest-version computation and the four-argument getSchemaVersion call. Pull that into a private resolveSchemaVersion(SchemaReference) helper so the call sites read at one level of abstraction and a future change to the resolution rule lands in one place. * Fix Glue schema version list projection --------- Signed-off-by: Tristan Burch <tburch@users.noreply.github.com> Signed-off-by: Hector Ventura <hectorvent@gmail.com> Co-authored-by: Hector Ventura <hectorvent@gmail.com> |
||
|
|
2832bc7714 |
feat(codebuild,codedeploy): Implementing real build in docker phase2 (#649)
* feat(codebuild,codedeploy): real build execution and Lambda deployment engine CodeBuild Phase 2: runs buildspec phases inside real Docker containers. Source injected via docker cp (copyArchiveToContainerCmd); artifacts extracted via docker cp (copyArchiveFromContainerCmd). No bind mounts — works transparently in Docker-in-Docker. CloudWatch log streaming, S3 artifact upload, StopBuild, RetryBuild, ListBuilds, ListBuildsForProject. CodeDeploy Phase 2: real Lambda deployments with traffic shifting via alias RoutingConfig, lifecycle hook invocation against live Lambda functions, PutLifecycleEventHookExecutionStatus callback, and auto-rollback on hook failure. CreateDeployment, GetDeployment, deployment state polling, ListDeployments, BatchGetDeployments, ListDeploymentTargets, BatchGetDeploymentTargets. * docs: updating docs with new services details |
||
|
|
88f40a839b |
docs: update Docker image references to floci/floci (#595)
* docs: update Docker image references to floci/floci * docs: keep README Docker Hub badges pointing to hectorvent/floci The hectorvent/floci image has accumulated pull and size metrics; switch the badges to floci/floci once the new image has comparable numbers. |
||
|
|
16fc5c9691 | docs: updating documentation logo | ||
|
|
a32b7f1f3b |
docs: comprehensive audit sweep + CHANGELOG backfill (1.1.0-1.5.2) (#326)
CHANGELOG.md was empty for the 1.1.0-1.5.2 release cycle and service docs had drifted from code behaviour. This sweep reconciles docs against the current codebase on upstream/main. - Backfill CHANGELOG.md for 1.1.0 through 1.5.2 from git history - Correct exact operation counts in docs/services/index.md: S3 (~30 -> 58), Lambda (~25 -> 30), API Gateway v1 (~24 -> 62). Counts now come from the actual dispatch handlers rather than @Path annotation counts. - Rewrite README "Supported Services" table to drop per-service op counts (they drift too fast); point readers at docs/services/index.md - Update 24 service docs for accuracy, add "Not Implemented" sections where relevant (s3.md, lambda.md, api-gateway.md) - Refresh configuration and getting-started docs - Add EventBridge Scheduler and AppConfig to mkdocs nav - Add AppConfig / AppConfigData rows to README and services index following the 1.5.2 upstream release |
||
|
|
e7ab687a6a |
feat: add SES V2 REST JSON protocol support (#265)
* feat: add SES V2 REST JSON protocol support * fix: address SES V2 review feedback |
||
|
|
48b6ca3475 |
feat(scheduler): add EventBridge Scheduler service (#260)
* feat(scheduler): add EventBridge Scheduler ScheduleGroup CRUD
Introduces the scheduler service skeleton with ScheduleGroup CRUD over
the REST JSON protocol at /schedule-groups/{Name}. The default group is
lazily seeded on first access, mirroring the EventBridge default bus
pattern. Covers Create/Get/Delete/List, region scoping, name validation,
and the default-group delete guard.
* feat(scheduler): add Java SDK compatibility tests for ScheduleGroup CRUD
* feat(scheduler): add Schedule CRUD operations
|
||
|
|
fe2480e596 |
docs: add SES documentation (#181)
* docs: introduce SES (Simple Email Service) documentation * docs: integrate SES into service lists and navigation |
||
|
|
4fc9398df4 |
feat: officially support Docker named volumes for Native images (#155)
* feat: officially support Docker named volumes for Native images * Pre-creates /app/data and assigns 1001 ownership in Dockerfile.native and Dockerfile.native-package before declaring VOLUME and dropping to USER 1001. This natively fixes the AccessDeniedException when utilizing Docker named volumes instead of local bind mounts, aligning container architecture flawlessly with tools like LocalStack. * Standardizes named volumes as officially documented optional alternatives across docker-compose templates in quick-start, index, and README documentation for a cleaner repository drop-in replacement footprint. * feat: natively support Docker named volumes via recursive permissions * Pre-creates /app/data and applies recursive 1001:root ownership and g+rwX permissions in Dockerfile.native and Dockerfile.native-package before declaring VOLUME and dropping to USER 1001. This elegantly resolves AccessDeniedException crashes when mapping Docker named volumes instead of local binds, natively supporting frictionless LocalStack-style drop-in architecture. * Standardizes named volumes as officially documented optional alternatives across docker-compose templates in quick-start, index, and README documentation for a cleaner repository drop-in replacement footprint. |
||
|
|
e96cf4212b | fix: trigger build actions | ||
|
|
61433f59ab | firt commit |