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

Buffer and Connection bloat in TNonBlockingServer

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • None
    • None
    • C++ - Library
    • None
    • Patch Available

    Description

      This patch helps to reduce the amount of memory allocated by TNonBlockingServer. It uses a configurable limit on the number of idle connections to keep around, and has a configurable limit on the amount of memory to keep allocated in the readBuffer when the connection is closed. This fix is in use at Facebook and has significantly reduced the amount of memory used by Scribe (https://sourceforge.net/projects/scribeserver/).

      See THRIFT-265 for another memory usage fix which reallocates input/output buffers every 512 reads/writes. THRIFT-265(and THRIFT-354) and this patch can be used together to tune the amount of memory used. The buffer_limit patch is especially useful for the case when there are many idle TConnections with large buffers allocated.

      Attachments

        1. buffer_limit.patch
          5 kB
          Anthony Giardullo

        Issue Links

          Activity

            People

              agiardullo Anthony Giardullo
              agiardullo Anthony Giardullo
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: