grpc-tools 1.65.2 → 1.82.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (58) hide show
  1. checksums.yaml +4 -4
  2. data/bin/x86-linux/google/protobuf/any.proto +52 -108
  3. data/bin/x86-linux/google/protobuf/api.proto +24 -2
  4. data/bin/x86-linux/google/protobuf/compiler/plugin.proto +2 -2
  5. data/bin/x86-linux/google/protobuf/descriptor.proto +306 -53
  6. data/bin/x86-linux/google/protobuf/field_mask.proto +16 -18
  7. data/bin/x86-linux/google/protobuf/struct.proto +38 -22
  8. data/bin/x86-linux/google/protobuf/timestamp.proto +9 -8
  9. data/bin/x86-linux/google/protobuf/type.proto +24 -0
  10. data/bin/x86-linux/google/protobuf/wrappers.proto +38 -4
  11. data/bin/x86-linux/grpc_ruby_plugin +0 -0
  12. data/bin/x86-linux/protoc +0 -0
  13. data/bin/x86-windows/google/protobuf/any.proto +52 -108
  14. data/bin/x86-windows/google/protobuf/api.proto +24 -2
  15. data/bin/x86-windows/google/protobuf/compiler/plugin.proto +2 -2
  16. data/bin/x86-windows/google/protobuf/descriptor.proto +306 -53
  17. data/bin/x86-windows/google/protobuf/field_mask.proto +16 -18
  18. data/bin/x86-windows/google/protobuf/struct.proto +38 -22
  19. data/bin/x86-windows/google/protobuf/timestamp.proto +9 -8
  20. data/bin/x86-windows/google/protobuf/type.proto +24 -0
  21. data/bin/x86-windows/google/protobuf/wrappers.proto +38 -4
  22. data/bin/x86-windows/grpc_ruby_plugin.exe +0 -0
  23. data/bin/x86-windows/protoc.exe +0 -0
  24. data/bin/x86_64-linux/google/protobuf/any.proto +52 -108
  25. data/bin/x86_64-linux/google/protobuf/api.proto +24 -2
  26. data/bin/x86_64-linux/google/protobuf/compiler/plugin.proto +2 -2
  27. data/bin/x86_64-linux/google/protobuf/descriptor.proto +306 -53
  28. data/bin/x86_64-linux/google/protobuf/field_mask.proto +16 -18
  29. data/bin/x86_64-linux/google/protobuf/struct.proto +38 -22
  30. data/bin/x86_64-linux/google/protobuf/timestamp.proto +9 -8
  31. data/bin/x86_64-linux/google/protobuf/type.proto +24 -0
  32. data/bin/x86_64-linux/google/protobuf/wrappers.proto +38 -4
  33. data/bin/x86_64-linux/grpc_ruby_plugin +0 -0
  34. data/bin/x86_64-linux/protoc +0 -0
  35. data/bin/x86_64-macos/google/protobuf/any.proto +52 -108
  36. data/bin/x86_64-macos/google/protobuf/api.proto +24 -2
  37. data/bin/x86_64-macos/google/protobuf/compiler/plugin.proto +2 -2
  38. data/bin/x86_64-macos/google/protobuf/descriptor.proto +306 -53
  39. data/bin/x86_64-macos/google/protobuf/field_mask.proto +16 -18
  40. data/bin/x86_64-macos/google/protobuf/struct.proto +38 -22
  41. data/bin/x86_64-macos/google/protobuf/timestamp.proto +9 -8
  42. data/bin/x86_64-macos/google/protobuf/type.proto +24 -0
  43. data/bin/x86_64-macos/google/protobuf/wrappers.proto +38 -4
  44. data/bin/x86_64-macos/grpc_ruby_plugin +0 -0
  45. data/bin/x86_64-macos/protoc +0 -0
  46. data/bin/x86_64-windows/google/protobuf/any.proto +52 -108
  47. data/bin/x86_64-windows/google/protobuf/api.proto +24 -2
  48. data/bin/x86_64-windows/google/protobuf/compiler/plugin.proto +2 -2
  49. data/bin/x86_64-windows/google/protobuf/descriptor.proto +306 -53
  50. data/bin/x86_64-windows/google/protobuf/field_mask.proto +16 -18
  51. data/bin/x86_64-windows/google/protobuf/struct.proto +38 -22
  52. data/bin/x86_64-windows/google/protobuf/timestamp.proto +9 -8
  53. data/bin/x86_64-windows/google/protobuf/type.proto +24 -0
  54. data/bin/x86_64-windows/google/protobuf/wrappers.proto +38 -4
  55. data/bin/x86_64-windows/grpc_ruby_plugin.exe +0 -0
  56. data/bin/x86_64-windows/protoc.exe +0 -0
  57. data/version.rb +1 -1
  58. metadata +4 -4
@@ -40,55 +40,71 @@ option java_multiple_files = true;
40
40
  option objc_class_prefix = "GPB";
41
41
  option csharp_namespace = "Google.Protobuf.WellKnownTypes";
42
42
 
43
- // `Struct` represents a structured data value, consisting of fields
44
- // which map to dynamically typed values. In some languages, `Struct`
45
- // might be supported by a native representation. For example, in
46
- // scripting languages like JS a struct is represented as an
47
- // object. The details of that representation are described together
48
- // with the proto support for the language.
43
+ // Represents a JSON object.
49
44
  //
50
- // The JSON representation for `Struct` is JSON object.
45
+ // An unordered key-value map, intending to perfectly capture the semantics of a
46
+ // JSON object. This enables parsing any arbitrary JSON payload as a message
47
+ // field in ProtoJSON format.
48
+ //
49
+ // This follows RFC 8259 guidelines for interoperable JSON: notably this type
50
+ // cannot represent large Int64 values or `NaN`/`Infinity` numbers,
51
+ // since the JSON format generally does not support those values in its number
52
+ // type.
53
+ //
54
+ // If you do not intend to parse arbitrary JSON into your message, a custom
55
+ // typed message should be preferred instead of using this type.
51
56
  message Struct {
52
57
  // Unordered map of dynamically typed values.
53
58
  map<string, Value> fields = 1;
54
59
  }
55
60
 
61
+ // Represents a JSON value.
62
+ //
56
63
  // `Value` represents a dynamically typed value which can be either
57
64
  // null, a number, a string, a boolean, a recursive struct value, or a
58
65
  // list of values. A producer of value is expected to set one of these
59
- // variants. Absence of any variant indicates an error.
60
- //
61
- // The JSON representation for `Value` is JSON value.
66
+ // variants. Absence of any variant is an invalid state.
62
67
  message Value {
63
68
  // The kind of value.
64
69
  oneof kind {
65
- // Represents a null value.
70
+ // Represents a JSON `null`.
66
71
  NullValue null_value = 1;
67
- // Represents a double value.
72
+
73
+ // Represents a JSON number. Must not be `NaN`, `Infinity` or
74
+ // `-Infinity`, since those are not supported in JSON. This also cannot
75
+ // represent large Int64 values, since JSON format generally does not
76
+ // support them in its number type.
68
77
  double number_value = 2;
69
- // Represents a string value.
78
+
79
+ // Represents a JSON string.
70
80
  string string_value = 3;
71
- // Represents a boolean value.
81
+
82
+ // Represents a JSON boolean (`true` or `false` literal in JSON).
72
83
  bool bool_value = 4;
73
- // Represents a structured value.
84
+
85
+ // Represents a JSON object.
74
86
  Struct struct_value = 5;
75
- // Represents a repeated `Value`.
87
+
88
+ // Represents a JSON array.
76
89
  ListValue list_value = 6;
77
90
  }
78
91
  }
79
92
 
80
- // `NullValue` is a singleton enumeration to represent the null value for the
81
- // `Value` type union.
93
+ // Represents a JSON `null`.
82
94
  //
83
- // The JSON representation for `NullValue` is JSON `null`.
95
+ // `NullValue` is a sentinel, using an enum with only one value to represent
96
+ // the null value for the `Value` type union.
97
+ //
98
+ // A field of type `NullValue` with any value other than `0` is considered
99
+ // invalid. Most ProtoJSON serializers will emit a Value with a `null_value` set
100
+ // as a JSON `null` regardless of the integer value, and so will round trip to
101
+ // a `0` value.
84
102
  enum NullValue {
85
103
  // Null value.
86
104
  NULL_VALUE = 0;
87
105
  }
88
106
 
