Class NeptuneConfig
java.lang.Object
io.floci.testcontainers.config.services.AbstractServiceConfig<NeptuneConfig.Builder>
io.floci.testcontainers.config.services.NeptuneConfig
Configuration for Neptune-specific container settings.
Instances are created via NeptuneConfig.Builder:
NeptuneConfig config = NeptuneConfig.builder()
.enabled(true)
.proxyPortRange(8182, 10)
.defaultImage("tinkerpop/gremlin-server:3.7.3")
.build();
-
Nested Class Summary
Nested Classes -
Field Summary
Fields inherited from class io.floci.testcontainers.config.services.AbstractServiceConfig
DEFAULT_ENABLED -
Method Summary
Modifier and TypeMethodDescriptionvoidapplyEnvVarsToContainer(org.testcontainers.containers.Container<?> container) Applies this service configuration to the given container by setting the appropriate environment variables.voidapplyExposedPortsToContainer(org.testcontainers.containers.Container<?> container) Applies this service configuration to the given container by exposing the appropriate ports.static NeptuneConfig.Builderbuilder()Returns a newNeptuneConfig.Builderfor this configuration.Returns the backend graph engine and query language used for Neptune:gremlin(Apache TinkerPop, Gremlin over WebSocket) orneo4j(Neo4j, openCypher over Bolt).Returns the default Docker image used whengetDbType()isgremlin.Returns the default Docker image used whengetDbType()isneo4j(openCypher / Bolt).Returns the Docker network used for Neptune containers, ornullif not set.intReturns the base port for the Neptune proxy port range.intReturns the inclusive upper bound of the Neptune proxy port range.intReturns the number of ports allocated for the Neptune proxy, starting fromgetProxyBasePort().Returns a newNeptuneConfig.Builderfor this configuration, initialized with the current values of this instance.Methods inherited from class io.floci.testcontainers.config.services.AbstractServiceConfig
isEnabled
-
Method Details
-
builder
Returns a newNeptuneConfig.Builderfor this configuration.- Returns:
- a new builder
-
toBuilder
Returns a newNeptuneConfig.Builderfor this configuration, initialized with the current values of this instance.- Specified by:
toBuilderin classAbstractServiceConfig<NeptuneConfig.Builder>- Returns:
- a new builder pre-populated with this configuration's values
-
getProxyBasePort
public int getProxyBasePort()Returns the base port for the Neptune proxy port range.- Returns:
- the base port
-
getProxyPortsCount
public int getProxyPortsCount()Returns the number of ports allocated for the Neptune proxy, starting fromgetProxyBasePort().- Returns:
- the number of proxy ports
-
getProxyMaxPort
public int getProxyMaxPort()Returns the inclusive upper bound of the Neptune proxy port range.- Returns:
- the maximum port
-
getDbType
Returns the backend graph engine and query language used for Neptune:gremlin(Apache TinkerPop, Gremlin over WebSocket) orneo4j(Neo4j, openCypher over Bolt). Mirrors LocalStack'sNEPTUNE_DB_TYPE.- Returns:
- the database type
-
getDefaultImage
Returns the default Docker image used whengetDbType()isgremlin.- Returns:
- the image name
-
getDefaultNeo4jImage
Returns the default Docker image used whengetDbType()isneo4j(openCypher / Bolt).- Returns:
- the image name
-
getDockerNetwork
Returns the Docker network used for Neptune containers, ornullif not set.- Returns:
- the Docker network name, or
null
-
applyEnvVarsToContainer
public void applyEnvVarsToContainer(org.testcontainers.containers.Container<?> container) Description copied from class:AbstractServiceConfigApplies this service configuration to the given container by setting the appropriate environment variables.- Overrides:
applyEnvVarsToContainerin classAbstractServiceConfig<NeptuneConfig.Builder>- Parameters:
container- the container to configure
-
applyExposedPortsToContainer
public void applyExposedPortsToContainer(org.testcontainers.containers.Container<?> container) Description copied from class:AbstractServiceConfigApplies this service configuration to the given container by exposing the appropriate ports.- Overrides:
applyExposedPortsToContainerin classAbstractServiceConfig<NeptuneConfig.Builder>- Parameters:
container- the container to configure
-