Uploaded image for project: 'Apache Avro'
  1. Apache Avro
  2. AVRO-115

remove RPC sessions

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 1.2.0
    • spec
    • None
    • Incompatible change

    Description

      The spec currently has a notion of an RPC session. Within a session requests and responses need not be prefixed by handshakes.

      The existing RPC implementations (python and Java) assume that all transports naturally have sessions, which is not the case. An HTTP transport may or may not have a session, a UDP transport does not naturally have a session. Moreover, we anticipate the implementation in Avro of a high-performance scalable transport that, e.g., permits multiplexing of requests and responses over a single TCP connection. Establishing a session in this context creates a race condition. Also, it would be advantageous if a single connection could service multiple protocols.

      For the above reasons, I propose we remove the notion of RPC sessions. Each request and response payload must then be prefixed by a HandshakeRequest or HandshakeResponse respectively. In most cases this adds just 34 bytes to requests and 4 bytes to responses. The added runtime costs are negligible, as, instead of using a session key to access the cached protocol instead the protocol hashes are used.

      Attachments

        1. AVRO-115.patch
          31 kB
          Doug Cutting

        Activity

          People

            cutting Doug Cutting
            cutting Doug Cutting
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: