diff options
author | Robert Hensing <roberth@users.noreply.github.com> | 2023-10-20 15:34:26 +0200 |
---|---|---|
committer | eldritch horrors <pennae@lix.systems> | 2024-03-04 04:43:35 +0100 |
commit | ab40b2c5d0f90d6a119bf4b368f933f5331b0c15 (patch) | |
tree | 305c600d732546077701abefc9dddecdd2eadf0f /src/libstore/worker-protocol.hh | |
parent | 5ddd1a916667ec0d969f99a0a85a2092bf18b632 (diff) |
Merge pull request #9157 from obsidiansystems/protocol-versions
Add protocol versions to `{Worker,Serve}Proto::*Conn`
(cherry picked from commit 4d17c59d8d059a5b39f1d1da2b58f2ec8da44861)
Change-Id: I497af39deb792e50c157a1305d8c9e722798740b
Diffstat (limited to 'src/libstore/worker-protocol.hh')
-rw-r--r-- | src/libstore/worker-protocol.hh | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/src/libstore/worker-protocol.hh b/src/libstore/worker-protocol.hh index c84060103..2d55d926a 100644 --- a/src/libstore/worker-protocol.hh +++ b/src/libstore/worker-protocol.hh @@ -48,25 +48,28 @@ struct WorkerProto enum struct Op : uint64_t; /** + * Version type for the protocol. + * + * @todo Convert to struct with separate major vs minor fields. + */ + using Version = unsigned int; + + /** * A unidirectional read connection, to be used by the read half of the * canonical serializers below. - * - * This currently is just a `Source &`, but more fields will be added - * later. */ struct ReadConn { Source & from; + Version version; }; /** * A unidirectional write connection, to be used by the write half of the * canonical serializers below. - * - * This currently is just a `Sink &`, but more fields will be added - * later. */ struct WriteConn { Sink & to; + Version version; }; /** |