Package org.apache.camel.main
Class HttpServerConfigurationProperties
java.lang.Object
org.apache.camel.main.HttpServerConfigurationProperties
- All Implemented Interfaces:
Closeable,AutoCloseable,org.apache.camel.spi.BootstrapCloseable
@Configurer(bootstrap=true)
public class HttpServerConfigurationProperties
extends Object
implements org.apache.camel.spi.BootstrapCloseable
Configuration for embedded HTTP server for standalone Camel applications (not Spring Boot / Quarkus).
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidclose()end()getHost()getPath()intgetPort()booleanbooleanbooleanbooleanbooleanvoidsetDevConsoleEnabled(boolean devConsoleEnabled) Whether to enable developer console (not intended for production use).voidsetEnabled(boolean enabled) Whether embedded HTTP server is enabled.voidsetHealthCheckEnabled(boolean healthCheckEnabled) Whether to enable health-check console.voidHostname to use for binding embedded HTTP servervoidsetMaxBodySize(Long maxBodySize) Maximum HTTP body size the embedded HTTP server can accept.voidContext-path to use for embedded HTTP servervoidsetPort(int port) Port to use for binding embedded HTTP servervoidsetUploadEnabled(boolean uploadEnabled) Whether to enable file upload via HTTP (not intended for production use).voidsetUploadSourceDir(String uploadSourceDir) Source directory when upload is enabled.voidsetUseGlobalSslContextParameters(boolean useGlobalSslContextParameters) Whether to use global SSL configuration for securing the embedded HTTP server.withDevConsoleEnabled(boolean devConsoleEnabled) Whether to enable developer console (not intended for production use).withEnabled(boolean enabled) Whether embedded HTTP server is enabled.withHealthCheckEnabled(boolean healthCheckEnabled) Whether to enable health-check console.Hostname to use for binding embedded HTTP serverwithMaxBodySize(long maxBodySize) Maximum HTTP body size the embedded HTTP server can accept.Context-path to use for embedded HTTP serverwithPort(int port) Port to use for binding embedded HTTP serverwithUploadEnabled(boolean uploadEnabled) Whether to enable file upload via HTTP (not intended for production use).withUploadSourceDir(String uploadSourceDir) Source directory when upload is enabled.withUseGlobalSslContextParameters(boolean useGlobalSslContextParameters) Whether to use global SSL configuration for securing the embedded HTTP server.
-
Constructor Details
-
HttpServerConfigurationProperties
-
-
Method Details
-
end
-
close
public void close()- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable
-
isEnabled
public boolean isEnabled() -
setEnabled
public void setEnabled(boolean enabled) Whether embedded HTTP server is enabled. By default, the server is not enabled. -
getHost
-
setHost
Hostname to use for binding embedded HTTP server -
getPort
public int getPort() -
setPort
public void setPort(int port) Port to use for binding embedded HTTP server -
getPath
-
setPath
Context-path to use for embedded HTTP server -
getMaxBodySize
-
setMaxBodySize
Maximum HTTP body size the embedded HTTP server can accept. -
isUseGlobalSslContextParameters
public boolean isUseGlobalSslContextParameters() -
setUseGlobalSslContextParameters
public void setUseGlobalSslContextParameters(boolean useGlobalSslContextParameters) Whether to use global SSL configuration for securing the embedded HTTP server. -
isDevConsoleEnabled
public boolean isDevConsoleEnabled() -
setDevConsoleEnabled
public void setDevConsoleEnabled(boolean devConsoleEnabled) Whether to enable developer console (not intended for production use). Dev console must also be enabled on CamelContext. For example by setting camel.context.dev-console=true in application.properties, or via code camelContext.setDevConsole(true); If enabled then you can access a basic developer console on context-path: /q/dev. -
isHealthCheckEnabled
public boolean isHealthCheckEnabled() -
setHealthCheckEnabled
public void setHealthCheckEnabled(boolean healthCheckEnabled) Whether to enable health-check console. If enabled then you can access health-check status on context-path: /q/health -
isUploadEnabled
public boolean isUploadEnabled() -
setUploadEnabled
public void setUploadEnabled(boolean uploadEnabled) Whether to enable file upload via HTTP (not intended for production use). This functionality is for development to be able to reload Camel routes and code with source changes (if reload is enabled). If enabled then you can upload/delete files via HTTP PUT/DELETE on context-path: /q/upload/{name}. You must also configure the uploadSourceDir option. -
getUploadSourceDir
-
setUploadSourceDir
Source directory when upload is enabled. -
withEnabled
Whether embedded HTTP server is enabled. By default, the server is not enabled. -
withHost
Hostname to use for binding embedded HTTP server -
withPort
Port to use for binding embedded HTTP server -
withPath
Context-path to use for embedded HTTP server -
withMaxBodySize
Maximum HTTP body size the embedded HTTP server can accept. -
withUseGlobalSslContextParameters
public HttpServerConfigurationProperties withUseGlobalSslContextParameters(boolean useGlobalSslContextParameters) Whether to use global SSL configuration for securing the embedded HTTP server. -
withDevConsoleEnabled
Whether to enable developer console (not intended for production use). Dev console must also be enabled on CamelContext. For example by setting camel.context.dev-console=true in application.properties, or via code camelContext.setDevConsole(true); If enabled then you can access a basic developer console on context-path: /q/dev. -
withHealthCheckEnabled
Whether to enable health-check console. If enabled then you can access health-check status on context-path: /q/health -
withUploadEnabled
Whether to enable file upload via HTTP (not intended for production use). This functionality is for development to be able to reload Camel routes and code with source changes (if reload is enabled). If enabled then you can upload/delete files via HTTP PUT/DELETE on context-path: /q/upload/{name}. You must also configure the uploadSourceDir option. -
withUploadSourceDir
Source directory when upload is enabled.
-