@Experimental public final class MiniClusterExtension extends Object implements org.junit.jupiter.api.extension.BeforeAllCallback, org.junit.jupiter.api.extension.BeforeEachCallback, org.junit.jupiter.api.extension.AfterEachCallback, org.junit.jupiter.api.extension.AfterAllCallback, org.junit.jupiter.api.extension.ParameterResolver
MiniCluster
and registers the respective ExecutionEnvironment
and
StreamExecutionEnvironment
in the correct thread local environment.
Example usage:
{@code
Constructor and Description |
---|
MiniClusterExtension() |
MiniClusterExtension(org.apache.flink.runtime.testutils.MiniClusterResourceConfiguration miniClusterResourceConfiguration) |
MiniClusterExtension(java.util.function.Supplier<org.apache.flink.runtime.testutils.MiniClusterResourceConfiguration> miniClusterResourceConfigurationSupplier) |
Modifier and Type | Method and Description |
---|---|
void |
afterAll(org.junit.jupiter.api.extension.ExtensionContext context) |
void |
afterEach(org.junit.jupiter.api.extension.ExtensionContext context) |
void |
beforeAll(org.junit.jupiter.api.extension.ExtensionContext context) |
void |
beforeEach(org.junit.jupiter.api.extension.ExtensionContext context) |
Configuration |
getClientConfiguration() |
Object |
resolveParameter(org.junit.jupiter.api.extension.ParameterContext parameterContext,
org.junit.jupiter.api.extension.ExtensionContext extensionContext) |
boolean |
supportsParameter(org.junit.jupiter.api.extension.ParameterContext parameterContext,
org.junit.jupiter.api.extension.ExtensionContext extensionContext) |
public MiniClusterExtension()
public MiniClusterExtension(org.apache.flink.runtime.testutils.MiniClusterResourceConfiguration miniClusterResourceConfiguration)
@Experimental public MiniClusterExtension(java.util.function.Supplier<org.apache.flink.runtime.testutils.MiniClusterResourceConfiguration> miniClusterResourceConfigurationSupplier)
public boolean supportsParameter(org.junit.jupiter.api.extension.ParameterContext parameterContext, org.junit.jupiter.api.extension.ExtensionContext extensionContext) throws org.junit.jupiter.api.extension.ParameterResolutionException
supportsParameter
in interface org.junit.jupiter.api.extension.ParameterResolver
org.junit.jupiter.api.extension.ParameterResolutionException
public Object resolveParameter(org.junit.jupiter.api.extension.ParameterContext parameterContext, org.junit.jupiter.api.extension.ExtensionContext extensionContext) throws org.junit.jupiter.api.extension.ParameterResolutionException
resolveParameter
in interface org.junit.jupiter.api.extension.ParameterResolver
org.junit.jupiter.api.extension.ParameterResolutionException
public void beforeAll(org.junit.jupiter.api.extension.ExtensionContext context) throws Exception
beforeAll
in interface org.junit.jupiter.api.extension.BeforeAllCallback
Exception
public void beforeEach(org.junit.jupiter.api.extension.ExtensionContext context) throws Exception
beforeEach
in interface org.junit.jupiter.api.extension.BeforeEachCallback
Exception
public void afterEach(org.junit.jupiter.api.extension.ExtensionContext context) throws Exception
afterEach
in interface org.junit.jupiter.api.extension.AfterEachCallback
Exception
public void afterAll(org.junit.jupiter.api.extension.ExtensionContext context) throws Exception
afterAll
in interface org.junit.jupiter.api.extension.AfterAllCallback
Exception
public Configuration getClientConfiguration()
Copyright © 2014–2024 The Apache Software Foundation. All rights reserved.