public void disableExtension(
        final @NotNull String extensionName,
        final @NotNull String extensionDirectory,
        final @NotNull Duration timeout
    ) throws TimeoutException {
        final String regEX = "(.*)Extension \"" + extensionName + "\" version (.*) stopped successfully(.*)";
        try {
            final String containerPath =
                "/opt/hivemq/extensions" + PathUtil.prepareInnerPath(extensionDirectory) + "DISABLED";

            final CountDownLatch latch = new CountDownLatch(1);
            containerOutputLatches.put(regEX, latch);

            execInContainer("touch", containerPath);
            LOGGER.info("Putting DISABLED file into container path '{}'", containerPath);

            final boolean await = latch.await(timeout.getSeconds(), TimeUnit.SECONDS);
            if (!await) {
                throw new TimeoutException(
                    "Extension disabling timed out after '" +
                    timeout.getSeconds() +
                    "' seconds. " +
                    "Maybe you are using a HiveMQ Community Edition image, " +
                    "which does not support disabling of extensions"
                );
            }
        } catch (final InterruptedException | IOException e) {
            throw new RuntimeException(e);
        } finally {
            containerOutputLatches.remove(regEX);
        }
    }
Disables the extension with the given name and extension directory name.
This method blocks until the HiveMQ log for successful disabling is consumed or it times out after {timeOut}.
Note: Disabling Extensions is a HiveMQ Enterprise feature, it will not work when using the HiveMQ Community Edition.
<p>
This can only be called once the container is started.

@param extensionName      the name of the extension to disable
@param extensionDirectory the name of the extension's directory
@param timeout            the timeout
@throws TimeoutException if the extension was not disabled within the configured timeout
modules/hivemq/src/main/java/org/testcontainers/hivemq/HiveMQContainer.java