Class Settings

java.lang.Object
org.apache.tinkerpop.gremlin.driver.Settings

public final class Settings extends Object
Settings for the Cluster and its related components.
Author:
Stephen Mallette (http://stephen.genoprime.com)
  • Field Details

    • port

      public int port
      The port of the Gremlin Server to connect to which defaults to 8182. The same port will be applied for all hosts.
    • path

      public String path
      The path to the Gremlin service which is defaulted to "/gremlin".
    • hosts

      public List<String> hosts
      The list of hosts that the driver will connect to.
    • responseSerializer

      public Settings.SerializerSettings responseSerializer
      The serializer used to deserialize responses from the server. This selects the encoding requested via the Accept header; requests are always sent as JSON regardless of this setting. Note that this serializer should be supported by the server configuration.
    • connectionPool

      public org.apache.tinkerpop.gremlin.driver.Settings.ConnectionPoolSettings connectionPool
      Settings for connections and connection pool.
    • auth

      public Settings.AuthSettings auth
      Settings for authentication.
    • nioPoolSize

      public int nioPoolSize
      The size of the thread pool defaulted to the number of available processors.
    • workerPoolSize

      public int workerPoolSize
      The number of worker threads defaulted to the number of available processors * 2.
    • enableUserAgentOnConnect

      public boolean enableUserAgentOnConnect
      Toggles if user agent should be sent in web socket handshakes.
    • bulkResults

      public boolean bulkResults
      Toggles if result from server is bulked. Default is false.
  • Constructor Details

    • Settings

      public Settings()
  • Method Details

    • read

      public static Settings read(InputStream stream)
      Read configuration from a file into a new Settings object.
      Parameters:
      stream - an input stream containing a Gremlin Server YAML configuration
    • from

      public static Settings from(org.apache.commons.configuration2.Configuration conf)
      Read configuration from a file into a new Settings object.