You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
1014 lines
25 KiB
1014 lines
25 KiB
// Code generated by protoc-gen-gogo. DO NOT EDIT. |
|
// source: app/service/ops/log-agent/output/lancergrpc/lancergateway/StreamEvent.proto |
|
|
|
/* |
|
Package StreamEvent is a generated protocol buffer package. |
|
|
|
It is generated from these files: |
|
app/service/ops/log-agent/output/lancergrpc/lancergateway/StreamEvent.proto |
|
|
|
It has these top-level messages: |
|
SimpleEvent |
|
EventList |
|
Response |
|
*/ |
|
package lancergateway |
|
|
|
import proto "github.com/gogo/protobuf/proto" |
|
import fmt "fmt" |
|
import math "math" |
|
import _ "github.com/gogo/protobuf/gogoproto" |
|
|
|
import context "golang.org/x/net/context" |
|
import grpc "google.golang.org/grpc" |
|
|
|
import io "io" |
|
|
|
// 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.GoGoProtoPackageIsVersion2 // please upgrade the proto package |
|
|
|
type StatusCode int32 |
|
|
|
const ( |
|
StatusCode_NULL StatusCode = 0 |
|
StatusCode_SUCCESS StatusCode = 200 |
|
StatusCode_LOAD_FULL StatusCode = 429 |
|
) |
|
|
|
var StatusCode_name = map[int32]string{ |
|
0: "NULL", |
|
200: "SUCCESS", |
|
429: "LOAD_FULL", |
|
} |
|
var StatusCode_value = map[string]int32{ |
|
"NULL": 0, |
|
"SUCCESS": 200, |
|
"LOAD_FULL": 429, |
|
} |
|
|
|
func (x StatusCode) String() string { |
|
return proto.EnumName(StatusCode_name, int32(x)) |
|
} |
|
func (StatusCode) EnumDescriptor() ([]byte, []int) { return fileDescriptorStreamEvent, []int{0} } |
|
|
|
type SimpleEvent struct { |
|
LogId string `protobuf:"bytes,1,opt,name=logId,proto3" json:"logId,omitempty"` |
|
OuterId string `protobuf:"bytes,2,opt,name=outerId,proto3" json:"outerId,omitempty"` |
|
Header map[string]string `protobuf:"bytes,3,rep,name=header" json:"header,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"` |
|
Data []byte `protobuf:"bytes,4,opt,name=data,proto3" json:"data,omitempty"` |
|
} |
|
|
|
func (m *SimpleEvent) Reset() { *m = SimpleEvent{} } |
|
func (m *SimpleEvent) String() string { return proto.CompactTextString(m) } |
|
func (*SimpleEvent) ProtoMessage() {} |
|
func (*SimpleEvent) Descriptor() ([]byte, []int) { return fileDescriptorStreamEvent, []int{0} } |
|
|
|
func (m *SimpleEvent) GetLogId() string { |
|
if m != nil { |
|
return m.LogId |
|
} |
|
return "" |
|
} |
|
|
|
func (m *SimpleEvent) GetOuterId() string { |
|
if m != nil { |
|
return m.OuterId |
|
} |
|
return "" |
|
} |
|
|
|
func (m *SimpleEvent) GetHeader() map[string]string { |
|
if m != nil { |
|
return m.Header |
|
} |
|
return nil |
|
} |
|
|
|
func (m *SimpleEvent) GetData() []byte { |
|
if m != nil { |
|
return m.Data |
|
} |
|
return nil |
|
} |
|
|
|
type EventList struct { |
|
Events []*SimpleEvent `protobuf:"bytes,1,rep,name=events" json:"events,omitempty"` |
|
} |
|
|
|
func (m *EventList) Reset() { *m = EventList{} } |
|
func (m *EventList) String() string { return proto.CompactTextString(m) } |
|
func (*EventList) ProtoMessage() {} |
|
func (*EventList) Descriptor() ([]byte, []int) { return fileDescriptorStreamEvent, []int{1} } |
|
|
|
func (m *EventList) GetEvents() []*SimpleEvent { |
|
if m != nil { |
|
return m.Events |
|
} |
|
return nil |
|
} |
|
|
|
type Response struct { |
|
Code StatusCode `protobuf:"varint,1,opt,name=code,proto3,enum=StatusCode" json:"code,omitempty"` |
|
Msg string `protobuf:"bytes,2,opt,name=msg,proto3" json:"msg,omitempty"` |
|
} |
|
|
|
func (m *Response) Reset() { *m = Response{} } |
|
func (m *Response) String() string { return proto.CompactTextString(m) } |
|
func (*Response) ProtoMessage() {} |
|
func (*Response) Descriptor() ([]byte, []int) { return fileDescriptorStreamEvent, []int{2} } |
|
|
|
func (m *Response) GetCode() StatusCode { |
|
if m != nil { |
|
return m.Code |
|
} |
|
return StatusCode_NULL |
|
} |
|
|
|
func (m *Response) GetMsg() string { |
|
if m != nil { |
|
return m.Msg |
|
} |
|
return "" |
|
} |
|
|
|
func init() { |
|
proto.RegisterType((*SimpleEvent)(nil), "SimpleEvent") |
|
proto.RegisterType((*EventList)(nil), "EventList") |
|
proto.RegisterType((*Response)(nil), "Response") |
|
proto.RegisterEnum("StatusCode", StatusCode_name, StatusCode_value) |
|
} |
|
|
|
// Reference imports to suppress errors if they are not otherwise used. |
|
var _ context.Context |
|
var _ grpc.ClientConn |
|
|
|
// This is a compile-time assertion to ensure that this generated file |
|
// is compatible with the grpc package it is being compiled against. |
|
const _ = grpc.SupportPackageIsVersion4 |
|
|
|
// Client API for Gateway2Server service |
|
|
|
type Gateway2ServerClient interface { |
|
SendList(ctx context.Context, in *EventList, opts ...grpc.CallOption) (*Response, error) |
|
Send(ctx context.Context, in *SimpleEvent, opts ...grpc.CallOption) (*Response, error) |
|
} |
|
|
|
type gateway2ServerClient struct { |
|
cc *grpc.ClientConn |
|
} |
|
|
|
func NewGateway2ServerClient(cc *grpc.ClientConn) Gateway2ServerClient { |
|
return &gateway2ServerClient{cc} |
|
} |
|
|
|
func (c *gateway2ServerClient) SendList(ctx context.Context, in *EventList, opts ...grpc.CallOption) (*Response, error) { |
|
out := new(Response) |
|
err := grpc.Invoke(ctx, "/Gateway2Server/sendList", in, out, c.cc, opts...) |
|
if err != nil { |
|
return nil, err |
|
} |
|
return out, nil |
|
} |
|
|
|
func (c *gateway2ServerClient) Send(ctx context.Context, in *SimpleEvent, opts ...grpc.CallOption) (*Response, error) { |
|
out := new(Response) |
|
err := grpc.Invoke(ctx, "/Gateway2Server/send", in, out, c.cc, opts...) |
|
if err != nil { |
|
return nil, err |
|
} |
|
return out, nil |
|
} |
|
|
|
// Server API for Gateway2Server service |
|
|
|
type Gateway2ServerServer interface { |
|
SendList(context.Context, *EventList) (*Response, error) |
|
Send(context.Context, *SimpleEvent) (*Response, error) |
|
} |
|
|
|
func RegisterGateway2ServerServer(s *grpc.Server, srv Gateway2ServerServer) { |
|
s.RegisterService(&_Gateway2Server_serviceDesc, srv) |
|
} |
|
|
|
func _Gateway2Server_SendList_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
|
in := new(EventList) |
|
if err := dec(in); err != nil { |
|
return nil, err |
|
} |
|
if interceptor == nil { |
|
return srv.(Gateway2ServerServer).SendList(ctx, in) |
|
} |
|
info := &grpc.UnaryServerInfo{ |
|
Server: srv, |
|
FullMethod: "/Gateway2Server/SendList", |
|
} |
|
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
|
return srv.(Gateway2ServerServer).SendList(ctx, req.(*EventList)) |
|
} |
|
return interceptor(ctx, in, info, handler) |
|
} |
|
|
|
func _Gateway2Server_Send_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { |
|
in := new(SimpleEvent) |
|
if err := dec(in); err != nil { |
|
return nil, err |
|
} |
|
if interceptor == nil { |
|
return srv.(Gateway2ServerServer).Send(ctx, in) |
|
} |
|
info := &grpc.UnaryServerInfo{ |
|
Server: srv, |
|
FullMethod: "/Gateway2Server/Send", |
|
} |
|
handler := func(ctx context.Context, req interface{}) (interface{}, error) { |
|
return srv.(Gateway2ServerServer).Send(ctx, req.(*SimpleEvent)) |
|
} |
|
return interceptor(ctx, in, info, handler) |
|
} |
|
|
|
var _Gateway2Server_serviceDesc = grpc.ServiceDesc{ |
|
ServiceName: "Gateway2Server", |
|
HandlerType: (*Gateway2ServerServer)(nil), |
|
Methods: []grpc.MethodDesc{ |
|
{ |
|
MethodName: "sendList", |
|
Handler: _Gateway2Server_SendList_Handler, |
|
}, |
|
{ |
|
MethodName: "send", |
|
Handler: _Gateway2Server_Send_Handler, |
|
}, |
|
}, |
|
Streams: []grpc.StreamDesc{}, |
|
Metadata: "app/service/ops/log-agent/output/lancergrpc/lancergateway/StreamEvent.proto", |
|
} |
|
|
|
func (m *SimpleEvent) Marshal() (dAtA []byte, err error) { |
|
size := m.Size() |
|
dAtA = make([]byte, size) |
|
n, err := m.MarshalTo(dAtA) |
|
if err != nil { |
|
return nil, err |
|
} |
|
return dAtA[:n], nil |
|
} |
|
|
|
func (m *SimpleEvent) MarshalTo(dAtA []byte) (int, error) { |
|
var i int |
|
_ = i |
|
var l int |
|
_ = l |
|
if len(m.LogId) > 0 { |
|
dAtA[i] = 0xa |
|
i++ |
|
i = encodeVarintStreamEvent(dAtA, i, uint64(len(m.LogId))) |
|
i += copy(dAtA[i:], m.LogId) |
|
} |
|
if len(m.OuterId) > 0 { |
|
dAtA[i] = 0x12 |
|
i++ |
|
i = encodeVarintStreamEvent(dAtA, i, uint64(len(m.OuterId))) |
|
i += copy(dAtA[i:], m.OuterId) |
|
} |
|
if len(m.Header) > 0 { |
|
for k, _ := range m.Header { |
|
dAtA[i] = 0x1a |
|
i++ |
|
v := m.Header[k] |
|
mapSize := 1 + len(k) + sovStreamEvent(uint64(len(k))) + 1 + len(v) + sovStreamEvent(uint64(len(v))) |
|
i = encodeVarintStreamEvent(dAtA, i, uint64(mapSize)) |
|
dAtA[i] = 0xa |
|
i++ |
|
i = encodeVarintStreamEvent(dAtA, i, uint64(len(k))) |
|
i += copy(dAtA[i:], k) |
|
dAtA[i] = 0x12 |
|
i++ |
|
i = encodeVarintStreamEvent(dAtA, i, uint64(len(v))) |
|
i += copy(dAtA[i:], v) |
|
} |
|
} |
|
if len(m.Data) > 0 { |
|
dAtA[i] = 0x22 |
|
i++ |
|
i = encodeVarintStreamEvent(dAtA, i, uint64(len(m.Data))) |
|
i += copy(dAtA[i:], m.Data) |
|
} |
|
return i, nil |
|
} |
|
|
|
func (m *EventList) Marshal() (dAtA []byte, err error) { |
|
size := m.Size() |
|
dAtA = make([]byte, size) |
|
n, err := m.MarshalTo(dAtA) |
|
if err != nil { |
|
return nil, err |
|
} |
|
return dAtA[:n], nil |
|
} |
|
|
|
func (m *EventList) MarshalTo(dAtA []byte) (int, error) { |
|
var i int |
|
_ = i |
|
var l int |
|
_ = l |
|
if len(m.Events) > 0 { |
|
for _, msg := range m.Events { |
|
dAtA[i] = 0xa |
|
i++ |
|
i = encodeVarintStreamEvent(dAtA, i, uint64(msg.Size())) |
|
n, err := msg.MarshalTo(dAtA[i:]) |
|
if err != nil { |
|
return 0, err |
|
} |
|
i += n |
|
} |
|
} |
|
return i, nil |
|
} |
|
|
|
func (m *Response) Marshal() (dAtA []byte, err error) { |
|
size := m.Size() |
|
dAtA = make([]byte, size) |
|
n, err := m.MarshalTo(dAtA) |
|
if err != nil { |
|
return nil, err |
|
} |
|
return dAtA[:n], nil |
|
} |
|
|
|
func (m *Response) MarshalTo(dAtA []byte) (int, error) { |
|
var i int |
|
_ = i |
|
var l int |
|
_ = l |
|
if m.Code != 0 { |
|
dAtA[i] = 0x8 |
|
i++ |
|
i = encodeVarintStreamEvent(dAtA, i, uint64(m.Code)) |
|
} |
|
if len(m.Msg) > 0 { |
|
dAtA[i] = 0x12 |
|
i++ |
|
i = encodeVarintStreamEvent(dAtA, i, uint64(len(m.Msg))) |
|
i += copy(dAtA[i:], m.Msg) |
|
} |
|
return i, nil |
|
} |
|
|
|
func encodeVarintStreamEvent(dAtA []byte, offset int, v uint64) int { |
|
for v >= 1<<7 { |
|
dAtA[offset] = uint8(v&0x7f | 0x80) |
|
v >>= 7 |
|
offset++ |
|
} |
|
dAtA[offset] = uint8(v) |
|
return offset + 1 |
|
} |
|
func (m *SimpleEvent) Size() (n int) { |
|
var l int |
|
_ = l |
|
l = len(m.LogId) |
|
if l > 0 { |
|
n += 1 + l + sovStreamEvent(uint64(l)) |
|
} |
|
l = len(m.OuterId) |
|
if l > 0 { |
|
n += 1 + l + sovStreamEvent(uint64(l)) |
|
} |
|
if len(m.Header) > 0 { |
|
for k, v := range m.Header { |
|
_ = k |
|
_ = v |
|
mapEntrySize := 1 + len(k) + sovStreamEvent(uint64(len(k))) + 1 + len(v) + sovStreamEvent(uint64(len(v))) |
|
n += mapEntrySize + 1 + sovStreamEvent(uint64(mapEntrySize)) |
|
} |
|
} |
|
l = len(m.Data) |
|
if l > 0 { |
|
n += 1 + l + sovStreamEvent(uint64(l)) |
|
} |
|
return n |
|
} |
|
|
|
func (m *EventList) Size() (n int) { |
|
var l int |
|
_ = l |
|
if len(m.Events) > 0 { |
|
for _, e := range m.Events { |
|
l = e.Size() |
|
n += 1 + l + sovStreamEvent(uint64(l)) |
|
} |
|
} |
|
return n |
|
} |
|
|
|
func (m *Response) Size() (n int) { |
|
var l int |
|
_ = l |
|
if m.Code != 0 { |
|
n += 1 + sovStreamEvent(uint64(m.Code)) |
|
} |
|
l = len(m.Msg) |
|
if l > 0 { |
|
n += 1 + l + sovStreamEvent(uint64(l)) |
|
} |
|
return n |
|
} |
|
|
|
func sovStreamEvent(x uint64) (n int) { |
|
for { |
|
n++ |
|
x >>= 7 |
|
if x == 0 { |
|
break |
|
} |
|
} |
|
return n |
|
} |
|
func sozStreamEvent(x uint64) (n int) { |
|
return sovStreamEvent(uint64((x << 1) ^ uint64((int64(x) >> 63)))) |
|
} |
|
func (m *SimpleEvent) Unmarshal(dAtA []byte) error { |
|
l := len(dAtA) |
|
iNdEx := 0 |
|
for iNdEx < l { |
|
preIndex := iNdEx |
|
var wire uint64 |
|
for shift := uint(0); ; shift += 7 { |
|
if shift >= 64 { |
|
return ErrIntOverflowStreamEvent |
|
} |
|
if iNdEx >= l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
b := dAtA[iNdEx] |
|
iNdEx++ |
|
wire |= (uint64(b) & 0x7F) << shift |
|
if b < 0x80 { |
|
break |
|
} |
|
} |
|
fieldNum := int32(wire >> 3) |
|
wireType := int(wire & 0x7) |
|
if wireType == 4 { |
|
return fmt.Errorf("proto: SimpleEvent: wiretype end group for non-group") |
|
} |
|
if fieldNum <= 0 { |
|
return fmt.Errorf("proto: SimpleEvent: illegal tag %d (wire type %d)", fieldNum, wire) |
|
} |
|
switch fieldNum { |
|
case 1: |
|
if wireType != 2 { |
|
return fmt.Errorf("proto: wrong wireType = %d for field LogId", wireType) |
|
} |
|
var stringLen uint64 |
|
for shift := uint(0); ; shift += 7 { |
|
if shift >= 64 { |
|
return ErrIntOverflowStreamEvent |
|
} |
|
if iNdEx >= l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
b := dAtA[iNdEx] |
|
iNdEx++ |
|
stringLen |= (uint64(b) & 0x7F) << shift |
|
if b < 0x80 { |
|
break |
|
} |
|
} |
|
intStringLen := int(stringLen) |
|
if intStringLen < 0 { |
|
return ErrInvalidLengthStreamEvent |
|
} |
|
postIndex := iNdEx + intStringLen |
|
if postIndex > l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
m.LogId = string(dAtA[iNdEx:postIndex]) |
|
iNdEx = postIndex |
|
case 2: |
|
if wireType != 2 { |
|
return fmt.Errorf("proto: wrong wireType = %d for field OuterId", wireType) |
|
} |
|
var stringLen uint64 |
|
for shift := uint(0); ; shift += 7 { |
|
if shift >= 64 { |
|
return ErrIntOverflowStreamEvent |
|
} |
|
if iNdEx >= l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
b := dAtA[iNdEx] |
|
iNdEx++ |
|
stringLen |= (uint64(b) & 0x7F) << shift |
|
if b < 0x80 { |
|
break |
|
} |
|
} |
|
intStringLen := int(stringLen) |
|
if intStringLen < 0 { |
|
return ErrInvalidLengthStreamEvent |
|
} |
|
postIndex := iNdEx + intStringLen |
|
if postIndex > l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
m.OuterId = string(dAtA[iNdEx:postIndex]) |
|
iNdEx = postIndex |
|
case 3: |
|
if wireType != 2 { |
|
return fmt.Errorf("proto: wrong wireType = %d for field Header", wireType) |
|
} |
|
var msglen int |
|
for shift := uint(0); ; shift += 7 { |
|
if shift >= 64 { |
|
return ErrIntOverflowStreamEvent |
|
} |
|
if iNdEx >= l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
b := dAtA[iNdEx] |
|
iNdEx++ |
|
msglen |= (int(b) & 0x7F) << shift |
|
if b < 0x80 { |
|
break |
|
} |
|
} |
|
if msglen < 0 { |
|
return ErrInvalidLengthStreamEvent |
|
} |
|
postIndex := iNdEx + msglen |
|
if postIndex > l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
if m.Header == nil { |
|
m.Header = make(map[string]string) |
|
} |
|
var mapkey string |
|
var mapvalue string |
|
for iNdEx < postIndex { |
|
entryPreIndex := iNdEx |
|
var wire uint64 |
|
for shift := uint(0); ; shift += 7 { |
|
if shift >= 64 { |
|
return ErrIntOverflowStreamEvent |
|
} |
|
if iNdEx >= l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
b := dAtA[iNdEx] |
|
iNdEx++ |
|
wire |= (uint64(b) & 0x7F) << shift |
|
if b < 0x80 { |
|
break |
|
} |
|
} |
|
fieldNum := int32(wire >> 3) |
|
if fieldNum == 1 { |
|
var stringLenmapkey uint64 |
|
for shift := uint(0); ; shift += 7 { |
|
if shift >= 64 { |
|
return ErrIntOverflowStreamEvent |
|
} |
|
if iNdEx >= l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
b := dAtA[iNdEx] |
|
iNdEx++ |
|
stringLenmapkey |= (uint64(b) & 0x7F) << shift |
|
if b < 0x80 { |
|
break |
|
} |
|
} |
|
intStringLenmapkey := int(stringLenmapkey) |
|
if intStringLenmapkey < 0 { |
|
return ErrInvalidLengthStreamEvent |
|
} |
|
postStringIndexmapkey := iNdEx + intStringLenmapkey |
|
if postStringIndexmapkey > l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
mapkey = string(dAtA[iNdEx:postStringIndexmapkey]) |
|
iNdEx = postStringIndexmapkey |
|
} else if fieldNum == 2 { |
|
var stringLenmapvalue uint64 |
|
for shift := uint(0); ; shift += 7 { |
|
if shift >= 64 { |
|
return ErrIntOverflowStreamEvent |
|
} |
|
if iNdEx >= l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
b := dAtA[iNdEx] |
|
iNdEx++ |
|
stringLenmapvalue |= (uint64(b) & 0x7F) << shift |
|
if b < 0x80 { |
|
break |
|
} |
|
} |
|
intStringLenmapvalue := int(stringLenmapvalue) |
|
if intStringLenmapvalue < 0 { |
|
return ErrInvalidLengthStreamEvent |
|
} |
|
postStringIndexmapvalue := iNdEx + intStringLenmapvalue |
|
if postStringIndexmapvalue > l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
mapvalue = string(dAtA[iNdEx:postStringIndexmapvalue]) |
|
iNdEx = postStringIndexmapvalue |
|
} else { |
|
iNdEx = entryPreIndex |
|
skippy, err := skipStreamEvent(dAtA[iNdEx:]) |
|
if err != nil { |
|
return err |
|
} |
|
if skippy < 0 { |
|
return ErrInvalidLengthStreamEvent |
|
} |
|
if (iNdEx + skippy) > postIndex { |
|
return io.ErrUnexpectedEOF |
|
} |
|
iNdEx += skippy |
|
} |
|
} |
|
m.Header[mapkey] = mapvalue |
|
iNdEx = postIndex |
|
case 4: |
|
if wireType != 2 { |
|
return fmt.Errorf("proto: wrong wireType = %d for field Data", wireType) |
|
} |
|
var byteLen int |
|
for shift := uint(0); ; shift += 7 { |
|
if shift >= 64 { |
|
return ErrIntOverflowStreamEvent |
|
} |
|
if iNdEx >= l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
b := dAtA[iNdEx] |
|
iNdEx++ |
|
byteLen |= (int(b) & 0x7F) << shift |
|
if b < 0x80 { |
|
break |
|
} |
|
} |
|
if byteLen < 0 { |
|
return ErrInvalidLengthStreamEvent |
|
} |
|
postIndex := iNdEx + byteLen |
|
if postIndex > l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
m.Data = append(m.Data[:0], dAtA[iNdEx:postIndex]...) |
|
if m.Data == nil { |
|
m.Data = []byte{} |
|
} |
|
iNdEx = postIndex |
|
default: |
|
iNdEx = preIndex |
|
skippy, err := skipStreamEvent(dAtA[iNdEx:]) |
|
if err != nil { |
|
return err |
|
} |
|
if skippy < 0 { |
|
return ErrInvalidLengthStreamEvent |
|
} |
|
if (iNdEx + skippy) > l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
iNdEx += skippy |
|
} |
|
} |
|
|
|
if iNdEx > l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
return nil |
|
} |
|
func (m *EventList) Unmarshal(dAtA []byte) error { |
|
l := len(dAtA) |
|
iNdEx := 0 |
|
for iNdEx < l { |
|
preIndex := iNdEx |
|
var wire uint64 |
|
for shift := uint(0); ; shift += 7 { |
|
if shift >= 64 { |
|
return ErrIntOverflowStreamEvent |
|
} |
|
if iNdEx >= l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
b := dAtA[iNdEx] |
|
iNdEx++ |
|
wire |= (uint64(b) & 0x7F) << shift |
|
if b < 0x80 { |
|
break |
|
} |
|
} |
|
fieldNum := int32(wire >> 3) |
|
wireType := int(wire & 0x7) |
|
if wireType == 4 { |
|
return fmt.Errorf("proto: EventList: wiretype end group for non-group") |
|
} |
|
if fieldNum <= 0 { |
|
return fmt.Errorf("proto: EventList: illegal tag %d (wire type %d)", fieldNum, wire) |
|
} |
|
switch fieldNum { |
|
case 1: |
|
if wireType != 2 { |
|
return fmt.Errorf("proto: wrong wireType = %d for field Events", wireType) |
|
} |
|
var msglen int |
|
for shift := uint(0); ; shift += 7 { |
|
if shift >= 64 { |
|
return ErrIntOverflowStreamEvent |
|
} |
|
if iNdEx >= l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
b := dAtA[iNdEx] |
|
iNdEx++ |
|
msglen |= (int(b) & 0x7F) << shift |
|
if b < 0x80 { |
|
break |
|
} |
|
} |
|
if msglen < 0 { |
|
return ErrInvalidLengthStreamEvent |
|
} |
|
postIndex := iNdEx + msglen |
|
if postIndex > l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
m.Events = append(m.Events, &SimpleEvent{}) |
|
if err := m.Events[len(m.Events)-1].Unmarshal(dAtA[iNdEx:postIndex]); err != nil { |
|
return err |
|
} |
|
iNdEx = postIndex |
|
default: |
|
iNdEx = preIndex |
|
skippy, err := skipStreamEvent(dAtA[iNdEx:]) |
|
if err != nil { |
|
return err |
|
} |
|
if skippy < 0 { |
|
return ErrInvalidLengthStreamEvent |
|
} |
|
if (iNdEx + skippy) > l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
iNdEx += skippy |
|
} |
|
} |
|
|
|
if iNdEx > l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
return nil |
|
} |
|
func (m *Response) Unmarshal(dAtA []byte) error { |
|
l := len(dAtA) |
|
iNdEx := 0 |
|
for iNdEx < l { |
|
preIndex := iNdEx |
|
var wire uint64 |
|
for shift := uint(0); ; shift += 7 { |
|
if shift >= 64 { |
|
return ErrIntOverflowStreamEvent |
|
} |
|
if iNdEx >= l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
b := dAtA[iNdEx] |
|
iNdEx++ |
|
wire |= (uint64(b) & 0x7F) << shift |
|
if b < 0x80 { |
|
break |
|
} |
|
} |
|
fieldNum := int32(wire >> 3) |
|
wireType := int(wire & 0x7) |
|
if wireType == 4 { |
|
return fmt.Errorf("proto: Response: wiretype end group for non-group") |
|
} |
|
if fieldNum <= 0 { |
|
return fmt.Errorf("proto: Response: illegal tag %d (wire type %d)", fieldNum, wire) |
|
} |
|
switch fieldNum { |
|
case 1: |
|
if wireType != 0 { |
|
return fmt.Errorf("proto: wrong wireType = %d for field Code", wireType) |
|
} |
|
m.Code = 0 |
|
for shift := uint(0); ; shift += 7 { |
|
if shift >= 64 { |
|
return ErrIntOverflowStreamEvent |
|
} |
|
if iNdEx >= l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
b := dAtA[iNdEx] |
|
iNdEx++ |
|
m.Code |= (StatusCode(b) & 0x7F) << shift |
|
if b < 0x80 { |
|
break |
|
} |
|
} |
|
case 2: |
|
if wireType != 2 { |
|
return fmt.Errorf("proto: wrong wireType = %d for field Msg", wireType) |
|
} |
|
var stringLen uint64 |
|
for shift := uint(0); ; shift += 7 { |
|
if shift >= 64 { |
|
return ErrIntOverflowStreamEvent |
|
} |
|
if iNdEx >= l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
b := dAtA[iNdEx] |
|
iNdEx++ |
|
stringLen |= (uint64(b) & 0x7F) << shift |
|
if b < 0x80 { |
|
break |
|
} |
|
} |
|
intStringLen := int(stringLen) |
|
if intStringLen < 0 { |
|
return ErrInvalidLengthStreamEvent |
|
} |
|
postIndex := iNdEx + intStringLen |
|
if postIndex > l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
m.Msg = string(dAtA[iNdEx:postIndex]) |
|
iNdEx = postIndex |
|
default: |
|
iNdEx = preIndex |
|
skippy, err := skipStreamEvent(dAtA[iNdEx:]) |
|
if err != nil { |
|
return err |
|
} |
|
if skippy < 0 { |
|
return ErrInvalidLengthStreamEvent |
|
} |
|
if (iNdEx + skippy) > l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
iNdEx += skippy |
|
} |
|
} |
|
|
|
if iNdEx > l { |
|
return io.ErrUnexpectedEOF |
|
} |
|
return nil |
|
} |
|
func skipStreamEvent(dAtA []byte) (n int, err error) { |
|
l := len(dAtA) |
|
iNdEx := 0 |
|
for iNdEx < l { |
|
var wire uint64 |
|
for shift := uint(0); ; shift += 7 { |
|
if shift >= 64 { |
|
return 0, ErrIntOverflowStreamEvent |
|
} |
|
if iNdEx >= l { |
|
return 0, io.ErrUnexpectedEOF |
|
} |
|
b := dAtA[iNdEx] |
|
iNdEx++ |
|
wire |= (uint64(b) & 0x7F) << shift |
|
if b < 0x80 { |
|
break |
|
} |
|
} |
|
wireType := int(wire & 0x7) |
|
switch wireType { |
|
case 0: |
|
for shift := uint(0); ; shift += 7 { |
|
if shift >= 64 { |
|
return 0, ErrIntOverflowStreamEvent |
|
} |
|
if iNdEx >= l { |
|
return 0, io.ErrUnexpectedEOF |
|
} |
|
iNdEx++ |
|
if dAtA[iNdEx-1] < 0x80 { |
|
break |
|
} |
|
} |
|
return iNdEx, nil |
|
case 1: |
|
iNdEx += 8 |
|
return iNdEx, nil |
|
case 2: |
|
var length int |
|
for shift := uint(0); ; shift += 7 { |
|
if shift >= 64 { |
|
return 0, ErrIntOverflowStreamEvent |
|
} |
|
if iNdEx >= l { |
|
return 0, io.ErrUnexpectedEOF |
|
} |
|
b := dAtA[iNdEx] |
|
iNdEx++ |
|
length |= (int(b) & 0x7F) << shift |
|
if b < 0x80 { |
|
break |
|
} |
|
} |
|
iNdEx += length |
|
if length < 0 { |
|
return 0, ErrInvalidLengthStreamEvent |
|
} |
|
return iNdEx, nil |
|
case 3: |
|
for { |
|
var innerWire uint64 |
|
var start int = iNdEx |
|
for shift := uint(0); ; shift += 7 { |
|
if shift >= 64 { |
|
return 0, ErrIntOverflowStreamEvent |
|
} |
|
if iNdEx >= l { |
|
return 0, io.ErrUnexpectedEOF |
|
} |
|
b := dAtA[iNdEx] |
|
iNdEx++ |
|
innerWire |= (uint64(b) & 0x7F) << shift |
|
if b < 0x80 { |
|
break |
|
} |
|
} |
|
innerWireType := int(innerWire & 0x7) |
|
if innerWireType == 4 { |
|
break |
|
} |
|
next, err := skipStreamEvent(dAtA[start:]) |
|
if err != nil { |
|
return 0, err |
|
} |
|
iNdEx = start + next |
|
} |
|
return iNdEx, nil |
|
case 4: |
|
return iNdEx, nil |
|
case 5: |
|
iNdEx += 4 |
|
return iNdEx, nil |
|
default: |
|
return 0, fmt.Errorf("proto: illegal wireType %d", wireType) |
|
} |
|
} |
|
panic("unreachable") |
|
} |
|
|
|
var ( |
|
ErrInvalidLengthStreamEvent = fmt.Errorf("proto: negative length found during unmarshaling") |
|
ErrIntOverflowStreamEvent = fmt.Errorf("proto: integer overflow") |
|
) |
|
|
|
func init() { |
|
proto.RegisterFile("app/service/ops/log-agent/output/lancergrpc/lancergateway/StreamEvent.proto", fileDescriptorStreamEvent) |
|
} |
|
|
|
var fileDescriptorStreamEvent = []byte{ |
|
// 437 bytes of a gzipped FileDescriptorProto |
|
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x54, 0x52, 0xd1, 0x8a, 0xd3, 0x40, |
|
0x14, 0xdd, 0xd9, 0xc6, 0x6e, 0x7b, 0x5b, 0x4a, 0x19, 0x7c, 0x08, 0x7d, 0xa8, 0xb5, 0x2a, 0x14, |
|
0x61, 0x27, 0x1a, 0x15, 0x54, 0xf0, 0x41, 0x6b, 0xd5, 0xc5, 0xa2, 0x92, 0xb0, 0xe0, 0x9b, 0x4c, |
|
0x93, 0x6b, 0x36, 0x98, 0x64, 0x86, 0x99, 0x49, 0xa5, 0x1f, 0xe5, 0x2f, 0xf8, 0xbc, 0x8f, 0x7e, |
|
0x82, 0xf4, 0x4b, 0x64, 0xa6, 0xa9, 0xdb, 0x3e, 0x04, 0xce, 0x99, 0x73, 0xb8, 0xe7, 0x5c, 0x72, |
|
0xe1, 0x23, 0x97, 0x32, 0xd0, 0xa8, 0xd6, 0x79, 0x82, 0x81, 0x90, 0x3a, 0x28, 0x44, 0x76, 0xce, |
|
0x33, 0xac, 0x4c, 0x20, 0x6a, 0x23, 0x6b, 0x13, 0x14, 0xbc, 0x4a, 0x50, 0x65, 0x4a, 0x26, 0x7b, |
|
0xc8, 0x0d, 0xfe, 0xe4, 0x9b, 0x20, 0x36, 0x0a, 0x79, 0xb9, 0x58, 0x63, 0x65, 0x98, 0x54, 0xc2, |
|
0x88, 0xd1, 0x79, 0x96, 0x9b, 0xab, 0x7a, 0xc5, 0x12, 0x51, 0x06, 0x99, 0xc8, 0x44, 0xe0, 0x9e, |
|
0x57, 0xf5, 0x77, 0xc7, 0x1c, 0x71, 0x68, 0x67, 0x9f, 0xfe, 0x26, 0xd0, 0x8b, 0xf3, 0x52, 0x16, |
|
0xe8, 0x86, 0xd0, 0xdb, 0x70, 0xab, 0x10, 0xd9, 0x45, 0xea, 0x93, 0x09, 0x99, 0x75, 0xa3, 0x1d, |
|
0xa1, 0x3e, 0x9c, 0x89, 0xda, 0xa0, 0xba, 0x48, 0xfd, 0x53, 0xf7, 0xbe, 0xa7, 0xf4, 0x11, 0xb4, |
|
0xaf, 0x90, 0xa7, 0xa8, 0xfc, 0xd6, 0xa4, 0x35, 0xeb, 0x85, 0x3e, 0x3b, 0x98, 0xc6, 0x3e, 0x38, |
|
0x69, 0x51, 0x19, 0xb5, 0x89, 0x1a, 0x1f, 0xa5, 0xe0, 0xa5, 0xdc, 0x70, 0xdf, 0x9b, 0x90, 0x59, |
|
0x3f, 0x72, 0x78, 0xf4, 0x02, 0x7a, 0x07, 0x56, 0x3a, 0x84, 0xd6, 0x0f, 0xdc, 0x34, 0x15, 0x2c, |
|
0xb4, 0xb5, 0xd6, 0xbc, 0xa8, 0xb1, 0x89, 0xdf, 0x91, 0x97, 0xa7, 0xcf, 0xc9, 0xf4, 0x31, 0x74, |
|
0x5d, 0xd6, 0x32, 0xd7, 0x86, 0xde, 0x87, 0x36, 0x5a, 0xa2, 0x7d, 0xe2, 0xda, 0xf4, 0x0f, 0xdb, |
|
0x44, 0x8d, 0x36, 0x7d, 0x05, 0x9d, 0x08, 0xb5, 0x14, 0x95, 0x46, 0x7a, 0x07, 0xbc, 0x44, 0xa4, |
|
0xe8, 0xb2, 0x06, 0x61, 0x8f, 0xc5, 0x86, 0x9b, 0x5a, 0xcf, 0x45, 0x8a, 0x91, 0x13, 0x6c, 0x97, |
|
0x52, 0x67, 0x4d, 0xae, 0x85, 0x0f, 0x9f, 0x02, 0xdc, 0xb8, 0x68, 0x07, 0xbc, 0x4f, 0x97, 0xcb, |
|
0xe5, 0xf0, 0x84, 0xf6, 0xe1, 0x2c, 0xbe, 0x9c, 0xcf, 0x17, 0x71, 0x3c, 0xbc, 0x26, 0x74, 0x00, |
|
0xdd, 0xe5, 0xe7, 0xd7, 0x6f, 0xbf, 0xbd, 0xb3, 0xe2, 0xaf, 0x56, 0xf8, 0x15, 0x06, 0xef, 0x77, |
|
0x3f, 0x2d, 0x8c, 0x51, 0xad, 0x51, 0xd1, 0x7b, 0xd0, 0xd1, 0x58, 0xa5, 0xae, 0x38, 0xb0, 0xff, |
|
0x4b, 0x8c, 0xba, 0x6c, 0xdf, 0x6e, 0x7a, 0x42, 0xef, 0x82, 0x67, 0x4d, 0xf4, 0x68, 0x93, 0x23, |
|
0xcb, 0x9b, 0x67, 0xd7, 0xdb, 0x31, 0xf9, 0xb3, 0x1d, 0x93, 0xbf, 0xdb, 0x31, 0x81, 0x07, 0x89, |
|
0x28, 0xd9, 0x2a, 0x2f, 0x72, 0xfb, 0xb1, 0xe6, 0x4e, 0x42, 0x7b, 0x0e, 0xa5, 0xa8, 0xd8, 0xfe, |
|
0x18, 0xbe, 0x90, 0x55, 0xdb, 0xe1, 0x27, 0xff, 0x02, 0x00, 0x00, 0xff, 0xff, 0x78, 0x44, 0xe9, |
|
0xca, 0x7e, 0x02, 0x00, 0x00, |
|
}
|
|
|