File tree Expand file tree Collapse file tree
wayang-commons/wayang-core/src/main/java/org/apache/wayang/core/api Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -308,13 +308,17 @@ protected void doExecute() {
308308 if (this .configuration .getBooleanProperty ("wayang.core.explain.enabled" )) {
309309 long unixTime = System .currentTimeMillis () / 1000L ;
310310
311+ String sanitized = ("job-" + this .name + "-" + unixTime )
312+ .replaceAll ("\\ s+" , "_" )
313+ .replaceAll ("[^a-zA-Z0-9._-]" , "" );
314+
311315 ExplainUtils .write (
312316 ExplainUtils .parsePlan (this .wayangPlan , true ),
313- this .configuration .getStringProperty ("wayang.core.explain.directory" ) + "job-" + this . name + "-" + unixTime + "-logical.json"
317+ this .configuration .getStringProperty ("wayang.core.explain.directory" ) + sanitized + "-logical.json"
314318 );
315319 ExplainUtils .write (
316320 ExplainUtils .parsePlan (executionPlan , true ),
317- this .configuration .getStringProperty ("wayang.core.explain.directory" ) + "job-" + this . name + "-" + unixTime + "-execution.json"
321+ this .configuration .getStringProperty ("wayang.core.explain.directory" ) + sanitized + "-execution.json"
318322 );
319323 }
320324
You can’t perform that action at this time.
0 commit comments