node-red / node-red/node-red-nodes

MongoError: Topology was destroyed

Open
#540 5 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
1.1k
Forks
612
Avg merge
13h 57m
Merged PRs (30d)
3

Description

Hello

Node-Red engine is configured to collect data from a cloud MongoDB and it works usually but sometime it stops with error messages MongoError: Topology was destroyed

I googled much and it seems to be a problem with keeping the connection to the MongpDB server up and running. I mean it looks like if something wrong happens to the existing connection then the driver doesn't even try to re-establish a new one.

10 May 13:09:01 - [info] Node-RED version: v0.17.5
10 May 13:09:01 - [info] Node.js version: v8.15.1
10 May 13:09:01 - [info] Linux 4.14.98-v7+ arm LE => Raspberry PI
$ npm --version
6.4.1
~/.node-red $ npm list | grep mongo
├─┬ node-red-node-mongodb@0.0.14
│ └─┬ mongodb@2.2.36
│ ├─┬ mongodb-core@2.1.20

I expect that the implementation of the connection pooling (or something similar used) to keep the connection alive and reliable

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the failure in the node-red-node-mongodb@0.0.14 setup with mongodb@2.2.36, using the Node-RED and Raspberry Pi versions listed. Investigate the connection-pooling behavior around the reported “Topology was destroyed” error. Done means the node reliably recovers or clearly reports when the MongoDB connection is lost.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, mongodb
Domain
backend, databases
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
20/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.