Skip to content

pubnub object is leaked on node destroy #2

@aditanase

Description

@aditanase

If you create a node-red node of type pubnub, deploy the flow, delete the node, then re-deploy, the old pubnub object is still around receiving messages.

I suspect you should look into the nodes lifecycle and destroy/stop the existing pubnub instance (pn_obj) on the node close event.

See here for an example: https://github.com/node-red/node-red/blob/master/nodes/core/io/10-mqtt.js#L66-L70

If you take pull requests, I'm happy to submit a patch.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions