docarray.array.mixins.post module#
- class docarray.array.mixins.post.PostMixin[source]#
Bases:
object
Helper functions for posting DocumentArray to Jina Flow.
- post(host, show_progress=False, batch_size=None, parameters=None, **kwargs)[source]#
Posting itself to a remote Flow/Sandbox and get the modified DocumentArray back
- Parameters:
host (
str
) – a host string. Can be one of the following: - grpc://192.168.0.123:8080/endpoint - ws://192.168.0.123:8080/endpoint - http://192.168.0.123:8080/endpoint - jinahub://Hello/endpoint - jinahub+docker://Hello/endpoint - jinahub+docker://Hello/v0.0.1/endpoint - jinahub+docker://Hello/latest/endpoint - jinahub+sandbox://Hello/endpointshow_progress (
bool
) – if to show a progressbarbatch_size (
Optional
[int
]) – number of Document on each requestparameters (
Optional
[Dict
]) – parameters to send in the request
- Return type:
- Returns:
the new DocumentArray returned from remote