Class DefaultContainerizedExternalSystem<C extends org.testcontainers.containers.GenericContainer<C>>

java.lang.Object
org.apache.flink.connector.testframe.external.DefaultContainerizedExternalSystem<C>
Type Parameters:
C - Type of underlying container
All Implemented Interfaces:
TestResource

@Experimental public class DefaultContainerizedExternalSystem<C extends org.testcontainers.containers.GenericContainer<C>> extends Object implements TestResource
Default implementation of external system based on container.
  • Method Details

    • builder

      public static <C extends org.testcontainers.containers.GenericContainer<C>> DefaultContainerizedExternalSystem.Builder<C> builder()
      Type Parameters:
      C - Type of underlying container
      Returns:
      An instance of builder
    • startUp

      public void startUp() throws Exception
      Description copied from interface: TestResource
      Start up the test resource.

      The implementation of this method should be idempotent.

      Specified by:
      startUp in interface TestResource
      Throws:
      Exception - if anything wrong when starting the resource
    • tearDown

      public void tearDown() throws Exception
      Description copied from interface: TestResource
      Tear down the test resource.

      The test resource should be able to tear down even without a startup (could be a no-op).

      Specified by:
      tearDown in interface TestResource
      Throws:
      Exception - if anything wrong when tearing the resource down
    • getContainer

      public C getContainer()