Skip to content

Commit 26976d6

Browse files
adding some logs
1 parent d98700d commit 26976d6

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/main/java/com/cloudbees/jenkins/support/SupportAction.java

+4-4
Original file line numberDiff line numberDiff line change
@@ -527,6 +527,7 @@ public SupportBundleAsyncGenerator init(UUID taskId, List<Component> components)
527527
@Override
528528
protected void compute() throws Exception {
529529
if (supportBundleGenerationInProgress) {
530+
logger.fine("Support bundle generation already in progress, for task id " + taskId);
530531
return;
531532
}
532533
this.supportBundleName = BundleFileName.generate();
@@ -539,8 +540,7 @@ protected void compute() throws Exception {
539540
}
540541
}
541542

542-
try (FileOutputStream fileOutputStream =
543-
new FileOutputStream(new File(outputDir, supportBundleName))) {
543+
try (FileOutputStream fileOutputStream = new FileOutputStream(new File(outputDir, supportBundleName))) {
544544
SupportPlugin.setRequesterAuthentication(Jenkins.getAuthentication2());
545545
try {
546546
try (ACLContext ignored = ACL.as2(ACL.SYSTEM2)) {
@@ -558,7 +558,6 @@ protected void compute() throws Exception {
558558
pathToBundle = outputDir.getAbsolutePath() + "/" + supportBundleName;
559559
isCompleted = true;
560560
progress(1);
561-
562561
}
563562

564563
@NonNull
@@ -577,7 +576,8 @@ public String getSupportBundleName() {
577576
}
578577

579578
public void doDownloadBundle(@QueryParameter("taskId") String taskId, StaplerResponse2 rsp) throws IOException {
580-
String supportBundleName = generatorByTaskId.get(UUID.fromString(taskId)).getSupportBundleName();
579+
String supportBundleName =
580+
generatorByTaskId.get(UUID.fromString(taskId)).getSupportBundleName();
581581
File bundleFile = new File(SUPPORT_BUNDLE_CREATION_FOLDER + "/" + taskId + "/" + supportBundleName);
582582
if (!bundleFile.exists()) {
583583
rsp.sendError(HttpServletResponse.SC_NOT_FOUND, "Support bundle file not found");

0 commit comments

Comments
 (0)