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

Remove pthread and boost::thread library support and use std::thread for C++11

    XMLWordPrintableJSON

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Duplicate
    • Affects Version/s: 0.11.0, 0.12.0
    • Fix Version/s: None
    • Labels:
      None

      Description

      We have a pretty awful thread class implementation:

      1. The build system compiles in the right files to implement the class definition.
      2. We support three thread libraries.

      I want to simplify this, tremendously, to:

      A. Remove the pthread implementation.
      B. Remove the boost thread implementation.
      C. Rename the std thread implementation (StdThreadFactory) to ThreadFactory
      D. Have one thread class implementation!
      E. Remove the WITH_STDTHREADS build time option as it will no longer be necessary.

      In short:

      • Support std::thread for C++11 or later
      • Drop support for boost threads
      • Drop support for native pthreads

      We have a lot of branches and test conditionals that do special things with different thread implementations. We need to simplify and move forward to reduce the maintenance cost in this area.

      Any objections?

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                jking3 James E. King III
                Reporter:
                jking3 James E. King III
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: