What is <Processor> - the computer #7
rayk
started this conversation in
Why, What & How
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Processor
A statement piece of code that is executed at each vertex in a logically effective manner until some termination condition is met (e.g. a number of iterations have occurred, all vertex in the graph have been consumed, or some other conditions.)
Constructor
(Graph) => GraphThe passed in
<Graph>here is NOT the target graph on which the processor is to be run. Rather it's a graph that contains the processor's configuration and initial state.Execution
(Stream<Node>) => ProcessorExecution of the processor entails passing it a
Stream<Node>that the processor shall subscribe and listen to. Handling any arriving<Node>. The runner or one of its controlled subprocesses then adds<Node>to the sink of the stream in topological order. The processor completes its work when the sink is closed, which the runner is notified about via the close event on the<Stream<Node>>to which it has subscribed.By calling
resulta<Graph>containing the result is returned.Processor Assumptions
Each implementation of
<Processor>make the following assumptions:5
Processor Guarantees
Each implementation of
<Processor>provides the following guarantees.Stream<Node>is destroyed after calling.result..resultbefore closing the sink associated with the stream will throw<StateError>.reseton the process returns it to the state before it received the stream..reseton a process a second time or before it receives a stream will result in a NOOP.Beta Was this translation helpful? Give feedback.
All reactions