Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F3375941
D8698.id29484.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1014 B
Referenced Files
None
Subscribers
None
D8698.id29484.diff
View Options
diff --git a/keyserver/src/push/send.js b/keyserver/src/push/send.js
--- a/keyserver/src/push/send.js
+++ b/keyserver/src/push/send.js
@@ -747,6 +747,34 @@
);
}
+ const canQueryBlobService =
+ platformDetails.codeVersion &&
+ platformDetails.codeVersion >= FUTURE_CODE_VERSION;
+
+ let blobHash, encryptionKey, blobUploadError;
+ if (canQueryBlobService) {
+ ({
+ blobHash: blobHash,
+ encryptionKey: encryptionKey,
+ blobUploadError: blobUploadError,
+ } = await blobServiceUpload(copyWithMessageInfos.compile()));
+ }
+
+ if (blobUploadError) {
+ console.warn(
+ `Failed to upload payload of notification: ${uniqueID} ` +
+ `due to error: ${blobUploadError}`,
+ );
+ }
+
+ if (blobHash && encryptionKey) {
+ notification.payload = {
+ blobHash,
+ encryptionKey,
+ ...notification.payload,
+ };
+ }
+
const notifsWithoutMessageInfos = await prepareEncryptedIOSNotifications(
devicesWithExcessiveSize,
notification,
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Wed, Nov 27, 9:31 PM (22 h, 6 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
2591731
Default Alt Text
D8698.id29484.diff (1014 B)
Attached To
Mode
D8698: Upload iOS notification payload to blob service if its size exceeds limits
Attached
Detach File
Event Timeline
Log In to Comment