mochi-mqtt / server

The fully compliant, embeddable high-performance Go MQTT v5 server for IoT, smarthome, and pubsub
MIT License
1.29k stars 222 forks source link

Clients MQTT often experience disconnection listener=tcp1 error=EOF and i/o timeout #422

Open abdidarmawan007 opened 4 months ago

abdidarmawan007 commented 4 months ago

Clients often experience disconnection

Error logs from mochi server : level=WARN msg="" listener=tcp1 error=EOF and "i/o timeout"

mochi server version : v2.6.4

my config

listeners:
  - type: "tcp"
    id: "tcp1"
    address: ":1883"
  - type: "ws"
    id: "ws1"
    address: ":1882"
  - type: "sysinfo"
    id: "stats"
    address: ":1880"
hooks:
  auth:
    allow_all: false
    ledger:
      auth:
        - username: staging-test
          password: xxxxxxxxxxxxx
          allow: true 
options:
  client_net_write_buffer_size: 2048
  client_net_read_buffer_size: 2048
  sys_topic_resend_interval: 10   
  inline_client: true
capabilities:
  maximum_client_writes_pending: 8192
  maximum_message_expiry_interval: 14400
  maximum_session_expiry_interval: 86400
  maximum_packet_size: 0
  receive_maximum: 4096
  maximum_inflight: 8192
  topic_alias_maximum: 65535
  shared_sub_available: 1
  minimum_protocol_version: 5
  maximum_qos: 2
  retain_available: 1
  wildcard_sub_available: 1
  sub_id_available: 1
compatibilities:
  obscure_not_authorized: true
  passive_client_disconnect: false
  always_return_response_info: false
  restore_sys_info_on_restart: false
  no_inherited_properties_on_ack: false
logging:
  level: INFO
thedevop commented 3 months ago

@abdidarmawan007 what's the keepalive value set on the client?