* fix(kms): return false for GetKeyRotationStatus on asymmetric/HMAC keys
AWS updated GetKeyRotationStatus behavior so asymmetric and HMAC keys
return { KeyRotationEnabled: false } instead of UnsupportedOperationException.
EnableKeyRotation and DisableKeyRotation still reject these key types.
* fix(kms): return false for GetKeyRotationStatus on asymmetric/HMAC keys
AWS updated GetKeyRotationStatus behavior so asymmetric and HMAC keys
return { KeyRotationEnabled: false } instead of UnsupportedOperationException.
EnableKeyRotation and DisableKeyRotation still reject these key types.
* feat(lambda): add bind-mount hot-reload mode via S3Bucket=hot-reload
Functions created with S3Bucket=hot-reload and S3Key=/absolute/path
have their host directory bind-mounted into /var/task rather than
packaged as a ZIP. Each invocation runs an ephemeral container so
file changes on disk are picked up immediately without calling
UpdateFunctionCode or re-uploading code.
Feature is disabled by default; opt in with:
FLOCI_SERVICES_LAMBDA_HOT_RELOAD_ENABLED=true
An optional path allowlist (FLOCI_SERVICES_LAMBDA_HOT_RELOAD_ALLOWED_PATHS)
restricts which host directories may be bind-mounted.
* fix: missing hot reload enable env
* feat(lambda): embedded DNS server for virtual-hosted S3 resolution
Lambda containers cannot resolve virtual-hosted S3 URLs
(my-bucket.floci:4566) because Docker DNS has no wildcard support —
queries for *.floci fall through to public DNS and hit real AWS.
Adds a Vert.x UDP/53 DNS server that binds automatically when Floci
runs inside Docker. It resolves any *.{floci.hostname} query to
Floci's container IP and forwards everything else upstream. Lambda
containers receive Floci's IP as their DNS server via HostConfig.withDns().
An optional floci.dns.extra-suffixes config allows LocalStack migrants
to route *.localhost.localstack.cloud without changing Lambda code.
Netty NioDatagramChannel was tried first but silently dropped IPv4
UDP packets due to AF_INET6 socket defaults — Vert.x DatagramSocket
with setIpV6(false) resolves this.
* fix: adding missing dns class
* 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.
* feat(athena): real SQL execution via floci-duck DuckDB sidecar
- Lazy-start floci/floci-duck:latest on first StartQueryExecution call;
reuse the running container for all subsequent queries
- Inject Glue tables as CREATE OR REPLACE VIEW statements via setup_sql
before the user SQL so DDL runs outside the COPY(...) wrapper
- SerDe-aware format inference: inferReadFunction now checks
SerdeInfo.SerializationLibrary in addition to InputFormat, so standard
AWS JSON tables (TextInputFormat + JsonSerDe) map to read_json_auto
- ImageCacheService: skip Docker Hub pull when image is already present
locally, preventing local builds from being overwritten
- Add AthenaIntegrationTest (5 unit integration tests)
- Add AthenaTest and DataLakeTest SDK compatibility tests
- Update docs: athena.md (full rewrite), glue.md, README, CHANGELOG
* fix: docker image check fix
* feat(ses): implement email template CRUD with stored, inline, and ARN variants
Adds CreateTemplate / GetTemplate / UpdateTemplate /
DeleteTemplate / ListTemplates on both V2 REST JSON
(/v2/email/templates) and V1 Query.
SendEmail / SendTemplatedEmail resolve templates in three forms
with Mustache-style {{var}} substitution against TemplateData:
- TemplateName references a stored template
- TemplateArn extracts the name from the template/<name>
segment of an SES template ARN (region and account segments
are not validated, mirroring how KMS / Secrets Manager
handle ARNs in Floci)
- TemplateContent (V2 only) supplies inline subject / text /
html without storing the template first
V2 Content.Template requires exactly one of TemplateName,
TemplateArn, or TemplateContent; violations return
BadRequestException (400). V1 SendTemplatedEmail accepts
TemplateArn either alone or alongside Template (name) — the
name is used for resolution when both are present, matching
AWS where boto3 and the Java SDK keep Template as a required
field and treat TemplateArn as supplementary for cross-account
addressing.
Templates persist region-scoped via StorageFactory in
ses-templates.json. Template names reject leading/trailing
whitespace (same rule as identities) and are validated through
a single validateTemplateName helper reachable from every
resolution path. listTemplates is sorted by CreatedTimestamp
with TemplateName as a tiebreaker for deterministic output.
Error codes: the service layer throws V1-style codes
(TemplateDoesNotExist / AlreadyExists / InvalidTemplate /
InvalidParameterValue); SesController remaps them to
NotFoundException (404) / AlreadyExistsException (400) /
BadRequestException (400) for V2 callers.
* test(ses): add Python and Java SDK compatibility tests for templates
Covers boto3 (ses / sesv2) and AWS Java SDK v2 (SesClient /
SesV2Client) against the SES email template CRUD, inline
TemplateContent, and TemplateArn paths. Happy path,
duplicate-create rejection, missing-template lookups,
Mustache-style variable substitution, and 3-way selector
conflicts on V2 Content.Template are exercised on both SDK
surfaces.
Adds:
- Python: ses_client / sesv2_client conftest fixtures and a
tests/test_ses_templates.py suite covering V1 + V2
- Java: sesv2 Maven dependency, SesV2Client factory in
TestFixtures, and a SesTemplateTest covering V1 + V2
* docs(ses): document email template CRUD and templated send
Adds the new V1 template actions (CreateTemplate / GetTemplate
/ UpdateTemplate / DeleteTemplate / ListTemplates /
SendTemplatedEmail) and the V2 /v2/email/templates endpoints
to the SES service reference, and extends the README service
matrix to mention template support on the SES / SES v2 rows.
* fix(ses): add template actions to SES_ACTIONS for unsigned request routing
Unsigned clients (curl, aws --no-sign-request) were falling through to
the SQS handler because the six template Query actions were not
registered in SES_ACTIONS.
* fix(ses): narrow exception catch to JsonProcessingException in template endpoints
Broad Exception catch was masking unexpected errors (e.g. NPE) as 400
responses. Narrowed to JsonProcessingException which is the only
checked exception from objectMapper.readTree().
* test(ses): add template variable substitution edge cases and cross-region isolation
Add SesServiceTemplateTest with 14 unit tests for applyTemplateData
covering undefined variables, spaced/hyphenated names, unclosed braces,
non-string JSON values, regex metacharacters, and case sensitivity.
Add cross-region isolation integration test verifying templates created
in one region are not visible in another.
* test(ses): add awscli compatibility tests for template CRUD and templated send
Cover create, get, update, list, delete template and send-templated-email
via the AWS CLI. Uses JSON parameter format to avoid awscli parser issues
with Mustache-style {{variable}} syntax.
---------
Co-authored-by: Kenshin OKINAKA <kenshin_okinaka@realcross.co.jp>
* feat(cognito): add TagResource, UntagResource, ListTagsForResource for user pools
Dispatch the three Cognito IDP tag operations through CognitoJsonHandler and
resolve user pools by parsing the resource ARN (O(1) pool-store lookup, not a
full scan). Malformed ARNs now surface as InvalidParameterException rather
than a swallowed ResourceNotFoundException.
Reject reserved floci:* keys on standalone TagResource via
ReservedTags.rejectReservedTagsOnUpdate, matching the existing strip-on-write
behavior on CreateUserPool / UpdateUserPool. Mutations are synchronized on
the pool instance to match the ensureJwtSigningKeys pattern.
Covered by new unit tests (CognitoServiceTest, CognitoJsonHandlerTest), AWS
CLI bats (cognito.bats), and Java SDK compat tests (CognitoFeaturesTest).
* chore: retrigger CI
Allow KMS CreateKey and Cognito CreateUserPool to accept a reserved floci:override-id tag at creation time so tests can pin deterministic resource IDs without a lookup round trip.
Strip reserved floci:* tags from stored metadata and responses, reject reserved tags on KMS TagResource, wire KMS CloudFormation provisioning through tagged key creation, and add focused unit, handler, integration, and AWS CLI bats coverage for the new behavior.
Adds a background dispatcher that reads persisted schedules and invokes their
targets on time, closing the CRUD-only gap called out in PR #260 and
documented under "Not Yet Supported".
- SchedulerExpressionParser parses at(), rate(), and 6-field cron() with
optional ScheduleExpressionTimezone (default UTC).
- ScheduleInvoker delivers to SQS, Lambda, SNS, and EventBridge PutEvents,
mirroring the EventBridgeInvoker pattern but adapted to Scheduler's Target
model (raw Input string, no JSONPath/template).
- ScheduleDispatcher is a single-threaded ticker that scans every schedule,
gates on State/StartDate/EndDate, fires due schedules, and honours
ActionAfterCompletion=DELETE for one-time at() schedules.
- FlexibleTimeWindow, RetryPolicy and DeadLetterConfig are stored but not
yet honoured; those can be layered on incrementally.
Config (floci.services.scheduler):
- invocation-enabled (default true)
- tick-interval-seconds (default 10)
Unit tests cover the parser (at/rate/cron, timezone, validation) and the
dispatcher (firing, once-semantics, delete-after-completion, state gating,
start/end windows, unsupported expression handling).
Closes#550
* feat(ses): add SMTP relay configuration to EmulatorConfig
Add smtp-host, smtp-port, smtp-user, smtp-pass, and smtp-starttls
settings to SesServiceConfig. smtp-host is Optional — when absent or
empty, relay is disabled and emails are stored only (existing behavior).
* feat(ses): implement SMTP relay with Vert.x MailClient and Mime4j
Add SmtpRelay that forwards SES emails to a configured SMTP server
using a dedicated Vert.x MailClient built from EmulatorConfig settings.
Simple emails are sent as MailMessage with From/To/Cc/Bcc/ReplyTo/
Subject/Text/Html. Raw MIME emails are parsed with Apache Mime4j to
extract headers and body, then sent via the same MailClient. When SES
Destinations is provided, it is used as the authoritative envelope
recipient list (MIME Cc headers do not add extra SMTP recipients).
Relay is dispatched asynchronously on a dedicated daemon thread with
a 30-second send timeout. Failures are logged with stack traces but
never affect the API response. The executor and MailClient are only
created when smtp-host is configured and ses.enabled is true, and
shut down in @PreDestroy.
SesService calls SmtpRelay.relay/relayRaw after storing emails so
the inspection endpoint always has the data regardless of relay.
Tests: SmtpRelayTest (12 cases) covers simple/raw relay, disabled
path, error swallowing, base64 decoding, HTML content type, envelope
fallback. SesServiceSmtpTest (5 cases) verifies relay integration
and store persistence.
* docs(ses): document SMTP relay configuration
Add SMTP Relay section to docs/services/ses.md with configuration
example, docker-compose snippet with Mailpit, and behavioral notes.
Add SMTP settings to the YAML sample and environment variable table
in docs/configuration/application-yml.md.
* fix(ses): preserve body against attachment overwrite and extract Bcc from raw MIME
- extractBodyFromEntity now only sets text/html when not already set, so a
text-typed attachment in multipart/mixed cannot clobber the body picked up
from multipart/alternative.
- doRelayRaw now reads Bcc from MIME headers alongside To/Cc when the caller
did not supply Destinations.
* fix(ses): initialize Vert.x NTLMEngineImpl at run time for native image
The vertx-mail-client dependency brings in io.vertx.ext.mail.impl.sasl.NTLMEngineImpl,
whose static state embeds a SecureRandom instance. GraalVM native-image rejects
build-time Random/SecureRandom objects because the cached seed makes runtime
behavior unpredictable. Mark the class for run-time initialization, matching the
existing entry for the Apache HttpClient NTLM engine.
Shutdown hooks could not reach Floci's HTTP endpoint (e.g.
`aws --endpoint-url http://localhost:4566 ...`) because they ran in
the ShutdownEvent observer, which Quarkus fires only AFTER the HTTP
server has already stopped.
Split the lifecycle:
- onPreShutdown(@Observes ShutdownDelayInitiatedEvent) runs stop hooks
while the HTTP server is still accepting connections.
- onStop(@Observes ShutdownEvent) handles resource cleanup only.
Enable the pre-shutdown phase via `quarkus.shutdown.delay-enabled:
true`. No `delay` value is set, so observers run synchronously with
no artificial sleep introduced.
Swallow all hook failures (including InterruptedException) without
restoring the interrupt flag, so the subsequent ShutdownEvent cleanup
phase always runs with a clean thread state and resource shutdown is
guaranteed even when hooks fail.
Fixesfloci-io/floci#431
* feat(lambda): support ScalingConfig.MaximumConcurrency on SQS event source mappings
Wire-level support for ScalingConfig on CreateEventSourceMapping,
UpdateEventSourceMapping, GetEventSourceMapping, and
ListEventSourceMappings:
- New ScalingConfig model carrying MaximumConcurrency (Integer, nullable).
- Create and Update parse ScalingConfig from the request, validate range
(2-1000), reject non-SQS event sources with InvalidParameterValueException.
- Response includes ScalingConfig only when a cap is set; omitted when
null, matching AWS behavior.
- Update with an empty ScalingConfig clears the cap (AWS reset semantics).
The value is persisted on the EventSourceMapping but not yet enforced at
invocation time — the SQS poller today serializes to one concurrent
invocation per ESM regardless. Real parallel dispatch capped by
MaximumConcurrency is a follow-up (Scope B).
Tests:
- EsmIntegrationTest: 6 new cases covering round-trip, below/above range
rejection, non-SQS rejection, omission when unset, add-then-clear via
update.
- LambdaEsmScalingConfigTest (SDK compat): 5 cases verifying SDK typed
ScalingConfig round-trips, InvalidParameterValueException on range
violations, and add/clear lifecycle via update.
* fix(lambda): reject non-integer MaximumConcurrency and ScalingConfig on non-SQS sources
- parseScalingConfig now detects fractional values (e.g. 2.5) and
returns InvalidParameterValueException instead of silently truncating.
- Empty ScalingConfig ({}) on a non-SQS event source is now rejected.
Previously the non-SQS check only fired when MaximumConcurrency was
non-null, so an empty ScalingConfig on Kinesis / DynamoDB Streams
slipped through.
- Two new integration tests cover both cases.
* fix(lambda): tighten ScalingConfig input validation
- Reject non-object ScalingConfig (e.g. "foo", []) with 400 instead of
silently treating it as absent. In update paths this previously cleared
an existing cap unintentionally.
- Reject non-numeric MaximumConcurrency (e.g. string "7"). AWS expects a
JSON number on the wire; the previous toString + parseInt path accepted
strings that real AWS would reject.
- Use longValue() before range-checking to avoid intValue() overflow on
large inputs (e.g. 5000000000) that would produce a negative value and
a misleading error message.
- Two new integration tests: string MaximumConcurrency and non-object
ScalingConfig.
* fix(lambda): add NaN/Infinity guard and expand ScalingConfig test coverage
- parseScalingConfig now explicitly rejects NaN and Infinity rather than
letting them fall through to longValue() with a misleading error.
- The post-range non-SQS guard was flagged as dead code by the reviewer
but is in fact reachable (non-SQS + valid numeric MaximumConcurrency).
Retained and confirmed by the existing @Order(43) test.
- New tests: update range validation (below/above on PUT), and list
with mixed ScalingConfig presence across ESMs.
* fix(ecr): fixing port and network issues on ecr
* fix: issue on merge with main
* fix(ecr): connect containers to network after start only when port bindings exist
Adds a bedrock-runtime service stub so AWS SDK and CLI clients can target
Floci for local development of Bedrock Runtime callers. Dummy responses
only: no real model inference.
- Register bedrock-runtime in ResolvedServiceCatalog under both "bedrock"
and "bedrock-runtime" credential scopes (boto3 signs with signingName
"bedrock" while some clients use the endpoint id)
- POST /model/{modelId}/converse returns a fixed assistant message plus
synthetic usage and latency metrics matching the AWS Converse contract
- POST /model/{modelId}/invoke returns an Anthropic-shaped body for
anthropic.* and *.anthropic.* model ids, generic {"outputs": [...]}
otherwise. Request body is passed through as opaque bytes
- {modelId:.+} path regex accepts full ARNs (inference profiles,
provisioned throughput) in addition to plain ids
- converse-stream and invoke-with-response-stream return 501 so SDKs
get a clear error instead of 404
- Response building uses JsonNode rather than typed POJOs, avoiding
native-image reflection registration
13 new integration tests (Converse + InvokeModel happy paths, validation,
inference-profile ids and ARNs, 501 streaming responses). Full suite
remains green: 2263 tests, 0 failures.
* feat: implement local Data Lake stack (Athena, Glue, and Firehose)
* fix: adding athena, firehose and glue documentation
* fix: updating dataLateTest
* feat(lambda): enforce reserved concurrency at invocation time
Introduce LambdaConcurrencyLimiter using AtomicInteger + CAS. Acquire a
permit before invoke and release in finally for both sync and async
paths. DryRun skips enforcement. Functions without a reserved value are
not enforced in this step (account-pool enforcement will follow).
Reset inflight counters when a function is deleted to prevent leaks.
* test(lambda): use JUnit Assertions in LambdaConcurrencyLimiterTest
AssertJ is not on the unit-test classpath; switch to the Jupiter
assertions already used by sibling tests.
* feat(lambda): enforce account-wide concurrency pool and validate Put
Extend LambdaConcurrencyLimiter with an account-shared unreserved pool
sized as accountLimit - Σreserved. Functions without a reserved value
now share this pool; exhaustion returns TooManyRequestsException.
PutFunctionConcurrency rejects values that would leave less than
unreserved-concurrency-min (AWS default: 100) available, matching AWS's
LimitExceededException behavior.
Config: floci.services.lambda.account-concurrency-limit (default 1000)
and floci.services.lambda.unreserved-concurrency-min (default 100).
Docs and controller javadoc updated accordingly.
* feat(lambda): rehydrate reserved concurrency and handle throttle in pollers
On startup, LambdaService walks functionStore.listAll() and re-registers
reserved values with the limiter so validatePut and the unreserved pool
see the correct totals before the first Put of the session.
SQS/Kinesis/DynamoDB Streams pollers now catch TooManyRequestsException
explicitly. SQS lets messages return via visibility timeout; Kinesis and
DynamoDB Streams skip advancing the shard iterator, so records are
redelivered on the next poll.
* test(lambda): add SDK compatibility tests for concurrency enforcement
Verify end-to-end wire behavior: LimitExceededException on Put that
violates unreserved-min, TooManyRequestsException on Event invoke when
reserved=0, and DryRun bypassing the concurrency gate.
* fix(lambda): close concurrency races in limiter and rehydrate
- Recompute cap inside the unreserved CAS loop so concurrent setReserved
does not leave permits granted above the live pool.
- Replace validatePut + setReserved with a single validateAndSetReserved
guarded by a reservedLock; concurrent Puts for different functions
can no longer each pass validation against stale totals.
- Rehydrate only $LATEST entries so published versions do not
double-count into totalReserved().
* fix(lambda): address PR review feedback
- Partition limiter state by region. AWS Lambda concurrency is per
account-per-region; functions in different regions no longer share
the same reserved totals or unreserved pool.
- PutFunctionConcurrency and DeleteFunctionConcurrency now roll back
the limiter update if functionStore.save() fails, so limiter and
persisted state stay consistent.
- Replace the awkward (InvokeResult) null cast in the DynamoDB Streams
poller with a plain forward declaration.
* refactor(lambda): rename account-concurrency-limit to region-concurrency-limit
The limit applies per-region (AWS Lambda's "account-level" quota is
actually per-account-per-region). Rename the config key, field, and
accessor to match what the value controls, and clarify the doc note.
No functional change.
* fix(lambda): O(1) region total and compare-and-rollback on save failure
- Maintain per-region AtomicInteger running total of reserved values,
updated under reservedLock on every mutation. acquireUnreserved reads
the cap in O(1) without iterating the map, eliminating the weakly-
consistent partial-sum window that existed when reads happened off
the lock while writes were serialized.
- Replace unconditional rollback with rollbackReservedIfExpected: the
limiter only restores the previous value if the current entry still
matches what the caller wrote, so a concurrent successful Put cannot
be clobbered by an earlier request's rollback after its save fails.
* docs(lambda): scrub remaining account-wide wording and document drain semantics
Replace lingering "account-wide" / "account pool" phrasing with
per-region terminology in the controller javadoc and unit-test comment.
Two references remain by design: EmulatorConfig and the lambda service
doc quote AWS's own "account-level" label to explain the renamed key.
Also fold two follow-up review items into this change:
- Replace fully-qualified AwsException / InvokeResult references in the
SQS, Kinesis, and DynamoDB Streams pollers with normal imports.
- Document that reducing or clearing a reserved value does not kill
already-inflight invocations, mirroring AWS behavior and causing a
brief drain window where total inflight may exceed the region limit.
* fix(lambda): serialize Put/Delete per function and preserve busy inflight
- Wrap PutFunctionConcurrency and DeleteFunctionConcurrency in a
per-function lock so concurrent requests for the same ARN can't
interleave the limiter update and the store save in a way that
leaves them out of sync.
- Retain the inflight counter on reset when permits are still open,
so an ARN recreated under load sees the remaining inflight rather
than starting fresh and briefly allowing more than reserved capacity.
Idle counters (value 0) are still dropped to prevent leaks.
- Tests now close acquired permits via try-with-resources and cover
both the retain-while-busy and drop-when-idle reset behaviors.
* test(lambda): close all permits via try-with-resources
Close the acquire() result in regions_areIndependent so the test leaves
no inflight state behind and accurately asserts both the exhausted and
recovered cases.
* perf(lambda): avoid regex split in regionOf on the invoke hot path
regionOf() runs on every acquire/release. Replace String.split(":"),
which uses regex and allocates an array, with a single pass that finds
the fourth ':' segment and returns a substring — same semantics, no
allocation beyond the returned region string.
* fix(lambda): keep per-function lock map and tighten compat assertion
- deleteFunction no longer removes the per-function entry from
concurrencyOpLocks. Removing it could race with a concurrent
Put/Delete still synchronized on the old lock object, letting the
next request create a fresh lock and run in parallel — defeating
the very serialization the map provides. The map grows by one
Object per deleted function, acceptable for a local emulator.
- LambdaConcurrencyTest now asserts the wire-level error identity
(400 status + "LimitExceededException" errorCode) for the Put
rejection. The Lambda SDK v2 model does not declare a typed
LimitExceededException class, so wire-level assertions catch
protocol-fidelity regressions more precisely than the previous
generic LambdaException check.
* fix(lambda): retain inflight counter on reset and allow over-committed reductions
- reset() no longer drops idle inflight counters. The previous
counter.get()==0 + remove pattern races with a concurrent
acquireReserved that has already obtained the AtomicInteger
reference and is about to increment it: a successful remove
between those two moments would leave the next acquire to
allocate a fresh counter and silently undercount inflight,
permitting reserved over-subscription.
- validateAndSetReserved now allows any value <= the function's
current reservation unconditionally. Reductions cannot worsen
unreserved capacity, so blocking them in an already over-committed
state (e.g. after lowering region-concurrency-limit at runtime)
prevented operators from recovering. Increases still go through
the unreserved-min check.
* fix(lambda): take per-function lock in deleteFunction
A concurrent deleteFunction + Put/DeleteFunctionConcurrency for the
same ARN could interleave the limiter reset and the store delete,
leaving the limiter holding (or clearing) state for a function the
store no longer knows about. Wrap the limiter+store mutations in the
same lockForConcurrencyOp(arn) used by the concurrency endpoints.
Tighten the surrounding comment so it describes the current code
rather than the lock-removal call that earlier revisions used to have.
* test(lambda): wire a real concurrency limiter into the test constructor
The package-private LambdaService constructor used by unit tests passed
null for concurrencyLimiter, so the null-guards in
putFunctionConcurrency / deleteFunctionConcurrency / deleteFunction made
those paths silently skip validation and limiter bookkeeping under tests.
That hid divergence from production behavior.
Construct a default LambdaConcurrencyLimiter (AWS defaults: 1000 / 100)
in the test ctor so the same enforcement runs in unit tests.
* test(lambda): cover concurrent PutFunctionConcurrency for the same ARN
Verify that the per-function lock in LambdaService serializes racing
Puts so the limiter and the functionStore always agree on whichever
write landed last. 50 iterations across two threads against the same
function exercise the lock discipline and assert store/limiter
consistency on every iteration.
* docs: document reserved concurrency config keys
- docs/services/lambda.md: drop redundant "(enforced at invocation)"
from the PutFunctionConcurrency table entry (the admonition below
already explains enforcement); add region-concurrency-limit and
unreserved-concurrency-min to the Configuration YAML sample.
- docs/configuration/application-yml.md: mirror the two new keys in
the top-level reference sample so every known lambda setting is
discoverable in one place.
* refactor(lambda): address review feedback (A)
- LambdaServiceTest.concurrentPutFunctionConcurrency now asserts against
limiter.totalReserved(region) instead of getFunctionConcurrency(), which
read the same field as the value under test. The new assertion actually
proves the limiter and the persisted store stayed in agreement.
- Expose a package-private concurrencyLimiter() accessor on LambdaService
so tests can inspect limiter state without reflection.
- Drop unused Permit.NOOP: the reserved=null path now runs through
acquireUnreserved and always returns a real decrement closure.
- Document the intentional unbounded growth of the inflight counter map
(race avoidance on reset) and concurrencyOpLocks (race avoidance on
deleteFunction). Both are acceptable for a local emulator workload.
* test(lambda): add rehydrate, multi-ARN race, and qualified-invoke coverage
- LambdaServiceTest.rehydrateConcurrency_restoresReservedFromStore
prepopulates a LambdaFunctionStore with reserved values, builds a
fresh LambdaService over it, and verifies totalReserved(region) goes
from 0 to the expected sum after the @PostConstruct hook runs.
- LambdaServiceTest.multiArnPutFunctionConcurrency_respectsRegionTotalUnderContention
races two Puts on different ARNs that would together push the region
below unreserved-min. reservedLock must let exactly one win; the
other must fail with LimitExceededException and the limiter's total
must reflect only the winning reservation.
- Compat LambdaConcurrencyTest.invoke_withVersionQualifier_stillHonorsReservedOnLatest
publishes a version, sets reserved=0, and invokes with the qualifier
set. Today Floci drops the qualifier and routes to $LATEST, so the
reservation throttles the call. This test locks the behavior in: a
future qualifier-routing change must either copy the reservation onto
the snapshot or key the limiter off the base ARN to keep it green.
* refactor(lambda): idempotent permits, warn on malformed ARN, more tests
- Wrap acquire()/release() counter closures in an AtomicBoolean guard so
a double-close of a Permit can never drive the inflight counter
negative. Future callers that mix try-with-resources with explicit
close, or that add retry logic around invoke, stay safe by default.
- regionOf() now warns once per unique malformed input instead of
silently coalescing everything into "unknown". The first occurrence
is logged so a bug that passes a bare function name into the limiter
is debuggable without spamming the log.
- New LambdaServiceTest.putFunctionConcurrency_rollsBackLimiterIfSaveFails
injects a failing LambdaFunctionStore and verifies the limiter total
is restored when functionStore.save throws.
- New LambdaServiceTest.deleteFunction_preservesInflightPermitUntilItCloses
holds a permit through a deleteFunction call and asserts the inflight
counter stays live until the permit is closed.
- New LambdaConcurrencyLimiterTest.permit_closeIsIdempotent locks in the
double-close guarantee.
Close drift gaps between main YAML, test YAML, and docs reference.
Test YAML: fix rds.proxy-base-port (7000→7001), add apigatewayv2/acm
sections, expand opensearch with proxy ports, fix appconfigdata missing
value, add acm storage flush. Main YAML: add apigatewayv2 section.
Docs: add apigatewayv2/appconfig/appconfigdata/ecr full config blocks,
clarify note about unlisted keys.
* feat(lambda): add PutFunctionConcurrency stub
Add PutFunctionConcurrency, GetFunctionConcurrency, and
DeleteFunctionConcurrency endpoints:
PUT /2017-10-31/functions/{FunctionName}/concurrency
DELETE /2017-10-31/functions/{FunctionName}/concurrency
GET /2019-09-30/functions/{FunctionName}/concurrency
The stored ReservedConcurrentExecutions value is persisted on
LambdaFunction and echoed back, but it is not enforced at invocation
time — invocation slots in LambdaExecutorService / WarmPool are not
bounded, and the account-level concurrent execution limit is not
validated.
* fix(lambda): tighten PutFunctionConcurrency validation
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
Add key rotation management with persisted state on the KmsKey model.
Rotation is only supported for symmetric ENCRYPT_DECRYPT keys, matching
AWS behavior. Includes validation that rejects asymmetric keys with
UnsupportedOperationException.
* feat(kinesis): resolve stream name from StreamARN parameter
Most Kinesis actions now accept StreamARN as an alternative to
StreamName, matching real AWS behavior. A shared resolveStreamName
helper extracts the stream name from the ARN (guarding against
malformed and consumer ARNs) and throws InvalidArgumentException
when neither field is valid. handleListShards inline logic replaced
with the shared helper. CreateStream excluded (no ARN at creation).
* fix(kinesis): use dedicated stream in ARN put/get test and renumber after rebase
The putAndGetRecordsByArn test read from shardId-000000000000 which was
split by an earlier test, so GetRecords returned 0 records. Use a
dedicated 1-shard stream and tighten assertions. Renumber ARN test
orders (20-23) to avoid collision with upstream retention period tests.
Wire up the two retention period API actions that were missing despite
the model already having retentionPeriodHours with getter/setter.
Validation matches AWS behavior:
- Increase rejects values <= current or > 8760 (365 days)
- Decrease rejects values >= current or < 24 hours
Closes#291
* 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
The init hook executor defaulted to /bin/bash, which is not available on
Alpine-based Docker images (eclipse-temurin:25-jre-alpine). This caused
startup hooks to fail with "No such file or directory". /bin/sh is
universally available and POSIX-compatible.
* docs: migrate docs GitHub references to floci-io
* docs: update MkDocs site and repo metadata to floci-io
* docs: update MkDocs site_url and repository references to floci-io
Improve the Docker Compose documentation for named volumes and
persistence section for clarity and consistency. Fix indentation in
quick-start.md that broke MkDocs tabbed content rendering.