appyx icon indicating copy to clipboard operation
appyx copied to clipboard

Issue #296 Dispose NodeConnector intake in onDestroy

Open LachlanMcKee opened this issue 2 years ago • 2 comments

Description

Closes #296

Check list

  • [x] I have updated CHANGELOG.md if required.
  • [x] I have updated documentation if required.

LachlanMcKee avatar Dec 04 '22 21:12 LachlanMcKee

Honestly do not think it is an error. Both source and subscriber are managed by us, they should be GCed together as soon as everybody unsubscribed from node.

But not against PR, makes sense.

CherryPerry avatar Dec 05 '22 10:12 CherryPerry

@CherryPerry the garbage collector is not deterministic, so if we don't unsubscribe in a deterministic manner, users may get unexpected behaviours (depending on whether they are still sending events after a node is destroyed.

LachlanMcKee avatar Dec 05 '22 10:12 LachlanMcKee