jina.peapods.runtimes.zmq.zed module

class jina.peapods.runtimes.zmq.zed.ZEDRuntime(args)[source]

Bases: jina.peapods.runtimes.zmq.base.ZMQRuntime

Runtime procedure leveraging ZmqStreamlet for Executor.

run_forever()[source]

Start the ZmqStreamlet.

setup()[source]

Initialize private parameters and execute private loading functions.

teardown()[source]

Close the ZmqStreamlet and Executor.

property is_idle

Return True when current time is max_idle_time seconds late than the last active time

Return type

bool

Returns

True if idle else false.

property request

Get the current request body inside the protobuf message

Return type

Request

Returns

ZEDRuntime request

property message

Get the current protobuf message to be processed

Return type

Message

Returns

ZEDRuntime message

property request_type

Get the type of message being processed

Return type

str

Returns

request type

property expect_parts

The expected number of partial messages before trigger handle()

Return type

int

Returns

expected number of partial messages

property partial_requests

The collected partial requests under the current request_id

Return type

List[Request]

Returns

collected partial requests

property partial_messages

The collected partial messages under the current request_id ” :rtype: List[Message] :return: collected partial messages

property docs

Return a DocumentArray by concatenate (multiple) requests.docs

Return type

DocumentArray

property groundtruths

Return a DocumentArray by concatenate (multiple) requests.groundtruths

Return type

DocumentArray

property docs_matrix

Return a list of DocumentArray from multiple requests

Return type

List[DocumentArray]

property groundtruths_matrix

A flattened DocumentArray from (multiple) requests

Return type

List[DocumentArray]

property envelope

Get the current message envelope

Return type

EnvelopeProto