Uploaded image for project: 'Couchbase Server'
  1. Couchbase Server
  2. MB-19259

ep-engine: Benign data race in DcpConsumer::backoffs

    XMLWordPrintable

Details

    • Untriaged
    • Unknown

    Description

      There is a data race on DcpConsumer::backoffs, as identified by ThreadSanitizer (see below). This variable is only used for statistics (total_backoffs and the per-connection "%s:backoff"), so the race is benign.

          As reported by ThreadSanitizer:
          
          WARNING: ThreadSanitizer: data race (pid=24629)
            Read of size 4 at 0x7d5000016b9c by main thread (mutexes: write M27034, write M2479):
              #0 void ConnHandler::addStat<unsigned int>(), void const*) ep-engine/src/tapconnection.h:291:18 (ep.so+0x00000004e993)
              #1 DcpConsumer::addStats(), void const*) ep-engine/src/dcp/consumer.cc:731:5 (ep.so+0x00000005a2c3)
              ...
          
            Previous write of size 4 at 0x7d5000016b9c by thread T10:
              #0 DcpConsumer::processBufferedItems() ep-engine/src/dcp/consumer.cc:755:17 (ep.so+0x0000000539c3)
              #1 Processer::run() ep-engine/src/dcp/consumer.cc:57:13 (ep.so+0x00000005376b)
              #2 ExecutorThread::run() ep-engine/src/executorthread.cc:115:26 (ep.so+0x0000000e944e)
      

      Note: already fixed in watson: http://review.couchbase.org/55924

      Attachments

        Issue Links

          For Gerrit Dashboard: MB-19259
          # Subject Branch Project Status CR V

          Activity

            People

              drigby Dave Rigby (Inactive)
              drigby Dave Rigby (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews

                  There are no open Gerrit changes

                  PagerDuty