Skip to content

Define ownership of sub-receivers #432

@llucax

Description

@llucax

Now that close() is part of the receiver interface, we need to be more clear and consistent about when and who closes sub-receivers.

Examples of objects that close the source receiver:

  • Receiver.filter()
  • Receiver.map()
  • merge()/Merger

Examples of objects that don't:

  • LatestValueCache
  • select()

For me the most clear approach would be that objects always take ownership of the source receiver and close them when they are themselves disposed, but to be able to do this and still be flexible, we probably need to resurrect the clone idea (#382), so if you want to also keep a copy of the original receiver, you can do so. Of course, this also opened a lot of questions, so not trivial.

Metadata

Metadata

Assignees

No one assigned

    Labels

    type:enhancementNew feature or enhancement visitble to users

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions