brocaar / chirpstack-application-server

ChirpStack Application Server is an open-source LoRaWAN application-server.
https://www.chirpstack.io
MIT License
501 stars 326 forks source link

AMQP Integration doesn't reestablish connection if channel was closed #687

Open DennisK92 opened 2 years ago

DennisK92 commented 2 years ago

What happened?

When restarting the AMQP server, all client channels are closed. The application server AMQP integration does not reestablish a connection to the AMQP server unless the application server is restarted.

What did you expect?

When the channel to the AMQP server is closed, the application server should try to establish a new connection instead of logging errors and not transmitting uplinks anymore.

Steps to reproduce this issue

Steps:

  1. Close the AMQP connection on serverside
  2. Check the logs on the application server or that messages aren't coming through anymore.
  3. Restart application server to resolve the issue.

Could you share your log output?

time="2022-05-30T13:46:42.486957131Z" level=info msg="integration/amqp: publishing event" ctx_id=1f5a323f-05d3-48d6-87f9-ccd821c7d333 routing_key=application.1.device.a81758fffe057092.event.up
time="2022-05-30T13:46:42.486990232Z" level=error msg="integration/multi: integration error" ctx_id=1f5a323f-05d3-48d6-87f9-ccd821c7d444 error="publish event error: Exception (504) Reason: \"channel/connection is not open\"" integration="*amqp.Integration"

Your Environment

Component Version
Application Server v3.17.6