public class Settings extends Object
| Modifier and Type | Class and Description | 
|---|---|
| static class  | Settings.AuthenticationSettingsSettings for the  Authenticatorimplementation. | 
| static class  | Settings.AuthorizationSettingsSettings for the  Authenticatorimplementation. | 
| static class  | Settings.BaseMetrics | 
| static class  | Settings.ConsoleReporterMetricsSettings for a  Metricsreporter that writes to the console. | 
| static class  | Settings.CsvReporterMetricsSettings for a  Metricsreporter that writes to a CSV file. | 
| static class  | Settings.GangliaReporterMetricsSettings for a  Metricsreporter that writes to Ganglia. | 
| static class  | Settings.GraphiteReporterMetricsSettings for a  Metricsreporter that writes to Graphite. | 
| static class  | Settings.HostPortIntervalMetrics | 
| static class  | Settings.IntervalMetrics | 
| static class  | Settings.JmxReporterMetricsSettings for a  Metricsreporter that writes to JMX. | 
| static class  | Settings.ProcessorSettingsCustom configurations for any  OpProcessorimplementations. | 
| static class  | Settings.ScriptEngineSettingsSettings for the  ScriptEngine. | 
| static class  | Settings.SerializerSettingsSettings for the  MessageSerializerimplementations. | 
| static class  | Settings.ServerMetricsSettings for  Metricsrecorded by Gremlin Server. | 
| static class  | Settings.Slf4jReporterMetricsSettings for a  Metricsreporter that writes to the SL4J output. | 
| static class  | Settings.SslSettingsSettings to configure SSL support. | 
| Modifier and Type | Field and Description | 
|---|---|
| Settings.AuthenticationSettings | authentication | 
| Settings.AuthorizationSettings | authorization | 
| String | channelizerThe full class name of the  Channelizerto use in Gremlin Server. | 
| Boolean | enableAuditLogEnable audit logging of authenticated users and gremlin evaluation requests. | 
| long | evaluationTimeoutTime in milliseconds to wait for a request (script or bytecode) to complete execution. | 
| String | graphManagerThe full class name of the  GraphManagerto use in Gremlin Server. | 
| Map<String,String> | graphs | 
| int | gremlinPoolSize of the Gremlin thread pool. | 
| String | hostHost to bind the server to. | 
| long | idleConnectionTimeoutTime in milliseconds that the server will allow a channel to not receive requests from a client before it
 automatically closes. | 
| long | keepAliveIntervalTime in milliseconds that the server will allow a channel to not send responses to a client before it sends
 a "ping" to see if it is still present. | 
| int | maxAccumulationBufferComponentsMaximum number of request components that can be aggregated for a message. | 
| int | maxChunkSizeThe maximum length of the content or each chunk. | 
| int | maxContentLengthThe maximum length of the aggregated content for a message. | 
| int | maxHeaderSizeThe maximum length of all headers. | 
| int | maxInitialLineLengthThe maximum length of the initial line (e.g. | 
| int | maxParametersMaximum number of parameters that can be passed on a request. | 
| int | maxSessionTaskQueueSizeMaximum size that an individual  Sessioncan queue requests before starting to reject them. | 
| int | maxWorkQueueSizeMaximum size the general processing queue can grow before starting to reject requests. | 
| Settings.ServerMetrics | metricsConfigured metrics for Gremlin Server. | 
| int | portPort to bind the server to. | 
| List<Settings.ProcessorSettings> | processorsCustom settings for  OpProcessorimplementations. | 
| int | resultIterationBatchSizeNumber of items in a particular resultset to iterate and serialize prior to pushing the data down the wire
 to the client. | 
| Map<String,Settings.ScriptEngineSettings> | scriptEnginesMapof settings forScriptEnginesetting objects keyed by the name of theScriptEngineimplementation. | 
| List<Settings.SerializerSettings> | serializersList of  MessageSerializerto configure. | 
| long | sessionLifetimeTimeoutThe time in milliseconds that a  UnifiedChannelizersession can exist. | 
| Settings.SslSettings | sslConfigures settings for SSL. | 
| boolean | strictTransactionManagementIf set to  truethealiasesoption is required on requests and Gremlin Server will use that
 information to control whichGraphinstances are transaction managed for that request. | 
| int | threadPoolBossSize of the boss thread pool. | 
| int | threadPoolWorkerSize of the worker thread pool. | 
| boolean | useCommonEngineForSessionsWhen  trueand using theUnifiedChannelizerthe same engine that will be used to server
 sessionless requests will also be use to serve sessions. | 
| boolean | useEpollEventLoopdetect if the OS is linux, then use epoll instead of NIO which causes less GC | 
| boolean | useGlobalFunctionCacheForSessionsEnable the global function cache for sessions when using the  UnifiedChannelizer. | 
| int | writeBufferHighWaterMarkIf the number of bytes in the network send buffer exceeds this value then the channel is no longer writeable,
 accepting no additional writes until buffer is drained and the  writeBufferLowWaterMarkis met. | 
| int | writeBufferLowWaterMarkOnce the number of bytes queued in the network send buffer exceeds the high water mark, the channel will not
 become writeable again until the buffer is drained and it drops below this value. | 
| Constructor and Description | 
|---|
| Settings() | 
| Modifier and Type | Method and Description | 
|---|---|
| protected static org.yaml.snakeyaml.constructor.Constructor | createDefaultYamlConstructor()Creates  Constructorwhich contains all configurations to parse
 a Gremlin Server YAML configuration file using SnakeYAML. | 
| long | getEvaluationTimeout() | 
| Optional<Settings.ServerMetrics> | optionalMetrics() | 
| Optional<Settings.ProcessorSettings> | optionalProcessor(Class<? extends OpProcessor> clazz)Find the  Settings.ProcessorSettingsrelated to the specified class. | 
| Optional<Settings.SslSettings> | optionalSsl() | 
| static Settings | read(InputStream stream)Read configuration from a file into a new  Settingsobject. | 
| static Settings | read(String file)Read configuration from a file into a new  Settingsobject. | 
public String host
public int port
public int threadPoolWorker
public boolean useEpollEventLoop
public int gremlinPool
Runtime#availableProcessors().public int threadPoolBoss
public long evaluationTimeout
public int resultIterationBatchSize
public int maxInitialLineLength
"GET / HTTP/1.0") processed in a request, which essentially
 controls the maximum length of the submitted URI. This setting ties to the Netty HttpRequestDecoder.public int maxHeaderSize
HttpRequestDecoderpublic int maxChunkSize
HttpContents.  If the transfer encoding of the HTTP request is 'chunked' already, each chunk will be
 split into smaller chunks if the length of the chunk exceeds this value.public int maxContentLength
maxChunkSize where
 chunked requests are accumulated back into a single message.  A request exceeding this size will
 return a 413 - Request Entity Too Large status code.  A response exceeding this size will raise an internal
 exception.public int maxAccumulationBufferComponents
public int writeBufferHighWaterMark
writeBufferLowWaterMark is met.public int writeBufferLowWaterMark
public long idleConnectionTimeout
keepAliveInterval. Note that while this value is to be provided as milliseconds it will resolve to
 second precision. Set this value to 0 to disable this feature.public long keepAliveInterval
idleConnectionTimeout and keep the channel open. If enabled, this number should be
 smaller than the value provided to the idleConnectionTimeout. Note that while this value is to be
 provided as milliseconds it will resolve to second precision. Set this value to 0 to disable this feature.public boolean strictTransactionManagement
true the aliases option is required on requests and Gremlin Server will use that
 information to control which Graph instances are transaction managed for that request.  If this
 setting is false (which is the default), specification of aliases is not required and Gremlin
 Server will simply apply a commit for all graphs.  This setting only applies to sessionless requests.
 With either setting the user is responsible for their own transaction management for in-session requests.public String channelizer
Channelizer to use in Gremlin Server.public String graphManager
GraphManager to use in Gremlin Server.public int maxWorkQueueSize
gremlinPool. All incoming requests
 will be processed by this thread pool. If the threads are exhausted, the requests will queue to the size
 specified by this value after which they will begin to reject the requests.
 
 This value should be taken in account with the maxSessionTaskQueueSize which is related in some
 respects. A request that starts a new Session is handled by this queue, but additional requests to a
 created Session will queue separately given that setting per session.
 
 By default this value is set to 8192.public int maxSessionTaskQueueSize
Session can queue requests before starting to reject them. Note that this
 configuration only applies to the UnifiedChannelizer. By default this value is set to 4096.maxWorkQueueSizepublic int maxParameters
UnifiedChannelizer.public long sessionLifetimeTimeout
UnifiedChannelizer session can exist. This value cannot be extended
 beyond this value irrespective of the number of requests and their individual timeouts. Requests must complete
 within this time frame. If this timeout is reached while there is a running evaluation, there will be an attempt
 to interrupt it which will result in a timeout error to the client. If there are existing requests enqueued for
 the session when this timeout is reached, those requests will not be executed and will be closed with server
 errors. Open transactions will be issued a rollback. The default is 10 minutes.public boolean useGlobalFunctionCacheForSessions
UnifiedChannelizer. This setting is only
 relevant when useGlobalFunctionCacheForSessions is false. When true it means that
 functions created in one request to a session remain available on the next request to that session.public boolean useCommonEngineForSessions
true and using the UnifiedChannelizer the same engine that will be used to server
 sessionless requests will also be use to serve sessions. The default value of true is recommended as
 it reduces the amount of object creation required for each session and should generally lead to better
 performance especially if the expectation is that there will be many sessions being created and destroyed
 rapidly. Setting this value to false is mostly present to support specific use cases that may require
 each session having its own engine or to match previous functionality provided by the older channelizers
 produced prior to 3.5.0.public Settings.ServerMetrics metrics
public Map<String,Settings.ScriptEngineSettings> scriptEngines
Map of settings for ScriptEngine setting objects keyed by the name of the ScriptEngine
 implementation.public List<Settings.SerializerSettings> serializers
MessageSerializer to configure. If no serializers are specified then default serializers for
 the most current versions of "application/json" and "application/vnd.gremlin-v1.0+gryo" are applied.public Settings.SslSettings ssl
public Settings.AuthenticationSettings authentication
public Settings.AuthorizationSettings authorization
public Boolean enableAuditLog
public List<Settings.ProcessorSettings> processors
OpProcessor implementations. Implementations are loaded via
 ServiceLoader but custom configurations can be supplied through this configuration.public Optional<Settings.ProcessorSettings> optionalProcessor(Class<? extends OpProcessor> clazz)
Settings.ProcessorSettings related to the specified class. If there are multiple entries then only the
 first is returned.public Optional<Settings.ServerMetrics> optionalMetrics()
public Optional<Settings.SslSettings> optionalSsl()
public long getEvaluationTimeout()
public static Settings read(String file) throws Exception
Settings object.protected static org.yaml.snakeyaml.constructor.Constructor createDefaultYamlConstructor()
Constructor which contains all configurations to parse
 a Gremlin Server YAML configuration file using SnakeYAML.Constructor to parse a Gremlin Server YAMLpublic static Settings read(InputStream stream)
Settings object.Copyright © 2013–2022 Apache Software Foundation. All rights reserved.