starpc 0.28.0 → 0.29.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Makefile +45 -74
- package/e2e/mock/mock.pb.go +167 -113
- package/e2e/mock/mock_srpc.pb.go +1 -1
- package/echo/echo.pb.go +168 -140
- package/echo/echo_srpc.pb.go +1 -1
- package/echo/server.go +1 -2
- package/go.mod +4 -4
- package/go.sum +12 -12
- package/package.json +6 -5
- package/srpc/message.go +4 -4
- package/srpc/rpcproto.pb.go +1057 -226
- package/e2e/mock/mock_vtproto.pb.go +0 -195
- package/echo/echo_vtproto.pb.go +0 -195
- package/srpc/rpcproto_vtproto.pb.go +0 -1068
package/Makefile
CHANGED
|
@@ -1,36 +1,35 @@
|
|
|
1
1
|
# https://github.com/aperturerobotics/protobuf-project
|
|
2
2
|
|
|
3
3
|
SHELL:=bash
|
|
4
|
+
ESBUILD=hack/bin/esbuild
|
|
4
5
|
PROTOWRAP=hack/bin/protowrap
|
|
5
|
-
PROTOC_GEN_GO=hack/bin/protoc-gen-go
|
|
6
|
+
PROTOC_GEN_GO=hack/bin/protoc-gen-go-lite
|
|
6
7
|
PROTOC_GEN_STARPC=hack/bin/protoc-gen-go-starpc
|
|
7
|
-
PROTOC_GEN_VTPROTO=hack/bin/protoc-gen-go-vtproto
|
|
8
8
|
GOIMPORTS=hack/bin/goimports
|
|
9
|
-
GOFUMPT=hack/bin/gofumpt
|
|
10
9
|
GOLANGCI_LINT=hack/bin/golangci-lint
|
|
11
10
|
GO_MOD_OUTDATED=hack/bin/go-mod-outdated
|
|
12
11
|
GOLIST=go list -f "{{ .Dir }}" -m
|
|
13
12
|
|
|
14
13
|
export GO111MODULE=on
|
|
15
|
-
undefine GOOS
|
|
16
14
|
undefine GOARCH
|
|
15
|
+
undefine GOOS
|
|
17
16
|
|
|
18
17
|
all:
|
|
19
18
|
|
|
20
19
|
vendor:
|
|
21
20
|
go mod vendor
|
|
22
21
|
|
|
23
|
-
$(
|
|
22
|
+
$(ESBUILD):
|
|
24
23
|
cd ./hack; \
|
|
25
24
|
go build -v \
|
|
26
|
-
-o ./bin/
|
|
27
|
-
|
|
25
|
+
-o ./bin/esbuild \
|
|
26
|
+
github.com/evanw/esbuild/cmd/esbuild
|
|
28
27
|
|
|
29
|
-
$(
|
|
28
|
+
$(PROTOC_GEN_GO):
|
|
30
29
|
cd ./hack; \
|
|
31
30
|
go build -v \
|
|
32
|
-
-o ./bin/protoc-gen-go-
|
|
33
|
-
github.com/
|
|
31
|
+
-o ./bin/protoc-gen-go-lite \
|
|
32
|
+
github.com/aperturerobotics/protobuf-go-lite/cmd/protoc-gen-go-lite
|
|
34
33
|
|
|
35
34
|
$(PROTOC_GEN_STARPC):
|
|
36
35
|
cd ./hack; \
|
|
@@ -44,12 +43,6 @@ $(GOIMPORTS):
|
|
|
44
43
|
-o ./bin/goimports \
|
|
45
44
|
golang.org/x/tools/cmd/goimports
|
|
46
45
|
|
|
47
|
-
$(GOFUMPT):
|
|
48
|
-
cd ./hack; \
|
|
49
|
-
go build -v \
|
|
50
|
-
-o ./bin/gofumpt \
|
|
51
|
-
mvdan.cc/gofumpt
|
|
52
|
-
|
|
53
46
|
$(PROTOWRAP):
|
|
54
47
|
cd ./hack; \
|
|
55
48
|
go build -v \
|
|
@@ -68,37 +61,11 @@ $(GO_MOD_OUTDATED):
|
|
|
68
61
|
-o ./bin/go-mod-outdated \
|
|
69
62
|
github.com/psampaz/go-mod-outdated
|
|
70
63
|
|
|
71
|
-
.PHONY: gengo
|
|
72
|
-
gengo: $(GOIMPORTS) $(PROTOWRAP) $(PROTOC_GEN_GO) $(PROTOC_GEN_VTPROTO) $(PROTOC_GEN_STARPC)
|
|
73
|
-
shopt -s globstar; \
|
|
74
|
-
set -eo pipefail; \
|
|
75
|
-
export PROJECT=$$(go list -m); \
|
|
76
|
-
export PATH=$$(pwd)/hack/bin:$${PATH}; \
|
|
77
|
-
mkdir -p $$(pwd)/vendor/$$(dirname $${PROJECT}); \
|
|
78
|
-
rm $$(pwd)/vendor/$${PROJECT} || true; \
|
|
79
|
-
ln -s $$(pwd) $$(pwd)/vendor/$${PROJECT} ; \
|
|
80
|
-
$(PROTOWRAP) \
|
|
81
|
-
-I $$(pwd)/vendor \
|
|
82
|
-
--go_out=$$(pwd)/vendor \
|
|
83
|
-
--go-vtproto_out=$$(pwd)/vendor \
|
|
84
|
-
--go-vtproto_opt=features=marshal+unmarshal+size+equal+clone \
|
|
85
|
-
--go-starpc_out=$$(pwd)/vendor \
|
|
86
|
-
--proto_path $$(pwd)/vendor \
|
|
87
|
-
--print_structure \
|
|
88
|
-
--only_specified_files \
|
|
89
|
-
$$(\
|
|
90
|
-
git \
|
|
91
|
-
ls-files "*.proto" |\
|
|
92
|
-
xargs printf -- \
|
|
93
|
-
"$$(pwd)/vendor/$${PROJECT}/%s "); \
|
|
94
|
-
rm $$(pwd)/vendor/$${PROJECT} || true
|
|
95
|
-
$(GOIMPORTS) -w ./
|
|
96
|
-
|
|
97
64
|
node_modules:
|
|
98
65
|
yarn install
|
|
99
66
|
|
|
100
|
-
.PHONY:
|
|
101
|
-
|
|
67
|
+
.PHONY: genproto
|
|
68
|
+
genproto: vendor node_modules $(GOIMPORTS) $(PROTOWRAP) $(PROTOC_GEN_GO) $(PROTOC_GEN_STARPC)
|
|
102
69
|
shopt -s globstar; \
|
|
103
70
|
set -eo pipefail; \
|
|
104
71
|
export PROJECT=$$(go list -m); \
|
|
@@ -106,33 +73,37 @@ gents: $(PROTOWRAP) node_modules
|
|
|
106
73
|
mkdir -p $$(pwd)/vendor/$$(dirname $${PROJECT}); \
|
|
107
74
|
rm $$(pwd)/vendor/$${PROJECT} || true; \
|
|
108
75
|
ln -s $$(pwd) $$(pwd)/vendor/$${PROJECT} ; \
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
76
|
+
protogen() { \
|
|
77
|
+
$(PROTOWRAP) \
|
|
78
|
+
-I $$(pwd)/vendor \
|
|
79
|
+
--plugin=./node_modules/.bin/protoc-gen-ts_proto \
|
|
80
|
+
--go-lite_out=$$(pwd)/vendor \
|
|
81
|
+
--go-lite_opt=features=marshal+unmarshal+size+equal+clone \
|
|
82
|
+
--go-starpc_out=$$(pwd)/vendor \
|
|
83
|
+
--ts_proto_out=$$(pwd)/vendor \
|
|
84
|
+
--ts_proto_opt=esModuleInterop=true \
|
|
85
|
+
--ts_proto_opt=fileSuffix=.pb \
|
|
86
|
+
--ts_proto_opt=importSuffix=.js \
|
|
87
|
+
--ts_proto_opt=forceLong=long \
|
|
88
|
+
--ts_proto_opt=oneof=unions \
|
|
89
|
+
--ts_proto_opt=outputServices=default,outputServices=generic-definitions \
|
|
90
|
+
--ts_proto_opt=useAbortSignal=true \
|
|
91
|
+
--ts_proto_opt=useAsyncIterable=true \
|
|
92
|
+
--ts_proto_opt=useDate=true \
|
|
93
|
+
--proto_path $$(pwd)/vendor \
|
|
94
|
+
--print_structure \
|
|
95
|
+
--only_specified_files \
|
|
96
|
+
$$(\
|
|
97
|
+
git \
|
|
98
|
+
ls-files "$$1" |\
|
|
99
|
+
xargs printf -- \
|
|
100
|
+
"$$(pwd)/vendor/$${PROJECT}/%s "); \
|
|
101
|
+
}; \
|
|
102
|
+
protogen "./*.proto"; \
|
|
130
103
|
rm $$(pwd)/vendor/$${PROJECT} || true
|
|
104
|
+
$(GOIMPORTS) -w ./
|
|
131
105
|
npm run format:js
|
|
132
106
|
|
|
133
|
-
.PHONY: genproto
|
|
134
|
-
genproto: gengo gents
|
|
135
|
-
|
|
136
107
|
.PHONY: gen
|
|
137
108
|
gen: genproto
|
|
138
109
|
|
|
@@ -146,21 +117,21 @@ list: $(GO_MOD_OUTDATED)
|
|
|
146
117
|
|
|
147
118
|
.PHONY: lint
|
|
148
119
|
lint: $(GOLANGCI_LINT)
|
|
149
|
-
$(GOLANGCI_LINT) run
|
|
120
|
+
$(GOLANGCI_LINT) run
|
|
150
121
|
|
|
151
122
|
.PHONY: fix
|
|
152
123
|
fix: $(GOLANGCI_LINT)
|
|
153
|
-
$(GOLANGCI_LINT) run --fix
|
|
124
|
+
$(GOLANGCI_LINT) run --fix
|
|
125
|
+
|
|
126
|
+
.PHONY: test
|
|
127
|
+
test:
|
|
128
|
+
go test -v ./...
|
|
154
129
|
|
|
155
130
|
.PHONY: format
|
|
156
131
|
format: $(GOFUMPT) $(GOIMPORTS)
|
|
157
132
|
$(GOIMPORTS) -w ./
|
|
158
133
|
$(GOFUMPT) -w ./
|
|
159
134
|
|
|
160
|
-
.PHONY: test
|
|
161
|
-
test:
|
|
162
|
-
go test -timeout=30s -v ./...
|
|
163
|
-
|
|
164
135
|
.PHONY: integration
|
|
165
136
|
integration: node_modules vendor
|
|
166
137
|
cd ./integration && bash ./integration.bash
|
package/e2e/mock/mock.pb.go
CHANGED
|
@@ -1,67 +1,28 @@
|
|
|
1
|
-
// Code generated by protoc-gen-go. DO NOT EDIT.
|
|
2
|
-
//
|
|
3
|
-
// protoc-gen-go v1.33.0-devel
|
|
4
|
-
// protoc v4.25.3
|
|
1
|
+
// Code generated by protoc-gen-go-lite. DO NOT EDIT.
|
|
2
|
+
// protoc-gen-go-lite version: v0.2.3
|
|
5
3
|
// source: github.com/aperturerobotics/starpc/e2e/mock/mock.proto
|
|
6
4
|
|
|
7
5
|
package e2e_mock
|
|
8
6
|
|
|
9
7
|
import (
|
|
10
|
-
|
|
11
|
-
|
|
8
|
+
fmt "fmt"
|
|
9
|
+
io "io"
|
|
12
10
|
|
|
13
|
-
|
|
14
|
-
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
|
15
|
-
)
|
|
16
|
-
|
|
17
|
-
const (
|
|
18
|
-
// Verify that this generated code is sufficiently up-to-date.
|
|
19
|
-
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
|
|
20
|
-
// Verify that runtime/protoimpl is sufficiently up-to-date.
|
|
21
|
-
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
|
|
11
|
+
protohelpers "github.com/aperturerobotics/protobuf-go-lite/protohelpers"
|
|
22
12
|
)
|
|
23
13
|
|
|
24
14
|
// MockMsg is the mock message body.
|
|
25
15
|
type MockMsg struct {
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
unknownFields protoimpl.UnknownFields
|
|
29
|
-
|
|
30
|
-
Body string `protobuf:"bytes,1,opt,name=body,proto3" json:"body,omitempty"`
|
|
16
|
+
unknownFields []byte
|
|
17
|
+
Body string `protobuf:"bytes,1,opt,name=body,proto3" json:"body,omitempty"`
|
|
31
18
|
}
|
|
32
19
|
|
|
33
20
|
func (x *MockMsg) Reset() {
|
|
34
21
|
*x = MockMsg{}
|
|
35
|
-
if protoimpl.UnsafeEnabled {
|
|
36
|
-
mi := &file_github_com_aperturerobotics_starpc_e2e_mock_mock_proto_msgTypes[0]
|
|
37
|
-
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
38
|
-
ms.StoreMessageInfo(mi)
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
func (x *MockMsg) String() string {
|
|
43
|
-
return protoimpl.X.MessageStringOf(x)
|
|
44
22
|
}
|
|
45
23
|
|
|
46
24
|
func (*MockMsg) ProtoMessage() {}
|
|
47
25
|
|
|
48
|
-
func (x *MockMsg) ProtoReflect() protoreflect.Message {
|
|
49
|
-
mi := &file_github_com_aperturerobotics_starpc_e2e_mock_mock_proto_msgTypes[0]
|
|
50
|
-
if protoimpl.UnsafeEnabled && x != nil {
|
|
51
|
-
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
|
52
|
-
if ms.LoadMessageInfo() == nil {
|
|
53
|
-
ms.StoreMessageInfo(mi)
|
|
54
|
-
}
|
|
55
|
-
return ms
|
|
56
|
-
}
|
|
57
|
-
return mi.MessageOf(x)
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
// Deprecated: Use MockMsg.ProtoReflect.Descriptor instead.
|
|
61
|
-
func (*MockMsg) Descriptor() ([]byte, []int) {
|
|
62
|
-
return file_github_com_aperturerobotics_starpc_e2e_mock_mock_proto_rawDescGZIP(), []int{0}
|
|
63
|
-
}
|
|
64
|
-
|
|
65
26
|
func (x *MockMsg) GetBody() string {
|
|
66
27
|
if x != nil {
|
|
67
28
|
return x.Body
|
|
@@ -69,83 +30,176 @@ func (x *MockMsg) GetBody() string {
|
|
|
69
30
|
return ""
|
|
70
31
|
}
|
|
71
32
|
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
0x6f, 0x63, 0x6b, 0x2e, 0x4d, 0x6f, 0x63, 0x6b, 0x4d, 0x73, 0x67, 0x1a, 0x11, 0x2e, 0x65, 0x32,
|
|
84
|
-
0x65, 0x2e, 0x6d, 0x6f, 0x63, 0x6b, 0x2e, 0x4d, 0x6f, 0x63, 0x6b, 0x4d, 0x73, 0x67, 0x62, 0x06,
|
|
85
|
-
0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
|
33
|
+
func (m *MockMsg) CloneVT() *MockMsg {
|
|
34
|
+
if m == nil {
|
|
35
|
+
return (*MockMsg)(nil)
|
|
36
|
+
}
|
|
37
|
+
r := new(MockMsg)
|
|
38
|
+
r.Body = m.Body
|
|
39
|
+
if len(m.unknownFields) > 0 {
|
|
40
|
+
r.unknownFields = make([]byte, len(m.unknownFields))
|
|
41
|
+
copy(r.unknownFields, m.unknownFields)
|
|
42
|
+
}
|
|
43
|
+
return r
|
|
86
44
|
}
|
|
87
45
|
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
)
|
|
46
|
+
func (m *MockMsg) CloneMessageVT() any {
|
|
47
|
+
return m.CloneVT()
|
|
48
|
+
}
|
|
92
49
|
|
|
93
|
-
func
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
}
|
|
97
|
-
|
|
50
|
+
func (this *MockMsg) EqualVT(that *MockMsg) bool {
|
|
51
|
+
if this == that {
|
|
52
|
+
return true
|
|
53
|
+
} else if this == nil || that == nil {
|
|
54
|
+
return false
|
|
55
|
+
}
|
|
56
|
+
if this.Body != that.Body {
|
|
57
|
+
return false
|
|
58
|
+
}
|
|
59
|
+
return string(this.unknownFields) == string(that.unknownFields)
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
func (this *MockMsg) EqualMessageVT(thatMsg any) bool {
|
|
63
|
+
that, ok := thatMsg.(*MockMsg)
|
|
64
|
+
if !ok {
|
|
65
|
+
return false
|
|
66
|
+
}
|
|
67
|
+
return this.EqualVT(that)
|
|
68
|
+
}
|
|
69
|
+
func (m *MockMsg) MarshalVT() (dAtA []byte, err error) {
|
|
70
|
+
if m == nil {
|
|
71
|
+
return nil, nil
|
|
72
|
+
}
|
|
73
|
+
size := m.SizeVT()
|
|
74
|
+
dAtA = make([]byte, size)
|
|
75
|
+
n, err := m.MarshalToSizedBufferVT(dAtA[:size])
|
|
76
|
+
if err != nil {
|
|
77
|
+
return nil, err
|
|
78
|
+
}
|
|
79
|
+
return dAtA[:n], nil
|
|
98
80
|
}
|
|
99
81
|
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
(
|
|
82
|
+
func (m *MockMsg) MarshalToVT(dAtA []byte) (int, error) {
|
|
83
|
+
size := m.SizeVT()
|
|
84
|
+
return m.MarshalToSizedBufferVT(dAtA[:size])
|
|
103
85
|
}
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
86
|
+
|
|
87
|
+
func (m *MockMsg) MarshalToSizedBufferVT(dAtA []byte) (int, error) {
|
|
88
|
+
if m == nil {
|
|
89
|
+
return 0, nil
|
|
90
|
+
}
|
|
91
|
+
i := len(dAtA)
|
|
92
|
+
_ = i
|
|
93
|
+
var l int
|
|
94
|
+
_ = l
|
|
95
|
+
if m.unknownFields != nil {
|
|
96
|
+
i -= len(m.unknownFields)
|
|
97
|
+
copy(dAtA[i:], m.unknownFields)
|
|
98
|
+
}
|
|
99
|
+
if len(m.Body) > 0 {
|
|
100
|
+
i -= len(m.Body)
|
|
101
|
+
copy(dAtA[i:], m.Body)
|
|
102
|
+
i = protohelpers.EncodeVarint(dAtA, i, uint64(len(m.Body)))
|
|
103
|
+
i--
|
|
104
|
+
dAtA[i] = 0xa
|
|
105
|
+
}
|
|
106
|
+
return len(dAtA) - i, nil
|
|
112
107
|
}
|
|
113
108
|
|
|
114
|
-
func
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
109
|
+
func (m *MockMsg) SizeVT() (n int) {
|
|
110
|
+
if m == nil {
|
|
111
|
+
return 0
|
|
112
|
+
}
|
|
113
|
+
var l int
|
|
114
|
+
_ = l
|
|
115
|
+
l = len(m.Body)
|
|
116
|
+
if l > 0 {
|
|
117
|
+
n += 1 + l + protohelpers.SizeOfVarint(uint64(l))
|
|
118
118
|
}
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
119
|
+
n += len(m.unknownFields)
|
|
120
|
+
return n
|
|
121
|
+
}
|
|
122
|
+
|
|
123
|
+
func (m *MockMsg) UnmarshalVT(dAtA []byte) error {
|
|
124
|
+
l := len(dAtA)
|
|
125
|
+
iNdEx := 0
|
|
126
|
+
for iNdEx < l {
|
|
127
|
+
preIndex := iNdEx
|
|
128
|
+
var wire uint64
|
|
129
|
+
for shift := uint(0); ; shift += 7 {
|
|
130
|
+
if shift >= 64 {
|
|
131
|
+
return protohelpers.ErrIntOverflow
|
|
132
|
+
}
|
|
133
|
+
if iNdEx >= l {
|
|
134
|
+
return io.ErrUnexpectedEOF
|
|
130
135
|
}
|
|
136
|
+
b := dAtA[iNdEx]
|
|
137
|
+
iNdEx++
|
|
138
|
+
wire |= uint64(b&0x7F) << shift
|
|
139
|
+
if b < 0x80 {
|
|
140
|
+
break
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
fieldNum := int32(wire >> 3)
|
|
144
|
+
wireType := int(wire & 0x7)
|
|
145
|
+
if wireType == 4 {
|
|
146
|
+
return fmt.Errorf("proto: MockMsg: wiretype end group for non-group")
|
|
147
|
+
}
|
|
148
|
+
if fieldNum <= 0 {
|
|
149
|
+
return fmt.Errorf("proto: MockMsg: illegal tag %d (wire type %d)", fieldNum, wire)
|
|
131
150
|
}
|
|
151
|
+
switch fieldNum {
|
|
152
|
+
case 1:
|
|
153
|
+
if wireType != 2 {
|
|
154
|
+
return fmt.Errorf("proto: wrong wireType = %d for field Body", wireType)
|
|
155
|
+
}
|
|
156
|
+
var stringLen uint64
|
|
157
|
+
for shift := uint(0); ; shift += 7 {
|
|
158
|
+
if shift >= 64 {
|
|
159
|
+
return protohelpers.ErrIntOverflow
|
|
160
|
+
}
|
|
161
|
+
if iNdEx >= l {
|
|
162
|
+
return io.ErrUnexpectedEOF
|
|
163
|
+
}
|
|
164
|
+
b := dAtA[iNdEx]
|
|
165
|
+
iNdEx++
|
|
166
|
+
stringLen |= uint64(b&0x7F) << shift
|
|
167
|
+
if b < 0x80 {
|
|
168
|
+
break
|
|
169
|
+
}
|
|
170
|
+
}
|
|
171
|
+
intStringLen := int(stringLen)
|
|
172
|
+
if intStringLen < 0 {
|
|
173
|
+
return protohelpers.ErrInvalidLength
|
|
174
|
+
}
|
|
175
|
+
postIndex := iNdEx + intStringLen
|
|
176
|
+
if postIndex < 0 {
|
|
177
|
+
return protohelpers.ErrInvalidLength
|
|
178
|
+
}
|
|
179
|
+
if postIndex > l {
|
|
180
|
+
return io.ErrUnexpectedEOF
|
|
181
|
+
}
|
|
182
|
+
m.Body = string(dAtA[iNdEx:postIndex])
|
|
183
|
+
iNdEx = postIndex
|
|
184
|
+
default:
|
|
185
|
+
iNdEx = preIndex
|
|
186
|
+
skippy, err := protohelpers.Skip(dAtA[iNdEx:])
|
|
187
|
+
if err != nil {
|
|
188
|
+
return err
|
|
189
|
+
}
|
|
190
|
+
if (skippy < 0) || (iNdEx+skippy) < 0 {
|
|
191
|
+
return protohelpers.ErrInvalidLength
|
|
192
|
+
}
|
|
193
|
+
if (iNdEx + skippy) > l {
|
|
194
|
+
return io.ErrUnexpectedEOF
|
|
195
|
+
}
|
|
196
|
+
m.unknownFields = append(m.unknownFields, dAtA[iNdEx:iNdEx+skippy]...)
|
|
197
|
+
iNdEx += skippy
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
if iNdEx > l {
|
|
202
|
+
return io.ErrUnexpectedEOF
|
|
132
203
|
}
|
|
133
|
-
|
|
134
|
-
out := protoimpl.TypeBuilder{
|
|
135
|
-
File: protoimpl.DescBuilder{
|
|
136
|
-
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
|
137
|
-
RawDescriptor: file_github_com_aperturerobotics_starpc_e2e_mock_mock_proto_rawDesc,
|
|
138
|
-
NumEnums: 0,
|
|
139
|
-
NumMessages: 1,
|
|
140
|
-
NumExtensions: 0,
|
|
141
|
-
NumServices: 1,
|
|
142
|
-
},
|
|
143
|
-
GoTypes: file_github_com_aperturerobotics_starpc_e2e_mock_mock_proto_goTypes,
|
|
144
|
-
DependencyIndexes: file_github_com_aperturerobotics_starpc_e2e_mock_mock_proto_depIdxs,
|
|
145
|
-
MessageInfos: file_github_com_aperturerobotics_starpc_e2e_mock_mock_proto_msgTypes,
|
|
146
|
-
}.Build()
|
|
147
|
-
File_github_com_aperturerobotics_starpc_e2e_mock_mock_proto = out.File
|
|
148
|
-
file_github_com_aperturerobotics_starpc_e2e_mock_mock_proto_rawDesc = nil
|
|
149
|
-
file_github_com_aperturerobotics_starpc_e2e_mock_mock_proto_goTypes = nil
|
|
150
|
-
file_github_com_aperturerobotics_starpc_e2e_mock_mock_proto_depIdxs = nil
|
|
204
|
+
return nil
|
|
151
205
|
}
|
package/e2e/mock/mock_srpc.pb.go
CHANGED