You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Fix AWS Glacier/Deep Archive loading of restored objects (#759)
* Naive headObject method wrapper for GLACIER_ARCHIVE restore. Observed header combinations while debugging do not seem to align docs, more investigation is needed.
* The AWS SDK Java v2 HeadObject.restore() is not reliable as of version 2.8.5, see aws/aws-sdk-java-v2#670 (comment)
* Other than fixing the Glacier/Archive tier error handling, also implemented support for File->Load From URL if the user knows the S3 URL, they can paste it there directly. Also aws-java-sdk-v2 version bump from Maven
* This field gets populated on newer versions of the aws-java-sdk-v2, fortunately
* Apply suggestions/code review from @reisingerf. Rollback aws-sdk version bump since it affects error messaging and "germane-ity" of this PR. Killing Triple/Tuple in next commit.
// Determine in which state this object really is:
253
+
// 1. Archived.
254
+
// 2. In the process of being restored.
255
+
// 3. Restored
256
+
//
257
+
// This is important because after restoration the object mantains the Tier (DEEP_ARCHIVE) instead of
258
+
// transitioning that attribute to STANDARD, we must look at head_object response for the "Restore"
259
+
// attribute.
260
+
//
261
+
// Possible error reason messages for the users are:
262
+
263
+
Stringarchived = "Amazon S3 object is in " + s3ObjectStorageClass + " storage tier, not accessible at this moment. " +
264
+
"Please contact your local system administrator about object: s3://" + bucket + "/" + key;
265
+
StringrestoreInProgress = "Amazon S3 object is in " + s3ObjectStorageClass + " and being restored right now, please be patient, this can take up to 48h. " +
266
+
"For further enquiries about this dataset, please use the following path when communicating with your system administrator: s3://" + bucket + "/" + key;
267
+
268
+
if (s3ObjectStorageClass.contains("DEEP_ARCHIVE") ||
0 commit comments