Uploaded image for project: 'Thrift'
  1. Thrift
  2. THRIFT-2868

Enhance error handling in the Go client

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 0.9.2
    • Fix Version/s: 0.9.3
    • Component/s: Go - Compiler, Go - Library
    • Labels:
      None
    • Patch Info:
      Patch Available

      Description

      The Go client doesn't do proper error checking. E.g. it doesn't check whether the received method name is correct nor if the message type has the expected value.

      The following PR enhances the Go client error handling by the following:

      • Check if method name is correct -> if not return thrift.WRONG_METHOD_NAME
      • Check if MessageType is thrift.REPLY or EXCEPTION -> if not return thrift.INVALID_MESSAGE_TYPE_EXCEPTION
      • Checking the sequence id is done before checking the message type

      Includes test cases for every error case.

      https://github.com/apache/thrift/pull/297

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                jensg Jens Geyer
                Reporter:
                cvlchinet Chi Vinh Le
              • Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: