Uploaded image for project: 'Couchbase C client library libcouchbase'
  1. Couchbase C client library libcouchbase
  2. CCBC-1496

Server::next_timeout() execution time

    XMLWordPrintable

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • None
    • 3.3.3
    • library
    • 1

    Description

      Profiling some client application shows that noticeable amout of time is spent in Server::next_timeout() (defined inĀ src/mcserver/mcserver.cc).

      It appears that this function searches for request with shortest timeout deadline using a linear complexity algorithm. Eventually changing data structure from a linked list to a heap implemented as a binary tree would allow to implement this function in O(1) complexity.

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          jo JC created issue -
          avsej Sergey Avseyev made changes -
          Field Original Value New Value
          Status New [ 10003 ] Open [ 1 ]
          avsej Sergey Avseyev made changes -
          Labels technical-debt
          avsej Sergey Avseyev made changes -
          Fix Version/s 3.3.0 [ 17253 ]
          avsej Sergey Avseyev made changes -
          Fix Version/s 3.3.1 [ 17253 ]
          Fix Version/s 3.3.2 [ 18396 ]
          avsej Sergey Avseyev made changes -
          Fix Version/s 3.3.2 [ 18396 ]
          Fix Version/s 3.3.3 [ 18539 ]
          Fix Version/s 3.3.3 [ 18539 ]

          People

            avsej Sergey Avseyev
            jo JC
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes

                PagerDuty