enapps-enorman commented on a change in pull request #24:
URL: 
https://github.com/apache/sling-org-apache-sling-feature-launcher/pull/24#discussion_r612720295



##########
File path: src/main/java/org/apache/sling/feature/launcher/impl/Main.java
##########
@@ -264,20 +270,23 @@ protected static void parseArgs(final LauncherConfig 
config, final String[] args
                 config.getConfigClashOverrides().put(name, 
cfgCProps.getProperty(name));
             }
 
-            Properties fwProps = 
cl.getOptionProperties(OPT_FRAMEWORK_PROPERTIES);
-            for (final String name : fwProps.stringPropertyNames()) {
-                config.getInstallation()
-                        .getFrameworkProperties()
-                        .put(name, fwProps.getProperty(name));
-            }
+            extractValuesFromOption(cl, 
OPT_FRAMEWORK_PROPERTIES).orElseGet(ArrayList::new)
+                    .forEach(value -> {
+                        final String[] keyVal = split(value);
+                        
config.getInstallation().getFrameworkProperties().put(keyVal[0], keyVal[1]);
+                    });
 
             Properties varProps = cl.getOptionProperties(OPT_VARIABLE_VALUES);
             for (final String name : varProps.stringPropertyNames()) {
                 config.getVariables().put(name, varProps.getProperty(name));
             }
 
-            extractValueFromOption(cl, OPT_VERBOSE, "debug").ifPresent(
-                    value -> 
System.setProperty("org.slf4j.simpleLogger.defaultLogLevel", value));
+            if (cl.hasOption(OPT_VERBOSE)) {
+                extractValueFromOption(cl, OPT_VERBOSE, 
"debug").ifPresent(value -> System

Review comment:
       This should validate that the supplied verbose option is a valid log 
level.  It must be one of ("trace", "debug", "info", "warn", "error" or "off"). 
 Any other value should report an error.




-- 
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:
us...@infra.apache.org


Reply via email to