Change pipeline api types

This commit is contained in:
2022-12-24 22:11:44 -07:00
parent 112bca1a55
commit 825f269710
3 changed files with 29 additions and 29 deletions
+2 -2
View File
@@ -18,9 +18,9 @@ func (s *ApiServer) GetRunner(
ctx context.Context,
req *connect.Request[get_runnerv1.GetRunnerRequest],
) (*connect.Response[get_runnerv1.GetRunnerResponse], error) {
log.Debugf("Request Headers: %v", req.Header())
res := connect.NewResponse(&get_runnerv1.GetRunnerResponse{
Success: true,
RunnerId: 0,
})
res.Header().Set("GetRunner-Version", "v1")
return res, nil
+25 -25
View File
@@ -25,7 +25,7 @@ type GetRunnerRequest struct {
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
Tag string `protobuf:"bytes,1,opt,name=tag,proto3" json:"tag,omitempty"`
Tags []string `protobuf:"bytes,1,rep,name=tags,proto3" json:"tags,omitempty"`
}
func (x *GetRunnerRequest) Reset() {
@@ -60,11 +60,11 @@ func (*GetRunnerRequest) Descriptor() ([]byte, []int) {
return file_get_runner_v1_get_runner_proto_rawDescGZIP(), []int{0}
}
func (x *GetRunnerRequest) GetTag() string {
func (x *GetRunnerRequest) GetTags() []string {
if x != nil {
return x.Tag
return x.Tags
}
return ""
return nil
}
type GetRunnerResponse struct {
@@ -72,7 +72,7 @@ type GetRunnerResponse struct {
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
Success bool `protobuf:"varint,1,opt,name=success,proto3" json:"success,omitempty"`
RunnerId int64 `protobuf:"varint,1,opt,name=runner_id,json=runnerId,proto3" json:"runner_id,omitempty"`
}
func (x *GetRunnerResponse) Reset() {
@@ -107,11 +107,11 @@ func (*GetRunnerResponse) Descriptor() ([]byte, []int) {
return file_get_runner_v1_get_runner_proto_rawDescGZIP(), []int{1}
}
func (x *GetRunnerResponse) GetSuccess() bool {
func (x *GetRunnerResponse) GetRunnerId() int64 {
if x != nil {
return x.Success
return x.RunnerId
}
return false
return 0
}
var File_get_runner_v1_get_runner_proto protoreflect.FileDescriptor
@@ -120,23 +120,23 @@ var file_get_runner_v1_get_runner_proto_rawDesc = []byte{
0x0a, 0x1e, 0x67, 0x65, 0x74, 0x5f, 0x72, 0x75, 0x6e, 0x6e, 0x65, 0x72, 0x2f, 0x76, 0x31, 0x2f,
0x67, 0x65, 0x74, 0x5f, 0x72, 0x75, 0x6e, 0x6e, 0x65, 0x72, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f,
0x12, 0x0d, 0x67, 0x65, 0x74, 0x5f, 0x72, 0x75, 0x6e, 0x6e, 0x65, 0x72, 0x2e, 0x76, 0x31, 0x22,
0x24, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x75, 0x6e, 0x6e, 0x65, 0x72, 0x52, 0x65, 0x71, 0x75,
0x65, 0x73, 0x74, 0x12, 0x10, 0x0a, 0x03, 0x74, 0x61, 0x67, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09,
0x52, 0x03, 0x74, 0x61, 0x67, 0x22, 0x2d, 0x0a, 0x11, 0x47, 0x65, 0x74, 0x52, 0x75, 0x6e, 0x6e,
0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x18, 0x0a, 0x07, 0x73, 0x75,
0x63, 0x63, 0x65, 0x73, 0x73, 0x18, 0x01, 0x20, 0x01, 0x28, 0x08, 0x52, 0x07, 0x73, 0x75, 0x63,
0x63, 0x65, 0x73, 0x73, 0x32, 0x64, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x75, 0x6e, 0x6e, 0x65,
0x72, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x50, 0x0a, 0x09, 0x47, 0x65, 0x74, 0x52,
0x75, 0x6e, 0x6e, 0x65, 0x72, 0x12, 0x1f, 0x2e, 0x67, 0x65, 0x74, 0x5f, 0x72, 0x75, 0x6e, 0x6e,
0x65, 0x72, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x75, 0x6e, 0x6e, 0x65, 0x72, 0x52,
0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x2e, 0x67, 0x65, 0x74, 0x5f, 0x72, 0x75, 0x6e,
0x6e, 0x65, 0x72, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x75, 0x6e, 0x6e, 0x65, 0x72,
0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42, 0x44, 0x5a, 0x42, 0x67, 0x69,
0x74, 0x2e, 0x6f, 0x68, 0x65, 0x61, 0x2e, 0x78, 0x79, 0x7a, 0x2f, 0x63, 0x75, 0x72, 0x73, 0x6f,
0x72, 0x69, 0x75, 0x73, 0x2f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x2f, 0x70, 0x72, 0x6f, 0x74,
0x6f, 0x2f, 0x67, 0x65, 0x6e, 0x2f, 0x67, 0x65, 0x74, 0x5f, 0x72, 0x75, 0x6e, 0x6e, 0x65, 0x72,
0x2f, 0x76, 0x31, 0x3b, 0x67, 0x65, 0x74, 0x5f, 0x72, 0x75, 0x6e, 0x6e, 0x65, 0x72, 0x76, 0x31,
0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
0x26, 0x0a, 0x10, 0x47, 0x65, 0x74, 0x52, 0x75, 0x6e, 0x6e, 0x65, 0x72, 0x52, 0x65, 0x71, 0x75,
0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x61, 0x67, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28,
0x09, 0x52, 0x04, 0x74, 0x61, 0x67, 0x73, 0x22, 0x30, 0x0a, 0x11, 0x47, 0x65, 0x74, 0x52, 0x75,
0x6e, 0x6e, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1b, 0x0a, 0x09,
0x72, 0x75, 0x6e, 0x6e, 0x65, 0x72, 0x5f, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x03, 0x52,
0x08, 0x72, 0x75, 0x6e, 0x6e, 0x65, 0x72, 0x49, 0x64, 0x32, 0x64, 0x0a, 0x10, 0x47, 0x65, 0x74,
0x52, 0x75, 0x6e, 0x6e, 0x65, 0x72, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x50, 0x0a,
0x09, 0x47, 0x65, 0x74, 0x52, 0x75, 0x6e, 0x6e, 0x65, 0x72, 0x12, 0x1f, 0x2e, 0x67, 0x65, 0x74,
0x5f, 0x72, 0x75, 0x6e, 0x6e, 0x65, 0x72, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52, 0x75,
0x6e, 0x6e, 0x65, 0x72, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x2e, 0x67, 0x65,
0x74, 0x5f, 0x72, 0x75, 0x6e, 0x6e, 0x65, 0x72, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x52,
0x75, 0x6e, 0x6e, 0x65, 0x72, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42,
0x44, 0x5a, 0x42, 0x67, 0x69, 0x74, 0x2e, 0x6f, 0x68, 0x65, 0x61, 0x2e, 0x78, 0x79, 0x7a, 0x2f,
0x63, 0x75, 0x72, 0x73, 0x6f, 0x72, 0x69, 0x75, 0x73, 0x2f, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72,
0x2f, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x2f, 0x67, 0x65, 0x6e, 0x2f, 0x67, 0x65, 0x74, 0x5f, 0x72,
0x75, 0x6e, 0x6e, 0x65, 0x72, 0x2f, 0x76, 0x31, 0x3b, 0x67, 0x65, 0x74, 0x5f, 0x72, 0x75, 0x6e,
0x6e, 0x65, 0x72, 0x76, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
}
var (
+2 -2
View File
@@ -5,11 +5,11 @@ package get_runner.v1;
option go_package = "git.ohea.xyz/cursorius/server/proto/gen/get_runner/v1;get_runnerv1";
message GetRunnerRequest {
string tag = 1;
repeated string tags = 1;
}
message GetRunnerResponse {
bool success = 1;
int64 runner_id = 1;
}
service GetRunnerService {