mirror of
https://github.com/etcd-io/etcd.git
synced 2024-09-27 06:25:44 +00:00

Using Go-style import paths in protos is not idiomatic. Normally, this detail would be internal to etcd, but the path from which gogoproto is imported affects downstream consumers (e.g. cockroachdb). In cockroach, we want to avoid including `$GOPATH/src` in our protoc include path for various reasons. This patch puts etcd on the same convention, which allows this for cockroach. More information: https://github.com/cockroachdb/cockroach/pull/2339#discussion_r38663417 This commit also regenerates all the protos, which seem to have drifted a tiny bit.
21 lines
539 B
Protocol Buffer
21 lines
539 B
Protocol Buffer
syntax = "proto2";
|
|
package walpb;
|
|
|
|
import "gogoproto/gogo.proto";
|
|
|
|
option (gogoproto.marshaler_all) = true;
|
|
option (gogoproto.sizer_all) = true;
|
|
option (gogoproto.unmarshaler_all) = true;
|
|
option (gogoproto.goproto_getters_all) = false;
|
|
|
|
message Record {
|
|
optional int64 type = 1 [(gogoproto.nullable) = false];
|
|
optional uint32 crc = 2 [(gogoproto.nullable) = false];
|
|
optional bytes data = 3;
|
|
}
|
|
|
|
message Snapshot {
|
|
optional uint64 index = 1 [(gogoproto.nullable) = false];
|
|
optional uint64 term = 2 [(gogoproto.nullable) = false];
|
|
}
|