josh-mckenzie commented on code in PR #1488:
URL: https://github.com/apache/cassandra/pull/1488#discussion_r1084484487


##########
src/java/org/apache/cassandra/io/util/PathUtils.java:
##########
@@ -64,14 +64,16 @@
     private static final Set<StandardOpenOption> READ_WRITE_OPTIONS = 
unmodifiableSet(EnumSet.of(READ, WRITE, CREATE));
     private static final FileAttribute<?>[] NO_ATTRIBUTES = new 
FileAttribute[0];
 
+    private static final boolean USE_NIX_RECURSIVE_DELETE = 
CassandraRelevantProperties.USE_NIX_RECURSIVE_DELETE.getBoolean();
+
     private static final Logger logger = 
LoggerFactory.getLogger(PathUtils.class);
     private static final NoSpamLogger nospam1m = 
NoSpamLogger.getLogger(logger, 1, TimeUnit.MINUTES);
 
     private static Consumer<Path> onDeletion = path -> {
         if (StorageService.instance.isDaemonSetupCompleted())
             setDeletionListener(ignore -> {});
-        else
-            logger.info("Deleting file during startup: {}", path);
+        else if (logger.isTraceEnabled())

Review Comment:
   Really good point, and it'd split the idiom if we had "string interpolation 
goes this route, non goes that route". I've spent too much time working in C# 
w/Conditional runtime method attributes. :)
   
   Could _probably_ rely on hotspot to realize don't have tracing enabled and 
optimize that path away but not worth the UX / idiom split IMO.



-- 
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]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to