Created
October 16, 2024 14:20
-
-
Save reubenmiller/aed28209d9864bb803d45431e928c83f to your computer and use it in GitHub Desktop.
Example nanomq configuration
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# NanoMQ Configuration 0.18.0 | |
#============================================================ | |
# NanoMQ Broker | |
#============================================================ | |
system { | |
daemon = false | |
num_taskq_thread = 0 | |
max_taskq_thread = 0 | |
parallel = 0 | |
} | |
mqtt = { | |
max_packet_size = 260MB # Maximum packet size NanoMQ can accept and send, 1B~260MB. | |
max_mqueue_len = 2048 # Maximum length of the in-flight window queue | |
retry_interval = 5s # Retry interval for QoS 1/2 message delivering | |
keepalive_multiplier = 1.25 # Multiplier for MQTT keepalive timeout. | |
property_size = 32 # Maximum size for a MQTT user property. | |
} | |
# Message persistence | |
sqlite { | |
disk_cache_size = 102400 # Max number of messages for caching | |
mounted_file_path="/tmp/" # Mounted file path | |
flush_mem_threshold = 100 # The threshold number of flushing messages to flash | |
resend_interval = 5000 # Resend interval (ms) | |
} | |
log { | |
to = [console] | |
level = info | |
} | |
# Listeners | |
listeners.tcp { | |
bind = "127.0.0.1:1883" | |
} | |
# listeners.ssl { | |
# bind = "0.0.0.0:8883" # Bind to all network interfaces on port 8883 | |
# # key_password = <yourpass> # String with the password to decrypt private keyfile | |
# keyfile = "/etc/certs/key.pem" # Key file path | |
# certfile = "/etc/certs/cert.pem" # User certificate file path | |
# cacertfile = "/etc/certs/cacert.pem" # CA certificate file path | |
# verify_peer = true # If NanoMQ requests a certificate from the client | |
# fail_if_no_peer_cert = true # If to reject connection if no certificate is provided | |
# } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment