Skip to content

Add control message payloads #44

@b3by

Description

@b3by

Description

Nodes in Juturna are always supposed to produce message objects on their output channels, and similarly, they expect message objects on their input channels. Still, node threads use None as a termination signal. This behaviour may lead to confusion in cases where:

  • None is part of the set of possible input/output values expected by/from a node;
  • a source function in a source node produces null or empty values;
  • messages should be propagated on the pipeline that trigger behaviours different from the stop;
  • it is required to collect information about who triggered a pipeline stop.

This issues could be solved with the introduction of a new payload, that is only used internally by nodes to communicate control actions to take related with the pipeline execution and lifecycle.

Current Behavior

Nodes use None messages to stop their execution. No other actions can be triggered using messages.

Proposed Solutions

A new payload can be introduced, something like ControlPayload, to simply carry an enum value, where each one can be related with an action the nodes should perform (stop is an example).


This is a topic open for discussion.

Metadata

Metadata

Assignees

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions