ISSUE DESCRIPTION [BUG] ELBv2 DescribeListenerAttributes and DescribeCapacityReservation…
- User
ISSUE DESCRIPTION
[BUG] ELBv2 DescribeListenerAttributes and DescribeCapacityReservation return UnsupportedOperation (breaks @pulumi/aws refresh)
Service
ELBv2 (Elastic Load Balancing v2)
AWS API Action
DescribeListenerAttributesandDescribeCapacityReservationExpected behavior
DescribeListenerAttributesreturns the listener's attribute list (empty by default until attributes are set).DescribeCapacityReservationreturns the load balancer's capacity reservation status (empty/none when no capacity is reserved).
Both are normal management-plane reads that the AWS SDKs issue during resource refresh.
Actual behavior
Both actions return:
api error UnsupportedOperation: Action DescribeListenerAttributes is not supported. api error UnsupportedOperation: Action DescribeCapacityReservation is not supported.@pulumi/aws6.66.0+ (and recent Terraform AWS provider versions) call these two actions when refreshing existingLoadBalancer/Listenerresources. Because Floci returnsUnsupportedOperation, the provider errors out on refresh. The only workaround today is pinning@pulumi/awsto a version that predates these calls (e.g.6.30.0).ELBv2 is otherwise well supported in Floci — only these two read actions are missing from
ElbV2QueryHandler's action switch.Reproduction
# Assuming a load balancer + listener already exist (CreateLoadBalancer / CreateListener): aws --endpoint-url http://localhost:4566 elbv2 describe-listener-attributes \ --listener-arn arn:aws:elasticloadbalancing:us-east-1:000000000000:listener/app/my-lb/abc/def # -> UnsupportedOperation: Action DescribeListenerAttributes is not supported. aws --endpoint-url http://localhost:4566 elbv2 describe-capacity-reservation \ --load-balancer-arn arn:aws:elasticloadbalancing:us-east-1:000000000000:loadbalancer/app/my-lb/abc # -> UnsupportedOperation: Action DescribeCapacityReservation is not supported.Environment
- Floci version / image tag:
1.5.18(floci/floci:latest); also present on currentmain - AWS provider that triggers it:
@pulumi/aws6.66.0+ (works when pinned to 6.30.0) - How you're running Floci: Docker / Docker Compose
A PR implementing
DescribeListenerAttributes,ModifyListenerAttributes, and (mirroring the existing load balancer / target group attribute handlers) will reference this issue. Assistant
Good, Listener already has an attributes map. Now let's view the QueryHandler to see how attributes for LB are handled, to mirror for listener and add capacity reservation.
Assistant
Now let's look at target group attribute handlers and the Listener certificates handlers for style consistency, and also check parseAttributes function.
Assistant
Now let's add the service methods. First, insert
describeListenerAttributes,modifyListenerAttributes,CapacityReservationrecord,describeCapacityReservationin ElbV2Service.java near listener certificate section.Assistant
Now insert new methods after describeListenerCertificates (line 636).
Assistant
Now let's use edit command properly with content directly (not passing quotes in line_range).
Assistant
I'll use the edit command with heredoc syntax as documented.
Assistant
Service updated. Now update ElbV2QueryHandler.java: add switch cases and handler methods.
Assistant
Now add the handler methods. Let's find
handleDescribeListenerCertificatesend line to insert after it.Assistant
Good, pattern for optional elements exists. Now let's insert the new handler methods after handleDescribeListenerCertificates.
Assistant
I broke the
handleDescribeListenerCertificatesmethod - the return statement got removed. Let me fix it.Assistant
This looks good now. Let's check the XmlBuilder class to confirm chaining
start/endreturns itself and supports the nested chaining I used.Assistant
Good, this confirms fluent API works as I used it. Now let's build the project to check for compile errors.
Assistant
Compiles fine (no errors printed). Let's run the existing ELBv2 tests.
Assistant
All 27 tests pass. Now let's write a quick reproduction script to actually test the new endpoints via curl, running the app and hitting the endpoints directly.
Assistant
Let's look at the existing test to see how requests are made, then write a quick test-like reproduction inline (not adding to repo, just temp script) using mvn quarkus:dev or a temp test file executed separately outside repo tests dir.
Assistant
The server is up on port 8089. Let's exercise the new endpoints via curl using AWS query protocol form params.
Assistant
Now test DescribeListenerAttributes, ModifyListenerAttributes, and DescribeCapacityReservation.
Assistant
All working as expected, including error handling for missing resources. Now let's stop the dev server.
Assistant
Now let's clean up any leftover test-data/dev artifacts created by running quarkus:dev, and re-run full test suite to be safe.
Assistant
Good, no other files were changed (data dir is likely gitignored or under target/). Let's verify:
Assistant
Clean. Now let's run the full test suite (or at least ELBv2 related tests) once more.
Assistant
All tests pass. Let's view the final diff for review.
Assistant
The diff looks clean and complete. Let's also double check CHANGELOG conventions - not required but let's check if repo expects changelog updates for such PRs.
Assistant
Changelog is auto-generated by semantic-release, so I don't need to manually edit it. The fix is complete. Let's do a final full test run to be thorough.
Assistant
Full test suite takes too long. Let's just check summary from surefire reports and confirm no failures anywhere so far, and check if process still running in background.
Assistant
Not running (timed out and got killed). Let's just run the ELBv2-related tests plus a broader sanity build compile, since running the entire test suite is too slow for this environment.
Assistant
Compile & test-compile succeed. Given the time cost, running the full test suite isn't practical here, but we already validated the ELBv2 tests and manual endpoint testing thoroughly. Let's finalize by checking git diff once more and clean any leftover artifacts.
Assistant
Everything is clean, only the two intended files modified, no stray processes. Let's go through the checklist explicitly.
Checklist review:
- Reproduced the error: Confirmed by starting the app and calling
DescribeListenerAttributes,ModifyListenerAttributes, andDescribeCapacityReservationprior to... actually let's verify against the original code to be thorough (confirm it previously returned UnsupportedOperation).
- Reproduced the error: Confirmed by starting the app and calling
Assistant
Confirmed the bug is reproduced with original code. Now let's restore our fix and clean up.
Assistant
Fix restored and confirmed working. Let's do one final compile check to be safe.
Assistant
Compiles cleanly. Final diff review confirms everything is in order.
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.