Uploaded image for project: 'Hadoop Common'
  1. Hadoop Common
  2. HADOOP-15768

Do not use Time#now to calculate the rpc process time duration

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Open
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: 3.1.1
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None
    • Target Version/s:

      Description

      For the rpc process time calculation, we are using a not-recommended way: Using Time#now to calculate for this.

              // Invoke the protocol method
              long startTime = Time.now();
              int qTime = (int) (startTime-receivedTime);
      ....
                int processingTime = (int) (Time.now() - startTime);
      ...
      server.updateMetrics(detailedMetricsName, qTime, processingTime, false);
      

       

      Actually we should use Time#monotonicNow() instead. This JIRA will fix these across RpcEngine impl classes.

        Attachments

          Activity

            People

            • Assignee:
              jianliang.wu Ryan Wu
              Reporter:
              linyiqun Yiqun Lin
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated: