wimsymons commented on a change in pull request #24:
URL: 
https://github.com/apache/sling-org-apache-sling-resourceresolver/pull/24#discussion_r524153454



##########
File path: 
src/main/java/org/apache/sling/resourceresolver/impl/ResourceResolverFactoryActivator.java
##########
@@ -128,6 +129,9 @@
 
     private volatile ResourceResolverFactoryConfig config = DEFAULT_CONFIG;
 
+    /** Alias path whitelist */
+    private AtomicReferenceArray<String> aliasPathAllowList;

Review comment:
       I'd suggest to drop the volatile keyword, just use CopyOnWriteArrayList 
and initialize it here. Let the rest of the code never set it to another value. 
Just use add/remove/clear. Thread-safe, readable and no Sonar issues.




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

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


Reply via email to