From 641b9dcd72a5fcead241a33fc5f9963e352501c9 Mon Sep 17 00:00:00 2001 From: Brad Wood Date: Mon, 2 May 2022 20:21:20 -0500 Subject: [PATCH] COMMANDBOX-1460 --- src/java/cliloader/LoaderCLIMain.java | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/java/cliloader/LoaderCLIMain.java b/src/java/cliloader/LoaderCLIMain.java index 3e595678..a530d1d5 100644 --- a/src/java/cliloader/LoaderCLIMain.java +++ b/src/java/cliloader/LoaderCLIMain.java @@ -713,6 +713,8 @@ public static ArrayList< String > initialize( String[] arguments ) throws IOExce File libDir = getLibDir(); // Default Log4j2 config is in the libn folder System.setProperty("log4j2.configurationFile", new File( libDir, "log4j2.xml" ).toURI().toString() ); + // The OSGI bundle loader is throwing an error so we need to force the default CL context selector + System.setProperty("Log4jContextSelector", "org.apache.logging.log4j.core.selector.ClassLoaderContextSelector" ); props.setProperty( "cfml.cli.lib", libDir.getAbsolutePath() ); File cfmlDir = new File( cli_home.getPath() + "/cfml" ); File cfmlSystemDir = new File( cli_home.getPath() + "/cfml/system" );