Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F32322904
D7720.1765301739.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D7720.1765301739.diff
View Options
diff --git a/services/tunnelbroker/src/constants.rs b/services/tunnelbroker/src/constants.rs
--- a/services/tunnelbroker/src/constants.rs
+++ b/services/tunnelbroker/src/constants.rs
@@ -7,3 +7,22 @@
pub const LOG_LEVEL_ENV_VAR: &str =
tracing_subscriber::filter::EnvFilter::DEFAULT_ENV;
+
+pub mod dynamodb {
+ // This table holds messages which could not be immediately delivered to
+ // a device.
+ //
+ // - (primary key) = (deviceID: Partition Key, createdAt: Sort Key)
+ // - deviceID: The public key of a device's olm identity key
+ // - payload: Message to be delivered. See shared/tunnelbroker_messages.
+ // - createdAt: UNIX timestamp of when the item was inserted.
+ // Timestamp is needed to order the messages correctly to the device.
+ pub mod undelivered_messages {
+ pub const TABLE_NAME: &str = "tunnelbroker-undelivered-messages";
+ pub const PARTITION_KEY: &str = "deviceID";
+ pub const DEVICE_ID: &str = "deviceID";
+ pub const PAYLOAD: &str = "payload";
+ pub const CREATED_AT: &str = "createdAt";
+ pub const SORT_KEY: &str = "createdAt";
+ }
+}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Tue, Dec 9, 5:35 PM (3 h, 36 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
5856244
Default Alt Text
D7720.1765301739.diff (1 KB)
Attached To
Mode
D7720: [Tunnelbroker] Define undelivered-messages table in rust
Attached
Detach File
Event Timeline
Log In to Comment