magibney commented on code in PR #2591:
URL: https://github.com/apache/solr/pull/2591#discussion_r1691461924


##########
solr/core/src/java/org/apache/solr/handler/RequestHandlerBase.java:
##########
@@ -246,20 +250,24 @@ public void handleRequest(SolrQueryRequest req, 
SolrQueryResponse rsp) {
       processErrorMetricsOnException(normalized, metrics);
       rsp.setException(normalized);
     } finally {
-      long elapsed = timer.stop();
-      metrics.totalTime.inc(elapsed);
-
-      if (publishCpuTime && threadCpuTimer != null) {
-        Optional<Long> cpuTime = threadCpuTimer.getElapsedCpuMs();
-        if (cpuTime.isPresent()) {
-          // add CPU_TIME if not already added by SearchHandler
-          NamedList<Object> header = rsp.getResponseHeader();
-          if (header != null) {
-            if (header.get(ThreadCpuTimer.CPU_TIME) == null) {
-              header.add(ThreadCpuTimer.CPU_TIME, cpuTime.get());
+      try {
+        metrics.concurrency.update(-1);

Review Comment:
   > try-finally paranoia
   
   heh yeah, I guess that's all it is really. Thanks for calling it out, fixed 
in 8d4b0779fc366f06ed96a0f26420458db9126154



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@solr.apache.org
For additional commands, e-mail: issues-h...@solr.apache.org

Reply via email to