89
- // `ListValue` is a wrapper around a repeated field of values.
90
- //
91
- // The JSON representation for `ListValue` is JSON array.
107
+ // Represents a JSON array.
92
108
  message ListValue {
93
109
  // Repeated field of dynamically typed values.
94
110
  repeated Value values = 1;
@@ -112,8 +112,8 @@ option csharp_namespace = "Google.Protobuf.WellKnownTypes";
112
112
  // {hour}, {min}, and {sec} are zero-padded to two digits each. The fractional
113
113
  // seconds, which can go up to 9 digits (i.e. up to 1 nanosecond resolution),
114
114
  // are optional. The "Z" suffix indicates the timezone ("UTC"); the timezone
115
- // is required. A proto3 JSON serializer should always use UTC (as indicated by
116
- // "Z") when printing the Timestamp type and a proto3 JSON parser should be
115
+ // is required. A ProtoJSON serializer should always use UTC (as indicated by
116
+ // "Z") when printing the Timestamp type and a ProtoJSON parser should be
117
117
  // able to accept both UTC and other timezones (as indicated by an offset).
118
118
  //
119
119
  // For example, "2017-01-15T01:30:15.01Z" encodes 15.01 seconds past
@@ -131,14 +131,15 @@ option csharp_namespace = "Google.Protobuf.WellKnownTypes";
131
131
  // ) to obtain a formatter capable of generating timestamps in this format.
132
132
  //
133
133
  message Timestamp {
134
- // Represents seconds of UTC time since Unix epoch
135
- // 1970-01-01T00:00:00Z. Must be from 0001-01-01T00:00:00Z to
136
- // 9999-12-31T23:59:59Z inclusive.
134
+ // Represents seconds of UTC time since Unix epoch 1970-01-01T00:00:00Z. Must
135
+ // be between -62135596800 and 253402300799 inclusive (which corresponds to
136
+ // 0001-01-01T00:00:00Z to 9999-12-31T23:59:59Z).
137
137
  int64 seconds = 1;
138
138
 
139
- // Non-negative fractions of a second at nanosecond resolution. Negative
140
- // second values with fractions must still have non-negative nanos values
141
- // that count forward in time. Must be from 0 to 999,999,999
139
+ // Non-negative fractions of a second at nanosecond resolution. This field is
140
+ // the nanosecond portion of the duration, not an alternative to seconds.
141
+ // Negative second values with fractions must still have non-negative nanos
142
+ // values that count forward in time. Must be between 0 and 999,999,999
142
143
  // inclusive.
143
144
  int32 nanos = 2;
144
145
  }
@@ -44,6 +44,11 @@ option csharp_namespace = "Google.Protobuf.WellKnownTypes";
44
44
  option go_package = "google.golang.org/protobuf/types/known/typepb";
45
45
 
46
46
  // A protocol buffer message type.
47
+ //
48
+ // New usages of this message as an alternative to DescriptorProto are strongly
49
+ // discouraged. This message does not reliability preserve all information
50
+ // necessary to model the schema and preserve semantics. Instead make use of
51
+ // FileDescriptorSet which preserves the necessary information.
47
52
  message Type {
48
53
  // The fully qualified message name.
49
54
  string name = 1;
@@ -62,6 +67,11 @@ message Type {
62
67
  }
63
68
 
64
69
  // A single field of a message type.
70
+ //
71
+ // New usages of this message as an alternative to FieldDescriptorProto are
72
+ // strongly discouraged. This message does not reliability preserve all
73
+ // information necessary to model the schema and preserve semantics. Instead
74
+ // make use of FileDescriptorSet which preserves the necessary information.
65
75
  message Field {
66
76
  // Basic field types.
67
77
  enum Kind {
@@ -142,6 +152,11 @@ message Field {
142
152
  }
143
153
 
144
154
  // Enum type definition.
155
+ //
156
+ // New usages of this message as an alternative to EnumDescriptorProto are
157
+ // strongly discouraged. This message does not reliability preserve all
158
+ // information necessary to model the schema and preserve semantics. Instead
159
+ // make use of FileDescriptorSet which preserves the necessary information.
145
160
  message Enum {
146
161
  // Enum type name.
147
162
  string name = 1;
@@ -158,6 +173,11 @@ message Enum {
158
173
  }
159
174
 
160
175
  // Enum value definition.
176
+ //
177
+ // New usages of this message as an alternative to EnumValueDescriptorProto are
178
+ // strongly discouraged. This message does not reliability preserve all
179
+ // information necessary to model the schema and preserve semantics. Instead
180
+ // make use of FileDescriptorSet which preserves the necessary information.
161
181
  message EnumValue {
162
182
  // Enum value name.
163
183
  string name = 1;
@@ -169,6 +189,10 @@ message EnumValue {
169
189
 
170
190
  // A protocol buffer option, which can be attached to a message, field,
171
191
  // enumeration, etc.
192
+ //
193
+ // New usages of this message as an alternative to FileOptions, MessageOptions,
194
+ // FieldOptions, EnumOptions, EnumValueOptions, ServiceOptions, or MethodOptions
195
+ // are strongly discouraged.
172
196
  message Option {
173
197
  // The option's name. For protobuf built-in options (options defined in
174
198
  // descriptor.proto), this is the short name. For example, `"map_entry"`.
@@ -28,10 +28,17 @@
28
28
  // (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
29
29
  // OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
30
30
  //
31
- // Wrappers for primitive (non-message) types. These types are useful
32
- // for embedding primitives in the `google.protobuf.Any` type and for places
33
- // where we need to distinguish between the absence of a primitive
34
- // typed field and its default value.
31
+ // Wrappers for primitive (non-message) types. These types were needed
32
+ // for legacy reasons and are not recommended for use in new APIs.
33
+ //
34
+ // Historically these wrappers were useful to have presence on proto3 primitive
35
+ // fields, but proto3 syntax has been updated to support the `optional` keyword.
36
+ // Using that keyword is now the strongly preferred way to add presence to
37
+ // proto3 primitive fields.
38
+ //
39
+ // A secondary usecase was to embed primitives in the `google.protobuf.Any`
40
+ // type: it is now recommended that you embed your value in your own wrapper
41
+ // message which can be specifically documented.
35
42
  //
36
43
  // These wrappers have no meaningful use within repeated fields as they lack
37
44
  // the ability to detect presence on individual elements.
@@ -53,6 +60,9 @@ option csharp_namespace = "Google.Protobuf.WellKnownTypes";
53
60
  // Wrapper message for `double`.
54
61
  //
55
62
  // The JSON representation for `DoubleValue` is JSON number.
63
+ //
64
+ // Not recommended for use in new APIs, but still useful for legacy APIs and
65
+ // has no plan to be removed.
56
66
  message DoubleValue {
57
67
  // The double value.
58
68
  double value = 1;
@@ -61,6 +71,9 @@ message DoubleValue {
61
71
  // Wrapper message for `float`.
62
72
  //
63
73
  // The JSON representation for `FloatValue` is JSON number.
74
+ //
75
+ // Not recommended for use in new APIs, but still useful for legacy APIs and
76
+ // has no plan to be removed.
64
77
  message FloatValue {
65
78
  // The float value.
66
79
  float value = 1;
@@ -69,6 +82,9 @@ message FloatValue {
69
82
  // Wrapper message for `int64`.
70
83
  //
71
84
  // The JSON representation for `Int64Value` is JSON string.
85
+ //
86
+ // Not recommended for use in new APIs, but still useful for legacy APIs and
87
+ // has no plan to be removed.
72
88
  message Int64Value {
73
89
  // The int64 value.
74
90
  int64 value = 1;
@@ -77,6 +93,9 @@ message Int64Value {
77
93
  // Wrapper message for `uint64`.
78
94
  //
79
95
  // The JSON representation for `UInt64Value` is JSON string.
96
+ //
97
+ // Not recommended for use in new APIs, but still useful for legacy APIs and
98
+ // has no plan to be removed.
80
99
  message UInt64Value {
81
100
  // The uint64 value.
82
101
  uint64 value = 1;
@@ -85,6 +104,9 @@ message UInt64Value {
85
104
  // Wrapper message for `int32`.
86
105
  //
87
106
  // The JSON representation for `Int32Value` is JSON number.
107
+ //
108
+ // Not recommended for use in new APIs, but still useful for legacy APIs and
109
+ // has no plan to be removed.
88
110
  message Int32Value {
89
111
  // The int32 value.
90
112
  int32 value = 1;
@@ -93,6 +115,9 @@ message Int32Value {
93
115
  // Wrapper message for `uint32`.
94
116
  //
95
117
  // The JSON representation for `UInt32Value` is JSON number.
118
+ //
119
+ // Not recommended for use in new APIs, but still useful for legacy APIs and
120
+ // has no plan to be removed.
96
121
  message UInt32Value {
97
122
  // The uint32 value.
98
123
  uint32 value = 1;
@@ -101,6 +126,9 @@ message UInt32Value {
101
126
  // Wrapper message for `bool`.
102
127
  //
103
128
  // The JSON representation for `BoolValue` is JSON `true` and `false`.
129
+ //
130
+ // Not recommended for use in new APIs, but still useful for legacy APIs and
131
+ // has no plan to be removed.
104
132
  message BoolValue {
105
133
  // The bool value.
106
134
  bool value = 1;
@@ -109,6 +137,9 @@ message BoolValue {
109
137
  // Wrapper message for `string`.
110
138
  //
111
139
  // The JSON representation for `StringValue` is JSON string.
140
+ //
141
+ // Not recommended for use in new APIs, but still useful for legacy APIs and
142
+ // has no plan to be removed.
112
143
  message StringValue {
113
144
  // The string value.
114
145
  string value = 1;
@@ -117,6 +148,9 @@ message StringValue {
117
148
  // Wrapper message for `bytes`.
118
149
  //
119
150
  // The JSON representation for `BytesValue` is JSON string.
151
+ //
152
+ // Not recommended for use in new APIs, but still useful for legacy APIs and
153
+ // has no plan to be removed.
120
154
  message BytesValue {
121
155
  // The bytes value.
122
156
  bytes value = 1;
Binary file
data/bin/x86-linux/protoc CHANGED
Binary file
@@ -42,121 +42,65 @@ option csharp_namespace = "Google.Protobuf.WellKnownTypes";
42
42
  // `Any` contains an arbitrary serialized protocol buffer message along with a
43
43
  // URL that describes the type of the serialized message.
44
44
  //
45
- // Protobuf library provides support to pack/unpack Any values in the form
46
- // of utility functions or additional generated methods of the Any type.
47
- //
48
- // Example 1: Pack and unpack a message in C++.
49
- //
50
- // Foo foo = ...;
51
- // Any any;
52
- // any.PackFrom(foo);
53
- // ...
54
- // if (any.UnpackTo(&foo)) {
55
- // ...
56
- // }
57
- //
58
- // Example 2: Pack and unpack a message in Java.
59
- //
60
- // Foo foo = ...;
61
- // Any any = Any.pack(foo);
62
- // ...
63
- // if (any.is(Foo.class)) {
64
- // foo = any.unpack(Foo.class);
65
- // }
66
- // // or ...
67
- // if (any.isSameTypeAs(Foo.getDefaultInstance())) {
68
- // foo = any.unpack(Foo.getDefaultInstance());
69
- // }
70
- //
71
- // Example 3: Pack and unpack a message in Python.
72
- //
73
- // foo = Foo(...)
74
- // any = Any()
75
- // any.Pack(foo)
76
- // ...
77
- // if any.Is(Foo.DESCRIPTOR):
78
- // any.Unpack(foo)
79
- // ...
80
- //
81
- // Example 4: Pack and unpack a message in Go
82
- //
83
- // foo := &pb.Foo{...}
84
- // any, err := anypb.New(foo)
85
- // if err != nil {
86
- // ...
87
- // }
88
- // ...
89
- // foo := &pb.Foo{}
90
- // if err := any.UnmarshalTo(foo); err != nil {
91
- // ...
92
- // }
93
- //
94
- // The pack methods provided by protobuf library will by default use
95
- // 'type.googleapis.com/full.type.name' as the type URL and the unpack
96
- // methods only use the fully qualified type name after the last '/'
97
- // in the type URL, for example "foo.bar.com/x/y.z" will yield type
98
- // name "y.z".
99
- //
100
- // JSON
101
- // ====
102
- // The JSON representation of an `Any` value uses the regular
103
- // representation of the deserialized, embedded message, with an
104
- // additional field `@type` which contains the type URL. Example:
105
- //
106
- // package google.profile;
107
- // message Person {
108
- // string first_name = 1;
109
- // string last_name = 2;
110
- // }
111
- //
112
- // {
113
- // "@type": "type.googleapis.com/google.profile.Person",
114
- // "firstName": <string>,
115
- // "lastName": <string>
116
- // }
117
- //
118
- // If the embedded message type is well-known and has a custom JSON
119
- // representation, that representation will be embedded adding a field
120
- // `value` which holds the custom JSON in addition to the `@type`
121
- // field. Example (for message [google.protobuf.Duration][]):
122
- //
123
- // {
124
- // "@type": "type.googleapis.com/google.protobuf.Duration",
125
- // "value": "1.212s"
126
- // }
127
- //
45
+ // In its binary encoding, an `Any` is an ordinary message; but in other wire
46
+ // forms like JSON, it has a special encoding. The format of the type URL is
47
+ // described on the `type_url` field.
48
+ //
49
+ // Protobuf APIs provide utilities to interact with `Any` values:
50
+ //
51
+ // - A 'pack' operation accepts a message and constructs a generic `Any` wrapper
52
+ // around it.
53
+ // - An 'unpack' operation reads the content of an `Any` message, either into an
54
+ // existing message or a new one. Unpack operations must check the type of the
55
+ // value they unpack against the declared `type_url`.
56
+ // - An 'is' operation decides whether an `Any` contains a message of the given
57
+ // type, i.e. whether it can 'unpack' that type.
58
+ //
59
+ // The JSON format representation of an `Any` follows one of these cases:
60
+ //
61
+ // - For types without special-cased JSON encodings, the JSON format
62
+ // representation of the `Any` is the same as that of the message, with an
63
+ // additional `@type` field which contains the type URL.
64
+ // - For types with special-cased JSON encodings (typically called 'well-known'
65
+ // types, listed in https://protobuf.dev/programming-guides/json/#any), the
66
+ // JSON format representation has a key `@type` which contains the type URL
67
+ // and a key `value` which contains the JSON-serialized value.
68
+ //
69
+ // The text format representation of an `Any` is like a message with one field
70
+ // whose name is the type URL in brackets. For example, an `Any` containing a
71
+ // `foo.Bar` message may be written `[type.googleapis.com/foo.Bar] { a: 2 }`.
128
72
  message Any {
129
- // A URL/resource name that uniquely identifies the type of the serialized
130
- // protocol buffer message. This string must contain at least
131
- // one "/" character. The last segment of the URL's path must represent
132
- // the fully qualified name of the type (as in
133
- // `path/google.protobuf.Duration`). The name should be in a canonical form
134
- // (e.g., leading "." is not accepted).
73
+ // Identifies the type of the serialized Protobuf message with a URI reference
74
+ // consisting of a prefix ending in a slash and the fully-qualified type name.
135
75
  //
136
- // In practice, teams usually precompile into the binary all types that they
137
- // expect it to use in the context of Any. However, for URLs which use the
138
- // scheme `http`, `https`, or no scheme, one can optionally set up a type
139
- // server that maps type URLs to message definitions as follows:
76
+ // Example: type.googleapis.com/google.protobuf.StringValue
140
77
  //
141
- // * If no scheme is provided, `https` is assumed.
142
- // * An HTTP GET on the URL must yield a [google.protobuf.Type][]
143
- // value in binary format, or produce an error.
144
- // * Applications are allowed to cache lookup results based on the
145
- // URL, or have them precompiled into a binary to avoid any
146
- // lookup. Therefore, binary compatibility needs to be preserved
147
- // on changes to types. (Use versioned type names to manage
148
- // breaking changes.)
78
+ // This string must contain at least one `/` character, and the content after
79
+ // the last `/` must be the fully-qualified name of the type in canonical
80
+ // form, without a leading dot. Do not write a scheme on these URI references
81
+ // so that clients do not attempt to contact them.
149
82
  //
150
- // Note: this functionality is not currently available in the official
151
- // protobuf release, and it is not used for type URLs beginning with
152
- // type.googleapis.com. As of May 2023, there are no widely used type server
153
- // implementations and no plans to implement one.
83
+ // The prefix is arbitrary and Protobuf implementations are expected to
84
+ // simply strip off everything up to and including the last `/` to identify
85
+ // the type. `type.googleapis.com/` is a common default prefix that some
86
+ // legacy implementations require. This prefix does not indicate the origin of
87
+ // the type, and URIs containing it are not expected to respond to any
88
+ // requests.
154
89
  //
155
- // Schemes other than `http`, `https` (or the empty scheme) might be
156
- // used with implementation specific semantics.
90
+ // All type URL strings must be legal URI references with the additional
91
+ // restriction (for the text format) that the content of the reference
92
+ // must consist only of alphanumeric characters, percent-encoded escapes, and
93
+ // characters in the following set (not including the outer backticks):
94
+ // `/-.~_!$&()*+,;=`. Despite our allowing percent encodings, implementations
95
+ // should not unescape them to prevent confusion with existing parsers. For
96
+ // example, `type.googleapis.com%2FFoo` should be rejected.
157
97
  //
98
+ // In the original design of `Any`, the possibility of launching a type
99
+ // resolution service at these type URLs was considered but Protobuf never
100
+ // implemented one and considers contacting these URLs to be problematic and
101
+ // a potential security issue. Do not attempt to contact type URLs.
158
102
  string type_url = 1;
159
103
 
160
- // Must be a valid serialized protocol buffer of the above specified type.
104
+ // Holds a Protobuf serialization of the type described by type_url.
161
105
  bytes value = 2;
162
106
  }
@@ -51,6 +51,11 @@ option go_package = "google.golang.org/protobuf/types/known/apipb";
51
51
  // sometimes simply referred to as "APIs" in other contexts, such as the name of
52
52
  // this message itself. See https://cloud.google.com/apis/design/glossary for
53
53
  // detailed terminology.
54
+ //
55
+ // New usages of this message as an alternative to ServiceDescriptorProto are
56
+ // strongly discouraged. This message does not reliability preserve all
57
+ // information necessary to model the schema and preserve semantics. Instead
58
+ // make use of FileDescriptorSet which preserves the necessary information.
54
59
  message Api {
55
60
  // The fully qualified name of this interface, including package name
56
61
  // followed by the interface's simple name.
@@ -93,9 +98,17 @@ message Api {
93
98
 
94
99
  // The source syntax of the service.
95
100
  Syntax syntax = 7;
101
+
102
+ // The source edition string, only valid when syntax is SYNTAX_EDITIONS.
103
+ string edition = 8;
96
104
  }
97
105
 
98
106
  // Method represents a method of an API interface.
107
+ //
108
+ // New usages of this message as an alternative to MethodDescriptorProto are
109
+ // strongly discouraged. This message does not reliability preserve all
110
+ // information necessary to model the schema and preserve semantics. Instead
111
+ // make use of FileDescriptorSet which preserves the necessary information.
99
112
  message Method {
100
113
  // The simple name of this method.
101
114
  string name = 1;
@@ -116,7 +129,16 @@ message Method {
116
129
  repeated Option options = 6;
117
130
 
118
131
  // The source syntax of this method.
119
- Syntax syntax = 7;
132
+ //
133
+ // This field should be ignored, instead the syntax should be inherited from
134
+ // Api. This is similar to Field and EnumValue.
135
+ Syntax syntax = 7 [deprecated = true];
136
+
137
+ // The source edition string, only valid when syntax is SYNTAX_EDITIONS.
138
+ //
139
+ // This field should be ignored, instead the edition should be inherited from
140
+ // Api. This is similar to Field and EnumValue.
141
+ string edition = 8 [deprecated = true];
120
142
  }
121
143
 
122
144
  // Declares an API Interface to be included in this interface. The including
@@ -166,7 +188,7 @@ message Method {
166
188
  // The mixin construct implies that all methods in `AccessControl` are
167
189
  // also declared with same name and request/response types in
168
190
  // `Storage`. A documentation generator or annotation processor will
169
- // see the effective `Storage.GetAcl` method after inherting
191
+ // see the effective `Storage.GetAcl` method after inheriting
170
192
  // documentation and annotations as follows:
171
193
  //
172
194
  // service Storage {
@@ -24,11 +24,11 @@ package google.protobuf.compiler;
24
24
  option java_package = "com.google.protobuf.compiler";
25
25
  option java_outer_classname = "PluginProtos";
26
26
 
27
+ import "google/protobuf/descriptor.proto";
28
+
27
29
  option csharp_namespace = "Google.Protobuf.Compiler";
28
30
  option go_package = "google.golang.org/protobuf/types/pluginpb";
29
31
 
30
- import "google/protobuf/descriptor.proto";
31
-
32
32
  // The version number of protocol compiler.
33
33
  message Version {
34
34
  optional int32 major = 1;