Skip to content

Commit

Permalink
Merge pull request #6032 from TheThingsNetwork/feature/2798-remove-go…
Browse files Browse the repository at this point in the history
…goproto

Move to Go protobuf API v2
  • Loading branch information
adriansmares authored Jan 25, 2023
2 parents 0b840a6 + 6937d12 commit ce55365
Show file tree
Hide file tree
Showing 576 changed files with 79,586 additions and 48,361 deletions.
5 changes: 0 additions & 5 deletions api/_api.proto
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,9 @@

syntax = "proto3";

import "github.com/gogo/protobuf/gogoproto/gogo.proto";

// Package documentation should be added in the comment block below:

// The Things Stack for LoRaWAN v3 API
package ttn.lorawan.v3;

option go_package = "go.thethings.network/lorawan-stack/v3/pkg/ttnpb";

// TODO: Migrate away from GoGo Protobuf (https://github.com/TheThingsNetwork/lorawan-stack/issues/2798).
option (gogoproto.goproto_registration) = true;
1 change: 1 addition & 0 deletions api/api.swagger.json
Original file line number Diff line number Diff line change
Expand Up @@ -6342,6 +6342,7 @@
"parameters": [
{
"name": "body",
"description": "EntityIdentifiers contains one of the possible entity identifiers.",
"in": "body",
"required": true,
"schema": {
Expand Down
4 changes: 0 additions & 4 deletions api/application.proto
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
syntax = "proto3";

import "github.com/envoyproxy/protoc-gen-validate/validate/validate.proto";
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
import "github.com/TheThingsIndustries/protoc-gen-go-json/annotations.proto";
import "github.com/TheThingsIndustries/protoc-gen-go-flags/annotations.proto";
import "google/protobuf/field_mask.proto";
Expand All @@ -29,9 +28,6 @@ package ttn.lorawan.v3;

option go_package = "go.thethings.network/lorawan-stack/v3/pkg/ttnpb";

// TODO: Migrate away from GoGo Protobuf (https://github.com/TheThingsNetwork/lorawan-stack/issues/2798).
option (gogoproto.goproto_registration) = true;

// Application is the message that defines an Application in the network.
message Application {
option (thethings.flags.message) = { select: true, set: true };
Expand Down
4 changes: 0 additions & 4 deletions api/application_services.proto
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@

syntax = "proto3";

import "github.com/gogo/protobuf/gogoproto/gogo.proto";
import "google/api/annotations.proto";
import "google/protobuf/empty.proto";
import "lorawan-stack/api/application.proto";
Expand All @@ -25,9 +24,6 @@ package ttn.lorawan.v3;

option go_package = "go.thethings.network/lorawan-stack/v3/pkg/ttnpb";

// TODO: Migrate away from GoGo Protobuf (https://github.com/TheThingsNetwork/lorawan-stack/issues/2798).
option (gogoproto.goproto_registration) = true;

// The ApplicationRegistry service, exposed by the Identity Server, is used to manage
// application registrations.
service ApplicationRegistry {
Expand Down
4 changes: 0 additions & 4 deletions api/applicationserver.proto
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
syntax = "proto3";

import "github.com/envoyproxy/protoc-gen-validate/validate/validate.proto";
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
import "github.com/TheThingsIndustries/protoc-gen-go-flags/annotations.proto";
import "github.com/TheThingsIndustries/protoc-gen-go-json/annotations.proto";
import "google/api/annotations.proto";
Expand All @@ -33,9 +32,6 @@ package ttn.lorawan.v3;

option go_package = "go.thethings.network/lorawan-stack/v3/pkg/ttnpb";

// TODO: Migrate away from GoGo Protobuf (https://github.com/TheThingsNetwork/lorawan-stack/issues/2798).
option (gogoproto.goproto_registration) = true;

message ApplicationLink {
option (thethings.flags.message) = { select: true, set: true };
reserved 1; // Deprecated: network_server_address
Expand Down
4 changes: 0 additions & 4 deletions api/applicationserver_integrations_storage.proto
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
syntax = "proto3";

import "github.com/envoyproxy/protoc-gen-validate/validate/validate.proto";
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
import "google/api/annotations.proto";
import "google/protobuf/field_mask.proto";
import "google/protobuf/timestamp.proto";
Expand All @@ -28,9 +27,6 @@ package ttn.lorawan.v3;

option go_package = "go.thethings.network/lorawan-stack/v3/pkg/ttnpb";

// TODO: Migrate away from GoGo Protobuf (https://github.com/TheThingsNetwork/lorawan-stack/issues/2798).
option (gogoproto.goproto_registration) = true;

message GetStoredApplicationUpRequest {
// Query upstream messages from all end devices of an application. Cannot be used in conjunction with end_device_ids.
ApplicationIdentifiers application_ids = 1;
Expand Down
4 changes: 0 additions & 4 deletions api/applicationserver_packages.proto
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ syntax = "proto3";

import "github.com/TheThingsIndustries/protoc-gen-go-flags/annotations.proto";
import "github.com/envoyproxy/protoc-gen-validate/validate/validate.proto";
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
import "google/api/annotations.proto";
import "google/protobuf/empty.proto";
import "google/protobuf/field_mask.proto";
Expand All @@ -28,9 +27,6 @@ package ttn.lorawan.v3;

option go_package = "go.thethings.network/lorawan-stack/v3/pkg/ttnpb";

// TODO: Migrate away from GoGo Protobuf (https://github.com/TheThingsNetwork/lorawan-stack/issues/2798).
option (gogoproto.goproto_registration) = true;

message ApplicationPackage {
string name = 1 [(validate.rules).string = {pattern: "^[a-z0-9](?:[-]?[a-z0-9]){2,}$" , max_len: 36}];
uint32 default_f_port = 2 [(validate.rules).uint32 = {gte: 1, lte: 255}];
Expand Down
4 changes: 0 additions & 4 deletions api/applicationserver_pubsub.proto
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ syntax = "proto3";

import "github.com/TheThingsIndustries/protoc-gen-go-flags/annotations.proto";
import "github.com/envoyproxy/protoc-gen-validate/validate/validate.proto";
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
import "github.com/TheThingsIndustries/protoc-gen-go-json/annotations.proto";
import "google/api/annotations.proto";
import "google/protobuf/duration.proto";
Expand All @@ -29,9 +28,6 @@ package ttn.lorawan.v3;

option go_package = "go.thethings.network/lorawan-stack/v3/pkg/ttnpb";

// TODO: Migrate away from GoGo Protobuf (https://github.com/TheThingsNetwork/lorawan-stack/issues/2798).
option (gogoproto.goproto_registration) = true;

message ApplicationPubSubIdentifiers {
option (thethings.flags.message) = { select: false, set: true };
ApplicationIdentifiers application_ids = 1 [(validate.rules).message.required = true];
Expand Down
4 changes: 0 additions & 4 deletions api/applicationserver_web.proto
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ syntax = "proto3";

import "github.com/TheThingsIndustries/protoc-gen-go-flags/annotations.proto";
import "github.com/envoyproxy/protoc-gen-validate/validate/validate.proto";
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
import "google/api/annotations.proto";
import "google/protobuf/empty.proto";
import "google/protobuf/field_mask.proto";
Expand All @@ -28,9 +27,6 @@ package ttn.lorawan.v3;

option go_package = "go.thethings.network/lorawan-stack/v3/pkg/ttnpb";

// TODO: Migrate away from GoGo Protobuf (https://github.com/TheThingsNetwork/lorawan-stack/issues/2798).
option (gogoproto.goproto_registration) = true;

message ApplicationWebhookIdentifiers {
option (thethings.flags.message) = { select: true, set: true };
ApplicationIdentifiers application_ids = 1 [(validate.rules).message.required = true];
Expand Down
4 changes: 0 additions & 4 deletions api/client.proto
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ syntax = "proto3";

import "github.com/TheThingsIndustries/protoc-gen-go-flags/annotations.proto";
import "github.com/envoyproxy/protoc-gen-validate/validate/validate.proto";
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
import "github.com/TheThingsIndustries/protoc-gen-go-json/annotations.proto";
import "google/protobuf/field_mask.proto";
import "google/protobuf/timestamp.proto";
Expand All @@ -29,9 +28,6 @@ package ttn.lorawan.v3;

option go_package = "go.thethings.network/lorawan-stack/v3/pkg/ttnpb";

// TODO: Migrate away from GoGo Protobuf (https://github.com/TheThingsNetwork/lorawan-stack/issues/2798).
option (gogoproto.goproto_registration) = true;

// The OAuth2 flows an OAuth client can use to get an access token.
enum GrantType {
option (thethings.json.enum) = { marshal_as_string: true, prefix: "GRANT" };
Expand Down
4 changes: 0 additions & 4 deletions api/client_services.proto
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@

syntax = "proto3";

import "github.com/gogo/protobuf/gogoproto/gogo.proto";
import "google/api/annotations.proto";
import "google/protobuf/empty.proto";
import "lorawan-stack/api/client.proto";
Expand All @@ -25,9 +24,6 @@ package ttn.lorawan.v3;

option go_package = "go.thethings.network/lorawan-stack/v3/pkg/ttnpb";

// TODO: Migrate away from GoGo Protobuf (https://github.com/TheThingsNetwork/lorawan-stack/issues/2798).
option (gogoproto.goproto_registration) = true;

// The ClientRegistry service, exposed by the Identity Server, is used to manage
// OAuth client registrations.
service ClientRegistry {
Expand Down
4 changes: 0 additions & 4 deletions api/cluster.proto
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,12 @@

syntax = "proto3";

import "github.com/gogo/protobuf/gogoproto/gogo.proto";
import "lorawan-stack/api/enums.proto";

package ttn.lorawan.v3;

option go_package = "go.thethings.network/lorawan-stack/v3/pkg/ttnpb";

// TODO: Migrate away from GoGo Protobuf (https://github.com/TheThingsNetwork/lorawan-stack/issues/2798).
option (gogoproto.goproto_registration) = true;

// PeerInfo
message PeerInfo {
// Port on which the gRPC server is exposed.
Expand Down
4 changes: 0 additions & 4 deletions api/configuration_services.proto
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ syntax = "proto3";

import "github.com/TheThingsIndustries/protoc-gen-go-flags/annotations.proto";
import "github.com/envoyproxy/protoc-gen-validate/validate/validate.proto";
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
import "google/protobuf/duration.proto";
import "google/api/annotations.proto";
import "google/protobuf/wrappers.proto";
Expand All @@ -26,9 +25,6 @@ package ttn.lorawan.v3;

option go_package = "go.thethings.network/lorawan-stack/v3/pkg/ttnpb";

// TODO: Migrate away from GoGo Protobuf (https://github.com/TheThingsNetwork/lorawan-stack/issues/2798).
option (gogoproto.goproto_registration) = true;

message ListFrequencyPlansRequest {
option (thethings.flags.message) = { select: false, set: true };
// Optional base frequency in MHz for hardware support (433, 470, 868 or 915)
Expand Down
4 changes: 0 additions & 4 deletions api/contact_info.proto
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
syntax = "proto3";

import "github.com/envoyproxy/protoc-gen-validate/validate/validate.proto";
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
import "github.com/TheThingsIndustries/protoc-gen-go-json/annotations.proto";
import "github.com/TheThingsIndustries/protoc-gen-go-flags/annotations.proto";
import "google/api/annotations.proto";
Expand All @@ -27,9 +26,6 @@ package ttn.lorawan.v3;

option go_package = "go.thethings.network/lorawan-stack/v3/pkg/ttnpb";

// TODO: Migrate away from GoGo Protobuf (https://github.com/TheThingsNetwork/lorawan-stack/issues/2798).
option (gogoproto.goproto_registration) = true;

enum ContactType {
option (thethings.json.enum) = { marshal_as_string: true, prefix: "CONTACT_TYPE" };

Expand Down
4 changes: 0 additions & 4 deletions api/deviceclaimingserver.proto
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
syntax = "proto3";

import "github.com/envoyproxy/protoc-gen-validate/validate/validate.proto";
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
import "google/api/annotations.proto";
import "google/protobuf/struct.proto";
import "google/protobuf/empty.proto";
Expand All @@ -27,9 +26,6 @@ package ttn.lorawan.v3;

option go_package = "go.thethings.network/lorawan-stack/v3/pkg/ttnpb";

// TODO: Migrate away from GoGo Protobuf (https://github.com/TheThingsNetwork/lorawan-stack/issues/2798).
option (gogoproto.goproto_registration) = true;

message ClaimEndDeviceRequest {
message AuthenticatedIdentifiers {
// JoinEUI (or AppEUI) of the device to claim.
Expand Down
4 changes: 0 additions & 4 deletions api/devicerepository.proto
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
syntax = "proto3";

import "github.com/envoyproxy/protoc-gen-validate/validate/validate.proto";
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
import "github.com/TheThingsIndustries/protoc-gen-go-json/annotations.proto";
import "google/api/annotations.proto";
import "google/protobuf/field_mask.proto";
Expand All @@ -29,9 +28,6 @@ package ttn.lorawan.v3;

option go_package = "go.thethings.network/lorawan-stack/v3/pkg/ttnpb";

// TODO: Migrate away from GoGo Protobuf (https://github.com/TheThingsNetwork/lorawan-stack/issues/2798).
option (gogoproto.goproto_registration) = true;

message EndDeviceBrand {
// Brand identifier, as specified in the Device Repository.
string brand_id = 1 [(validate.rules).string = {pattern: "^[a-z0-9](?:[-]?[a-z0-9]){2,}$" , max_len: 36}];
Expand Down
4 changes: 0 additions & 4 deletions api/end_device.proto
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
syntax = "proto3";

import "github.com/envoyproxy/protoc-gen-validate/validate/validate.proto";
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
import "github.com/TheThingsIndustries/protoc-gen-go-flags/annotations.proto";
import "github.com/TheThingsIndustries/protoc-gen-go-json/annotations.proto";
import "google/protobuf/duration.proto";
Expand All @@ -36,9 +35,6 @@ package ttn.lorawan.v3;

option go_package = "go.thethings.network/lorawan-stack/v3/pkg/ttnpb";

// TODO: Migrate away from GoGo Protobuf (https://github.com/TheThingsNetwork/lorawan-stack/issues/2798).
option (gogoproto.goproto_registration) = true;

message Session {
option (thethings.flags.message) = { select: true, set: true };
reserved 1; // RFU: Session ID
Expand Down
4 changes: 0 additions & 4 deletions api/end_device_services.proto
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@

syntax = "proto3";

import "github.com/gogo/protobuf/gogoproto/gogo.proto";
import "google/api/annotations.proto";
import "google/protobuf/empty.proto";
import "lorawan-stack/api/end_device.proto";
Expand All @@ -24,9 +23,6 @@ package ttn.lorawan.v3;

option go_package = "go.thethings.network/lorawan-stack/v3/pkg/ttnpb";

// TODO: Migrate away from GoGo Protobuf (https://github.com/TheThingsNetwork/lorawan-stack/issues/2798).
option (gogoproto.goproto_registration) = true;

// The EndDeviceRegistry service, exposed by the Identity Server, is used to manage
// end device registrations.
//
Expand Down
5 changes: 0 additions & 5 deletions api/enums.proto
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,10 @@
syntax = "proto3";

package ttn.lorawan.v3;

import "github.com/gogo/protobuf/gogoproto/gogo.proto";
import "github.com/TheThingsIndustries/protoc-gen-go-json/annotations.proto";

option go_package = "go.thethings.network/lorawan-stack/v3/pkg/ttnpb";

// TODO: Migrate away from GoGo Protobuf (https://github.com/TheThingsNetwork/lorawan-stack/issues/2798).
option (gogoproto.goproto_registration) = true;

enum DownlinkPathConstraint {
option (thethings.json.enum) = { marshal_as_string: true, prefix: "DOWNLINK_PATH_CONSTRAINT" };

Expand Down
4 changes: 0 additions & 4 deletions api/error.proto
Original file line number Diff line number Diff line change
Expand Up @@ -15,17 +15,13 @@
syntax = "proto3";

import "github.com/TheThingsIndustries/protoc-gen-go-flags/annotations.proto";
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
import "google/protobuf/any.proto";
import "google/protobuf/struct.proto";

package ttn.lorawan.v3;

option go_package = "go.thethings.network/lorawan-stack/v3/pkg/ttnpb";

// TODO: Migrate away from GoGo Protobuf (https://github.com/TheThingsNetwork/lorawan-stack/issues/2798).
option (gogoproto.goproto_registration) = true;

// Error details that are communicated over gRPC (and HTTP) APIs.
// The messages (for translation) are stored as "error:<namespace>:<name>".
message ErrorDetails {
Expand Down
4 changes: 0 additions & 4 deletions api/events.proto
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
syntax = "proto3";

import "github.com/envoyproxy/protoc-gen-validate/validate/validate.proto";
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
import "google/api/annotations.proto";
import "google/protobuf/any.proto";
import "google/protobuf/timestamp.proto";
Expand All @@ -26,9 +25,6 @@ package ttn.lorawan.v3;

option go_package = "go.thethings.network/lorawan-stack/v3/pkg/ttnpb";

// TODO: Migrate away from GoGo Protobuf (https://github.com/TheThingsNetwork/lorawan-stack/issues/2798).
option (gogoproto.goproto_registration) = true;

message Event {
// Name of the event. This can be used to find the (localized) event description.
string name = 1;
Expand Down
4 changes: 0 additions & 4 deletions api/gateway.proto
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ syntax = "proto3";

import "github.com/TheThingsIndustries/protoc-gen-go-flags/annotations.proto";
import "github.com/envoyproxy/protoc-gen-validate/validate/validate.proto";
import "github.com/gogo/protobuf/gogoproto/gogo.proto";
import "github.com/TheThingsIndustries/protoc-gen-go-json/annotations.proto";
import "google/protobuf/duration.proto";
import "google/protobuf/field_mask.proto";
Expand All @@ -34,9 +33,6 @@ package ttn.lorawan.v3;

option go_package = "go.thethings.network/lorawan-stack/v3/pkg/ttnpb";

// TODO: Migrate away from GoGo Protobuf (https://github.com/TheThingsNetwork/lorawan-stack/issues/2798).
option (gogoproto.goproto_registration) = true;

message GatewayBrand {
string id = 1;
string name = 2;
Expand Down
4 changes: 0 additions & 4 deletions api/gateway_services.proto
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@

syntax = "proto3";

import "github.com/gogo/protobuf/gogoproto/gogo.proto";
import "google/api/annotations.proto";
import "google/protobuf/empty.proto";
import "google/protobuf/field_mask.proto";
Expand All @@ -26,9 +25,6 @@ package ttn.lorawan.v3;

option go_package = "go.thethings.network/lorawan-stack/v3/pkg/ttnpb";

// TODO: Migrate away from GoGo Protobuf (https://github.com/TheThingsNetwork/lorawan-stack/issues/2798).
option (gogoproto.goproto_registration) = true;

// The GatewayRegistry service, exposed by the Identity Server, is used to manage
// gateway registrations.
service GatewayRegistry {
Expand Down
Loading

0 comments on commit ce55365

Please sign in to comment.