blob: 3c3f28a5fc29b35ac970bfdef0327329d491b36d [file] [log] [blame]
// Code generated by protoc-gen-go.
// source:
Package v2 is a generated protocol buffer package.
It is generated from these files:
It has these top-level messages:
package v2
import proto ""
import fmt "fmt"
import math "math"
import _ ""
import google_api3 ""
import google_logging_type ""
import google_logging_type1 ""
import google_protobuf2 ""
import google_protobuf3 ""
import google_protobuf4 ""
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
// An individual entry in a log.
type LogEntry struct {
// Required. The resource name of the log to which this log entry
// belongs. The format of the name is
// `"projects/<project-id>/logs/<log-id>"`. Examples:
// `"projects/my-projectid/logs/syslog"`,
// `"projects/my-projectid/logs/"`.
// The log ID part of resource name must be less than 512 characters
// long and can only include the following characters: upper and
// lower case alphanumeric characters: [A-Za-z0-9]; and punctuation
// characters: forward-slash, underscore, hyphen, and period.
// Forward-slash (`/`) characters in the log ID must be URL-encoded.
LogName string `protobuf:"bytes,12,opt,name=log_name,json=logName" json:"log_name,omitempty"`
// Required. The monitored resource associated with this log entry.
// Example: a log entry that reports a database error would be
// associated with the monitored resource designating the particular
// database that reported the error.
Resource *google_api3.MonitoredResource `protobuf:"bytes,8,opt,name=resource" json:"resource,omitempty"`
// Optional. The log entry payload, which can be one of multiple types.
// Types that are valid to be assigned to Payload:
// *LogEntry_ProtoPayload
// *LogEntry_TextPayload
// *LogEntry_JsonPayload
Payload isLogEntry_Payload `protobuf_oneof:"payload"`
// Optional. The time the event described by the log entry occurred. If
// omitted, Stackdriver Logging will use the time the log entry is received.
Timestamp *google_protobuf4.Timestamp `protobuf:"bytes,9,opt,name=timestamp" json:"timestamp,omitempty"`
// Optional. The severity of the log entry. The default value is
// `LogSeverity.DEFAULT`.
Severity google_logging_type1.LogSeverity `protobuf:"varint,10,opt,name=severity,enum=google.logging.type.LogSeverity" json:"severity,omitempty"`
// Optional. A unique ID for the log entry. If you provide this
// field, the logging service considers other log entries in the
// same project with the same ID as duplicates which can be removed. If
// omitted, Stackdriver Logging will generate a unique ID for this
// log entry.
InsertId string `protobuf:"bytes,4,opt,name=insert_id,json=insertId" json:"insert_id,omitempty"`
// Optional. Information about the HTTP request associated with this
// log entry, if applicable.
HttpRequest *google_logging_type.HttpRequest `protobuf:"bytes,7,opt,name=http_request,json=httpRequest" json:"http_request,omitempty"`
// Optional. A set of user-defined (key, value) data that provides additional
// information about the log entry.
Labels map[string]string `protobuf:"bytes,11,rep,name=labels" json:"labels,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"`
// Optional. Information about an operation associated with the log entry, if
// applicable.
Operation *LogEntryOperation `protobuf:"bytes,15,opt,name=operation" json:"operation,omitempty"`
func (m *LogEntry) Reset() { *m = LogEntry{} }
func (m *LogEntry) String() string { return proto.CompactTextString(m) }
func (*LogEntry) ProtoMessage() {}
func (*LogEntry) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
type isLogEntry_Payload interface {
type LogEntry_ProtoPayload struct {
ProtoPayload *google_protobuf2.Any `protobuf:"bytes,2,opt,name=proto_payload,json=protoPayload,oneof"`
type LogEntry_TextPayload struct {
TextPayload string `protobuf:"bytes,3,opt,name=text_payload,json=textPayload,oneof"`
type LogEntry_JsonPayload struct {
JsonPayload *google_protobuf3.Struct `protobuf:"bytes,6,opt,name=json_payload,json=jsonPayload,oneof"`
func (*LogEntry_ProtoPayload) isLogEntry_Payload() {}
func (*LogEntry_TextPayload) isLogEntry_Payload() {}
func (*LogEntry_JsonPayload) isLogEntry_Payload() {}
func (m *LogEntry) GetPayload() isLogEntry_Payload {
if m != nil {
return m.Payload
return nil
func (m *LogEntry) GetResource() *google_api3.MonitoredResource {
if m != nil {
return m.Resource
return nil
func (m *LogEntry) GetProtoPayload() *google_protobuf2.Any {
if x, ok := m.GetPayload().(*LogEntry_ProtoPayload); ok {
return x.ProtoPayload
return nil
func (m *LogEntry) GetTextPayload() string {
if x, ok := m.GetPayload().(*LogEntry_TextPayload); ok {
return x.TextPayload
return ""
func (m *LogEntry) GetJsonPayload() *google_protobuf3.Struct {
if x, ok := m.GetPayload().(*LogEntry_JsonPayload); ok {
return x.JsonPayload
return nil
func (m *LogEntry) GetTimestamp() *google_protobuf4.Timestamp {
if m != nil {
return m.Timestamp
return nil
func (m *LogEntry) GetHttpRequest() *google_logging_type.HttpRequest {
if m != nil {
return m.HttpRequest
return nil
func (m *LogEntry) GetLabels() map[string]string {
if m != nil {
return m.Labels
return nil
func (m *LogEntry) GetOperation() *LogEntryOperation {
if m != nil {
return m.Operation
return nil
// XXX_OneofFuncs is for the internal use of the proto package.
func (*LogEntry) 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{}) {
return _LogEntry_OneofMarshaler, _LogEntry_OneofUnmarshaler, _LogEntry_OneofSizer, []interface{}{
func _LogEntry_OneofMarshaler(msg proto.Message, b *proto.Buffer) error {
m := msg.(*LogEntry)
// payload
switch x := m.Payload.(type) {
case *LogEntry_ProtoPayload:
b.EncodeVarint(2<<3 | proto.WireBytes)
if err := b.EncodeMessage(x.ProtoPayload); err != nil {
return err
case *LogEntry_TextPayload:
b.EncodeVarint(3<<3 | proto.WireBytes)
case *LogEntry_JsonPayload:
b.EncodeVarint(6<<3 | proto.WireBytes)
if err := b.EncodeMessage(x.JsonPayload); err != nil {
return err
case nil:
return fmt.Errorf("LogEntry.Payload has unexpected type %T", x)
return nil
func _LogEntry_OneofUnmarshaler(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error) {
m := msg.(*LogEntry)
switch tag {
case 2: // payload.proto_payload
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
msg := new(google_protobuf2.Any)
err := b.DecodeMessage(msg)
m.Payload = &LogEntry_ProtoPayload{msg}
return true, err
case 3: // payload.text_payload
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
x, err := b.DecodeStringBytes()
m.Payload = &LogEntry_TextPayload{x}
return true, err
case 6: // payload.json_payload
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
msg := new(google_protobuf3.Struct)
err := b.DecodeMessage(msg)
m.Payload = &LogEntry_JsonPayload{msg}
return true, err
return false, nil
func _LogEntry_OneofSizer(msg proto.Message) (n int) {
m := msg.(*LogEntry)
// payload
switch x := m.Payload.(type) {
case *LogEntry_ProtoPayload:
s := proto.Size(x.ProtoPayload)
n += proto.SizeVarint(2<<3 | proto.WireBytes)
n += proto.SizeVarint(uint64(s))
n += s
case *LogEntry_TextPayload:
n += proto.SizeVarint(3<<3 | proto.WireBytes)
n += proto.SizeVarint(uint64(len(x.TextPayload)))
n += len(x.TextPayload)
case *LogEntry_JsonPayload:
s := proto.Size(x.JsonPayload)
n += proto.SizeVarint(6<<3 | proto.WireBytes)
n += proto.SizeVarint(uint64(s))
n += s
case nil:
panic(fmt.Sprintf("proto: unexpected type %T in oneof", x))
return n
// Additional information about a potentially long-running operation with which
// a log entry is associated.
type LogEntryOperation struct {
// Optional. An arbitrary operation identifier. Log entries with the
// same identifier are assumed to be part of the same operation.
Id string `protobuf:"bytes,1,opt,name=id" json:"id,omitempty"`
// Optional. An arbitrary producer identifier. The combination of
// `id` and `producer` must be globally unique. Examples for `producer`:
// `""`, `""`.
Producer string `protobuf:"bytes,2,opt,name=producer" json:"producer,omitempty"`
// Optional. Set this to True if this is the first log entry in the operation.
First bool `protobuf:"varint,3,opt,name=first" json:"first,omitempty"`
// Optional. Set this to True if this is the last log entry in the operation.
Last bool `protobuf:"varint,4,opt,name=last" json:"last,omitempty"`
func (m *LogEntryOperation) Reset() { *m = LogEntryOperation{} }
func (m *LogEntryOperation) String() string { return proto.CompactTextString(m) }
func (*LogEntryOperation) ProtoMessage() {}
func (*LogEntryOperation) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
func init() {
proto.RegisterType((*LogEntry)(nil), "google.logging.v2.LogEntry")
proto.RegisterType((*LogEntryOperation)(nil), "google.logging.v2.LogEntryOperation")
func init() {
proto.RegisterFile("", fileDescriptor0)
var fileDescriptor0 = []byte{
// 617 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0xa4, 0x54, 0x5f, 0x6f, 0xd3, 0x3e,
0x14, 0xfd, 0x65, 0xff, 0x9a, 0xb8, 0xdd, 0x7e, 0xcc, 0x1a, 0x22, 0x04, 0x21, 0x55, 0x03, 0x09,
0x9e, 0x1c, 0x54, 0x84, 0xb4, 0x31, 0x24, 0xa0, 0x68, 0xd2, 0x26, 0x0d, 0x36, 0x79, 0x3c, 0x21,
0xa1, 0x2a, 0x4d, 0x5d, 0xd7, 0x90, 0xda, 0xc1, 0x71, 0x2a, 0xf2, 0x81, 0xf8, 0x8e, 0x3c, 0x62,
0x3b, 0x4e, 0x3a, 0x51, 0xc4, 0x36, 0xf1, 0xd0, 0xf6, 0x5e, 0xfb, 0x9c, 0x73, 0x7d, 0xcf, 0xb5,
0x0b, 0xde, 0x50, 0x21, 0x68, 0x46, 0x10, 0x15, 0x59, 0xc2, 0x29, 0x12, 0x92, 0xc6, 0x94, 0xf0,
0x5c, 0x0a, 0x25, 0xe2, 0x7a, 0x2b, 0xc9, 0x59, 0x11, 0x67, 0x82, 0x52, 0xc6, 0x69, 0xbc, 0x18,
0x98, 0x70, 0x44, 0xb8, 0x92, 0x15, 0xb2, 0x28, 0xb8, 0xeb, 0x14, 0x1c, 0x04, 0x2d, 0x06, 0xd1,
0xe9, 0xcd, 0x44, 0xf5, 0x57, 0x5c, 0x10, 0xb9, 0x60, 0x29, 0x49, 0x05, 0x9f, 0x32, 0x1a, 0x27,
0x9c, 0x0b, 0x95, 0x28, 0x26, 0x78, 0x51, 0xab, 0x47, 0xe7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