Skip to content

Commit 635bafa

Browse files
authored
[CYB-217] Fix NullPointerException when running on yarn cluster (#91)
1 parent 77f4b83 commit 635bafa

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

flink-cyber/metron-parser-chain/parser-chains-core/src/main/java/com/cloudera/parserchains/core/DefaultChainBuilder.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,9 @@ private ChainLink doBuild(ParserChainSchema chainSchema) throws InvalidParserExc
4848
for(ParserSchema parserSchema: chainSchema.getParsers()) {
4949
ChainLink next;
5050
boolean isRouter = ParserID.router().equals(parserSchema.getId());
51-
parserSchema.setBasePath(Paths.get(chainSchema.getBasePath(), "..").toString());
51+
if (chainSchema.getBasePath() != null) {
52+
parserSchema.setBasePath(Paths.get(chainSchema.getBasePath(), "..").toString());
53+
}
5254
if(isRouter) {
5355
next = buildRouter(parserSchema);
5456
} else {

0 commit comments

Comments
 (0)