Class GremlinServer
- java.lang.Object
-
- org.apache.tinkerpop.gremlin.server.GremlinServer
-
public class GremlinServer extends Object
Start and stop Gremlin Server.- Author:
- Stephen Mallette (http://stephen.genoprime.com)
-
-
Field Summary
Fields Modifier and Type Field Description static String
AUDIT_LOGGER_NAME
-
Constructor Summary
Constructors Constructor Description GremlinServer(Settings settings)
Construct a Gremlin Server instance fromSettings
.GremlinServer(Settings settings, ExecutorService gremlinExecutorService)
Construct a Gremlin Server instance fromSettings
andExecutorService
.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description Channelizer
getChannelizer()
static String
getHeader()
ServerGremlinExecutor
getServerGremlinExecutor()
static void
main(String[] args)
CompletableFuture<ServerGremlinExecutor>
start()
Start Gremlin Server withSettings
provided to the constructor.CompletableFuture<Void>
stop()
Stop Gremlin Server and free the port binding.String
toString()
-
-
-
Field Detail
-
AUDIT_LOGGER_NAME
public static final String AUDIT_LOGGER_NAME
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
GremlinServer
public GremlinServer(Settings settings)
Construct a Gremlin Server instance fromSettings
.
-
GremlinServer
public GremlinServer(Settings settings, ExecutorService gremlinExecutorService)
Construct a Gremlin Server instance fromSettings
andExecutorService
. This constructor is useful when Gremlin Server is being used in an embedded style and there is a need to share thread pools with the hosting application.
-
-
Method Detail
-
start
public CompletableFuture<ServerGremlinExecutor> start() throws Exception
Start Gremlin Server withSettings
provided to the constructor.- Throws:
Exception
-
stop
public CompletableFuture<Void> stop()
Stop Gremlin Server and free the port binding. Note that multiple calls to this method will return the same instance of theCompletableFuture
.
-
getServerGremlinExecutor
public ServerGremlinExecutor getServerGremlinExecutor()
-
getChannelizer
public Channelizer getChannelizer()
-
getHeader
public static String getHeader()
-
-