Uploaded image for project: 'Traffic Server'
  1. Traffic Server
  2. TS-1632

RecDecrRawStat does not seem to work as intended

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 3.3.2
    • Metrics
    • None

    Description

      In the RecDecrRawStat function (in I_RecProcess.h) there is a patch that doesn't let the sum value to go beneath the zero value.

      This can cause to a problem because the sum variable is per net-thread.
      When the increase is done in one net-thread and the decrease is done in another net-thread - the result will be 1 instead of 0.

      First solution:
      remove that patch
      The problem with the First Solution:
      If the TS-1631 fix will be in. When the TS will reset the stats, it can cause to not positive values in the sum. this ca be when the reset is done between an increase and decrease.

      Second solution:
      remove that patch
      add a patch on the global sum (RecProcess.cc) and not for each net-thread
      The problem with the First Solution:
      It is similar to the problem with the first solution. The different is that it won't show not negative values, but it can show lower value than the real one.

      anyone can think on a good solution?

      Attachments

        1. dec_stats_sol_1.diff
          0.7 kB
          Yakov Kopel
        2. dec_stats_sol_2.diff
          1 kB
          Yakov Kopel

        Issue Links

          Activity

            People

              zwoop Leif Hedstrom
              kopely Yakov Kopel
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: