Skip to content

Node-RED crashes when Postgres terminates connection unexpectedly due to out of memory error #97

@marcus-clements

Description

@marcus-clements

This looks related to #50

Node-RED v14.2
node.js v22.11.0

I am executing a query that occasionally causes an out of memory error in Postgres. This throws an uncaught exception which crashes Node-RED

8 Jan 16:29:16 - [error] [postgresql:Foo Query] error: out of memory
8 Jan 16:29:16 - [red] Uncaught Exception:
8 Jan 16:29:16 - [error] Error: Connection terminated unexpectedly
    at Connection.<anonymous> (/data/node_modules/pg/lib/client.js:131:73)
    at Object.onceWrapper (node:events:632:28)
    at Connection.emit (node:events:518:28)
    at Connection.emit (node:domain:489:12)
    at Socket.<anonymous> (/data/node_modules/pg/lib/connection.js:62:12)
    at Socket.emit (node:events:530:35)
    at Socket.emit (node:domain:489:12)
    at TCP.<anonymous> (node:net:343:12)

Metadata

Metadata

Assignees

No one assigned

    Labels

    help wantedExtra attention is needed

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions