jina.peapods.runtimes.zmq.base¶
-
class
jina.peapods.runtimes.zmq.base.
ZMQRuntime
(args)[source]¶ Bases:
jina.peapods.runtimes.base.BaseRuntime
,abc.ABC
-
cancel
()[source]¶ Cancelling
run_forever()
fromM
.cancel()
usually requires some special communication betweenM
andS
, e.g.Use
threading.Event
or multiprocessing.Event, whilerun_forever()
polls for this eventUse ZMQ to send a message, while
run_forever()
polls for this messageUse HTTP/REST to send a request, while
run_forever()
listens to this request
See also
run_forever()
for blocking the process/thread.
-
property
status
¶
-
property
is_ready
¶ - Return type
bool
-
-
class
jina.peapods.runtimes.zmq.base.
ZMQManyRuntime
(args)[source]¶ Bases:
jina.peapods.runtimes.base.BaseRuntime
,abc.ABC
-
cancel
()[source]¶ Cancelling
run_forever()
fromM
.cancel()
usually requires some special communication betweenM
andS
, e.g.Use
threading.Event
or multiprocessing.Event, whilerun_forever()
polls for this eventUse ZMQ to send a message, while
run_forever()
polls for this messageUse HTTP/REST to send a request, while
run_forever()
listens to this request
See also
run_forever()
for blocking the process/thread.
-
property
status
¶
-
property
is_ready
¶ - Return type
bool
-