Files
tasks/api/update/v1/message.pb.go
Matt McShaneandGitHub 1433222253 Add the event batch ID to update CompletionInfo (#4441)
Both the event ID and the event batch ID are required when the
read-through event cache does not find the event cached and must perform
a lookup through the persistence layer.
2023-06-06 20:07:59 -04:00

1102 lines
26 KiB
Go

// The MIT License
//
// Copyright (c) 2020 Temporal Technologies Inc. All rights reserved.
//
// Copyright (c) 2020 Uber Technologies, Inc.
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
// copies of the Software, and to permit persons to whom the Software is
// furnished to do so, subject to the following conditions:
//
// The above copyright notice and this permission notice shall be included in
// all copies or substantial portions of the Software.
//
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
// IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
// FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
// AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
// LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.
// Code generated by protoc-gen-gogo. DO NOT EDIT.
// source: temporal/server/api/update/v1/message.proto
package update
import (
fmt "fmt"
io "io"
math "math"
math_bits "math/bits"
reflect "reflect"
strings "strings"
proto "github.com/gogo/protobuf/proto"
)
// 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.GoGoProtoPackageIsVersion3 // please upgrade the proto package
// AcceptanceInfo contains information about an accepted update
type AcceptanceInfo struct {
// the event ID of the WorkflowExecutionUpdateAcceptedEvent
EventId int64 `protobuf:"varint,1,opt,name=event_id,json=eventId,proto3" json:"event_id,omitempty"`
}
func (m *AcceptanceInfo) Reset() { *m = AcceptanceInfo{} }
func (*AcceptanceInfo) ProtoMessage() {}
func (*AcceptanceInfo) Descriptor() ([]byte, []int) {
return fileDescriptor_4ed2a57b35a35897, []int{0}
}
func (m *AcceptanceInfo) XXX_Unmarshal(b []byte) error {
return m.Unmarshal(b)
}
func (m *AcceptanceInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
if deterministic {
return xxx_messageInfo_AcceptanceInfo.Marshal(b, m, deterministic)
} else {
b = b[:cap(b)]
n, err := m.MarshalToSizedBuffer(b)
if err != nil {
return nil, err
}
return b[:n], nil
}
}
func (m *AcceptanceInfo) XXX_Merge(src proto.Message) {
xxx_messageInfo_AcceptanceInfo.Merge(m, src)
}
func (m *AcceptanceInfo) XXX_Size() int {
return m.Size()
}
func (m *AcceptanceInfo) XXX_DiscardUnknown() {
xxx_messageInfo_AcceptanceInfo.DiscardUnknown(m)
}
var xxx_messageInfo_AcceptanceInfo proto.InternalMessageInfo
func (m *AcceptanceInfo) GetEventId() int64 {
if m != nil {
return m.EventId
}
return 0
}
// CompletionInfo contains information about a completed update
type CompletionInfo struct {
// the event ID of the WorkflowExecutionUpdateCompletedEvent
EventId int64 `protobuf:"varint,1,opt,name=event_id,json=eventId,proto3" json:"event_id,omitempty"`
// the ID of the event batch containing the event_id above
EventBatchId int64 `protobuf:"varint,2,opt,name=event_batch_id,json=eventBatchId,proto3" json:"event_batch_id,omitempty"`
}
func (m *CompletionInfo) Reset() { *m = CompletionInfo{} }
func (*CompletionInfo) ProtoMessage() {}
func (*CompletionInfo) Descriptor() ([]byte, []int) {
return fileDescriptor_4ed2a57b35a35897, []int{1}
}
func (m *CompletionInfo) XXX_Unmarshal(b []byte) error {
return m.Unmarshal(b)
}
func (m *CompletionInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
if deterministic {
return xxx_messageInfo_CompletionInfo.Marshal(b, m, deterministic)
} else {
b = b[:cap(b)]
n, err := m.MarshalToSizedBuffer(b)
if err != nil {
return nil, err
}
return b[:n], nil
}
}
func (m *CompletionInfo) XXX_Merge(src proto.Message) {
xxx_messageInfo_CompletionInfo.Merge(m, src)
}
func (m *CompletionInfo) XXX_Size() int {
return m.Size()
}
func (m *CompletionInfo) XXX_DiscardUnknown() {
xxx_messageInfo_CompletionInfo.DiscardUnknown(m)
}
var xxx_messageInfo_CompletionInfo proto.InternalMessageInfo
func (m *CompletionInfo) GetEventId() int64 {
if m != nil {
return m.EventId
}
return 0
}
func (m *CompletionInfo) GetEventBatchId() int64 {
if m != nil {
return m.EventBatchId
}
return 0
}
// UpdateInfo is the persistent state of a single update
type UpdateInfo struct {
// Types that are valid to be assigned to Value:
//
// *UpdateInfo_Acceptance
// *UpdateInfo_Completion
Value isUpdateInfo_Value `protobuf_oneof:"value"`
}
func (m *UpdateInfo) Reset() { *m = UpdateInfo{} }
func (*UpdateInfo) ProtoMessage() {}
func (*UpdateInfo) Descriptor() ([]byte, []int) {
return fileDescriptor_4ed2a57b35a35897, []int{2}
}
func (m *UpdateInfo) XXX_Unmarshal(b []byte) error {
return m.Unmarshal(b)
}
func (m *UpdateInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
if deterministic {
return xxx_messageInfo_UpdateInfo.Marshal(b, m, deterministic)
} else {
b = b[:cap(b)]
n, err := m.MarshalToSizedBuffer(b)
if err != nil {
return nil, err
}
return b[:n], nil
}
}
func (m *UpdateInfo) XXX_Merge(src proto.Message) {
xxx_messageInfo_UpdateInfo.Merge(m, src)
}
func (m *UpdateInfo) XXX_Size() int {
return m.Size()
}
func (m *UpdateInfo) XXX_DiscardUnknown() {
xxx_messageInfo_UpdateInfo.DiscardUnknown(m)
}
var xxx_messageInfo_UpdateInfo proto.InternalMessageInfo
type isUpdateInfo_Value interface {
isUpdateInfo_Value()
Equal(interface{}) bool
MarshalTo([]byte) (int, error)
Size() int
}
type UpdateInfo_Acceptance struct {
Acceptance *AcceptanceInfo `protobuf:"bytes,1,opt,name=acceptance,proto3,oneof" json:"acceptance,omitempty"`
}
type UpdateInfo_Completion struct {
Completion *CompletionInfo `protobuf:"bytes,2,opt,name=completion,proto3,oneof" json:"completion,omitempty"`
}
func (*UpdateInfo_Acceptance) isUpdateInfo_Value() {}
func (*UpdateInfo_Completion) isUpdateInfo_Value() {}
func (m *UpdateInfo) GetValue() isUpdateInfo_Value {
if m != nil {
return m.Value
}
return nil
}
func (m *UpdateInfo) GetAcceptance() *AcceptanceInfo {
if x, ok := m.GetValue().(*UpdateInfo_Acceptance); ok {
return x.Acceptance
}
return nil
}
func (m *UpdateInfo) GetCompletion() *CompletionInfo {
if x, ok := m.GetValue().(*UpdateInfo_Completion); ok {
return x.Completion
}
return nil
}
// XXX_OneofWrappers is for the internal use of the proto package.
func (*UpdateInfo) XXX_OneofWrappers() []interface{} {
return []interface{}{
(*UpdateInfo_Acceptance)(nil),
(*UpdateInfo_Completion)(nil),
}
}
func init() {
proto.RegisterType((*AcceptanceInfo)(nil), "temporal.server.api.update.v1.AcceptanceInfo")
proto.RegisterType((*CompletionInfo)(nil), "temporal.server.api.update.v1.CompletionInfo")
proto.RegisterType((*UpdateInfo)(nil), "temporal.server.api.update.v1.UpdateInfo")
}
func init() {
proto.RegisterFile("temporal/server/api/update/v1/message.proto", fileDescriptor_4ed2a57b35a35897)
}
var fileDescriptor_4ed2a57b35a35897 = []byte{
// 303 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xd2, 0x2e, 0x49, 0xcd, 0x2d,
0xc8, 0x2f, 0x4a, 0xcc, 0xd1, 0x2f, 0x4e, 0x2d, 0x2a, 0x4b, 0x2d, 0xd2, 0x4f, 0x2c, 0xc8, 0xd4,
0x2f, 0x2d, 0x48, 0x49, 0x2c, 0x49, 0xd5, 0x2f, 0x33, 0xd4, 0xcf, 0x4d, 0x2d, 0x2e, 0x4e, 0x4c,
0x4f, 0xd5, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x92, 0x85, 0x29, 0xd6, 0x83, 0x28, 0xd6, 0x4b,
0x2c, 0xc8, 0xd4, 0x83, 0x28, 0xd6, 0x2b, 0x33, 0x54, 0xd2, 0xe6, 0xe2, 0x73, 0x4c, 0x4e, 0x4e,
0x2d, 0x28, 0x49, 0xcc, 0x4b, 0x4e, 0xf5, 0xcc, 0x4b, 0xcb, 0x17, 0x92, 0xe4, 0xe2, 0x48, 0x2d,
0x4b, 0xcd, 0x2b, 0x89, 0xcf, 0x4c, 0x91, 0x60, 0x54, 0x60, 0xd4, 0x60, 0x0e, 0x62, 0x07, 0xf3,
0x3d, 0x53, 0x94, 0x02, 0xb9, 0xf8, 0x9c, 0xf3, 0x73, 0x0b, 0x72, 0x52, 0x4b, 0x32, 0xf3, 0xf3,
0x08, 0x28, 0x16, 0x52, 0xe1, 0xe2, 0x83, 0x48, 0x25, 0x25, 0x96, 0x24, 0x67, 0x80, 0x14, 0x30,
0x81, 0x15, 0xf0, 0x80, 0x45, 0x9d, 0x40, 0x82, 0x9e, 0x29, 0x4a, 0xdb, 0x19, 0xb9, 0xb8, 0x42,
0xc1, 0xae, 0x01, 0x9b, 0xe7, 0xcf, 0xc5, 0x95, 0x08, 0x77, 0x0e, 0xd8, 0x44, 0x6e, 0x23, 0x5d,
0x3d, 0xbc, 0x5e, 0xd0, 0x43, 0x75, 0xbf, 0x07, 0x43, 0x10, 0x92, 0x11, 0x20, 0x03, 0x93, 0xe1,
0x4e, 0x06, 0xbb, 0x80, 0xb0, 0x81, 0xa8, 0x7e, 0x04, 0x19, 0x88, 0x30, 0xc2, 0x89, 0x9d, 0x8b,
0xb5, 0x2c, 0x31, 0xa7, 0x34, 0xd5, 0x29, 0xe1, 0xc2, 0x43, 0x39, 0x86, 0x1b, 0x0f, 0xe5, 0x18,
0x3e, 0x3c, 0x94, 0x63, 0x6c, 0x78, 0x24, 0xc7, 0xb8, 0xe2, 0x91, 0x1c, 0xe3, 0x89, 0x47, 0x72,
0x8c, 0x17, 0x1e, 0xc9, 0x31, 0x3e, 0x78, 0x24, 0xc7, 0xf8, 0xe2, 0x91, 0x1c, 0xc3, 0x87, 0x47,
0x72, 0x8c, 0x13, 0x1e, 0xcb, 0x31, 0x5c, 0x78, 0x2c, 0xc7, 0x70, 0xe3, 0xb1, 0x1c, 0x43, 0x94,
0x56, 0x7a, 0x3e, 0xc2, 0xf6, 0xcc, 0x7c, 0xac, 0x31, 0x68, 0x0d, 0x61, 0x25, 0xb1, 0x81, 0x63,
0xd0, 0x18, 0x10, 0x00, 0x00, 0xff, 0xff, 0x54, 0x04, 0xb4, 0xeb, 0xf0, 0x01, 0x00, 0x00,
}
func (this *AcceptanceInfo) Equal(that interface{}) bool {
if that == nil {
return this == nil
}
that1, ok := that.(*AcceptanceInfo)
if !ok {
that2, ok := that.(AcceptanceInfo)
if ok {
that1 = &that2
} else {
return false
}
}
if that1 == nil {
return this == nil
} else if this == nil {
return false
}
if this.EventId != that1.EventId {
return false
}
return true
}
func (this *CompletionInfo) Equal(that interface{}) bool {
if that == nil {
return this == nil
}
that1, ok := that.(*CompletionInfo)
if !ok {
that2, ok := that.(CompletionInfo)
if ok {
that1 = &that2
} else {
return false
}
}
if that1 == nil {
return this == nil
} else if this == nil {
return false
}
if this.EventId != that1.EventId {
return false
}
if this.EventBatchId != that1.EventBatchId {
return false
}
return true
}
func (this *UpdateInfo) Equal(that interface{}) bool {
if that == nil {
return this == nil
}
that1, ok := that.(*UpdateInfo)
if !ok {
that2, ok := that.(UpdateInfo)
if ok {
that1 = &that2
} else {
return false
}
}
if that1 == nil {
return this == nil
} else if this == nil {
return false
}
if that1.Value == nil {
if this.Value != nil {
return false
}
} else if this.Value == nil {
return false
} else if !this.Value.Equal(that1.Value) {
return false
}
return true
}
func (this *UpdateInfo_Acceptance) Equal(that interface{}) bool {
if that == nil {
return this == nil
}
that1, ok := that.(*UpdateInfo_Acceptance)
if !ok {
that2, ok := that.(UpdateInfo_Acceptance)
if ok {
that1 = &that2
} else {
return false
}
}
if that1 == nil {
return this == nil
} else if this == nil {
return false
}
if !this.Acceptance.Equal(that1.Acceptance) {
return false
}
return true
}
func (this *UpdateInfo_Completion) Equal(that interface{}) bool {
if that == nil {
return this == nil
}
that1, ok := that.(*UpdateInfo_Completion)
if !ok {
that2, ok := that.(UpdateInfo_Completion)
if ok {
that1 = &that2
} else {
return false
}
}
if that1 == nil {
return this == nil
} else if this == nil {
return false
}
if !this.Completion.Equal(that1.Completion) {
return false
}
return true
}
func (this *AcceptanceInfo) GoString() string {
if this == nil {
return "nil"
}
s := make([]string, 0, 5)
s = append(s, "&update.AcceptanceInfo{")
s = append(s, "EventId: "+fmt.Sprintf("%#v", this.EventId)+",\n")
s = append(s, "}")
return strings.Join(s, "")
}
func (this *CompletionInfo) GoString() string {
if this == nil {
return "nil"
}
s := make([]string, 0, 6)
s = append(s, "&update.CompletionInfo{")
s = append(s, "EventId: "+fmt.Sprintf("%#v", this.EventId)+",\n")
s = append(s, "EventBatchId: "+fmt.Sprintf("%#v", this.EventBatchId)+",\n")
s = append(s, "}")
return strings.Join(s, "")
}
func (this *UpdateInfo) GoString() string {
if this == nil {
return "nil"
}
s := make([]string, 0, 6)
s = append(s, "&update.UpdateInfo{")
if this.Value != nil {
s = append(s, "Value: "+fmt.Sprintf("%#v", this.Value)+",\n")
}
s = append(s, "}")
return strings.Join(s, "")
}
func (this *UpdateInfo_Acceptance) GoString() string {
if this == nil {
return "nil"
}
s := strings.Join([]string{`&update.UpdateInfo_Acceptance{` +
`Acceptance:` + fmt.Sprintf("%#v", this.Acceptance) + `}`}, ", ")
return s
}
func (this *UpdateInfo_Completion) GoString() string {
if this == nil {
return "nil"
}
s := strings.Join([]string{`&update.UpdateInfo_Completion{` +
`Completion:` + fmt.Sprintf("%#v", this.Completion) + `}`}, ", ")
return s
}
func valueToGoStringMessage(v interface{}, typ string) string {
rv := reflect.ValueOf(v)
if rv.IsNil() {
return "nil"
}
pv := reflect.Indirect(rv).Interface()
return fmt.Sprintf("func(v %v) *%v { return &v } ( %#v )", typ, typ, pv)
}
func (m *AcceptanceInfo) Marshal() (dAtA []byte, err error) {
size := m.Size()
dAtA = make([]byte, size)
n, err := m.MarshalToSizedBuffer(dAtA[:size])
if err != nil {
return nil, err
}
return dAtA[:n], nil
}
func (m *AcceptanceInfo) MarshalTo(dAtA []byte) (int, error) {
size := m.Size()
return m.MarshalToSizedBuffer(dAtA[:size])
}
func (m *AcceptanceInfo) MarshalToSizedBuffer(dAtA []byte) (int, error) {
i := len(dAtA)
_ = i
var l int
_ = l
if m.EventId != 0 {
i = encodeVarintMessage(dAtA, i, uint64(m.EventId))
i--
dAtA[i] = 0x8
}
return len(dAtA) - i, nil
}
func (m *CompletionInfo) Marshal() (dAtA []byte, err error) {
size := m.Size()
dAtA = make([]byte, size)
n, err := m.MarshalToSizedBuffer(dAtA[:size])
if err != nil {
return nil, err
}
return dAtA[:n], nil
}
func (m *CompletionInfo) MarshalTo(dAtA []byte) (int, error) {
size := m.Size()
return m.MarshalToSizedBuffer(dAtA[:size])
}
func (m *CompletionInfo) MarshalToSizedBuffer(dAtA []byte) (int, error) {
i := len(dAtA)
_ = i
var l int
_ = l
if m.EventBatchId != 0 {
i = encodeVarintMessage(dAtA, i, uint64(m.EventBatchId))
i--
dAtA[i] = 0x10
}
if m.EventId != 0 {
i = encodeVarintMessage(dAtA, i, uint64(m.EventId))
i--
dAtA[i] = 0x8
}
return len(dAtA) - i, nil
}
func (m *UpdateInfo) Marshal() (dAtA []byte, err error) {
size := m.Size()
dAtA = make([]byte, size)
n, err := m.MarshalToSizedBuffer(dAtA[:size])
if err != nil {
return nil, err
}
return dAtA[:n], nil
}
func (m *UpdateInfo) MarshalTo(dAtA []byte) (int, error) {
size := m.Size()
return m.MarshalToSizedBuffer(dAtA[:size])
}
func (m *UpdateInfo) MarshalToSizedBuffer(dAtA []byte) (int, error) {
i := len(dAtA)
_ = i
var l int
_ = l
if m.Value != nil {
{
size := m.Value.Size()
i -= size
if _, err := m.Value.MarshalTo(dAtA[i:]); err != nil {
return 0, err
}
}
}
return len(dAtA) - i, nil
}
func (m *UpdateInfo_Acceptance) MarshalTo(dAtA []byte) (int, error) {
size := m.Size()
return m.MarshalToSizedBuffer(dAtA[:size])
}
func (m *UpdateInfo_Acceptance) MarshalToSizedBuffer(dAtA []byte) (int, error) {
i := len(dAtA)
if m.Acceptance != nil {
{
size, err := m.Acceptance.MarshalToSizedBuffer(dAtA[:i])
if err != nil {
return 0, err
}
i -= size
i = encodeVarintMessage(dAtA, i, uint64(size))
}
i--
dAtA[i] = 0xa
}
return len(dAtA) - i, nil
}
func (m *UpdateInfo_Completion) MarshalTo(dAtA []byte) (int, error) {
size := m.Size()
return m.MarshalToSizedBuffer(dAtA[:size])
}
func (m *UpdateInfo_Completion) MarshalToSizedBuffer(dAtA []byte) (int, error) {
i := len(dAtA)
if m.Completion != nil {
{
size, err := m.Completion.MarshalToSizedBuffer(dAtA[:i])
if err != nil {
return 0, err
}
i -= size
i = encodeVarintMessage(dAtA, i, uint64(size))
}
i--
dAtA[i] = 0x12
}
return len(dAtA) - i, nil
}
func encodeVarintMessage(dAtA []byte, offset int, v uint64) int {
offset -= sovMessage(v)
base := offset
for v >= 1<<7 {
dAtA[offset] = uint8(v&0x7f | 0x80)
v >>= 7
offset++
}
dAtA[offset] = uint8(v)
return base
}
func (m *AcceptanceInfo) Size() (n int) {
if m == nil {
return 0
}
var l int
_ = l
if m.EventId != 0 {
n += 1 + sovMessage(uint64(m.EventId))
}
return n
}
func (m *CompletionInfo) Size() (n int) {
if m == nil {
return 0
}
var l int
_ = l
if m.EventId != 0 {
n += 1 + sovMessage(uint64(m.EventId))
}
if m.EventBatchId != 0 {
n += 1 + sovMessage(uint64(m.EventBatchId))
}
return n
}
func (m *UpdateInfo) Size() (n int) {
if m == nil {
return 0
}
var l int
_ = l
if m.Value != nil {
n += m.Value.Size()
}
return n
}
func (m *UpdateInfo_Acceptance) Size() (n int) {
if m == nil {
return 0
}
var l int
_ = l
if m.Acceptance != nil {
l = m.Acceptance.Size()
n += 1 + l + sovMessage(uint64(l))
}
return n
}
func (m *UpdateInfo_Completion) Size() (n int) {
if m == nil {
return 0
}
var l int
_ = l
if m.Completion != nil {
l = m.Completion.Size()
n += 1 + l + sovMessage(uint64(l))
}
return n
}
func sovMessage(x uint64) (n int) {
return (math_bits.Len64(x|1) + 6) / 7
}
func sozMessage(x uint64) (n int) {
return sovMessage(uint64((x << 1) ^ uint64((int64(x) >> 63))))
}
func (this *AcceptanceInfo) String() string {
if this == nil {
return "nil"
}
s := strings.Join([]string{`&AcceptanceInfo{`,
`EventId:` + fmt.Sprintf("%v", this.EventId) + `,`,
`}`,
}, "")
return s
}
func (this *CompletionInfo) String() string {
if this == nil {
return "nil"
}
s := strings.Join([]string{`&CompletionInfo{`,
`EventId:` + fmt.Sprintf("%v", this.EventId) + `,`,
`EventBatchId:` + fmt.Sprintf("%v", this.EventBatchId) + `,`,
`}`,
}, "")
return s
}
func (this *UpdateInfo) String() string {
if this == nil {
return "nil"
}
s := strings.Join([]string{`&UpdateInfo{`,
`Value:` + fmt.Sprintf("%v", this.Value) + `,`,
`}`,
}, "")
return s
}
func (this *UpdateInfo_Acceptance) String() string {
if this == nil {
return "nil"
}
s := strings.Join([]string{`&UpdateInfo_Acceptance{`,
`Acceptance:` + strings.Replace(fmt.Sprintf("%v", this.Acceptance), "AcceptanceInfo", "AcceptanceInfo", 1) + `,`,
`}`,
}, "")
return s
}
func (this *UpdateInfo_Completion) String() string {
if this == nil {
return "nil"
}
s := strings.Join([]string{`&UpdateInfo_Completion{`,
`Completion:` + strings.Replace(fmt.Sprintf("%v", this.Completion), "CompletionInfo", "CompletionInfo", 1) + `,`,
`}`,
}, "")
return s
}
func valueToStringMessage(v interface{}) string {
rv := reflect.ValueOf(v)
if rv.IsNil() {
return "nil"
}
pv := reflect.Indirect(rv).Interface()
return fmt.Sprintf("*%v", pv)
}
func (m *AcceptanceInfo) 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 ErrIntOverflowMessage
}
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: AcceptanceInfo: wiretype end group for non-group")
}
if fieldNum <= 0 {
return fmt.Errorf("proto: AcceptanceInfo: illegal tag %d (wire type %d)", fieldNum, wire)
}
switch fieldNum {
case 1:
if wireType != 0 {
return fmt.Errorf("proto: wrong wireType = %d for field EventId", wireType)
}
m.EventId = 0
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowMessage
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
m.EventId |= int64(b&0x7F) << shift
if b < 0x80 {
break
}
}
default:
iNdEx = preIndex
skippy, err := skipMessage(dAtA[iNdEx:])
if err != nil {
return err
}
if skippy < 0 {
return ErrInvalidLengthMessage
}
if (iNdEx + skippy) < 0 {
return ErrInvalidLengthMessage
}
if (iNdEx + skippy) > l {
return io.ErrUnexpectedEOF
}
iNdEx += skippy
}
}
if iNdEx > l {
return io.ErrUnexpectedEOF
}
return nil
}
func (m *CompletionInfo) 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 ErrIntOverflowMessage
}
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: CompletionInfo: wiretype end group for non-group")
}
if fieldNum <= 0 {
return fmt.Errorf("proto: CompletionInfo: illegal tag %d (wire type %d)", fieldNum, wire)
}
switch fieldNum {
case 1:
if wireType != 0 {
return fmt.Errorf("proto: wrong wireType = %d for field EventId", wireType)
}
m.EventId = 0
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowMessage
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
m.EventId |= int64(b&0x7F) << shift
if b < 0x80 {
break
}
}
case 2:
if wireType != 0 {
return fmt.Errorf("proto: wrong wireType = %d for field EventBatchId", wireType)
}
m.EventBatchId = 0
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowMessage
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
m.EventBatchId |= int64(b&0x7F) << shift
if b < 0x80 {
break
}
}
default:
iNdEx = preIndex
skippy, err := skipMessage(dAtA[iNdEx:])
if err != nil {
return err
}
if skippy < 0 {
return ErrInvalidLengthMessage
}
if (iNdEx + skippy) < 0 {
return ErrInvalidLengthMessage
}
if (iNdEx + skippy) > l {
return io.ErrUnexpectedEOF
}
iNdEx += skippy
}
}
if iNdEx > l {
return io.ErrUnexpectedEOF
}
return nil
}
func (m *UpdateInfo) 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 ErrIntOverflowMessage
}
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: UpdateInfo: wiretype end group for non-group")
}
if fieldNum <= 0 {
return fmt.Errorf("proto: UpdateInfo: illegal tag %d (wire type %d)", fieldNum, wire)
}
switch fieldNum {
case 1:
if wireType != 2 {
return fmt.Errorf("proto: wrong wireType = %d for field Acceptance", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowMessage
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return ErrInvalidLengthMessage
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return ErrInvalidLengthMessage
}
if postIndex > l {
return io.ErrUnexpectedEOF
}
v := &AcceptanceInfo{}
if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
return err
}
m.Value = &UpdateInfo_Acceptance{v}
iNdEx = postIndex
case 2:
if wireType != 2 {
return fmt.Errorf("proto: wrong wireType = %d for field Completion", wireType)
}
var msglen int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return ErrIntOverflowMessage
}
if iNdEx >= l {
return io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
msglen |= int(b&0x7F) << shift
if b < 0x80 {
break
}
}
if msglen < 0 {
return ErrInvalidLengthMessage
}
postIndex := iNdEx + msglen
if postIndex < 0 {
return ErrInvalidLengthMessage
}
if postIndex > l {
return io.ErrUnexpectedEOF
}
v := &CompletionInfo{}
if err := v.Unmarshal(dAtA[iNdEx:postIndex]); err != nil {
return err
}
m.Value = &UpdateInfo_Completion{v}
iNdEx = postIndex
default:
iNdEx = preIndex
skippy, err := skipMessage(dAtA[iNdEx:])
if err != nil {
return err
}
if skippy < 0 {
return ErrInvalidLengthMessage
}
if (iNdEx + skippy) < 0 {
return ErrInvalidLengthMessage
}
if (iNdEx + skippy) > l {
return io.ErrUnexpectedEOF
}
iNdEx += skippy
}
}
if iNdEx > l {
return io.ErrUnexpectedEOF
}
return nil
}
func skipMessage(dAtA []byte) (n int, err error) {
l := len(dAtA)
iNdEx := 0
depth := 0
for iNdEx < l {
var wire uint64
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return 0, ErrIntOverflowMessage
}
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, ErrIntOverflowMessage
}
if iNdEx >= l {
return 0, io.ErrUnexpectedEOF
}
iNdEx++
if dAtA[iNdEx-1] < 0x80 {
break
}
}
case 1:
iNdEx += 8
case 2:
var length int
for shift := uint(0); ; shift += 7 {
if shift >= 64 {
return 0, ErrIntOverflowMessage
}
if iNdEx >= l {
return 0, io.ErrUnexpectedEOF
}
b := dAtA[iNdEx]
iNdEx++
length |= (int(b) & 0x7F) << shift
if b < 0x80 {
break
}
}
if length < 0 {
return 0, ErrInvalidLengthMessage
}
iNdEx += length
case 3:
depth++
case 4:
if depth == 0 {
return 0, ErrUnexpectedEndOfGroupMessage
}
depth--
case 5:
iNdEx += 4
default:
return 0, fmt.Errorf("proto: illegal wireType %d", wireType)
}
if iNdEx < 0 {
return 0, ErrInvalidLengthMessage
}
if depth == 0 {
return iNdEx, nil
}
}
return 0, io.ErrUnexpectedEOF
}
var (
ErrInvalidLengthMessage = fmt.Errorf("proto: negative length found during unmarshaling")
ErrIntOverflowMessage = fmt.Errorf("proto: integer overflow")
ErrUnexpectedEndOfGroupMessage = fmt.Errorf("proto: unexpected end of group")
)