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

Bind to zero port

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Won't Fix
    • None
    • None
    • C++ - Library
    • None
    • Patch Available

    Description

      apache::thrift::transport::TServerSocket class has a possibility to set 0 as port number. In this case bind will assign a free port number. Unfortunately there is no possibility to retrieve the assigned port number from the TServerSocket class. Thus clients will not be able to connect the server.

      The suggested patch introduces apache::thrift::transport::TServerSocket::getBindPort() method that return the assigned port number or -1 in the case of any failure or when the port has not been assigned yet.

      Attachments

        1. bindinfo_retrieval.diff
          3 kB
          Ivan Murashko

        Issue Links

          Activity

            People

              Unassigned Unassigned
              ivanm Ivan Murashko
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - 1h
                  1h
                  Remaining:
                  Remaining Estimate - 1h
                  1h
                  Logged:
                  Time Spent - Not Specified
                  Not Specified