Network settings
Lucenia uses HTTP settings to configure communication with external clients through the REST API and transport settings for internal node-to-node communication within Lucenia.
To learn more about static and dynamic settings, see Configuring Lucenia.
Lucenia supports the following common network settings:
-
network.host(Static, list): Binds an Lucenia node to an address. Use0.0.0.0to include all available network interfaces, or specify an IP address assigned to a specific interface. Thenetwork.hostsetting is a combination ofnetwork.bind_hostandnetwork.publish_hostif they are the same value. An alternative tonetwork.hostis to configurenetwork.bind_hostandnetwork.publish_hostseparately as needed. See Advanced network settings. -
http.port(Static, single value or range): Binds an Lucenia node to a custom port or a range of ports for HTTP communication. You can specify an address or a range of addresses. Default is9200-9300. -
transport.port(Static, single value or range): Binds an Lucenia node to a custom port for communication between nodes. You can specify an address or a range of addresses. Default is9300-9400.
Advanced network settings
Lucenia supports the following advanced network settings:
-
network.bind_host(Static, list): Binds an Lucenia node to an address or addresses for incoming connections. Default is the value innetwork.host. -
network.publish_host(Static, list): Specifies an address or addresses that an Lucenia node publishes to other nodes in the cluster so that they can connect to it.
Advanced HTTP settings
Lucenia supports the following advanced network settings for HTTP communication:
-
http.host(Static, list): Sets the address of an Lucenia node for HTTP communication. Thehttp.hostsetting is a combination ofhttp.bind_hostandhttp.publish_hostif they are the same value. An alternative tohttp.hostis to configurehttp.bind_hostandhttp.publish_hostseparately as needed. -
http.bind_host(Static, list): Specifies an address or addresses to which an Lucenia node binds to listen for incoming HTTP connections. -
http.publish_host(Static, list): Specifies an address or addresses that an Lucenia node publishes to other nodes for HTTP communication. -
http.compression(Static, Boolean): Enables support for compression usingAccept-Encodingwhen applicable. WhenHTTPSis enabled, the default isfalse, otherwise, the default istrue. Disabling compression for HTTPS helps mitigate potential security risks, such asBREACHattacks. To enable compression for HTTPS traffic, explicitly sethttp.compressiontotrue.
Advanced transport settings
Lucenia supports the following advanced network settings for transport communication:
-
transport.host(Static, list): Sets the address of an Lucenia node for transport communication. Thetransport.hostsetting is a combination oftransport.bind_hostandtransport.publish_hostif they are the same value. An alternative totransport.hostis to configuretransport.bind_hostandtransport.publish_hostseparately as needed. -
transport.bind_host(Static, list): Specifies an address or addresses to which an Lucenia node binds to listen for incoming transport connections. -
transport.publish_host(Static, list): Specifies an address or addresses that an Lucenia node publishes to other nodes for transport communication.
Selecting the transport
The default Lucenia transport is provided by the transport-netty4 module and uses the Netty 4 engine for both internal TCP-based communication between nodes in the cluster and external HTTP-based communication with clients. This communication is fully asynchronous and non-blocking. However, there are other transport plugins available that can be used interchangeably:
| Plugin | Description |
|---|---|
transport-nio | The Lucenia transport based on Java NIO. Installation: ./bin/lucenia-plugin install transport-nio Configuration (using lucenia.yml): transport.type: nio-transport http.type: nio-http-transport |
transport-reactor-netty4 | The Lucenia HTTP transport based on Project Reactor and Netty 4 (experimental) Installation: ./bin/lucenia-plugin install transport-reactor-netty4 Configuration (using lucenia.yml): http.type: reactor-netty4 http.type: reactor-netty4-secure |