Skip to content

Commit

Permalink
feat: split sid into two fields, use map for vector clock
Browse files Browse the repository at this point in the history
  • Loading branch information
richardhuaaa committed Sep 10, 2024
1 parent bdb0e67 commit db28f6d
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions proto/xmtpv4/message_api/message_api.proto
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ option go_package = "github.com/xmtp/proto/v3/go/xmtpv4/message_api";
// The last seen entry per originator. Originators that have not been seen are omitted.
// Entries MUST be sorted in ascending order, so that smaller node ID's appear first.
message VectorClock {
repeated uint64 originator_sids = 1;
map<uint32, uint64> node_id_to_sequence_id = 1;
}

// Data visible to the server that has been authenticated by the client.
Expand Down Expand Up @@ -42,15 +42,16 @@ message PayerEnvelope {
// For blockchain envelopes, the originator_sid is set by the smart contract,
// but the originator_ns is set by the publishing node
message UnsignedOriginatorEnvelope {
uint64 originator_sid = 1;
int64 originator_ns = 2;
PayerEnvelope payer_envelope = 3;
uint32 originator_node_id = 1;
uint64 originator_sequence_id = 2;
int64 originator_ns = 3;
PayerEnvelope payer_envelope = 4;
}

// An alternative to a signature for blockchain payloads
message BlockchainProof {
uint64 block_number = 1;
uint32 publisher_id = 2;
uint32 publisher_node_id = 2;
}

// Signed originator envelope
Expand Down

0 comments on commit db28f6d

Please sign in to comment.