| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125 | gRPC AsyncIO API================.. module:: grpc.experimental.aioOverview--------gRPC AsyncIO API is the **new version** of gRPC Python whose architecture istailored to AsyncIO. Underlying, it utilizes the same C-extension, gRPC C-Core,as existing stack, and it replaces all gRPC IO operations with methods providedby the AsyncIO library.This stack currently is under active development. Feel free to offersuggestions by opening issues on our GitHub repo `grpc/grpc <https://github.com/grpc/grpc>`_.The design doc can be found here as `gRFC <https://github.com/grpc/proposal/pull/155>`_.Caveats-------gRPC Async API objects may only be used on the thread on which they werecreated. AsyncIO doesn't provide thread safety for most of its APIs.Enable AsyncIO in gRPC----------------------Enable AsyncIO in gRPC Python is automatic when instantiating gRPC AsyncIOobjects (e.g., channels and servers). No additional function invocation isrequired.Making blocking function calls in coroutines or in the thread running eventloop will block the event loop, potentially starving all RPCs in the process.Refer to the Python language documentation on AsyncIO for more details (`running-blocking-code <https://docs.python.org/3/library/asyncio-dev.html#running-blocking-code>`_).Module Contents---------------Create Channel^^^^^^^^^^^^^^Channels are the abstraction of clients, where most of networking logichappens, for example, managing one or more underlying connections, nameresolution, load balancing, flow control, etc.. If you are using ProtoBuf,Channel objects works best when further encapsulate into stub objects, then theapplication can invoke remote functions as if they are local functions... autofunction:: insecure_channel.. autofunction:: secure_channelChannel Object^^^^^^^^^^^^^^.. autoclass:: ChannelCreate Server^^^^^^^^^^^^^.. autofunction:: serverServer Object^^^^^^^^^^^^^.. autoclass:: ServergRPC Exceptions^^^^^^^^^^^^^^^.. autoexception:: BaseError.. autoexception:: UsageError.. autoexception:: AbortError.. autoexception:: InternalError.. autoexception:: AioRpcErrorShared Context^^^^^^^^^^^^^^^^^^^^.. autoclass:: RpcContextClient-Side Context^^^^^^^^^^^^^^^^^^^^^^^.. autoclass:: Call.. autoclass:: UnaryUnaryCall.. autoclass:: UnaryStreamCall.. autoclass:: StreamUnaryCall.. autoclass:: StreamStreamCallServer-Side Context^^^^^^^^^^^^^^^^^^^^^^^.. autoclass:: ServicerContextClient-Side Interceptor^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^.. autoclass:: ClientCallDetails.. autoclass:: InterceptedUnaryUnaryCall.. autoclass:: UnaryUnaryClientInterceptor.. Service-Side Context.. ^^^^^^^^^^^^^^^^^^^^.. .. autoclass:: ServicerContextMulti-Callable Interfaces^^^^^^^^^^^^^^^^^^^^^^^^^.. autoclass:: UnaryUnaryMultiCallable.. autoclass:: UnaryStreamMultiCallable().. autoclass:: StreamUnaryMultiCallable().. autoclass:: StreamStreamMultiCallable()
 |