Listener configurations

The listener configurations of MOSN.

This topic describes the listener configurations of MOSN.

  • You can specify the ports on which MOSN listens upon startup and the specific logic corresponding to the ports in listener configurations.
  • You can supplement or modify listener configurations through dynamic listener APIs.
  1. {
  2. "name":"",
  3. "type":"",
  4. "address":"",
  5. "bind_port":"",
  6. "use_original_dst":"",
  7. "access_logs":[],
  8. "filter_chains":[],
  9. "stream_filters":[],
  10. "inspector":"",
  11. "connection_idle_timeout":""
  12. }

name

The name of a listener that is used to uniquely distinguish it from other listeners. If this parameter is left empty, a UUID will be generated by the system as a name by default. When you dynamically upgrade a listener by using its name as the index, a new listener is added if the name does not exist. If the name exists, the listener is updated.

type

The type of the listener. Valid values ingress and egress. Different types of listeners generate different trace logs.

address

The string in the IP:Port format. This is the unique address to which the listener listens.

bind_port

Boolean. Specifies whether the listener will occupy the address specified for the address parameter. Set this parameter to True in most cases.

use_original_dst

Boolean. Used for transparent proxying.

access_logs

Settings for a group of access logs.

filter_chains

Settings for a group of filter chains. However, MOSN only supports one filter_chain currently.

stream_filters

Settings for a group of stream_filters. Currently, this parameter is valid only when the filter configured in filter_chain contains proxy.

inspector

Boolean. Specifies whether to allow the listener to handle non-TLS requests even when TLS listener is enabled in filter_chain. Valid values: True and False.

connection_idle_timeout

The duration string, which specifies the timeout value of an idle string. MOSN closes a connection of a listener when its idle duration exceeds the configured idle connection timeout value.


FilterChain

The FilterChain configurations of MOSN.

Network Filter

The network filter configurations.

Last modified October 28, 2022: docs: Changes to the v1.2.0 configuration (#217) (d237414)