Struct strymon_job::Coordinator [] [src]

pub struct Coordinator { /* fields omitted */ }

Handle to communicate with the Strymon coordinator.

The methods of this object can be used to publish or subscribe to topics available in the catalog. In order to obtain a Coordinator instance, users must register the current process with strymon_job::execute.

Methods

impl Coordinator
[src]

[src]

Publishes a local stream and creates a topic in the catalog.

This will block the current worker until the coordinator has processed the publication request.

Each published stream must have a globally unique name, which used to create a topic in the catalog. This method injects a publisher operator into the Timely dataflow which forwards all data and progress messages put into stream. The created topic is deregistered when the frontier of the input stream becomes empty. Upon deregisteration, the current worker is blocked until the queues of any still connected subscribers are drained.

If the Partition::Merge strategy is used, a single topic is created whose name is specified in name. If a Partition::PerWorker partitioning scheme is used, one topic is created for each worker, with the worker's index appended, e.g. foobar.1.

impl Coordinator
[src]

[src]

Creates a new subscription for a single topic.

This method requests a subscription for a topic called name from the coordinator. The requested topic must be published with the same data and timestamp types Tand D respectively.

In to obtain progress tracking information from the upstream Timely computation(s), the subscription handle exposes a frontier() method which allows inspection of the current frontier.

When blocking is true, this call blocks until a remote publisher creates a topic with a suitable name. If blocking is false, the call returns with an error if the catalog does not contain a topic with a matching name.

[src]

Create a new subscription for a partitioned topic.

This method requests a subscription for each provided partition and merges their stream. The partition number is attached to each topic name, e.g. for prefix = "foo" and partitions = [0, 2, 5], the resulting subscriptions are for "foo.0", "foo.2", "foo.5".

See the subscribe method for more details.

impl Coordinator
[src]

[src]

Creates a new request service and announces it in the catalog.

Given a service interface definition and a name, creates a new server for receiving incoming requests. A topic is created under the specified name which is used by clients to bind to the service.

[src]

Creates a binding to a service topic for sending requests.

Returns a handle for submitting requests to the given server. The binding created by this invocation is also stored in the catalog as a Subscription. The subscription is revoked once the Client handle is dropped.

When blocking is true, this call blocks until a remote job registers a service with the matching name. If blocking is false, the call returns with an error if the topic does not exist.

Trait Implementations

impl Clone for Coordinator
[src]

[src]

Returns a copy of the value. Read more

1.0.0
[src]

Performs copy-assignment from source. Read more