mirror of
https://github.com/absmach/supermq.git
synced 2026-08-07 19:21:53 +00:00
e3916f91af
* Fix replication Signed-off-by: dusan <borovcanindusan1@gmail.com> * Fix forwarding for write policy forward Signed-off-by: dusan <borovcanindusan1@gmail.com> * Use replicate mode formwarding for ephemeral queues Signed-off-by: dusan <borovcanindusan1@gmail.com> --------- Signed-off-by: dusan <borovcanindusan1@gmail.com>
113 lines
2.1 KiB
YAML
113 lines
2.1 KiB
YAML
# MQTT Broker - 3-Node Cluster: Node 3
|
|
# Third node joining the cluster
|
|
# Run all three nodes simultaneously to form the cluster
|
|
|
|
server:
|
|
tcp:
|
|
plain:
|
|
addr: ":1885"
|
|
max_connections: 10000
|
|
read_timeout: "60s"
|
|
write_timeout: "60s"
|
|
tls: {}
|
|
mtls: {}
|
|
|
|
websocket:
|
|
plain:
|
|
addr: "" # Disabled for cluster testing
|
|
tls:
|
|
addr: ""
|
|
mtls:
|
|
addr: ""
|
|
|
|
http:
|
|
plain:
|
|
addr: "" # Disabled for cluster testing
|
|
tls:
|
|
addr: ""
|
|
mtls:
|
|
addr: ""
|
|
|
|
coap:
|
|
plain:
|
|
addr: "" # Disabled for cluster testing
|
|
dtls:
|
|
addr: ""
|
|
mdtls:
|
|
addr: ""
|
|
|
|
amqp:
|
|
plain:
|
|
addr: ":5674"
|
|
tls: {}
|
|
mtls: {}
|
|
|
|
amqp091:
|
|
plain:
|
|
addr: ":5684"
|
|
tls: {}
|
|
mtls: {}
|
|
|
|
health_enabled: true
|
|
health_addr: ":8083"
|
|
|
|
shutdown_timeout: "30s"
|
|
|
|
broker:
|
|
max_message_size: 1048576
|
|
max_retained_messages: 10000
|
|
retry_interval: "20s"
|
|
max_retries: 0
|
|
|
|
session:
|
|
max_sessions: 1000000
|
|
default_expiry_interval: 300
|
|
max_offline_queue_size: 1000
|
|
max_inflight_messages: 100
|
|
|
|
storage:
|
|
type: "badger"
|
|
badger_dir: "/tmp/fluxmq/node3/data"
|
|
|
|
cluster:
|
|
enabled: true
|
|
node_id: "node3"
|
|
|
|
etcd:
|
|
data_dir: "/tmp/fluxmq/node3/etcd"
|
|
bind_addr: "127.0.0.1:2580"
|
|
client_addr: "127.0.0.1:2579"
|
|
initial_cluster: "node1=http://127.0.0.1:2380,node2=http://127.0.0.1:2480,node3=http://127.0.0.1:2580"
|
|
bootstrap: true # Part of initial cluster formation
|
|
|
|
transport:
|
|
bind_addr: "127.0.0.1:7950"
|
|
peers:
|
|
node1: "127.0.0.1:7948"
|
|
node2: "127.0.0.1:7949"
|
|
|
|
raft:
|
|
enabled: true
|
|
replication_factor: 3
|
|
sync_mode: true
|
|
min_in_sync_replicas: 2
|
|
ack_timeout: "5s"
|
|
write_policy: "forward"
|
|
distribution_mode: "replicate"
|
|
bind_addr: "127.0.0.1:7300"
|
|
data_dir: "/tmp/fluxmq/node3/raft"
|
|
peers:
|
|
node1: "127.0.0.1:7100"
|
|
node2: "127.0.0.1:7200"
|
|
heartbeat_timeout: "1s"
|
|
election_timeout: "3s"
|
|
snapshot_interval: "5m"
|
|
snapshot_threshold: 8192
|
|
|
|
log:
|
|
level: "debug"
|
|
format: "text"
|
|
|
|
queue_manager:
|
|
auto_commit_interval: 5s
|