Skip to content

Commit

Permalink
Needed a trim() in JVM options parsing in case no options were given.
Browse files Browse the repository at this point in the history
  • Loading branch information
khituras committed Oct 22, 2020
1 parent 5af5d89 commit 73aed1c
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ public void runPipeline(JCoReUIMAPipeline pipeline, HierarchicalConfiguration<Im
final String plp = pipeline.getLoadDirectory().getAbsolutePath();
int numThreads = runnerConfig.containsKey(NUMTHREADS) ? runnerConfig.getInt(NUMTHREADS) : 2;
String memory = runnerConfig.containsKey(HEAP_SIZE) ? runnerConfig.getString(HEAP_SIZE) : "2G";
String[] jvmOptions = ((runnerConfig.containsKey(JVM_OPTS) ? runnerConfig.getString(JVM_OPTS) : "") + " -Xmx"+memory).split("\\s+") ;
String[] jvmOptions = ((runnerConfig.containsKey(JVM_OPTS) ? runnerConfig.getString(JVM_OPTS) : "") + " -Xmx"+memory).trim().split("\\s+") ;
final File cpeRunnerJar = findCpeRunnerJar();
Stream<File> classpathElements = pipeline.getClasspathElements();
classpathElements = Stream.concat(classpathElements, Stream.of(cpeRunnerJar, new File(plp + File.separator + JCoReUIMAPipeline.DIR_CONF), new File(plp + File.separator + "resources")));
Expand Down

0 comments on commit 73aed1c

Please sign in to comment.