1+ # #--------------------------------------------------------------------
2+ # # General
3+ # #--------------------------------------------------------------------
4+
5+ # #--------------------------------------------------------------------
6+ # # Task
7+ # #--------------------------------------------------------------------
8+ # Concurrent task count for global task executor.
9+ task.exec_workers = 200
10+ # Queue capacity for global task executor.
11+ task.exec_queue_max = 3_000
12+ # Concurrent task count for global local task executor, per worker thread.
13+ task.local_exec_workers = 5
14+ # Queue capacity for global local task executor, per worker thread.
15+ task.local_exec_queue_max = 1_000
16+ # The rate at which messages are dequeued from the 'LocalTaskExecQueue' message queue, per worker thread.
17+ # default value: "u32::MAX,1s"
18+ task.local_exec_rate_limit = " 100,1s"
19+
20+
21+ # #--------------------------------------------------------------------
22+ # # Node
23+ # #--------------------------------------------------------------------
24+ # Node id
25+ node.id = 1
26+
27+ # Busy status check switch.
28+ # default value: true
29+ node.busy.check_enable = true
30+ # Busy status update interval.
31+ # default value: 2s
32+ node.busy.update_interval = " 2s"
33+ # The threshold for the 1-minute average system load used to determine system busyness.
34+ # Value range: 0.0-100.0, default value: 80.0
35+ node.busy.loadavg = 80.0
36+ # The threshold for average CPU load used to determine system busyness.
37+ # Value range: 0.0-100.0, default value: 90.0
38+ node.busy.cpuloadavg = 90.0
39+ # The threshold for determining high-concurrency connection handshakes in progress.
40+ node.busy.handshaking = 0
41+
42+ # #--------------------------------------------------------------------
43+ # # RPC
44+ # #--------------------------------------------------------------------
45+ # rpc.server_addr = "0.0.0.0:5363"
46+ # rpc.server_workers = 4
47+ # Maximum number of messages sent in batch
48+ # rpc.batch_size = 128
49+ # Client concurrent request limit
50+ # rpc.client_concurrency_limit = 128
51+ # Connect and send to server timeout
52+ # rpc.client_timeout = "10s"
53+
54+
55+ # #--------------------------------------------------------------------
56+ # # Log
57+ # #--------------------------------------------------------------------
58+ # Value: off | file | console | both
59+ log.to = " file"
60+ # Value: trace, debug, info, warn, error
61+ log.level = " debug"
62+ log.dir = " /var/log/rmqtt"
63+ log.file = " rmqtt.log"
64+
65+
66+ # #--------------------------------------------------------------------
67+ # # Plugins
68+ # #--------------------------------------------------------------------
69+ # Plug in configuration file directory
70+ plugins.dir = " plugin/"
71+ # Plug in started by default, when the mqtt server is started
72+ plugins.default_startups = [
73+ # "rmqtt-plugin-template",
74+ # "rmqtt-retainer",
75+ # "rmqtt-auth-http",
76+ # "rmqtt-cluster-broadcast",
77+ # "rmqtt-cluster-raft",
78+ # "rmqtt-sys-topic",
79+ # "rmqtt-message-storage",
80+ # "rmqtt-session-storage",
81+ # "rmqtt-web-hook",
82+ # "rmqtt-http-api"
83+ ]
84+
85+
86+ # #--------------------------------------------------------------------
87+ # # MQTT
88+ # #--------------------------------------------------------------------
89+
90+
91+ # #--------------------------------------------------------------------
92+ # # Listeners
93+ # #--------------------------------------------------------------------
94+
95+ # #--------------------------------------------------------------------
96+ # # MQTT/TCP - External TCP Listener for MQTT Protocol
97+ listener.tcp.external.addr = " 0.0.0.0:1883"
98+ # Number of worker threads
99+ listener.tcp.external.workers = 8
100+ # The maximum number of concurrent connections allowed by the listener.
101+ listener.tcp.external.max_connections = 1024000
102+ # Maximum concurrent handshake limit, Default: 500
103+ listener.tcp.external.max_handshaking_limit = 500
104+ # Handshake timeout.
105+ listener.tcp.external.handshake_timeout = " 30s"
106+ # Maximum allowed mqtt message length. 0 means unlimited, default: 1m
107+ listener.tcp.external.max_packet_size = " 1m"
108+ # The maximum length of the TCP connection queue.
109+ # It indicates the maximum number of TCP connection queues that are being handshaked three times in the system
110+ listener.tcp.external.backlog = 1024
111+ # Whether anonymous login is allowed. Default: true
112+ listener.tcp.external.allow_anonymous = true
113+ # A value of zero indicates disabling the keep-alive feature, where the server
114+ # doesn't need to disconnect due to client inactivity, default: true
115+ listener.tcp.external.allow_zero_keepalive = true
116+ # Minimum allowable keepalive value for mqtt connection,
117+ # less than this value will reject the connection(MQTT V3),
118+ # less than this value will set keepalive to this value in CONNACK (MQTT V5),
119+ # default: 0, unit: seconds
120+ listener.tcp.external.min_keepalive = 0
121+ # Maximum allowable keepalive value for mqtt connection,
122+ # greater than this value will reject the connection(MQTT V3),
123+ # greater than this value will set keepalive to this value in CONNACK (MQTT V5),
124+ # default value: 65535, unit: seconds
125+ listener.tcp.external.max_keepalive = 65535
126+ # > 0.5, Keepalive * backoff * 2
127+ listener.tcp.external.keepalive_backoff = 0.75
128+ # Flight window size. The flight window is used to store the unanswered QoS 1 and QoS 2 messages
129+ listener.tcp.external.max_inflight = 16
130+ # Maximum length of message queue
131+ listener.tcp.external.max_mqueue_len = 1000
132+ # The rate at which messages are ejected from the message queue,
133+ # default value: "u32::max_value(),1s"
134+ listener.tcp.external.mqueue_rate_limit = " 1000,1s"
135+ # Maximum length of client ID allowed, Default: 65535
136+ listener.tcp.external.max_clientid_len = 65535
137+ # The maximum QoS level that clients are allowed to publish. default value: 2
138+ listener.tcp.external.max_qos_allowed = 2
139+ # The maximum level at which clients are allowed to subscribe to topics.
140+ # 0 means unlimited. default value: 0
141+ listener.tcp.external.max_topic_levels = 0
142+ # Whether support retain message, true/false, default value: false
143+ listener.tcp.external.retain_available = false
144+ # Session timeout, default value: 2 hours
145+ listener.tcp.external.session_expiry_interval = " 2h"
146+ # QoS 1/2 message retry interval, 0 means no resend
147+ listener.tcp.external.message_retry_interval = " 20s"
148+ # Message expiration time, 0 means no expiration
149+ listener.tcp.external.message_expiry_interval = " 5m"
150+ # The maximum number of topics that a single client is allowed to subscribe to
151+ # 0 means unlimited, default value: 0
152+ listener.tcp.external.max_subscriptions = 0
153+ # Shared subscription switch, default value: true
154+ listener.tcp.external.shared_subscription = true
155+ # topic alias maximum, default value: 0, topic aliases not enabled. (MQTT 5.0)
156+ listener.tcp.external.max_topic_aliases = 32
157+
158+ # #--------------------------------------------------------------------
159+ # # Internal TCP Listener for MQTT Protocol
160+ # listener.tcp.internal.enable = true
161+ # listener.tcp.internal.addr = "0.0.0.0:11883"
162+ # listener.tcp.internal.workers = 4
163+ # listener.tcp.internal.max_connections = 102400
164+ # listener.tcp.internal.max_handshaking_limit = 500
165+ # listener.tcp.internal.handshake_timeout = "30s"
166+ # listener.tcp.internal.max_packet_size = "1M"
167+ # listener.tcp.internal.backlog = 512
168+ # listener.tcp.internal.allow_anonymous = true
169+ # listener.tcp.internal.allow_zero_keepalive = true
170+ # listener.tcp.internal.min_keepalive = 0
171+ # listener.tcp.internal.max_keepalive = 65535
172+ # listener.tcp.internal.keepalive_backoff = 0.75
173+ # listener.tcp.internal.max_inflight = 16
174+ # listener.tcp.internal.max_mqueue_len = 1000
175+ # listener.tcp.internal.mqueue_rate_limit = "1000,1s"
176+ # listener.tcp.internal.max_clientid_len = 65535
177+ # listener.tcp.internal.max_qos_allowed = 2
178+ # listener.tcp.internal.max_topic_levels = 0
179+ # listener.tcp.internal.retain_available = false
180+ # listener.tcp.internal.session_expiry_interval = "2h"
181+ # listener.tcp.internal.message_retry_interval = "30s"
182+ # listener.tcp.internal.message_expiry_interval = "5m"
183+ # listener.tcp.internal.max_subscriptions = 0
184+ # listener.tcp.internal.shared_subscription = true
185+ # listener.tcp.internal.max_topic_aliases = 0
186+
187+ # #--------------------------------------------------------------------
188+ # # MQTT/TLS - External TLS Listener for MQTT Protocol, (TLSv1.2)
189+ # listener.tls.external.addr = "0.0.0.0:8883"
190+ # listener.tls.external.cross_certificate = true
191+ # listener.tls.external.cert = "./rmqtt-bin/rmqtt.fullchain.pem"
192+ # listener.tls.external.cross_certificate = false
193+ # listener.tls.external.cert = "./rmqtt-bin/rmqtt.pem"
194+ # listener.tls.external.key = "./rmqtt-bin/rmqtt.key"
195+
196+ # #--------------------------------------------------------------------
197+ # # MQTT/WebSocket - External WebSocket Listener for MQTT Protocol
198+ # listener.ws.external.addr = "0.0.0.0:8080"
199+
200+ # #--------------------------------------------------------------------
201+ # # MQTT/TLS-WebSocket - External TLS-WebSocket Listener for MQTT Protocol, (TLSv1.2)
202+ # listener.wss.external.addr = "0.0.0.0:8443"
203+ # listener.wss.external.cross_certificate = true
204+ # listener.wss.external.cert = "./rmqtt-bin/rmqtt.fullchain.pem"
205+ # listener.wss.external.cross_certificate = false
206+ # listener.wss.external.cert = "./rmqtt-bin/rmqtt.pem"
207+ # listener.wss.external.key = "./rmqtt-bin/rmqtt.key"
0 commit comments