Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ public class CFMLEngineFactory {
// set to false to disable patch loading, for example in major alpha releases
private static final boolean PATCH_ENABLED = true;

private static boolean loadRailoFromClassPath = false;
private static CFMLEngineFactory factory;
private static File railoServerRoot;
private static CFMLEngineWrapper engineListener;
Expand Down Expand Up @@ -171,6 +172,12 @@ else if(root.canWrite()) {
}
}
catch(IOException ioe){}
// if this is true, the railo patch file should be renamed to a jar file and placed on the classpath in order for it to work.
String loadRailoFromClasspathProperty = config.getInitParameter("railo-load-from-classpath");
if ( !Util.isEmpty( loadRailoFromClasspathProperty ) ) {
loadRailoFromClassPath = loadRailoFromClasspathProperty.toLowerCase().equals("true");
}

}


Expand Down Expand Up @@ -198,6 +205,19 @@ private CFMLEngine getEngine() throws ServletException {
}

private void initEngine() throws ServletException {

if ( loadRailoFromClassPath ) {
try {
engine = getEngine( mainClassLoader );
} catch (Exception e) {
e.printStackTrace();
}
} else {
_initPatchEngine();
}
}

private void _initPatchEngine() throws ServletException {

int coreVersion=Version.getIntVersion();
long coreCreated=Version.getCreateTime();
Expand Down