Remove all gogoproto extensions

This commit removes the following gogoproto extensions;

- gogoproto.nullable
- gogoproto.customename
- gogoproto.unmarshaller_all
- gogoproto.stringer_all
- gogoproto.sizer_all
- gogoproto.marshaler_all
- gogoproto.goproto_unregonized_all
- gogoproto.goproto_stringer_all
- gogoproto.goproto_getters_all

None of them are supported by Google's toolchain (see #6564).

Signed-off-by: Kazuyoshi Kato <katokazu@amazon.com>
This commit is contained in:
Kazuyoshi Kato
2022-04-20 03:30:52 +00:00
parent 9b33526ef6
commit 237ef0de9b
48 changed files with 1301 additions and 1246 deletions

View File

@@ -52,7 +52,7 @@ type Plugin struct {
//
// If the plugin prefers certain platforms over others, they should be
// listed from most to least preferred.
Platforms []types.Platform `protobuf:"bytes,4,rep,name=platforms,proto3" json:"platforms"`
Platforms []*types.Platform `protobuf:"bytes,4,rep,name=platforms,proto3" json:"platforms,omitempty"`
// Exports allows plugins to provide values about state or configuration to
// interested parties.
//
@@ -158,10 +158,10 @@ func (m *PluginsRequest) XXX_DiscardUnknown() {
var xxx_messageInfo_PluginsRequest proto.InternalMessageInfo
type PluginsResponse struct {
Plugins []Plugin `protobuf:"bytes,1,rep,name=plugins,proto3" json:"plugins"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
Plugins []*Plugin `protobuf:"bytes,1,rep,name=plugins,proto3" json:"plugins,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *PluginsResponse) Reset() { *m = PluginsResponse{} }
@@ -248,42 +248,41 @@ func init() {
}
var fileDescriptor_1a14fda866f10715 = []byte{
// 548 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x54, 0x41, 0x6f, 0xd3, 0x4c,
0x10, 0xad, 0x9d, 0x34, 0x6e, 0x36, 0xfd, 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xab, 0x04, 0x4f,
0x14, 0x92, 0x77, 0x60, 0x89, 0x12, 0x2a, 0xc8, 0xdd, 0xe1, 0xf3, 0x6d, 0x22, 0xf2, 0x6b, 0x71,
0xff, 0x04, 0x0e, 0xc7, 0x28, 0x33, 0x94, 0xab, 0x9b, 0x09, 0xec, 0xa6, 0x29, 0x9b, 0xd6, 0x9f,
0x3f, 0xaf, 0x87, 0xbf, 0x0d, 0x78, 0x70, 0xb5, 0x7e, 0x15, 0xc9, 0xc0, 0xaa, 0x2c, 0x91, 0x57,
0xdb, 0x4c, 0xae, 0xb7, 0x75, 0x5e, 0x6f, 0xa9, 0xaa, 0xdc, 0x7d, 0x80, 0x76, 0xe9, 0x97, 0x1c,
0xd7, 0x5f, 0xa6, 0x7e, 0xe5, 0x74, 0x94, 0xbf, 0x72, 0x67, 0x43, 0x3b, 0xcd, 0xad, 0x2f, 0x67,
0xb7, 0x77, 0xee, 0xce, 0xcf, 0x3b, 0x77, 0xe7, 0xfb, 0xd2, 0x35, 0x6e, 0x97, 0xae, 0xf1, 0x63,
0xe9, 0x1a, 0x7f, 0x96, 0xae, 0xf1, 0xe9, 0xfd, 0xff, 0xfd, 0x1a, 0xde, 0x34, 0x80, 0x49, 0xbb,
0x70, 0xfb, 0xf2, 0x5f, 0x00, 0x00, 0x00, 0xff, 0xff, 0x4c, 0x6f, 0xe7, 0xad, 0x71, 0x04, 0x00,
0x00,
}
// Reference imports to suppress errors if they are not otherwise used.
@@ -750,9 +749,9 @@ func (this *Plugin) String() string {
if this == nil {
return "nil"
}
repeatedStringForPlatforms := "[]Platform{"
repeatedStringForPlatforms := "[]*Platform{"
for _, f := range this.Platforms {
repeatedStringForPlatforms += fmt.Sprintf("%v", f) + ","
repeatedStringForPlatforms += strings.Replace(fmt.Sprintf("%v", f), "Platform", "types.Platform", 1) + ","
}
repeatedStringForPlatforms += "}"
keysForExports := make([]string, 0, len(this.Exports))
@@ -793,9 +792,9 @@ func (this *PluginsResponse) String() string {
if this == nil {
return "nil"
}
repeatedStringForPlugins := "[]Plugin{"
repeatedStringForPlugins := "[]*Plugin{"
for _, f := range this.Plugins {
repeatedStringForPlugins += strings.Replace(strings.Replace(f.String(), "Plugin", "Plugin", 1), `&`, ``, 1) + ","
repeatedStringForPlugins += strings.Replace(f.String(), "Plugin", "Plugin", 1) + ","
}
repeatedStringForPlugins += "}"
s := strings.Join([]string{`&PluginsResponse{`,
@@ -810,7 +809,7 @@ func (this *ServerResponse) String() string {
return "nil"
}
s := strings.Join([]string{`&ServerResponse{`,
`UUID:` + fmt.Sprintf("%v", this.UUID) + `,`,
`Uuid:` + fmt.Sprintf("%v", this.UUID) + `,`,
`XXX_unrecognized:` + fmt.Sprintf("%v", this.XXX_unrecognized) + `,`,
`}`,
}, "")
@@ -978,7 +977,7 @@ func (m *Plugin) Unmarshal(dAtA []byte) error {
if postIndex > l {
return io.ErrUnexpectedEOF
}
m.Platforms = append(m.Platforms, types.Platform{})
m.Platforms = append(m.Platforms, &types.Platform{})
if err := m.Platforms[len(m.Platforms)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
return err
}
@@ -1341,7 +1340,7 @@ func (m *PluginsResponse) Unmarshal(dAtA []byte) error {
if postIndex > l {
return io.ErrUnexpectedEOF
}
m.Plugins = append(m.Plugins, Plugin{})
m.Plugins = append(m.Plugins, &Plugin{})
if err := m.Plugins[len(m.Plugins)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
return err
}
@@ -1399,7 +1398,7 @@ func (m *ServerResponse) Unmarshal(dAtA []byte) error {
switch fieldNum {
case 1:
if wireType != 2 {
return fmt.Errorf("proto: wrong wireType = %d for field UUID", wireType)
return fmt.Errorf("proto: wrong wireType = %d for field Uuid", wireType)
}
var stringLen uint64
for shift := uint(0); ; shift += 7 {

View File

@@ -57,7 +57,7 @@ message Plugin {
//
// If the plugin prefers certain platforms over others, they should be
// listed from most to least preferred.
repeated types.Platform platforms = 4 [(gogoproto.nullable) = false];
repeated types.Platform platforms = 4;
// Exports allows plugins to provide values about state or configuration to
// interested parties.
@@ -96,9 +96,9 @@ message PluginsRequest {
}
message PluginsResponse {
repeated Plugin plugins = 1 [(gogoproto.nullable) = false];
repeated Plugin plugins = 1;
}
message ServerResponse {
string uuid = 1 [(gogoproto.customname) = "UUID"];
string uuid = 1;
}