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

Use select.poll instead of select.select in Python TNonblockingServer if available

    XMLWordPrintableJSON

Details

    Description

      Currently Python TNonblockingServer uses select.select to monitor the IO of all existing connections. The value of file descriptors monitored by select() is limited to be lower than FD_SETSIZE (1024). Any file desciptor higher than 1024, when passed into select.select, will trigger the "fd out of range" error. 

      Switching to select.poll can solve this problem. However, as noted in the official documentation, select.poll is not supported in all operating system. We should also check whether the current system has poll in the select module, and use poll if it's available.

      Attachments

        Activity

          People

            frankiechang Yiyang Zhou
            frankiechang Yiyang Zhou
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Time Tracking

                Estimated:
                Original Estimate - 48h
                48h
                Remaining:
                Time Spent - 2h 10m Remaining Estimate - 45h 50m
                45h 50m
                Logged:
                Time Spent - 2h 10m Remaining Estimate - 45h 50m
                2h 10m