Skip to content

Commit f95a471

Browse files
author
u0028003
committed
Hiding warning stack traces except for final fail.
1 parent c1cc984 commit f95a471

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

src/main/java/edu/utah/hci/aws/apps/copy/CopyJobWorker.java

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ public void restore(String bucketName, String key, String region, Tier tier) thr
115115
error = Util.getStackTrace(ase);
116116
//already restore request placed?
117117
if (error.contains("RestoreAlreadyInProgress")) return;
118-
sleep("\tWARNING: failed restoreRequest trying again, "+attempt+"\n"+error);
118+
sleep("\tWARNING: failed restoreRequest trying again, "+attempt);
119119
}
120120
}
121121
//only hits this if all the attempts failed
@@ -132,15 +132,15 @@ public void s3S3Copy(String sourceBucket, String sourceKey, String sourceRegion,
132132
return;
133133
} catch (AmazonServiceException ase) {
134134
error = Util.getStackTrace(ase);
135-
sleep("\tWARNING: failed 'tm.copy(sourceBucket, sourceObjectKey, destBucket, destObjectKey)' trying again, "+attempt+"\n"+error);
135+
sleep("\tWARNING: failed 'tm.copy(sourceBucket, sourceObjectKey, destBucket, destObjectKey)' trying again, "+attempt);
136136
}
137137
catch ( InterruptedException ie) {
138138
error = Util.getStackTrace(ie);
139-
sleep("\tWARNING: failed 'tm.copy(sourceBucket, sourceObjectKey, destBucket, destObjectKey)' trying again, "+attempt+"\n"+error);
139+
sleep("\tWARNING: failed 'tm.copy(sourceBucket, sourceObjectKey, destBucket, destObjectKey)' trying again, "+attempt);
140140
}
141141
catch (SdkClientException sce) {
142142
error = Util.getStackTrace(sce);
143-
sleep("\tWARNING: failed 'tm.copy(sourceBucket, sourceObjectKey, destBucket, destObjectKey)' trying again, "+attempt+"\n"+error);
143+
sleep("\tWARNING: failed 'tm.copy(sourceBucket, sourceObjectKey, destBucket, destObjectKey)' trying again, "+attempt);
144144
};
145145
}
146146
//only hits this if all the attempts failed
@@ -159,15 +159,15 @@ public void tryDownload(String bucketName, String key, String region, File desti
159159
return;
160160
} catch (AmazonServiceException ase) {
161161
error = Util.getStackTrace(ase);
162-
sleep("\tWARNING: failed 'tm.download(bucketName, key)' trying again, "+attempt+"\n"+error);
162+
sleep("\tWARNING: failed 'tm.download(bucketName, key)' trying again, "+attempt);
163163
}
164164
catch ( InterruptedException ie) {
165165
error = Util.getStackTrace(ie);
166-
sleep("\tWARNING: failed 'tm.download(bucketName, key)' trying again, "+attempt+"\n"+error);
166+
sleep("\tWARNING: failed 'tm.download(bucketName, key)' trying again, "+attempt);
167167
}
168168
catch (SdkClientException sce) {
169169
error = Util.getStackTrace(sce);
170-
sleep("\tWARNING: failed 'tm.download(bucketName, key)' trying again, "+attempt+"\n"+error);
170+
sleep("\tWARNING: failed 'tm.download(bucketName, key)' trying again, "+attempt);
171171
};
172172
}
173173
//only hits this if all the attempts failed

src/main/java/edu/utah/hci/aws/apps/copy/S3Copy.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -532,7 +532,7 @@ public static void printDiffAccountInstructions() {
532532
public void printDocs(){
533533
pl("\n" +
534534
"**************************************************************************************\n" +
535-
"** S3 Copy : Feb 2024 **\n" +
535+
"** S3 Copy : April 2024 **\n" +
536536
"**************************************************************************************\n" +
537537
"SC copies AWS S3 objects, unarchiving them as needed, within the same or different\n"+
538538
"accounts or downloads them to your local computer. Run this as a daemon with -l or run\n"+

0 commit comments

Comments
 (0)