* fix(autoscaling): use the modeled XML namespace
Promote the complete retained fork #269 namespace correction and exact Query success/error/catalog assertions. Original feature by Jackson Price <jxnprice@amazon.com>, authored 2026-10-28; original source commit d094b6168031df46c708d4dce056580d7e631853 retained unchanged.
Co-authored-by: Jackson Price <jxnprice@amazon.com>
Signed-off-by: Andre Kurait <AndreKurait@gmail.com>
* test(autoscaling): share modeled namespace assertions
Share the package namespace assertion across the Query handler and integration tests. Preserve root and all-descendant checks, the returned Element, and all existing populated, empty and error response assertions.
Signed-off-by: Andre Kurait <AndreKurait@gmail.com>
Signed-off-by: Andre Kurait <akurait@amazon.com>
---------
Signed-off-by: Andre Kurait <AndreKurait@gmail.com>
Signed-off-by: Andre Kurait <akurait@amazon.com>
* fix(kinesisanalytics): paginate ListApplicationSnapshots
* test(kinesisanalytics): cover ListApplicationSnapshots pagination and bounds
* test(kinesisanalytics): pin the snapshot cursor contract in tests
Assert the delete in the resume-after-deletion test, and the surviving list
length, so a no-op delete cannot let the case pass vacuously. Accept a token
purely as a cursor up to the modeled 512 characters, since this NextToken
declares no pattern. Reuse the issued token instead of retyping the expected
cursor, and assert the page-size message on the wire.
* fix(cloudfront): tunnel WebSocket upgrades to custom origins as AWS does
CloudFront forwards WebSocket handshakes to the origin on every distribution, but
Floci's serving path is a JAX-RS resource that strips Upgrade and Connection and
fetches the origin with a blocking client, so a socket.io client behind a
distribution never left long-polling.
A Vert.x route ahead of JAX-RS now catches an HTTP/1.1 WebSocket handshake to a
distribution host, resolves the behavior and custom origin as the GET path does
(allowed methods, signed requests, origin request policy, origin custom headers,
private-address guard), sends the handshake with its upgrade fields and splices
the two connections once the origin answers 101. Any other answer is relayed as
an ordinary response, and handshakes the distribution would not tunnel fall
through to the existing GET handling. Handshake detection and the byte relay are
shared with the ALB data plane.
* fix(cloudfront): honor disabled service and origin timeouts on WebSocket refusals
The WebSocket route runs ahead of ServiceEnabledFilter, so it now checks that
CloudFront is enabled before taking a handshake and otherwise falls through to
the disabled-service answer.
An origin answer that refuses the upgrade is no longer piped without limits: its
body is streamed within the origin's response timeout between packets and its
response completion timeout in all, counting only the origin's time, and an
origin that stalls past them ends the viewer connection.
* test: share the ALB fixture between the WebSocket integration tests
CloudFrontWebSocketIntegrationTest repeated ElbV2WebSocketIntegrationTest's load
balancer, target group, listener and WebSocket exchange helpers. Both now use
AlbFixtures.
* refactor(cloudfront): have the WebSocket origin clock spend a shared CompletionBudget
* fix(dynamodb): refuse unconvertible and out-of-range PartiQL number parameters before parsing the statement
* fix(dynamodb): decode binary PartiQL parameters first, and count types while reading each parameter
* fix(dynamodb): take a PartiQL parameter member set to null as absent
* fix(dynamodb): drop null parameter members before IAM reads the PartiQL attributes
CreateBackupPlan and UpdateBackupPlan accept Rules[].TargetLogicallyAirGappedBackupVaultArn
(BackupRuleInput) and GetBackupPlan returns it on BackupRule, but the rule model had no such
field, so Jackson's ignoreUnknown dropped it on read. Add it, omitted from the response when
the request did not set it.
* fix(docker): start the Windows binary with or without Docker running
The 2.4.0 Windows standalone binary exited at startup with an
UnsatisfiedLinkError for Java_com_sun_jna_Native_open. docker-java's
named-pipe socket calls JNA when the pipe does not open at once, and
JNA was initialized at image build time, so its native dispatch library
was loaded into the builder and never into the binary. JNA is now
initialized at run time, its JNI metadata (from
oracle/graalvm-reachability-metadata, CC0) and a proxy registration for
NamedPipeSocket$Kernel32 are bundled, and FlociDockerHttpClient turns a
LinkageError from the transport into an exception, so a JNA that still
cannot load fails that one Docker call instead of the whole emulator.
With JNA working, a Windows host without Docker never answered its
health check: docker-java retries a missing pipe for the whole 30 s
connect timeout, and DockerRetry retried the NoSuchFileException six
times. The pipe is now opened once first and a missing or denied pipe
fails at once, keeping docker-java's wait loop for a busy pipe, and
DockerRetry no longer retries either error.
The release smoke script prints both ends of a long log on failure.
Signed-off-by: Hector Ventura <hectorvent@gmail.com>
* test(docker): skip the named-pipe client tests on Windows and name the tolerated exception
Both tests stand a temporary directory in for a pipe, which only behaves that way off Windows: there a directory opens as access-denied and Kernel32 loads. The busy-pipe catch now names its exception expected, as AGENTS.md asks for a tolerated one.
Signed-off-by: Hector Ventura <hectorvent@gmail.com>
---------
Signed-off-by: Hector Ventura <hectorvent@gmail.com>
LaunchTemplateInstanceNetworkInterfaceSpecification.Groups is a GroupIdStringList
whose members are named groupId, not item. aws-sdk-go-v2 reads only groupId, so
Terraform saw security_groups as empty and planned an update every time.
In the docker runner mode each step of a cluster ran in a container of its
own, so nothing a step left in /home/hadoop, or in HDFS, was there for the
next, and the image has no HDFS at all: an hdfs:// path failed, and a path
without a scheme, which EMR reads as HDFS, went to the container's own
disk. The Management Guide calls HDFS "best used for caching the results produced by
intermediate job-flow steps", the prefix "hdfs:// (or no prefix)", and
"ephemeral storage that is reclaimed when you terminate a cluster"; the
Release Guide's S3DistCp page copies data "into HDFS where it can be
processed by subsequent steps".
Now a cluster's storage outlives its steps:
- each step's container mounts the cluster's two Docker volumes, one at
/home/hadoop and one at /mnt, both of which the image gives its hadoop
user, so Docker gives an empty volume that owner, and what the cluster's
bootstrap left there in the image its steps run in;
- HDFS is /mnt/hdfs: Spark gets fs.defaultFS hdfs:/// and the hdfs scheme
through Hadoop's ViewFileSystemOverloadScheme with a fallback link to
that folder, so hdfs:// paths and those without a scheme lead there, a
relative one under /user/hadoop, and a streaming query keeps its
checkpoints through Spark's file system checkpoint manager, as
FileContext refuses an hdfs:// path without a host. The cluster's
spark-defaults can set any of these otherwise;
- a command step's hadoop fs gets the same, through a copy of the image's
Hadoop configuration, or of the folder a spark-env export of
HADOOP_CONF_DIR names, links followed, whose core-site.xml takes in
the original's through Hadoop's XInclude and then those properties,
with its HDFS, MapReduce and YARN homes set; hdfs dfs runs as hadoop
fs, the image's hdfs command being unable to run;
- the volumes go once the cluster has ended and its last step is done,
tried again while Docker refuses, as the bootstrap's image is; on a
reset, a step's thread it overtook removing them again once its
container is gone; and, for clusters that are gone or have ended, when
the service starts, unless reconcile-containers-on-startup is off.
SparkJobRunner.Job carries the storage, which an EMR Serverless run leaves
null. ClusterStorage names, makes and removes the volumes;
EmrClusterStorage is its Docker side. A path without a scheme that a step
meant for its container's own disk now leads to HDFS, as on EMR. emr.md
says what HDFS lacks: no NameNode, no hdfs:// path with a host, no
hadoop fs -ls / and no S3 through hadoop fs.
* fix(s3): refuse a malformed or empty versionId with 400 InvalidArgument
S3 refuses a version id it did not mint with 400 InvalidArgument,
also on a missing key, and an empty versionId with its own message.
Floci mints every version id as a UUID, so it refuses any other value
on the object operations that take a version id.
* docs(s3): say an unknown UUID version id is handled as a missing version
* feat(stepfunctions): dispatch ECS Lambda mapping and secret SDK tasks
* fix(stepfunctions): render ECS task-set StabilityStatusAt as ISO-8601
* refactor(stepfunctions): share recase and timestamp helpers with SDK management invoker
Reuse AslExecutor.recaseKeys (with a verbatim-key set), capitalizeFirst and a
single renderSdkTimestamps walker instead of copies in SdkManagementTaskInvoker,
and inject the invoker through the AslExecutor constructor.
* fix(s3): name the key and version in NoSuchVersion errors
Every NoSuchVersion error names the key and the version id, and an
annotation request for a missing version answers NoSuchVersion
instead of NoSuchKey, as on S3.
* test(s3): check annotation put and delete and a missing key for NoSuchVersion
* refactor: read ARN resources through AwsArnUtils in EventBridge, Pipes and three more
Archive, replay and Pipes event-bus targets, Pipes Kinesis sources, MicroVM image and network
connector tags, Cloud Map tags and ECS service registries cut an ARN at its last '/' or ':'
by hand. They now read the resource with AwsArnUtils.resourceIfArnFor, which also checks the
service. A Pipes Kinesis source given as a stream-consumer ARN names its stream instead of
"consumer:timestamp", and an ECS registryArn that is not a Cloud Map service ARN is ignored
with the existing warning.
Signed-off-by: Hector Ventura <hectorvent@gmail.com>
* fix(lambda): read a MicroVM tag target the same way for IAM and the tag paths
TagResource takes only an ARN, and a network connector without a version. LambdaMicrovmsService.taggedResource is now the one reader for both the tag paths and ResourceArnBuilder, so a version-qualified connector is refused instead of reaching the bare connector while IAM checks another resource.
Signed-off-by: Hector Ventura <hectorvent@gmail.com>
---------
Signed-off-by: Hector Ventura <hectorvent@gmail.com>
Promote the complete retained fork #235 listener lookup validation and affected SDK and CloudFormation regressions on the qualified main base. Preserve the original compatibility fixture and JUnit SDK adapter.
Signed-off-by: Andre Kurait <AndreKurait@gmail.com>
* fix(s3): answer a GET or HEAD that reaches a delete marker as S3 does
A read of a key whose current version is a delete marker sends the
marker's headers with the 404, and a versionId that names a delete
marker is 405 MethodNotAllowed, as on S3.
* fix(s3): name the key in NoSuchKey errors
Every NoSuchKey error names the key in a Key element, and
GetObjectTagging names it with its bucket, as on S3.
* fix(ec2): include r5.large in the instance type catalog
Promote the complete retained fork #234 catalog entry and SDK regression on current main. Keep catalog metadata and offerings consistent.
Signed-off-by: Andre Kurait <AndreKurait@gmail.com>
* test(ec2): use JUnit and Hamcrest for R5 catalog assertions
Preserve all 18 metadata and offering assertions while following the src/test assertion conventions requested in review.
Signed-off-by: Andre Kurait <AndreKurait@gmail.com>
---------
Signed-off-by: Andre Kurait <AndreKurait@gmail.com>
A write in a versioning-suspended bucket makes the version or delete
marker it replaces noncurrent, and deleting versionId=null makes the
newest of them current again, as on S3.
* feat(cloudformation): provision AWS::EC2::KeyPair with its private key in Parameter Store
AWS::EC2::KeyPair had no provisioner, so a stack stubbed it: the stack
reached CREATE_COMPLETE without creating a key, Ref returned a made-up
id and Fn::GetAtt returned the literal "Key.KeyPairId". A template that
creates a key pair for an instance, as the AWS::EC2::KeyPair reference
shows, got nothing to log in with.
The new provisioner does what that reference describes:
- Without PublicKeyMaterial it calls CreateKeyPair with the template's
KeyType and KeyFormat, so rsa and ed25519 keys and pem and ppk files
all work, and stores the private key in the SecureString parameter
/ec2/keypair/<KeyPairId>. With PublicKeyMaterial it imports the key,
takes the key's type from the material (KeyType is ignored, as
documented) and writes no parameter.
- Ref is the key name; Fn::GetAtt KeyPairId and KeyFingerprint are the
key's own.
- Tags are applied once the key exists and the parameter is written
last, so a step that fails leaves only the key to undo. Deleting a
created key deletes its parameter first, on stack delete, rollback
and replacement cleanup alike; a key or parameter already gone counts
as deleted. A key is deleted by its name, as Cloud Control's
DeleteResource names it; a key deleted outside the stack still has
its parameter deleted with the stack.
- Only AWS::NoValue leaves a property out; an empty string a parameter
supplies is a value, as the same string written literally is. An
empty PublicKeyMaterial fails with the MissingParameter error
ImportKeyPair gives for it.
- Every property is create-only (the registry schema has no update
handler) and KeyName is required. An update that changes another
property under the same name is refused with CloudFormation's
custom-named replacement error. A rename creates the new key, then
deletes the old one with its parameter once the update commits, or
deletes the new one if the update rolls back.
The create-only list is added to create-only-properties.json, so a
change set reports a changed name or type as a replacement, and the
generated resource-type table lists KeyPair.
Signed-off-by: Jackson Price <59149601+jprice8@users.noreply.github.com>
* fix(cloudformation): delete orphaned key pair parameters on cleanup
Replacement cleanup and rollback delete a displaced or rolled-back
AWS::EC2::KeyPair by name only. When that key had already been deleted
outside the stack, its /ec2/keypair/<KeyPairId> SecureString parameter
was left behind.
Record the id of each created key the resource still owes a delete,
keyed by name, so the cleanup, the rollback and a rollback retry also
delete that key's parameter. Imported keys have no parameter and are
not recorded.
Signed-off-by: Jackson Price <59149601+jprice8@users.noreply.github.com>
* fix(cloudformation): end a key pair's rollback retry when an update starts
A rollback that could not delete a renamed key pair's replacement leaves
it owed for ContinueUpdateRollback. Once that skipped the resource, a
later update that failed before creating anything rolled back by
retrying that old delete instead of undoing itself, and could end in
UPDATE_ROLLBACK_FAILED.
Call ReplacementCleanup.endRollbackRetry as an update starts, as the
other replacing provisioners do. The replacement stays listed, so the
next committed update or the stack delete still removes it.
Signed-off-by: Jackson Price <59149601+jprice8@users.noreply.github.com>
* test(cloudformation): say the rollback retry test pins a helper contract
The test added with the endRollbackRetry call rolls back the same
resource whose update failed. The engine does not do that for a key
pair today: it restores the previous resource and skips its rollback,
so the earlier commit's UPDATE_ROLLBACK_FAILED scenario is not
reachable yet. Say that the test pins the ReplacementCleanup contract
instead.
Signed-off-by: Jackson Price <59149601+jprice8@users.noreply.github.com>
* fix(cloudformation): clean up partial KeyPair parameter writes
* refactor(cloudformation): share KeyPair create-only tracking
---------
Signed-off-by: Jackson Price <59149601+jprice8@users.noreply.github.com>
* fix(lambda-web): answer a delete marker as the code object as AWS does
A delete marker as the latest version is refused with AWS's own
message, and a versionId that names a delete marker is an internal
error, as on AWS.
* test(lambda-web): cover the null delete marker of a suspended bucket
* fix(elbv2): accept request headers up to 64 KB as AWS does
ALB listeners used Vert.x's default 8 KB maxHeaderSize, so a request with
several JWT cookies got 431 Request Header Fields Too Large. AWS ALBs accept
up to 64 KB of request headers. Raise the listener limit and the target proxy
client's response-header limit to match.
* fix(elbv2): apply the ALB response header and request line quotas
Size the proxy client for the 32 KB response header quota and raise the
listener's request line limit to 16 KB. The large-header test now stays
under the 16 KB single-header limit, sends a 10 KB query, and reads the
data plane's constants.
* fix(bedrock-agentcore): save a runtime's create tags with the runtime
The controller added the tags to the runtime after the service had already
stored it. WAL and persistent storage had written the record by then, so the
tags were lost on a crash unless something later saved the runtime again. The
same code ran on a clientToken replay and merged the retry's tags into the
original runtime.
Pass the tags into createAgentRuntime and set them before storage.put, as
CreateMemory does. The replay path returns before that point, so it no longer
changes them. CloudFormation keeps the existing overload because it applies
tags in its own rollback-guarded step.
Fixes#7126
* test(bedrock-agentcore): tighten the runtime create tag tests
The replay test ignored the second create's ARN, so it would still pass if
the retry created a second runtime. Assert that both creates return the same
ARN.
The WAL test started its try block after setup, so a failure there left both
stores and their compaction threads running. Guard each store from the point
it is constructed.
NuGet's native v3/package route can now retain a missing package version
from a repository's own public:nuget-org external connection and serve
it, instead of always 404ing, matching AWS's documented external-
connection behavior already shipped for Maven.
- A version's retention origin is claimed atomically before any fetch
happens, rejecting a later attempt under a different connection
outright ("checking asset origins").
- Package-level upstream: BLOCK is respected, including when the
restriction and the request spell the package name differently
(nuget/pypi names are case/punctuation normalized everywhere this
service tracks a package; PackageOriginConfig now keys by that same
normalization too, instead of the caller's raw spelling).
- A retained version reports originType: EXTERNAL and its source
connection through DescribePackageVersion/ListPackageVersions, for
any format that retains (not just Maven).
- A concurrent retention attempt racing a real client's own direct
push is never mislabeled as an external import: existence in the
real sidecar alone no longer implies success, only a confirmed claim
under the exact same connection does.
- Retained bytes are counted toward DescribeDomain's assetSizeBytes,
never double-counted on a concurrent retry.
- A real HTTP redirect from the public repository is followed instead
of being treated as a 404.
- Fixed-version retention only; resolving a floating/omitted version by
merging in nuget.org's own version listing is left for a follow-up,
the same baseline scope Maven's own external-connection work shipped
first.
New: NuGetExternalConnectionClient (the outbound client for
public:nuget-org) and CodeArtifactNuGetExternalConnectionImporter (the
retention decision logic), wired into CodeArtifactNuGetController.
The claim/fence/deploy machinery CodeArtifactService already used for
Maven's own external-connection retention is generalized into
format-parameterized methods so npm and pypi can reuse it too, with
Maven's own public methods kept as thin, behavior-identical delegates
over the generic ones.
In the docker runner mode the user guide's way of giving an EMR
Serverless job run its Python libraries did nothing. "Building a Python
virtual environment" packs a virtualenv into an archive in S3 and
submits the job with:
--conf spark.archives=s3://.../pyspark_venv.tar.gz#environment
--conf spark.emr-serverless.driverEnv.PYSPARK_DRIVER_PYTHON=./environment/bin/python
--conf spark.emr-serverless.driverEnv.PYSPARK_PYTHON=./environment/bin/python
--conf spark.executorEnv.PYSPARK_PYTHON=./environment/bin/python
Floci set no driverEnv variable on the driver's container, and Spark in
local mode unpacks spark.archives into a temporary files folder of its
own once the driver's Python has started, not into the working
directory. With the variables set, the driver could not start: "Cannot
run program "./environment/bin/python"".
Now:
- a spark.emr-serverless.driverEnv.<KEY> property ("Option that adds
environment variables to the Spark driver"), from the run's
spark-defaults or a --conf in its sparkSubmitParameters, which wins,
is an environment variable of the driver's container, replacing one
of Floci's own of that name;
- each archive of spark.archives (which spark-submit's own --archives
sets, winning over a --conf, as in Spark) in Floci's S3 is read as the
run's account, streamed into the created container and unpacked into
its working directory before spark-submit starts, under the name after
its # or else its file's name, as Spark's Utils.unpack does it (.jar
and .zip unzipped, .tar.gz, .tgz and .tar untarred, anything else
copied). The guide's venv-pack example puts the environment in
/home/hadoop/environment, and /home/hadoop is the image's working
directory. An archive that cannot be read fails the run before its
driver starts, naming it; a cancel, a reset or a shutdown while they
are put in ends the copy and puts in no other.
SparkJobRunner.Job carries the archives, which classic EMR's steps
leave empty. Spark still unpacks each archive into its own files folder
too, where SparkFiles.get finds it, and gives spark.executorEnv
variables to the Python workers it starts, so those need nothing more.
* fix(sts): cap account-root token durations at one hour
Cap GetSessionToken and GetFederationToken credentials issued to the account-root identity at one hour, preserving IAM user durations and validation ordering.
Signed-off-by: Andre Kurait <AndreKurait@gmail.com>
* test(sts): bound root token expiry by request time
Check the one-hour default using timestamps captured before the request and after the response, allowing millisecond wire precision. Preserve the root duration cap.
Signed-off-by: Andre Kurait <AndreKurait@gmail.com>
---------
Signed-off-by: Andre Kurait <AndreKurait@gmail.com>
* fix(cloudwatch): decompress gzip JSON PutMetricData bodies
The AWS CLI and the SDKs that speak JSON 1.0 to CloudWatch gzip a
PutMetricData body of 10 KiB or more and send Content-Encoding: gzip.
AwsJsonController binds the body as a String, so Floci read the
compressed bytes as text and every such request failed with HTTP 400
SerializationException. The metrics were never stored.
Add a reader interceptor that decompresses that one operation's body
when the controller reads it. It runs after every request filter, so
the signature is still verified over the compressed bytes the client
signed, and IAM still decides the request from X-Amz-Target first,
which is sound because nothing in that decision comes from the body.
The decompressed body is bounded by the decoder the CBOR protocol
already uses: past 10 MiB it returns HTTP 413 PayloadTooLargeException,
and a body that cannot be decompressed returns HTTP 400
InvalidRequestException, both in the controller's JSON error format.
A name binding keeps the interceptor on AwsJsonController alone, so
every other resource reads its body as before. In the native image a
global reader interceptor breaks the tag endpoints that resources
inherit from AbstractTagsController, because Quarkus REST then looks
their methods up reflectively.
Signed-off-by: Jackson Price <59149601+jprice8@users.noreply.github.com>
* test(cloudwatch): publish a compressed metric batch through boto3
botocore gzips a PutMetricData body of 10 KiB or more, and with the
pinned boto3 it calls CloudWatch over JSON 1.0. The Python
compatibility suite only ever sent a handful of datums, so it never
sent a compressed request.
Send a 100-datum batch, check that botocore sent it as JSON 1.0 with
Content-Encoding: gzip, and check that all 100 metrics are listed
afterwards. Checking the content type keeps the test from passing
through the CBOR path, which already decompressed gzip, should a later
botocore prefer CBOR.
Signed-off-by: Jackson Price <59149601+jprice8@users.noreply.github.com>
* chore(cloudwatch): reuse signed IAM test users
---------
Signed-off-by: Jackson Price <59149601+jprice8@users.noreply.github.com>
* fix(eks): tag node groups, Fargate profiles, add-ons, pod identity associations and access entries by ARN
TagResource, UntagResource and ListTagsForResource read the text after an ARN's last '/' as a cluster name, so a node group, Fargate profile, add-on, pod identity association or access entry ARN looked up a cluster named after its id and answered ResourceNotFoundException. The ARN is now parsed and routed by its resource type to the store that holds that resource, and a child ARN reaches the resource only when it matches the stored ARN.
Signed-off-by: Hector Ventura <hectorvent@gmail.com>
* fix(eks): answer TagResource and UntagResource with 200
The EKS model declares no responseCode on either tag write, so both answer 200, but EksService kept the shared tag route's 204 default.
Signed-off-by: Hector Ventura <hectorvent@gmail.com>
* fix(eks): lock tag writes and keep tags within the TagMap limits
The child retag methods now share their service's lock, so a tag write
racing a delete or disassociate can no longer restore the record it read.
TagResource checks the merged tags against the TagMap limits for every
resource type, and the tag operations answer the BadRequestException and
NotFoundException the model declares. A resource ARN with an empty
cluster or child segment is a bad request instead of a server error.
Signed-off-by: Hector Ventura <hectorvent@gmail.com>
---------
Signed-off-by: Hector Ventura <hectorvent@gmail.com>
A property the previous template declared and the new one drops is now
cleared on update for the EC2 network types: Tags on Subnet,
InternetGateway, RouteTable, NatGateway, EIP and PrefixList, and
MapPublicIpOnLaunch on Subnet, which goes back to false. A property the
stack never declared keeps what was set outside it. A failed update puts
the cleared tags and the flag back from the existing in-place snapshot.
Refs #6606