1 // Code generated by protoc-gen-go. DO NOT EDIT.
2 // source: grpc/binarylog/grpc_binarylog_v1/binarylog.proto
4 package grpc_binarylog_v1 // import "google.golang.org/grpc/binarylog/grpc_binarylog_v1"
6 import proto "github.com/golang/protobuf/proto"
9 import duration "github.com/golang/protobuf/ptypes/duration"
10 import timestamp "github.com/golang/protobuf/ptypes/timestamp"
12 // Reference imports to suppress errors if they are not otherwise used.
17 // This is a compile-time assertion to ensure that this generated file
18 // is compatible with the proto package it is being compiled against.
19 // A compilation error at this line likely means your copy of the
20 // proto package needs to be updated.
21 const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
23 // Enumerates the type of event
24 // Note the terminology is different from the RPC semantics
25 // definition, but the same meaning is expressed here.
26 type GrpcLogEntry_EventType int32
29 GrpcLogEntry_EVENT_TYPE_UNKNOWN GrpcLogEntry_EventType = 0
30 // Header sent from client to server
31 GrpcLogEntry_EVENT_TYPE_CLIENT_HEADER GrpcLogEntry_EventType = 1
32 // Header sent from server to client
33 GrpcLogEntry_EVENT_TYPE_SERVER_HEADER GrpcLogEntry_EventType = 2
34 // Message sent from client to server
35 GrpcLogEntry_EVENT_TYPE_CLIENT_MESSAGE GrpcLogEntry_EventType = 3
36 // Message sent from server to client
37 GrpcLogEntry_EVENT_TYPE_SERVER_MESSAGE GrpcLogEntry_EventType = 4
38 // A signal that client is done sending
39 GrpcLogEntry_EVENT_TYPE_CLIENT_HALF_CLOSE GrpcLogEntry_EventType = 5
40 // Trailer indicates the end of the RPC.
41 // On client side, this event means a trailer was either received
42 // from the network or the gRPC library locally generated a status
43 // to inform the application about a failure.
44 // On server side, this event means the server application requested
45 // to send a trailer. Note: EVENT_TYPE_CANCEL may still arrive after
46 // this due to races on server side.
47 GrpcLogEntry_EVENT_TYPE_SERVER_TRAILER GrpcLogEntry_EventType = 6
48 // A signal that the RPC is cancelled. On client side, this
49 // indicates the client application requests a cancellation.
50 // On server side, this indicates that cancellation was detected.
51 // Note: This marks the end of the RPC. Events may arrive after
52 // this due to races. For example, on client side a trailer
53 // may arrive even though the application requested to cancel the RPC.
54 GrpcLogEntry_EVENT_TYPE_CANCEL GrpcLogEntry_EventType = 7
57 var GrpcLogEntry_EventType_name = map[int32]string{
58 0: "EVENT_TYPE_UNKNOWN",
59 1: "EVENT_TYPE_CLIENT_HEADER",
60 2: "EVENT_TYPE_SERVER_HEADER",
61 3: "EVENT_TYPE_CLIENT_MESSAGE",
62 4: "EVENT_TYPE_SERVER_MESSAGE",
63 5: "EVENT_TYPE_CLIENT_HALF_CLOSE",
64 6: "EVENT_TYPE_SERVER_TRAILER",
65 7: "EVENT_TYPE_CANCEL",
67 var GrpcLogEntry_EventType_value = map[string]int32{
68 "EVENT_TYPE_UNKNOWN": 0,
69 "EVENT_TYPE_CLIENT_HEADER": 1,
70 "EVENT_TYPE_SERVER_HEADER": 2,
71 "EVENT_TYPE_CLIENT_MESSAGE": 3,
72 "EVENT_TYPE_SERVER_MESSAGE": 4,
73 "EVENT_TYPE_CLIENT_HALF_CLOSE": 5,
74 "EVENT_TYPE_SERVER_TRAILER": 6,
75 "EVENT_TYPE_CANCEL": 7,
78 func (x GrpcLogEntry_EventType) String() string {
79 return proto.EnumName(GrpcLogEntry_EventType_name, int32(x))
81 func (GrpcLogEntry_EventType) EnumDescriptor() ([]byte, []int) {
82 return fileDescriptor_binarylog_264c8c9c551ce911, []int{0, 0}
85 // Enumerates the entity that generates the log entry
86 type GrpcLogEntry_Logger int32
89 GrpcLogEntry_LOGGER_UNKNOWN GrpcLogEntry_Logger = 0
90 GrpcLogEntry_LOGGER_CLIENT GrpcLogEntry_Logger = 1
91 GrpcLogEntry_LOGGER_SERVER GrpcLogEntry_Logger = 2
94 var GrpcLogEntry_Logger_name = map[int32]string{
99 var GrpcLogEntry_Logger_value = map[string]int32{
105 func (x GrpcLogEntry_Logger) String() string {
106 return proto.EnumName(GrpcLogEntry_Logger_name, int32(x))
108 func (GrpcLogEntry_Logger) EnumDescriptor() ([]byte, []int) {
109 return fileDescriptor_binarylog_264c8c9c551ce911, []int{0, 1}
112 type Address_Type int32
115 Address_TYPE_UNKNOWN Address_Type = 0
116 // address is in 1.2.3.4 form
117 Address_TYPE_IPV4 Address_Type = 1
118 // address is in IPv6 canonical form (RFC5952 section 4)
119 // The scope is NOT included in the address string.
120 Address_TYPE_IPV6 Address_Type = 2
121 // address is UDS string
122 Address_TYPE_UNIX Address_Type = 3
125 var Address_Type_name = map[int32]string{
131 var Address_Type_value = map[string]int32{
138 func (x Address_Type) String() string {
139 return proto.EnumName(Address_Type_name, int32(x))
141 func (Address_Type) EnumDescriptor() ([]byte, []int) {
142 return fileDescriptor_binarylog_264c8c9c551ce911, []int{7, 0}
145 // Log entry we store in binary logs
146 type GrpcLogEntry struct {
147 // The timestamp of the binary log message
148 Timestamp *timestamp.Timestamp `protobuf:"bytes,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
149 // Uniquely identifies a call. The value must not be 0 in order to disambiguate
150 // from an unset value.
151 // Each call may have several log entries, they will all have the same call_id.
152 // Nothing is guaranteed about their value other than they are unique across
153 // different RPCs in the same gRPC process.
154 CallId uint64 `protobuf:"varint,2,opt,name=call_id,json=callId,proto3" json:"call_id,omitempty"`
155 // The entry sequence id for this call. The first GrpcLogEntry has a
156 // value of 1, to disambiguate from an unset value. The purpose of
157 // this field is to detect missing entries in environments where
158 // durability or ordering is not guaranteed.
159 SequenceIdWithinCall uint64 `protobuf:"varint,3,opt,name=sequence_id_within_call,json=sequenceIdWithinCall,proto3" json:"sequence_id_within_call,omitempty"`
160 Type GrpcLogEntry_EventType `protobuf:"varint,4,opt,name=type,proto3,enum=grpc.binarylog.v1.GrpcLogEntry_EventType" json:"type,omitempty"`
161 Logger GrpcLogEntry_Logger `protobuf:"varint,5,opt,name=logger,proto3,enum=grpc.binarylog.v1.GrpcLogEntry_Logger" json:"logger,omitempty"`
162 // The logger uses one of the following fields to record the payload,
163 // according to the type of the log entry.
165 // Types that are valid to be assigned to Payload:
166 // *GrpcLogEntry_ClientHeader
167 // *GrpcLogEntry_ServerHeader
168 // *GrpcLogEntry_Message
169 // *GrpcLogEntry_Trailer
170 Payload isGrpcLogEntry_Payload `protobuf_oneof:"payload"`
171 // true if payload does not represent the full message or metadata.
172 PayloadTruncated bool `protobuf:"varint,10,opt,name=payload_truncated,json=payloadTruncated,proto3" json:"payload_truncated,omitempty"`
173 // Peer address information, will only be recorded on the first
174 // incoming event. On client side, peer is logged on
175 // EVENT_TYPE_SERVER_HEADER normally or EVENT_TYPE_SERVER_TRAILER in
176 // the case of trailers-only. On server side, peer is always
177 // logged on EVENT_TYPE_CLIENT_HEADER.
178 Peer *Address `protobuf:"bytes,11,opt,name=peer,proto3" json:"peer,omitempty"`
179 XXX_NoUnkeyedLiteral struct{} `json:"-"`
180 XXX_unrecognized []byte `json:"-"`
181 XXX_sizecache int32 `json:"-"`
184 func (m *GrpcLogEntry) Reset() { *m = GrpcLogEntry{} }
185 func (m *GrpcLogEntry) String() string { return proto.CompactTextString(m) }
186 func (*GrpcLogEntry) ProtoMessage() {}
187 func (*GrpcLogEntry) Descriptor() ([]byte, []int) {
188 return fileDescriptor_binarylog_264c8c9c551ce911, []int{0}
190 func (m *GrpcLogEntry) XXX_Unmarshal(b []byte) error {
191 return xxx_messageInfo_GrpcLogEntry.Unmarshal(m, b)
193 func (m *GrpcLogEntry) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
194 return xxx_messageInfo_GrpcLogEntry.Marshal(b, m, deterministic)
196 func (dst *GrpcLogEntry) XXX_Merge(src proto.Message) {
197 xxx_messageInfo_GrpcLogEntry.Merge(dst, src)
199 func (m *GrpcLogEntry) XXX_Size() int {
200 return xxx_messageInfo_GrpcLogEntry.Size(m)
202 func (m *GrpcLogEntry) XXX_DiscardUnknown() {
203 xxx_messageInfo_GrpcLogEntry.DiscardUnknown(m)
206 var xxx_messageInfo_GrpcLogEntry proto.InternalMessageInfo
208 func (m *GrpcLogEntry) GetTimestamp() *timestamp.Timestamp {
215 func (m *GrpcLogEntry) GetCallId() uint64 {
222 func (m *GrpcLogEntry) GetSequenceIdWithinCall() uint64 {
224 return m.SequenceIdWithinCall
229 func (m *GrpcLogEntry) GetType() GrpcLogEntry_EventType {
233 return GrpcLogEntry_EVENT_TYPE_UNKNOWN
236 func (m *GrpcLogEntry) GetLogger() GrpcLogEntry_Logger {
240 return GrpcLogEntry_LOGGER_UNKNOWN
243 type isGrpcLogEntry_Payload interface {
244 isGrpcLogEntry_Payload()
247 type GrpcLogEntry_ClientHeader struct {
248 ClientHeader *ClientHeader `protobuf:"bytes,6,opt,name=client_header,json=clientHeader,proto3,oneof"`
251 type GrpcLogEntry_ServerHeader struct {
252 ServerHeader *ServerHeader `protobuf:"bytes,7,opt,name=server_header,json=serverHeader,proto3,oneof"`
255 type GrpcLogEntry_Message struct {
256 Message *Message `protobuf:"bytes,8,opt,name=message,proto3,oneof"`
259 type GrpcLogEntry_Trailer struct {
260 Trailer *Trailer `protobuf:"bytes,9,opt,name=trailer,proto3,oneof"`
263 func (*GrpcLogEntry_ClientHeader) isGrpcLogEntry_Payload() {}
265 func (*GrpcLogEntry_ServerHeader) isGrpcLogEntry_Payload() {}
267 func (*GrpcLogEntry_Message) isGrpcLogEntry_Payload() {}
269 func (*GrpcLogEntry_Trailer) isGrpcLogEntry_Payload() {}
271 func (m *GrpcLogEntry) GetPayload() isGrpcLogEntry_Payload {
278 func (m *GrpcLogEntry) GetClientHeader() *ClientHeader {
279 if x, ok := m.GetPayload().(*GrpcLogEntry_ClientHeader); ok {
280 return x.ClientHeader
285 func (m *GrpcLogEntry) GetServerHeader() *ServerHeader {
286 if x, ok := m.GetPayload().(*GrpcLogEntry_ServerHeader); ok {
287 return x.ServerHeader
292 func (m *GrpcLogEntry) GetMessage() *Message {
293 if x, ok := m.GetPayload().(*GrpcLogEntry_Message); ok {
299 func (m *GrpcLogEntry) GetTrailer() *Trailer {
300 if x, ok := m.GetPayload().(*GrpcLogEntry_Trailer); ok {
306 func (m *GrpcLogEntry) GetPayloadTruncated() bool {
308 return m.PayloadTruncated
313 func (m *GrpcLogEntry) GetPeer() *Address {
320 // XXX_OneofFuncs is for the internal use of the proto package.
321 func (*GrpcLogEntry) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{}) {
322 return _GrpcLogEntry_OneofMarshaler, _GrpcLogEntry_OneofUnmarshaler, _GrpcLogEntry_OneofSizer, []interface{}{
323 (*GrpcLogEntry_ClientHeader)(nil),
324 (*GrpcLogEntry_ServerHeader)(nil),
325 (*GrpcLogEntry_Message)(nil),
326 (*GrpcLogEntry_Trailer)(nil),
330 func _GrpcLogEntry_OneofMarshaler(msg proto.Message, b *proto.Buffer) error {
331 m := msg.(*GrpcLogEntry)
333 switch x := m.Payload.(type) {
334 case *GrpcLogEntry_ClientHeader:
335 b.EncodeVarint(6<<3 | proto.WireBytes)
336 if err := b.EncodeMessage(x.ClientHeader); err != nil {
339 case *GrpcLogEntry_ServerHeader:
340 b.EncodeVarint(7<<3 | proto.WireBytes)
341 if err := b.EncodeMessage(x.ServerHeader); err != nil {
344 case *GrpcLogEntry_Message:
345 b.EncodeVarint(8<<3 | proto.WireBytes)
346 if err := b.EncodeMessage(x.Message); err != nil {
349 case *GrpcLogEntry_Trailer:
350 b.EncodeVarint(9<<3 | proto.WireBytes)
351 if err := b.EncodeMessage(x.Trailer); err != nil {
356 return fmt.Errorf("GrpcLogEntry.Payload has unexpected type %T", x)
361 func _GrpcLogEntry_OneofUnmarshaler(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error) {
362 m := msg.(*GrpcLogEntry)
364 case 6: // payload.client_header
365 if wire != proto.WireBytes {
366 return true, proto.ErrInternalBadWireType
368 msg := new(ClientHeader)
369 err := b.DecodeMessage(msg)
370 m.Payload = &GrpcLogEntry_ClientHeader{msg}
372 case 7: // payload.server_header
373 if wire != proto.WireBytes {
374 return true, proto.ErrInternalBadWireType
376 msg := new(ServerHeader)
377 err := b.DecodeMessage(msg)
378 m.Payload = &GrpcLogEntry_ServerHeader{msg}
380 case 8: // payload.message
381 if wire != proto.WireBytes {
382 return true, proto.ErrInternalBadWireType
385 err := b.DecodeMessage(msg)
386 m.Payload = &GrpcLogEntry_Message{msg}
388 case 9: // payload.trailer
389 if wire != proto.WireBytes {
390 return true, proto.ErrInternalBadWireType
393 err := b.DecodeMessage(msg)
394 m.Payload = &GrpcLogEntry_Trailer{msg}
401 func _GrpcLogEntry_OneofSizer(msg proto.Message) (n int) {
402 m := msg.(*GrpcLogEntry)
404 switch x := m.Payload.(type) {
405 case *GrpcLogEntry_ClientHeader:
406 s := proto.Size(x.ClientHeader)
407 n += 1 // tag and wire
408 n += proto.SizeVarint(uint64(s))
410 case *GrpcLogEntry_ServerHeader:
411 s := proto.Size(x.ServerHeader)
412 n += 1 // tag and wire
413 n += proto.SizeVarint(uint64(s))
415 case *GrpcLogEntry_Message:
416 s := proto.Size(x.Message)
417 n += 1 // tag and wire
418 n += proto.SizeVarint(uint64(s))
420 case *GrpcLogEntry_Trailer:
421 s := proto.Size(x.Trailer)
422 n += 1 // tag and wire
423 n += proto.SizeVarint(uint64(s))
427 panic(fmt.Sprintf("proto: unexpected type %T in oneof", x))
432 type ClientHeader struct {
433 // This contains only the metadata from the application.
434 Metadata *Metadata `protobuf:"bytes,1,opt,name=metadata,proto3" json:"metadata,omitempty"`
435 // The name of the RPC method, which looks something like:
436 // /<service>/<method>
437 // Note the leading "/" character.
438 MethodName string `protobuf:"bytes,2,opt,name=method_name,json=methodName,proto3" json:"method_name,omitempty"`
439 // A single process may be used to run multiple virtual
440 // servers with different identities.
441 // The authority is the name of such a server identitiy.
442 // It is typically a portion of the URI in the form of
443 // <host> or <host>:<port> .
444 Authority string `protobuf:"bytes,3,opt,name=authority,proto3" json:"authority,omitempty"`
446 Timeout *duration.Duration `protobuf:"bytes,4,opt,name=timeout,proto3" json:"timeout,omitempty"`
447 XXX_NoUnkeyedLiteral struct{} `json:"-"`
448 XXX_unrecognized []byte `json:"-"`
449 XXX_sizecache int32 `json:"-"`
452 func (m *ClientHeader) Reset() { *m = ClientHeader{} }
453 func (m *ClientHeader) String() string { return proto.CompactTextString(m) }
454 func (*ClientHeader) ProtoMessage() {}
455 func (*ClientHeader) Descriptor() ([]byte, []int) {
456 return fileDescriptor_binarylog_264c8c9c551ce911, []int{1}
458 func (m *ClientHeader) XXX_Unmarshal(b []byte) error {
459 return xxx_messageInfo_ClientHeader.Unmarshal(m, b)
461 func (m *ClientHeader) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
462 return xxx_messageInfo_ClientHeader.Marshal(b, m, deterministic)
464 func (dst *ClientHeader) XXX_Merge(src proto.Message) {
465 xxx_messageInfo_ClientHeader.Merge(dst, src)
467 func (m *ClientHeader) XXX_Size() int {
468 return xxx_messageInfo_ClientHeader.Size(m)
470 func (m *ClientHeader) XXX_DiscardUnknown() {
471 xxx_messageInfo_ClientHeader.DiscardUnknown(m)
474 var xxx_messageInfo_ClientHeader proto.InternalMessageInfo
476 func (m *ClientHeader) GetMetadata() *Metadata {
483 func (m *ClientHeader) GetMethodName() string {
490 func (m *ClientHeader) GetAuthority() string {
497 func (m *ClientHeader) GetTimeout() *duration.Duration {
504 type ServerHeader struct {
505 // This contains only the metadata from the application.
506 Metadata *Metadata `protobuf:"bytes,1,opt,name=metadata,proto3" json:"metadata,omitempty"`
507 XXX_NoUnkeyedLiteral struct{} `json:"-"`
508 XXX_unrecognized []byte `json:"-"`
509 XXX_sizecache int32 `json:"-"`
512 func (m *ServerHeader) Reset() { *m = ServerHeader{} }
513 func (m *ServerHeader) String() string { return proto.CompactTextString(m) }
514 func (*ServerHeader) ProtoMessage() {}
515 func (*ServerHeader) Descriptor() ([]byte, []int) {
516 return fileDescriptor_binarylog_264c8c9c551ce911, []int{2}
518 func (m *ServerHeader) XXX_Unmarshal(b []byte) error {
519 return xxx_messageInfo_ServerHeader.Unmarshal(m, b)
521 func (m *ServerHeader) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
522 return xxx_messageInfo_ServerHeader.Marshal(b, m, deterministic)
524 func (dst *ServerHeader) XXX_Merge(src proto.Message) {
525 xxx_messageInfo_ServerHeader.Merge(dst, src)
527 func (m *ServerHeader) XXX_Size() int {
528 return xxx_messageInfo_ServerHeader.Size(m)
530 func (m *ServerHeader) XXX_DiscardUnknown() {
531 xxx_messageInfo_ServerHeader.DiscardUnknown(m)
534 var xxx_messageInfo_ServerHeader proto.InternalMessageInfo
536 func (m *ServerHeader) GetMetadata() *Metadata {
543 type Trailer struct {
544 // This contains only the metadata from the application.
545 Metadata *Metadata `protobuf:"bytes,1,opt,name=metadata,proto3" json:"metadata,omitempty"`
546 // The gRPC status code.
547 StatusCode uint32 `protobuf:"varint,2,opt,name=status_code,json=statusCode,proto3" json:"status_code,omitempty"`
548 // An original status message before any transport specific
550 StatusMessage string `protobuf:"bytes,3,opt,name=status_message,json=statusMessage,proto3" json:"status_message,omitempty"`
551 // The value of the 'grpc-status-details-bin' metadata key. If
552 // present, this is always an encoded 'google.rpc.Status' message.
553 StatusDetails []byte `protobuf:"bytes,4,opt,name=status_details,json=statusDetails,proto3" json:"status_details,omitempty"`
554 XXX_NoUnkeyedLiteral struct{} `json:"-"`
555 XXX_unrecognized []byte `json:"-"`
556 XXX_sizecache int32 `json:"-"`
559 func (m *Trailer) Reset() { *m = Trailer{} }
560 func (m *Trailer) String() string { return proto.CompactTextString(m) }
561 func (*Trailer) ProtoMessage() {}
562 func (*Trailer) Descriptor() ([]byte, []int) {
563 return fileDescriptor_binarylog_264c8c9c551ce911, []int{3}
565 func (m *Trailer) XXX_Unmarshal(b []byte) error {
566 return xxx_messageInfo_Trailer.Unmarshal(m, b)
568 func (m *Trailer) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
569 return xxx_messageInfo_Trailer.Marshal(b, m, deterministic)
571 func (dst *Trailer) XXX_Merge(src proto.Message) {
572 xxx_messageInfo_Trailer.Merge(dst, src)
574 func (m *Trailer) XXX_Size() int {
575 return xxx_messageInfo_Trailer.Size(m)
577 func (m *Trailer) XXX_DiscardUnknown() {
578 xxx_messageInfo_Trailer.DiscardUnknown(m)
581 var xxx_messageInfo_Trailer proto.InternalMessageInfo
583 func (m *Trailer) GetMetadata() *Metadata {
590 func (m *Trailer) GetStatusCode() uint32 {
597 func (m *Trailer) GetStatusMessage() string {
599 return m.StatusMessage
604 func (m *Trailer) GetStatusDetails() []byte {
606 return m.StatusDetails
611 // Message payload, used by CLIENT_MESSAGE and SERVER_MESSAGE
612 type Message struct {
613 // Length of the message. It may not be the same as the length of the
614 // data field, as the logging payload can be truncated or omitted.
615 Length uint32 `protobuf:"varint,1,opt,name=length,proto3" json:"length,omitempty"`
616 // May be truncated or omitted.
617 Data []byte `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"`
618 XXX_NoUnkeyedLiteral struct{} `json:"-"`
619 XXX_unrecognized []byte `json:"-"`
620 XXX_sizecache int32 `json:"-"`
623 func (m *Message) Reset() { *m = Message{} }
624 func (m *Message) String() string { return proto.CompactTextString(m) }
625 func (*Message) ProtoMessage() {}
626 func (*Message) Descriptor() ([]byte, []int) {
627 return fileDescriptor_binarylog_264c8c9c551ce911, []int{4}
629 func (m *Message) XXX_Unmarshal(b []byte) error {
630 return xxx_messageInfo_Message.Unmarshal(m, b)
632 func (m *Message) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
633 return xxx_messageInfo_Message.Marshal(b, m, deterministic)
635 func (dst *Message) XXX_Merge(src proto.Message) {
636 xxx_messageInfo_Message.Merge(dst, src)
638 func (m *Message) XXX_Size() int {
639 return xxx_messageInfo_Message.Size(m)
641 func (m *Message) XXX_DiscardUnknown() {
642 xxx_messageInfo_Message.DiscardUnknown(m)
645 var xxx_messageInfo_Message proto.InternalMessageInfo
647 func (m *Message) GetLength() uint32 {
654 func (m *Message) GetData() []byte {
661 // A list of metadata pairs, used in the payload of client header,
662 // server header, and server trailer.
663 // Implementations may omit some entries to honor the header limits
664 // of GRPC_BINARY_LOG_CONFIG.
666 // Header keys added by gRPC are omitted. To be more specific,
667 // implementations will not log the following entries, and this is
668 // not to be treated as a truncation:
669 // - entries handled by grpc that are not user visible, such as those
670 // that begin with 'grpc-' (with exception of grpc-trace-bin)
671 // or keys like 'lb-token'
672 // - transport specific entries, including but not limited to:
673 // ':path', ':authority', 'content-encoding', 'user-agent', 'te', etc
674 // - entries added for call credentials
676 // Implementations must always log grpc-trace-bin if it is present.
677 // Practically speaking it will only be visible on server side because
678 // grpc-trace-bin is managed by low level client side mechanisms
679 // inaccessible from the application level. On server side, the
680 // header is just a normal metadata key.
681 // The pair will not count towards the size limit.
682 type Metadata struct {
683 Entry []*MetadataEntry `protobuf:"bytes,1,rep,name=entry,proto3" json:"entry,omitempty"`
684 XXX_NoUnkeyedLiteral struct{} `json:"-"`
685 XXX_unrecognized []byte `json:"-"`
686 XXX_sizecache int32 `json:"-"`
689 func (m *Metadata) Reset() { *m = Metadata{} }
690 func (m *Metadata) String() string { return proto.CompactTextString(m) }
691 func (*Metadata) ProtoMessage() {}
692 func (*Metadata) Descriptor() ([]byte, []int) {
693 return fileDescriptor_binarylog_264c8c9c551ce911, []int{5}
695 func (m *Metadata) XXX_Unmarshal(b []byte) error {
696 return xxx_messageInfo_Metadata.Unmarshal(m, b)
698 func (m *Metadata) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
699 return xxx_messageInfo_Metadata.Marshal(b, m, deterministic)
701 func (dst *Metadata) XXX_Merge(src proto.Message) {
702 xxx_messageInfo_Metadata.Merge(dst, src)
704 func (m *Metadata) XXX_Size() int {
705 return xxx_messageInfo_Metadata.Size(m)
707 func (m *Metadata) XXX_DiscardUnknown() {
708 xxx_messageInfo_Metadata.DiscardUnknown(m)
711 var xxx_messageInfo_Metadata proto.InternalMessageInfo
713 func (m *Metadata) GetEntry() []*MetadataEntry {
720 // A metadata key value pair
721 type MetadataEntry struct {
722 Key string `protobuf:"bytes,1,opt,name=key,proto3" json:"key,omitempty"`
723 Value []byte `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
724 XXX_NoUnkeyedLiteral struct{} `json:"-"`
725 XXX_unrecognized []byte `json:"-"`
726 XXX_sizecache int32 `json:"-"`
729 func (m *MetadataEntry) Reset() { *m = MetadataEntry{} }
730 func (m *MetadataEntry) String() string { return proto.CompactTextString(m) }
731 func (*MetadataEntry) ProtoMessage() {}
732 func (*MetadataEntry) Descriptor() ([]byte, []int) {
733 return fileDescriptor_binarylog_264c8c9c551ce911, []int{6}
735 func (m *MetadataEntry) XXX_Unmarshal(b []byte) error {
736 return xxx_messageInfo_MetadataEntry.Unmarshal(m, b)
738 func (m *MetadataEntry) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
739 return xxx_messageInfo_MetadataEntry.Marshal(b, m, deterministic)
741 func (dst *MetadataEntry) XXX_Merge(src proto.Message) {
742 xxx_messageInfo_MetadataEntry.Merge(dst, src)
744 func (m *MetadataEntry) XXX_Size() int {
745 return xxx_messageInfo_MetadataEntry.Size(m)
747 func (m *MetadataEntry) XXX_DiscardUnknown() {
748 xxx_messageInfo_MetadataEntry.DiscardUnknown(m)
751 var xxx_messageInfo_MetadataEntry proto.InternalMessageInfo
753 func (m *MetadataEntry) GetKey() string {
760 func (m *MetadataEntry) GetValue() []byte {
767 // Address information
768 type Address struct {
769 Type Address_Type `protobuf:"varint,1,opt,name=type,proto3,enum=grpc.binarylog.v1.Address_Type" json:"type,omitempty"`
770 Address string `protobuf:"bytes,2,opt,name=address,proto3" json:"address,omitempty"`
771 // only for TYPE_IPV4 and TYPE_IPV6
772 IpPort uint32 `protobuf:"varint,3,opt,name=ip_port,json=ipPort,proto3" json:"ip_port,omitempty"`
773 XXX_NoUnkeyedLiteral struct{} `json:"-"`
774 XXX_unrecognized []byte `json:"-"`
775 XXX_sizecache int32 `json:"-"`
778 func (m *Address) Reset() { *m = Address{} }
779 func (m *Address) String() string { return proto.CompactTextString(m) }
780 func (*Address) ProtoMessage() {}
781 func (*Address) Descriptor() ([]byte, []int) {
782 return fileDescriptor_binarylog_264c8c9c551ce911, []int{7}
784 func (m *Address) XXX_Unmarshal(b []byte) error {
785 return xxx_messageInfo_Address.Unmarshal(m, b)
787 func (m *Address) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
788 return xxx_messageInfo_Address.Marshal(b, m, deterministic)
790 func (dst *Address) XXX_Merge(src proto.Message) {
791 xxx_messageInfo_Address.Merge(dst, src)
793 func (m *Address) XXX_Size() int {
794 return xxx_messageInfo_Address.Size(m)
796 func (m *Address) XXX_DiscardUnknown() {
797 xxx_messageInfo_Address.DiscardUnknown(m)
800 var xxx_messageInfo_Address proto.InternalMessageInfo
802 func (m *Address) GetType() Address_Type {
806 return Address_TYPE_UNKNOWN
809 func (m *Address) GetAddress() string {
816 func (m *Address) GetIpPort() uint32 {
824 proto.RegisterType((*GrpcLogEntry)(nil), "grpc.binarylog.v1.GrpcLogEntry")
825 proto.RegisterType((*ClientHeader)(nil), "grpc.binarylog.v1.ClientHeader")
826 proto.RegisterType((*ServerHeader)(nil), "grpc.binarylog.v1.ServerHeader")
827 proto.RegisterType((*Trailer)(nil), "grpc.binarylog.v1.Trailer")
828 proto.RegisterType((*Message)(nil), "grpc.binarylog.v1.Message")
829 proto.RegisterType((*Metadata)(nil), "grpc.binarylog.v1.Metadata")
830 proto.RegisterType((*MetadataEntry)(nil), "grpc.binarylog.v1.MetadataEntry")
831 proto.RegisterType((*Address)(nil), "grpc.binarylog.v1.Address")
832 proto.RegisterEnum("grpc.binarylog.v1.GrpcLogEntry_EventType", GrpcLogEntry_EventType_name, GrpcLogEntry_EventType_value)
833 proto.RegisterEnum("grpc.binarylog.v1.GrpcLogEntry_Logger", GrpcLogEntry_Logger_name, GrpcLogEntry_Logger_value)
834 proto.RegisterEnum("grpc.binarylog.v1.Address_Type", Address_Type_name, Address_Type_value)
838 proto.RegisterFile("grpc/binarylog/grpc_binarylog_v1/binarylog.proto", fileDescriptor_binarylog_264c8c9c551ce911)
841 var fileDescriptor_binarylog_264c8c9c551ce911 = []byte{
842 // 900 bytes of a gzipped FileDescriptorProto
843 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xa4, 0x55, 0x51, 0x6f, 0xe3, 0x44,
844 0x10, 0x3e, 0x37, 0x69, 0xdc, 0x4c, 0x92, 0xca, 0x5d, 0x95, 0x3b, 0x5f, 0x29, 0x34, 0xb2, 0x04,
845 0x0a, 0x42, 0x72, 0xb9, 0x94, 0xeb, 0xf1, 0x02, 0x52, 0x92, 0xfa, 0xd2, 0x88, 0x5c, 0x1a, 0x6d,
846 0x72, 0x3d, 0x40, 0x48, 0xd6, 0x36, 0x5e, 0x1c, 0x0b, 0xc7, 0x6b, 0xd6, 0x9b, 0xa0, 0xfc, 0x2c,
847 0xde, 0x90, 0xee, 0x77, 0xf1, 0x8e, 0xbc, 0x6b, 0x27, 0xa6, 0x69, 0x0f, 0x09, 0xde, 0x3c, 0xdf,
848 0x7c, 0xf3, 0xcd, 0xee, 0x78, 0x66, 0x16, 0xbe, 0xf2, 0x79, 0x3c, 0x3b, 0xbf, 0x0b, 0x22, 0xc2,
849 0xd7, 0x21, 0xf3, 0xcf, 0x53, 0xd3, 0xdd, 0x98, 0xee, 0xea, 0xc5, 0xd6, 0x67, 0xc7, 0x9c, 0x09,
850 0x86, 0x8e, 0x52, 0x8a, 0xbd, 0x45, 0x57, 0x2f, 0x4e, 0x3e, 0xf5, 0x19, 0xf3, 0x43, 0x7a, 0x2e,
851 0x09, 0x77, 0xcb, 0x5f, 0xce, 0xbd, 0x25, 0x27, 0x22, 0x60, 0x91, 0x0a, 0x39, 0x39, 0xbb, 0xef,
852 0x17, 0xc1, 0x82, 0x26, 0x82, 0x2c, 0x62, 0x45, 0xb0, 0xde, 0xeb, 0x50, 0xef, 0xf3, 0x78, 0x36,
853 0x64, 0xbe, 0x13, 0x09, 0xbe, 0x46, 0xdf, 0x40, 0x75, 0xc3, 0x31, 0xb5, 0xa6, 0xd6, 0xaa, 0xb5,
854 0x4f, 0x6c, 0xa5, 0x62, 0xe7, 0x2a, 0xf6, 0x34, 0x67, 0xe0, 0x2d, 0x19, 0x3d, 0x03, 0x7d, 0x46,
855 0xc2, 0xd0, 0x0d, 0x3c, 0x73, 0xaf, 0xa9, 0xb5, 0xca, 0xb8, 0x92, 0x9a, 0x03, 0x0f, 0xbd, 0x84,
856 0x67, 0x09, 0xfd, 0x6d, 0x49, 0xa3, 0x19, 0x75, 0x03, 0xcf, 0xfd, 0x3d, 0x10, 0xf3, 0x20, 0x72,
857 0x53, 0xa7, 0x59, 0x92, 0xc4, 0xe3, 0xdc, 0x3d, 0xf0, 0xde, 0x49, 0x67, 0x8f, 0x84, 0x21, 0xfa,
858 0x16, 0xca, 0x62, 0x1d, 0x53, 0xb3, 0xdc, 0xd4, 0x5a, 0x87, 0xed, 0x2f, 0xec, 0x9d, 0xdb, 0xdb,
859 0xc5, 0x83, 0xdb, 0xce, 0x8a, 0x46, 0x62, 0xba, 0x8e, 0x29, 0x96, 0x61, 0xe8, 0x3b, 0xa8, 0x84,
860 0xcc, 0xf7, 0x29, 0x37, 0xf7, 0xa5, 0xc0, 0xe7, 0xff, 0x26, 0x30, 0x94, 0x6c, 0x9c, 0x45, 0xa1,
861 0xd7, 0xd0, 0x98, 0x85, 0x01, 0x8d, 0x84, 0x3b, 0xa7, 0xc4, 0xa3, 0xdc, 0xac, 0xc8, 0x62, 0x9c,
862 0x3d, 0x20, 0xd3, 0x93, 0xbc, 0x6b, 0x49, 0xbb, 0x7e, 0x82, 0xeb, 0xb3, 0x82, 0x9d, 0xea, 0x24,
863 0x94, 0xaf, 0x28, 0xcf, 0x75, 0xf4, 0x47, 0x75, 0x26, 0x92, 0xb7, 0xd5, 0x49, 0x0a, 0x36, 0xba,
864 0x04, 0x7d, 0x41, 0x93, 0x84, 0xf8, 0xd4, 0x3c, 0xc8, 0x7f, 0xcb, 0x8e, 0xc2, 0x1b, 0xc5, 0xb8,
865 0x7e, 0x82, 0x73, 0x72, 0x1a, 0x27, 0x38, 0x09, 0x42, 0xca, 0xcd, 0xea, 0xa3, 0x71, 0x53, 0xc5,
866 0x48, 0xe3, 0x32, 0x32, 0xfa, 0x12, 0x8e, 0x62, 0xb2, 0x0e, 0x19, 0xf1, 0x5c, 0xc1, 0x97, 0xd1,
867 0x8c, 0x08, 0xea, 0x99, 0xd0, 0xd4, 0x5a, 0x07, 0xd8, 0xc8, 0x1c, 0xd3, 0x1c, 0x47, 0x36, 0x94,
868 0x63, 0x4a, 0xb9, 0x59, 0x7b, 0x34, 0x43, 0xc7, 0xf3, 0x38, 0x4d, 0x12, 0x2c, 0x79, 0xd6, 0x5f,
869 0x1a, 0x54, 0x37, 0x3f, 0x0c, 0x3d, 0x05, 0xe4, 0xdc, 0x3a, 0xa3, 0xa9, 0x3b, 0xfd, 0x71, 0xec,
870 0xb8, 0x6f, 0x47, 0xdf, 0x8f, 0x6e, 0xde, 0x8d, 0x8c, 0x27, 0xe8, 0x14, 0xcc, 0x02, 0xde, 0x1b,
871 0x0e, 0xd2, 0xef, 0x6b, 0xa7, 0x73, 0xe5, 0x60, 0x43, 0xbb, 0xe7, 0x9d, 0x38, 0xf8, 0xd6, 0xc1,
872 0xb9, 0x77, 0x0f, 0x7d, 0x02, 0xcf, 0x77, 0x63, 0xdf, 0x38, 0x93, 0x49, 0xa7, 0xef, 0x18, 0xa5,
873 0x7b, 0xee, 0x2c, 0x38, 0x77, 0x97, 0x51, 0x13, 0x4e, 0x1f, 0xc8, 0xdc, 0x19, 0xbe, 0x76, 0x7b,
874 0xc3, 0x9b, 0x89, 0x63, 0xec, 0x3f, 0x2c, 0x30, 0xc5, 0x9d, 0xc1, 0xd0, 0xc1, 0x46, 0x05, 0x7d,
875 0x04, 0x47, 0x45, 0x81, 0xce, 0xa8, 0xe7, 0x0c, 0x0d, 0xdd, 0xea, 0x42, 0x45, 0xb5, 0x19, 0x42,
876 0x70, 0x38, 0xbc, 0xe9, 0xf7, 0x1d, 0x5c, 0xb8, 0xef, 0x11, 0x34, 0x32, 0x4c, 0x65, 0x34, 0xb4,
877 0x02, 0xa4, 0x52, 0x18, 0x7b, 0xdd, 0x2a, 0xe8, 0x59, 0xfd, 0xad, 0xf7, 0x1a, 0xd4, 0x8b, 0xcd,
878 0x87, 0x5e, 0xc1, 0xc1, 0x82, 0x0a, 0xe2, 0x11, 0x41, 0xb2, 0xe1, 0xfd, 0xf8, 0xc1, 0x2e, 0x51,
879 0x14, 0xbc, 0x21, 0xa3, 0x33, 0xa8, 0x2d, 0xa8, 0x98, 0x33, 0xcf, 0x8d, 0xc8, 0x82, 0xca, 0x01,
880 0xae, 0x62, 0x50, 0xd0, 0x88, 0x2c, 0x28, 0x3a, 0x85, 0x2a, 0x59, 0x8a, 0x39, 0xe3, 0x81, 0x58,
881 0xcb, 0xb1, 0xad, 0xe2, 0x2d, 0x80, 0x2e, 0x40, 0x4f, 0x17, 0x01, 0x5b, 0x0a, 0x39, 0xae, 0xb5,
882 0xf6, 0xf3, 0x9d, 0x9d, 0x71, 0x95, 0x6d, 0x26, 0x9c, 0x33, 0xad, 0x3e, 0xd4, 0x8b, 0x1d, 0xff,
883 0x9f, 0x0f, 0x6f, 0xfd, 0xa1, 0x81, 0x9e, 0x75, 0xf0, 0xff, 0xaa, 0x40, 0x22, 0x88, 0x58, 0x26,
884 0xee, 0x8c, 0x79, 0xaa, 0x02, 0x0d, 0x0c, 0x0a, 0xea, 0x31, 0x8f, 0xa2, 0xcf, 0xe0, 0x30, 0x23,
885 0xe4, 0x73, 0xa8, 0xca, 0xd0, 0x50, 0x68, 0x36, 0x7a, 0x05, 0x9a, 0x47, 0x05, 0x09, 0xc2, 0x44,
886 0x56, 0xa4, 0x9e, 0xd3, 0xae, 0x14, 0x68, 0xbd, 0x04, 0x3d, 0x8f, 0x78, 0x0a, 0x95, 0x90, 0x46,
887 0xbe, 0x98, 0xcb, 0x03, 0x37, 0x70, 0x66, 0x21, 0x04, 0x65, 0x79, 0x8d, 0x3d, 0x19, 0x2f, 0xbf,
888 0xad, 0x2e, 0x1c, 0xe4, 0x67, 0x47, 0x97, 0xb0, 0x4f, 0xd3, 0xcd, 0x65, 0x6a, 0xcd, 0x52, 0xab,
889 0xd6, 0x6e, 0x7e, 0xe0, 0x9e, 0x72, 0xc3, 0x61, 0x45, 0xb7, 0x5e, 0x41, 0xe3, 0x1f, 0x38, 0x32,
890 0xa0, 0xf4, 0x2b, 0x5d, 0xcb, 0xec, 0x55, 0x9c, 0x7e, 0xa2, 0x63, 0xd8, 0x5f, 0x91, 0x70, 0x49,
891 0xb3, 0xdc, 0xca, 0xb0, 0xfe, 0xd4, 0x40, 0xcf, 0xe6, 0x18, 0x5d, 0x64, 0xdb, 0x59, 0x93, 0xcb,
892 0xf5, 0xec, 0xf1, 0x89, 0xb7, 0x0b, 0x3b, 0xd9, 0x04, 0x9d, 0x28, 0x34, 0xeb, 0xb0, 0xdc, 0x4c,
893 0x1f, 0x8f, 0x20, 0x76, 0x63, 0xc6, 0x85, 0xac, 0x6a, 0x03, 0x57, 0x82, 0x78, 0xcc, 0xb8, 0xb0,
894 0x1c, 0x28, 0xcb, 0x1d, 0x61, 0x40, 0xfd, 0xde, 0x76, 0x68, 0x40, 0x55, 0x22, 0x83, 0xf1, 0xed,
895 0xd7, 0x86, 0x56, 0x34, 0x2f, 0x8d, 0xbd, 0x8d, 0xf9, 0x76, 0x34, 0xf8, 0xc1, 0x28, 0x75, 0x7f,
896 0x86, 0xe3, 0x80, 0xed, 0x1e, 0xb2, 0x7b, 0xd8, 0x95, 0xd6, 0x90, 0xf9, 0xe3, 0xb4, 0x51, 0xc7,
897 0xda, 0x4f, 0xed, 0xac, 0x71, 0x7d, 0x16, 0x92, 0xc8, 0xb7, 0x19, 0x57, 0x4f, 0xf3, 0x87, 0x5e,
898 0xea, 0xbb, 0x8a, 0xec, 0xf2, 0x8b, 0xbf, 0x03, 0x00, 0x00, 0xff, 0xff, 0xe7, 0xf6, 0x4b, 0x50,
899 0xd4, 0x07, 0x00, 0x00,