File tree Expand file tree Collapse file tree 1 file changed +7
-1
lines changed
platform-api/src/main/java/com/flow/platform/api/controller Expand file tree Collapse file tree 1 file changed +7
-1
lines changed Original file line number Diff line number Diff line change 2525import com .flow .platform .api .service .job .JobSearchService ;
2626import com .flow .platform .api .service .node .YmlService ;
2727import com .flow .platform .api .util .I18nUtil ;
28+ import com .flow .platform .core .exception .NotFoundException ;
2829import com .flow .platform .util .Logger ;
2930import com .flow .platform .util .StringUtil ;
3031import com .flow .platform .util .git .model .GitEventType ;
@@ -174,7 +175,12 @@ public Job show(@PathVariable Integer buildNumber) {
174175 @ GetMapping (path = "/{root}/{buildNumber}/yml" )
175176 public String yml (@ PathVariable Integer buildNumber ) {
176177 String path = currentNodePath .get ();
177- return jobService .findYml (path , buildNumber );
178+ try {
179+ return jobService .findYml (path , buildNumber );
180+ } catch (NotFoundException ignore ) {
181+ // ignore job node not found exception since maybe job node created when yml loading
182+ return StringUtil .EMPTY ;
183+ }
178184 }
179185
180186 /**
You can’t perform that action at this time.
0 commit comments