Interface VertxHttpConfig


@ConfigMapping(prefix="quarkus.http") @ConfigRoot(phase=RUN_TIME) public interface VertxHttpConfig
  • Method Details

    • auth

      @ConfigDocSection(generated=true) AuthRuntimeConfig auth()
      Authentication configuration
    • port

      @WithDefault("8080") int port()
      The HTTP port
    • testPort

      @WithDefault("8081") int testPort()
      The HTTP port used to run tests
    • host

      String host()
      The HTTP host

      In dev/test mode this defaults to localhost, in prod mode this defaults to 0.0.0.0

      Defaulting to 0.0.0.0 makes it easier to deploy Quarkus to container, however it is not suitable for dev/test mode as other people on the network can connect to your development machine.

      As an exception, when running in Windows Subsystem for Linux (WSL), the HTTP host defaults to 0.0.0.0 even in dev/test mode since using localhost makes the application inaccessible.

    • testHost

      Optional<String> testHost()
      Used when QuarkusIntegrationTest is meant to execute against an application that is already running and listening on the host specified by this property.
    • hostEnabled

      @WithDefault("true") boolean hostEnabled()
      Enable listening to host:port
    • sslPort

      @WithDefault("8443") int sslPort()
      The HTTPS port
    • testSslPort

      @WithDefault("8444") int testSslPort()
      The HTTPS port used to run tests
    • testSslEnabled

      Optional<Boolean> testSslEnabled()
      Used when QuarkusIntegrationTest is meant to execute against an application that is already running to configure the test to use SSL.
    • insecureRequests

      If insecure (i.e. http rather than https) requests are allowed. If this is enabled then http works as normal. redirect will still open the http port, but all requests will be redirected to the HTTPS port. disabled will prevent the HTTP port from opening at all.

      Default is enabled except when client auth is set to required (configured using quarkus.http.ssl.client-auth=required). In this case, the default is disabled.

    • http2

      @WithDefault("true") boolean http2()
      If this is true (the default) then HTTP/2 will be enabled.

      Note that for browsers to be able to use it HTTPS must be enabled.

    • http2PushEnabled

      @WithDefault("true") boolean http2PushEnabled()
      Enables or Disable the HTTP/2 Push feature. This setting can be used to disable server push. The server will not send a PUSH_PROMISE frame if it receives this parameter set to false.
    • http2ConnectionWindowSize

      @ConfigDocDefault("-1") OptionalInt http2ConnectionWindowSize()
      Set the default HTTP/2 connection window size. It overrides the initial window size set by Http2Settings.getInitialWindowSize(), so the connection window size is greater than for its streams, in order the data throughput.

      A value of -1 reuses the initial window size setting.

    • cors

      @ConfigDocSection(generated=true) CORSConfig cors()
      The CORS config
    • ssl

      The SSL config
    • tlsConfigurationName

      Optional<String> tlsConfigurationName()
      The name of the TLS configuration to use.

      If not set and the default TLS configuration is configured (quarkus.tls.*) then that will be used. If a name is configured, it uses the configuration from quarkus.tls.<name>.* If a name is configured, but no TLS configuration is found with that name then an error will be thrown.

      If no TLS configuration is set, and quarkus.tls.* is not configured, then, `quarkus.http.ssl` will be used.

    • staticResources

      @ConfigDocSection(generated=true) StaticResourcesConfig staticResources()
      Static Resources.
    • handle100ContinueAutomatically

      @WithName("handle-100-continue-automatically") @WithDefault("false") boolean handle100ContinueAutomatically()
      When set to true, the HTTP server automatically sends `100 CONTINUE` response when the request expects it (with the `Expect: 100-Continue` header).
    • ioThreads

      OptionalInt ioThreads()
      The number if IO threads used to perform IO. This will be automatically set to a reasonable value based on the number of CPU cores if it is not provided. If this is set to a higher value than the number of Vert.x event loops then it will be capped at the number of event loops.

      In general this should be controlled by setting quarkus.vertx.event-loops-pool-size, this setting should only be used if you want to limit the number of HTTP io threads to a smaller number than the total number of IO threads.

    • limits

      @ConfigDocSection(generated=true) ServerLimitsConfig limits()
      Server limits.
    • idleTimeout

      @WithDefault("30M") Duration idleTimeout()
      Http connection idle timeout
    • readTimeout

      @WithDefault("60s") Duration readTimeout()
      Http connection read timeout for blocking IO. This is the maximum amount of time a thread will wait for data, before an IOException will be thrown and the connection closed.
    • body

      BodyConfig body()
      Request body related settings
    • encryptionKey

      @WithName("auth.session.encryption-key") Optional<String> encryptionKey()
      The encryption key that is used to store persistent logins (e.g. for form auth). Logins are stored in a persistent cookie that is encrypted with AES-256 using a key derived from a SHA-256 hash of the key that is provided here.

      If no key is provided then an in-memory one will be generated, this will change on every restart though so it is not suitable for production environments. This must be more than 16 characters long for security reasons

    • soReusePort

      @WithDefault("false") boolean soReusePort()
      Enable socket reuse port (linux/macOs native transport only)
    • tcpQuickAck

      @WithDefault("false") boolean tcpQuickAck()
      Enable tcp quick ack (linux native transport only)
    • tcpCork

      @WithDefault("false") boolean tcpCork()
      Enable tcp cork (linux native transport only)
    • tcpFastOpen

      @WithDefault("false") boolean tcpFastOpen()
      Enable tcp fast open (linux native transport only)
    • acceptBacklog

      @WithDefault("-1") int acceptBacklog()
      The accept backlog, this is how many connections can be waiting to be accepted before connections start being rejected
    • initialWindowSize

      OptionalInt initialWindowSize()
      Set the SETTINGS_INITIAL_WINDOW_SIZE HTTP/2 setting. Indicates the sender's initial window size (in octets) for stream-level flow control. The initial value is 2^16-1 (65,535) octets.
    • domainSocket

      @WithDefault("/var/run/io.quarkus.app.socket") String domainSocket()
      Path to a unix domain socket
    • domainSocketEnabled

      @WithDefault("false") boolean domainSocketEnabled()
      Enable listening to host:port
    • recordRequestStartTime

      @WithDefault("false") boolean recordRequestStartTime()
      If this is true then the request start time will be recorded to enable logging of total request time.

      This has a small performance penalty, so is disabled by default.

    • accessLog

      @ConfigDocSection(generated=true) AccessLogConfig accessLog()
      Access logs.
    • trafficShaping

      @ConfigDocSection TrafficShapingConfig trafficShaping()
      Traffic shaping.
    • sameSiteCookie

      Map<String,SameSiteCookieConfig> sameSiteCookie()
      Configuration that allows setting the same site attributes for cookies.
    • unhandledErrorContentTypeDefault

      Optional<VertxHttpConfig.PayloadHint> unhandledErrorContentTypeDefault()
      Provides a hint (optional) for the default content type of responses generated for the errors not handled by the application.

      If the client requested a supported content-type in request headers (e.g. "Accept: application/json", "Accept: text/html"), Quarkus will use that content type.

      Otherwise, it will default to the content type configured here.

    • header

      @ConfigDocSection(generated=true) Map<String,HeaderConfig> header()
      Additional HTTP Headers always sent in the response
    • filter

      @ConfigDocSection(generated=true) Map<String,FilterConfig> filter()
      Additional HTTP configuration per path
    • proxy

      @ConfigDocSection ProxyConfig proxy()
      Proxy.
    • websocketServer

      @ConfigDocSection WebsocketServerConfig websocketServer()
      WebSocket Server configuration.
    • determinePort

      default int determinePort(io.quarkus.runtime.LaunchMode launchMode)
    • determineSslPort

      default int determineSslPort(io.quarkus.runtime.LaunchMode launchMode)