oscerd opened a new pull request, #29247:
URL: https://github.com/apache/camel/pull/29247

   **Depends on #29229** (CAMEL-26615), which adds the Floci AZ container to 
the Azure test-infra: until #29229 is merged,
   this PR also shows its commit. It stays a draft until then.
   
   ## Description
   
   The integration tests of camel-azure-servicebus ran only against a real 
namespace
   (`camel.component.azure-servicebus.connection-string`). [Floci 
AZ](https://github.com/floci-io/floci-az) emulates the
   Service Bus AMQP 1.0 data plane, with an ActiveMQ Artemis broker that it 
starts itself through the Docker socket. This PR:
   
   - adds a `camel-test-infra-azure-servicebus` module: a local service on 
Floci AZ (`camel infra run azure service-bus`)
     whose queues, topics and subscriptions, sessions included, are declared in 
the `Config.json` format of the official
     emulator, with its connection string (`UseDevelopmentEmulator=true`), and 
a remote one. Floci AZ gets the Docker
     socket (with SELinux labeling disabled), Docker publishes the broker on 
free host ports, and the service removes the
     broker at shutdown (by the label of its resource namespace, also 
registered with the resource reaper of
     Testcontainers). The Artemis image is pinned in 
`azure.servicebus.broker.container`, as it must match the Floci AZ
     image;
   - runs the integration tests against it by default, and against Azure, as 
before, when the connection string is given:
     there the tests still create and delete their entities;
   - renames `ServiceBusSenderOperationsTest` to 
`ServiceBusSenderOperationsIT`: it is in the integration package and
     needs a broker;
   - skips the integration tests on ppc64le and s390x, where the Floci AZ image 
is not available.
   
   Remote only, with the reason in their `disabledReason`:
   
   - the scheduling tests of the producer and of the sender operations: Floci 
AZ does not implement
     `com.microsoft:schedule-message`, and has no `$management` node for a 
topic;
   - `serviceBusSessionEnabledQueueIsConsumedByCamel`: Floci AZ does not set 
the lock annotation on the messages of a
     session entity, so the `LOCKED_UNTIL` header is null.
   
   `ServiceBusConsumerIT` now gives the messages it sends a message id: the 
test asserted the `MESSAGE_ID` header but
   relied on the broker to set one, which Floci AZ does not do (Service Bus 
documents the message id as defined by the
   application).
   
   ## Testing
   
   - 22 integration tests: 13 pass against Floci AZ 0.16.0, 9 are remote only; 
no broker container is left after a run;
     the unit tests pass.
   - Full reactor build; the test-infra metadata is regenerated.
   
   _Claude Code on behalf of Andrea Cosentino_
   
   🤖 Generated with [Claude Code](https://claude.com/claude-code)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to