Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

node-amqp-connection-manager doesn't retry "Operation failed: QueueDeclare" error #368

Open
IvanKodak opened this issue Apr 18, 2024 · 1 comment

Comments

@IvanKodak
Copy link

I got a case when my RabbitMq was unavailable and after a few retries, the app was through an unhandled rejection error.
I think that was caused because node-amqp-connection-manager doesn't handle this type of error from the amqplib.

I will attach the logs, that I have. Thanks in advance for helping.

Package versions:
amqp-connection-manager: 4.1.14
amqplib: 0.10.3

Stack:

Error: Operation failed: QueueDeclare; 404 (NOT-FOUND) with message "NOT_FOUND - failed to perform operation on queue '<queue-name>' in vhost 'dev' due to timeout"
    at reply (/usr/app/node_modules/amqplib/lib/channel.js:133:29)
    at ConfirmChannel.C.accept (/usr/app/node_modules/amqplib/lib/channel.js:416:7)
    at Connection.mainAccept (/usr/app/node_modules/amqplib/lib/connection.js:63:33)
    at TLSSocket.go (/usr/app/node_modules/amqplib/lib/connection.js:486:48)
    at TLSSocket.emit (node:events:518:28)
    at TLSSocket.emit (node:domain:488:12)
    at emitReadable_ (node:internal/streams/readable:832:12)
    at processTicksAndRejections (node:internal/process/task_queues:81:21)


Trace:

{
  "file": "/usr/app/node_modules/amqplib/lib/channel.js",
  "line": 133,
  "column": 29,
  "native": false,
  "method": null,
  "function": "reply"
},
{
  "file": "/usr/app/node_modules/amqplib/lib/channel.js",
  "line": 416,
  "column": 7,
  "native": false,
  "method": "accept",
  "function": "ConfirmChannel.C.accept"
},
{
  "file": "/usr/app/node_modules/amqplib/lib/connection.js",
  "line": 63,
  "column": 33,
  "native": false,
  "method": "mainAccept",
  "function": "Connection.mainAccept"
},
{
  "file": "/usr/app/node_modules/amqplib/lib/connection.js",
  "line": 486,
  "column": 48,
  "native": false,
  "method": "go",
  "function": "TLSSocket.go"
},
{
  "file": "node:events",
  "line": 518,
  "column": 28,
  "native": false,
  "method": "emit",
  "function": "TLSSocket.emit"
},
{
  "file": "node:domain",
  "line": 488,
  "column": 12,
  "native": false,
  "method": "emit",
  "function": "TLSSocket.emit"
},
{
  "file": "node:internal/streams/readable",
  "line": 832,
  "column": 12,
  "native": false,
  "method": null,
  "function": "emitReadable_"
},
{
  "file": "node:internal/process/task_queues",
  "line": 81,
  "column": 21,
  "native": false,
  "method": null,
  "function": "processTicksAndRejections"
}
@DmytroShalaiev
Copy link

Maybe someone can help with an issue, should such errors be handled & processed by node-amqp-connection-manager?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants