I’m making a workflow that should trigger by AMQP Trigger when a new message appears in the ActiveMQ queue.
I noticied 2 problems with the Trigger when it triggered manually.
AMQP Trigger does not close a connection
If I click the “Listen For Event” button on the Trigger properties window and no event occurs after 30 seconds of waiting, I receive an error:
The error is okay, but it looks like an exception for n8n, so it does not close a connection to the AMQP server. Also if I listen for events two times with no messages, I am unable to receive any messages further in UI anymore: it looks like they are read by connections stuck in the background.
~ $ netstat -anp | grep 5672
tcp 0 0 10.10.0.2:42654 10.10.0.4:5672 ESTABLISHED 8/node
tcp 0 0 10.10.0.2:51812 10.10.0.4:5672 ESTABLISHED 8/node
tcp 0 0 10.10.0.2:39246 10.10.0.4:5672 ESTABLISHED 8/node
Unable to stop listening to events
If I click the “Stop Listening” button on the Trigger properties window during event listening, nothing happens. The Trigger continues listening until a timeout of 30 seconds occurs. Then one more connection remains in the background.
To continue testing of the workflow I can only restart n8n, which is quite inconvenient.
Information on n8n setup
- n8n version: 1.7.1
- Database: PostgreSQL
- n8n EXECUTIONS_MODE setting: regular
- Running n8n via: Docker
- Operating system: Linux