Notice: Over the next few months, we're reorganizing the App Engine documentation site to make it easier to find content and better align with the rest of Google Cloud products. The same content will be available, but the navigation will now match the rest of the Cloud products. If you have feedback or questions as you navigate the site, click Send Feedback.

Python 2 is no longer supported by the community. We recommend that you migrate Python 2 apps to Python 3.

The Transport Class

Stay organized with collections Save and categorize content based on your preferences.

Transport is the base class for implementing a Protocol RPC transport. Transports allow you to send and receive messages over HTTP.

This method receives an encoded response as determined by the transport's configured protocol. The transport is expected to set the RPC response or raise an exception before termination.

Note: Asynchronous transports are not supported.

Transport is provided by the protorpc.transport module.


class Transport (protocol=protobuf)

Instantiates a Transport object.

The protocol implementation. Must implement encode_message() and decode_message(), which are available in other protocols, such as protorpc.protojson, protorpc.protobuf, and protorpc.protojson.

Class Property

The Transport class provides the following property:

The protocol associated with this transport.

Instance Methods

Transport instances have the following method:

send_rpc(remote_info, request)
Initiate sending an RPC over the transport. Arguments
The remote information object associated with the remote method.