瀏覽代碼

corrected minor error in calculating the statistics

thomas 4 年之前
父節點
當前提交
1b29a6686a
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      src/ua-stress-test/main.cpp

+ 1 - 1
src/ua-stress-test/main.cpp

@@ -97,7 +97,7 @@ void workerThread()
     cout << "\tRequests sent: " << reqId << endl;
     cout << "\tResponses received: " << d.numberOfResponesReceived << endl;
     cout << "\tRuntime(ms): " << (std::chrono::duration_cast<std::chrono::milliseconds>(endTime-startTime)).count() << endl;
-    cout << "\tRequests sent per s: " << ((double)reqId) / (std::chrono::duration_cast<std::chrono::seconds>(endTime-startTime)).count() << endl;
+    cout << "\tRequests sent per s: " << ((double)reqId) / (std::chrono::duration_cast<std::chrono::milliseconds>(endTime-startTime)).count() * 1000.0 << endl;
 }
 
 int main(int argc, char **argv) {