worlkoad templates parsing bug fix

This commit is contained in:
phact 2020-03-23 17:16:31 -04:00
parent 3d95bf38ab
commit 93a1ecbf41
2 changed files with 3 additions and 2 deletions

View File

@ -37,8 +37,8 @@ import java.util.stream.Collectors;
public class NosqlBenchFiles {
private final static Logger logger = LoggerFactory.getLogger(NosqlBenchFiles.class);
private static Pattern templatePattern = Pattern.compile("TEMPLATE\\((.+)\\)");
private static Pattern templatePattern2 = Pattern.compile("<<(.+)>>");
private static Pattern templatePattern = Pattern.compile("TEMPLATE\\((.+?)\\)");
private static Pattern templatePattern2 = Pattern.compile("<<(.+?)>>");
public static InputStream findRequiredStreamOrFile(String basename, String extension, String... searchPaths) {

View File

@ -237,6 +237,7 @@ public class NBCLI {
System.out.println("# with the following optional parameters and defaults: ");
templates.stream()
.map(x -> x.replaceAll(",","="))
.map(x -> x.replaceAll(":","="))
.map(x -> " # "+x)
.forEach(System.out::println);
}