Skip to content

Commit 27b9a0d

Browse files
committed
[servicebus] Skip waiting for sql to be ready
By default, Azure ServiceBus emulator waits 15 seconds for sql to be ready. Testcontainers is in charge of service readiness, so, the emulator should skip waiting for sql.
1 parent 485ef1d commit 27b9a0d

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

modules/azure/src/main/java/org/testcontainers/azure/ServiceBusEmulatorContainer.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,7 @@ public ServiceBusEmulatorContainer(final DockerImageName dockerImageName) {
4141
super(dockerImageName);
4242
dockerImageName.assertCompatibleWith(DEFAULT_IMAGE_NAME);
4343
withExposedPorts(DEFAULT_PORT);
44+
withEnv("SQL_WAIT_INTERVAL", "0");
4445
waitingFor(Wait.forLogMessage(".*Emulator Service is Successfully Up!.*", 1));
4546
}
4647

modules/azure/src/test/java/org/testcontainers/azure/ServiceBusEmulatorContainerTest.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ public class ServiceBusEmulatorContainerTest {
4848
@Rule
4949
// emulatorContainer {
5050
public ServiceBusEmulatorContainer emulator = new ServiceBusEmulatorContainer(
51-
"mcr.microsoft.com/azure-messaging/servicebus-emulator:1.0.1"
51+
"mcr.microsoft.com/azure-messaging/servicebus-emulator:1.1.2"
5252
)
5353
.acceptLicense()
5454
.withConfig(MountableFile.forClasspathResource("/service-bus-config.json"))

0 commit comments

Comments
 (0)