mirror of
https://github.com/octoleo/syncthing.git
synced 2024-11-19 19:45:12 +00:00
0296c23685
This makes the device ID a real type that can be used in the protobuf schema. That avoids the juggling back and forth from []byte in a bunch of places and simplifies the code. GitHub-Pull-Request: https://github.com/syncthing/syncthing/pull/3695
16 lines
540 B
Protocol Buffer
16 lines
540 B
Protocol Buffer
syntax = "proto3";
|
|
|
|
package discover;
|
|
|
|
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
|
|
|
|
option (gogoproto.goproto_getters_all) = false;
|
|
option (gogoproto.sizer_all) = false;
|
|
option (gogoproto.protosizer_all) = true;
|
|
|
|
message Announce {
|
|
bytes id = 1 [(gogoproto.customname) = "ID", (gogoproto.customtype) = "github.com/syncthing/syncthing/lib/protocol.DeviceID", (gogoproto.nullable) = false];
|
|
repeated string addresses = 2;
|
|
int64 instance_id = 3 [(gogoproto.customname) = "InstanceID"];
|
|
}
|