You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@logging.apache.org by GitBox <gi...@apache.org> on 2022/02/08 12:06:14 UTC

[GitHub] [logging-log4j2] Kay-kay2019 commented on a change in pull request #742: LOG4J2-3366 Fixes order of property sources

Kay-kay2019 commented on a change in pull request #742:
URL: https://github.com/apache/logging-log4j2/pull/742#discussion_r801560830



##########
File path: log4j-api/src/main/java/org/apache/logging/log4j/util/PropertiesUtil.java
##########
@@ -435,17 +452,18 @@ private Environment(final PropertySource propertySource) {
                 // Access to System Properties is restricted so just skip it.
             }
             sources.add(propertySource);
-			for (final ClassLoader classLoader : LoaderUtil.getClassLoaders()) {
-				try {
-					for (final PropertySource source : ServiceLoader.load(PropertySource.class, classLoader)) {
-						sources.add(source);
-					}
-				} catch (final Throwable ex) {
-					/* Don't log anything to the console. It may not be a problem that a PropertySource
-					 * isn't accessible.
-					 */
-				}
-			}
+            for (final ClassLoader classLoader : LoaderUtil.getClassLoaders()) {

Review comment:
       Okay, thank you so much. 




-- 
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: notifications-unsubscribe@logging.apache.org

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