joerghoh commented on code in PR #201:
URL: 
https://github.com/apache/sling-org-apache-sling-resourceresolver/pull/201#discussion_r2309737440


##########
src/main/java/org/apache/sling/resourceresolver/impl/mapping/VanityPathHandler.java:
##########
@@ -746,10 +743,12 @@ private MapEntry createMapEntry(
 
     private Iterator<Resource> queryUnpaged(String query, ResourceResolver 
resolver) {
         log.debug("start vanity path query: {}", query);
-        long queryStart = System.nanoTime();
+        StopWatch sw = StopWatch.createStarted();
         final Iterator<Resource> it = resolver.findResources(query, 
"JCR-SQL2");
-        long queryElapsed = System.nanoTime() - queryStart;
-        log.debug("end vanity path query; elapsed {}ms", 
TimeUnit.NANOSECONDS.toMillis(queryElapsed));
+        log.debug(
+                "end vanity path query; elapsed {} ({}ms)",
+                sw.getDuration(),

Review Comment:
   when I see ```PT20.345S``` I need to google for that format... :-) 
   
   The next question is why the double-logging (both in ISO 8061 and 
miliseconds)? 



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to