node-red / node-red/node-red-nodes
Cannot retrieve node-red-node-mongodb query status
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 1.1k
- Forks
- 612
- Avg merge
- 13h 57m
- Merged PRs (30d)
- 3
Description
Hi,
I think the OUT node for node-red-node-mongodb (which is provided with the extra nodes package) should provide an output, so we can process the status of the query (Did it fail ? Did it succeed ? When ?).
Simple real case : I'm exposing an HTTP endpoint updating a document in a mongo DB. As of right now, I have no means to send the HTTP response WHEN the query is done, or to provide details on the success of the query in the HTTP response. My only option is to send a HTTP 200 when the HTTP endpoint is called, meaning I cannot send an error response when/if the node fails.
I was suggested on the node-red forum to use the status node to catch status emitted from the mongo node, but with this method, I cannot keep the http related properties (msg.req, etc...) to send to the http out node (since you can only pass fill, shape and text properties with status, where you can send a whole object with node.error for example).
I'm willing to implement this if needed.
Have a good day
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the node-red-node-mongodb OUT node and reviewing how its query completion and failure are currently handled; the issue also references the status node and HTTP endpoint flow. Done means the OUT node exposes query completion details, including success or failure, while allowing the HTTP request properties to reach the HTTP response.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, mongodb
- Domain
- backend, databases
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100