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
Copy file name to clipboardExpand all lines: extensions/data-transfer/portability-data-transfer-apple/src/main/java/org/datatransferproject/datatransfer/apple/AppleTransferExtension.java
Copy file name to clipboardExpand all lines: extensions/data-transfer/portability-data-transfer-apple/src/main/java/org/datatransferproject/datatransfer/apple/constants/ApplePhotosConstants.java
+1Lines changed: 1 addition & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -30,4 +30,5 @@ public class ApplePhotosConstants {
Copy file name to clipboardExpand all lines: extensions/data-transfer/portability-data-transfer-apple/src/main/java/org/datatransferproject/datatransfer/apple/constants/AuditKeys.java
Copy file name to clipboardExpand all lines: extensions/data-transfer/portability-data-transfer-apple/src/main/java/org/datatransferproject/datatransfer/apple/photos/AppleMediaImporter.java
// lower stack retry logic in data copier will not handle the skippable error case, that's why we want to build retry logic in importer itself.
100
+
101
+
// executor can either be a RetryingInMemoryIdempotentImportExecutor or an InMemoryIdempotentImportExecutor
102
+
// RetryingInMemoryIdempotentImportExecutor will return null for skippable error, throw for the others
103
+
// InMemoryIdempotentImportExecutor will throw every error (the callableImporter will throw it as well if we don't throw it here)
104
+
105
+
// if executor is a RetryingInMemoryIdempotentImportExecutor, then it will be different from the idempotentExecutor in the param, which will check for recent errors in lower stack (CallableImporter),
106
+
// So if the error in executor is skippable, we need to clean the errors in idempotentExecutor to make sure they will not be thrown in the lower stack.
if (!errors.isEmpty() && executorinstanceofRetryingInMemoryIdempotentImportExecutor) { // throw the error for retryExecutor to retry, only include the actual error message, but not the stack traces
// if retryingExecutor thinks the errors are skippable, we need to clean the errors in idempotentExecutor to make sure they will not be thrown in the lower stack.
151
+
// (Notice that lower stack CallableImporter does not have skip logic)
Copy file name to clipboardExpand all lines: extensions/data-transfer/portability-data-transfer-apple/src/main/java/org/datatransferproject/datatransfer/apple/photos/AppleMediaInterface.java
+47-51Lines changed: 47 additions & 51 deletions
Original file line number
Diff line number
Diff line change
@@ -192,13 +192,11 @@ public Map<String, String> uploadContent(
192
192
totalSize += data.length;
193
193
194
194
if (totalSize > ApplePhotosConstants.maxMediaTransferByteSize) {
195
-
monitor.severe(
196
-
() -> "file too large to import to Apple: ",
197
-
AuditKeys.dataId, dataId,
198
-
AuditKeys.downloadURL, downloadURL,
199
-
authorizeUploadResponse.getUploadUrl());
200
195
uploadClient.completeUpload();
201
-
thrownewAppleContentException("file too large to import to Apple");
196
+
thrownewAppleContentException(getApplePhotosImportThrowingMessage("file too large to import to Apple", ImmutableMap.of(
0 commit comments