Class Settings

java.lang.Object
net.targetr.wtm3.Settings

public class Settings extends Object
Loads default settings and reads settings from properties files.
Author:
Dr Michael Gardiner
  • Field Details

    • server

      public String server
      The configured server string.
    • port

      public int port
      The listen port.
    • backlog

      public int backlog
      The listen backlog.
    • listenAddr

      public String listenAddr
      The bind address or null for all.
    • transferBufferSize

      public int transferBufferSize
      Size of the buffer used for data transfers. Should fit in CPU cache.
    • tcpSocketTimeout

      public int tcpSocketTimeout
      Max time to block on socket read
    • tcpSocketLingerSeconds

      public int tcpSocketLingerSeconds
      Max time to block on socket close
    • tcpNoDelay

      public boolean tcpNoDelay
      Disable Nagle's algorithm
    • tcpKeepAlive

      public boolean tcpKeepAlive
      Enable TCP keep alive
    • metaDataRequestTimeout

      public int metaDataRequestTimeout
      Max time to read the HTTP headers
    • metadataReadBufferSize

      public int metadataReadBufferSize
      Max size of HTTP request line and headers
    • requestBodyMaxSize

      public int requestBodyMaxSize
      Max size of HTTP request body
    • requestBodyTimeout

      public int requestBodyTimeout
      Max time to read the HTTP request body
    • websocketMaxFrameSize

      public int websocketMaxFrameSize
      Max size of a WebSocket frame
    • websocketMaxMessageSize

      public int websocketMaxMessageSize
      Max size of a WebSocket message
    • resourceCacheEnabled

      public boolean resourceCacheEnabled
      Specifies if resource cache should be disabled. Disable for fast testing without cache invalidation.
    • sanitizeWebLogs

      public boolean sanitizeWebLogs
      Remove senstive data from logs that are accessible online
    • backgroundMaintenance

      public boolean backgroundMaintenance
      Perform maintenance tasks in the background
    • sslContext

      public String sslContext
      The SSL Context protocol.
    • sslProtocols

      public String[] sslProtocols
      Supported SSL protocols.
    • cipherSuites

      public String[] cipherSuites
      Supported Cipher suites.
    • noSniDomain

      public String noSniDomain
      Domain to assume for clients without SNI.
    • keyStorePath

      public String keyStorePath
      Path to keystore.
    • keyStoreType

      public String keyStoreType
      Type of keystore.
    • keyStorePassword

      public String keyStorePassword
      Keystore password.
    • keystoreInternalKeyPassword

      public String keystoreInternalKeyPassword
      Internal keystore key password.
    • selfSignedAlias

      public String selfSignedAlias
      Alias for self signed root.
    • sslSelfSignedRootDn

      public String sslSelfSignedRootDn
      Custom SSL root distinguished name.
    • sslSelfSignedDomainDn

      public String sslSelfSignedDomainDn
      Custom SSL domain distinguished name.
    • errorFormatter

      public HtmlErrorFormatter errorFormatter
      HTML error page formatter.
  • Method Details

    • get

      public static Settings get()
      Gets the singleton Settings instance.
      Returns:
      the singleton Settings
    • load

      public void load(Properties props)
      Populates the public fields of this class from a properties object.
      Parameters:
      props - A properties object to read values from.