Best Rod code snippet using proto.ProtoReq
polyaxon_sdk.pb.gw.go
Source:polyaxon_sdk.pb.gw.go
1// Copyright 2019 Polyaxon, Inc.2//3// Licensed under the Apache License, Version 2.0 (the "License");4// you may not use this file except in compliance with the License.5// You may obtain a copy of the License at6//7// http://www.apache.org/licenses/LICENSE-2.08//9// Unless required by applicable law or agreed to in writing, software10// distributed under the License is distributed on an "AS IS" BASIS,11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.12// See the License for the specific language governing permissions and13// limitations under the License.14// Code generated by protoc-gen-grpc-gateway. DO NOT EDIT.15// source: v1/polyaxon_sdk.proto16/*17Package v1 is a reverse proxy.18It translates gRPC into RESTful JSON APIs.19*/20package v121import (22 "context"23 "io"24 "net/http"25 "github.com/golang/protobuf/descriptor"26 "github.com/golang/protobuf/proto"27 "github.com/golang/protobuf/ptypes/empty"28 "github.com/grpc-ecosystem/grpc-gateway/runtime"29 "github.com/grpc-ecosystem/grpc-gateway/utilities"30 "google.golang.org/grpc"31 "google.golang.org/grpc/codes"32 "google.golang.org/grpc/grpclog"33 "google.golang.org/grpc/status"34)35// Suppress "imported and not used" errors36var _ codes.Code37var _ io.Reader38var _ status.Status39var _ = runtime.String40var _ = utilities.NewDoubleArray41var _ = descriptor.ForMessage42var (43 filter_RunsV1_ListBookmarkedRuns_0 = &utilities.DoubleArray{Encoding: map[string]int{"user": 0}, Base: []int{1, 1, 0}, Check: []int{0, 1, 2}}44)45func request_RunsV1_ListBookmarkedRuns_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {46 var protoReq UserResouceListRequest47 var metadata runtime.ServerMetadata48 var (49 val string50 ok bool51 err error52 _ = err53 )54 val, ok = pathParams["user"]55 if !ok {56 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "user")57 }58 protoReq.User, err = runtime.String(val)59 if err != nil {60 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "user", err)61 }62 if err := req.ParseForm(); err != nil {63 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)64 }65 if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_RunsV1_ListBookmarkedRuns_0); err != nil {66 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)67 }68 msg, err := client.ListBookmarkedRuns(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))69 return msg, metadata, err70}71func local_request_RunsV1_ListBookmarkedRuns_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {72 var protoReq UserResouceListRequest73 var metadata runtime.ServerMetadata74 var (75 val string76 ok bool77 err error78 _ = err79 )80 val, ok = pathParams["user"]81 if !ok {82 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "user")83 }84 protoReq.User, err = runtime.String(val)85 if err != nil {86 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "user", err)87 }88 if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_RunsV1_ListBookmarkedRuns_0); err != nil {89 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)90 }91 msg, err := server.ListBookmarkedRuns(ctx, &protoReq)92 return msg, metadata, err93}94var (95 filter_RunsV1_ListArchivedRuns_0 = &utilities.DoubleArray{Encoding: map[string]int{"user": 0}, Base: []int{1, 1, 0}, Check: []int{0, 1, 2}}96)97func request_RunsV1_ListArchivedRuns_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {98 var protoReq UserResouceListRequest99 var metadata runtime.ServerMetadata100 var (101 val string102 ok bool103 err error104 _ = err105 )106 val, ok = pathParams["user"]107 if !ok {108 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "user")109 }110 protoReq.User, err = runtime.String(val)111 if err != nil {112 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "user", err)113 }114 if err := req.ParseForm(); err != nil {115 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)116 }117 if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_RunsV1_ListArchivedRuns_0); err != nil {118 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)119 }120 msg, err := client.ListArchivedRuns(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))121 return msg, metadata, err122}123func local_request_RunsV1_ListArchivedRuns_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {124 var protoReq UserResouceListRequest125 var metadata runtime.ServerMetadata126 var (127 val string128 ok bool129 err error130 _ = err131 )132 val, ok = pathParams["user"]133 if !ok {134 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "user")135 }136 protoReq.User, err = runtime.String(val)137 if err != nil {138 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "user", err)139 }140 if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_RunsV1_ListArchivedRuns_0); err != nil {141 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)142 }143 msg, err := server.ListArchivedRuns(ctx, &protoReq)144 return msg, metadata, err145}146var (147 filter_RunsV1_ListRuns_0 = &utilities.DoubleArray{Encoding: map[string]int{"owner": 0, "project": 1}, Base: []int{1, 1, 2, 0, 0}, Check: []int{0, 1, 1, 2, 3}}148)149func request_RunsV1_ListRuns_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {150 var protoReq ProjectResourceListRequest151 var metadata runtime.ServerMetadata152 var (153 val string154 ok bool155 err error156 _ = err157 )158 val, ok = pathParams["owner"]159 if !ok {160 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")161 }162 protoReq.Owner, err = runtime.String(val)163 if err != nil {164 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)165 }166 val, ok = pathParams["project"]167 if !ok {168 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")169 }170 protoReq.Project, err = runtime.String(val)171 if err != nil {172 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)173 }174 if err := req.ParseForm(); err != nil {175 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)176 }177 if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_RunsV1_ListRuns_0); err != nil {178 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)179 }180 msg, err := client.ListRuns(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))181 return msg, metadata, err182}183func local_request_RunsV1_ListRuns_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {184 var protoReq ProjectResourceListRequest185 var metadata runtime.ServerMetadata186 var (187 val string188 ok bool189 err error190 _ = err191 )192 val, ok = pathParams["owner"]193 if !ok {194 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")195 }196 protoReq.Owner, err = runtime.String(val)197 if err != nil {198 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)199 }200 val, ok = pathParams["project"]201 if !ok {202 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")203 }204 protoReq.Project, err = runtime.String(val)205 if err != nil {206 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)207 }208 if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_RunsV1_ListRuns_0); err != nil {209 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)210 }211 msg, err := server.ListRuns(ctx, &protoReq)212 return msg, metadata, err213}214func request_RunsV1_CreateRun_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {215 var protoReq RunBodyRequest216 var metadata runtime.ServerMetadata217 newReader, berr := utilities.IOReaderFactory(req.Body)218 if berr != nil {219 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)220 }221 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Run); err != nil && err != io.EOF {222 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)223 }224 var (225 val string226 ok bool227 err error228 _ = err229 )230 val, ok = pathParams["owner"]231 if !ok {232 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")233 }234 protoReq.Owner, err = runtime.String(val)235 if err != nil {236 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)237 }238 val, ok = pathParams["project"]239 if !ok {240 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")241 }242 protoReq.Project, err = runtime.String(val)243 if err != nil {244 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)245 }246 msg, err := client.CreateRun(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))247 return msg, metadata, err248}249func local_request_RunsV1_CreateRun_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {250 var protoReq RunBodyRequest251 var metadata runtime.ServerMetadata252 newReader, berr := utilities.IOReaderFactory(req.Body)253 if berr != nil {254 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)255 }256 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Run); err != nil && err != io.EOF {257 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)258 }259 var (260 val string261 ok bool262 err error263 _ = err264 )265 val, ok = pathParams["owner"]266 if !ok {267 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")268 }269 protoReq.Owner, err = runtime.String(val)270 if err != nil {271 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)272 }273 val, ok = pathParams["project"]274 if !ok {275 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")276 }277 protoReq.Project, err = runtime.String(val)278 if err != nil {279 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)280 }281 msg, err := server.CreateRun(ctx, &protoReq)282 return msg, metadata, err283}284func request_RunsV1_GetRun_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {285 var protoReq EntityResourceRequest286 var metadata runtime.ServerMetadata287 var (288 val string289 ok bool290 err error291 _ = err292 )293 val, ok = pathParams["owner"]294 if !ok {295 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")296 }297 protoReq.Owner, err = runtime.String(val)298 if err != nil {299 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)300 }301 val, ok = pathParams["project"]302 if !ok {303 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")304 }305 protoReq.Project, err = runtime.String(val)306 if err != nil {307 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)308 }309 val, ok = pathParams["uuid"]310 if !ok {311 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")312 }313 protoReq.Uuid, err = runtime.String(val)314 if err != nil {315 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)316 }317 msg, err := client.GetRun(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))318 return msg, metadata, err319}320func local_request_RunsV1_GetRun_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {321 var protoReq EntityResourceRequest322 var metadata runtime.ServerMetadata323 var (324 val string325 ok bool326 err error327 _ = err328 )329 val, ok = pathParams["owner"]330 if !ok {331 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")332 }333 protoReq.Owner, err = runtime.String(val)334 if err != nil {335 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)336 }337 val, ok = pathParams["project"]338 if !ok {339 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")340 }341 protoReq.Project, err = runtime.String(val)342 if err != nil {343 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)344 }345 val, ok = pathParams["uuid"]346 if !ok {347 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")348 }349 protoReq.Uuid, err = runtime.String(val)350 if err != nil {351 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)352 }353 msg, err := server.GetRun(ctx, &protoReq)354 return msg, metadata, err355}356func request_RunsV1_UpdateRun_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {357 var protoReq RunBodyRequest358 var metadata runtime.ServerMetadata359 newReader, berr := utilities.IOReaderFactory(req.Body)360 if berr != nil {361 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)362 }363 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Run); err != nil && err != io.EOF {364 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)365 }366 var (367 val string368 ok bool369 err error370 _ = err371 )372 val, ok = pathParams["owner"]373 if !ok {374 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")375 }376 protoReq.Owner, err = runtime.String(val)377 if err != nil {378 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)379 }380 val, ok = pathParams["project"]381 if !ok {382 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")383 }384 protoReq.Project, err = runtime.String(val)385 if err != nil {386 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)387 }388 val, ok = pathParams["run.uuid"]389 if !ok {390 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "run.uuid")391 }392 err = runtime.PopulateFieldFromPath(&protoReq, "run.uuid", val)393 if err != nil {394 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "run.uuid", err)395 }396 msg, err := client.UpdateRun(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))397 return msg, metadata, err398}399func local_request_RunsV1_UpdateRun_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {400 var protoReq RunBodyRequest401 var metadata runtime.ServerMetadata402 newReader, berr := utilities.IOReaderFactory(req.Body)403 if berr != nil {404 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)405 }406 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Run); err != nil && err != io.EOF {407 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)408 }409 var (410 val string411 ok bool412 err error413 _ = err414 )415 val, ok = pathParams["owner"]416 if !ok {417 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")418 }419 protoReq.Owner, err = runtime.String(val)420 if err != nil {421 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)422 }423 val, ok = pathParams["project"]424 if !ok {425 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")426 }427 protoReq.Project, err = runtime.String(val)428 if err != nil {429 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)430 }431 val, ok = pathParams["run.uuid"]432 if !ok {433 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "run.uuid")434 }435 err = runtime.PopulateFieldFromPath(&protoReq, "run.uuid", val)436 if err != nil {437 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "run.uuid", err)438 }439 msg, err := server.UpdateRun(ctx, &protoReq)440 return msg, metadata, err441}442func request_RunsV1_PatchRun_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {443 var protoReq RunBodyRequest444 var metadata runtime.ServerMetadata445 newReader, berr := utilities.IOReaderFactory(req.Body)446 if berr != nil {447 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)448 }449 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Run); err != nil && err != io.EOF {450 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)451 }452 var (453 val string454 ok bool455 err error456 _ = err457 )458 val, ok = pathParams["owner"]459 if !ok {460 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")461 }462 protoReq.Owner, err = runtime.String(val)463 if err != nil {464 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)465 }466 val, ok = pathParams["project"]467 if !ok {468 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")469 }470 protoReq.Project, err = runtime.String(val)471 if err != nil {472 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)473 }474 val, ok = pathParams["run.uuid"]475 if !ok {476 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "run.uuid")477 }478 err = runtime.PopulateFieldFromPath(&protoReq, "run.uuid", val)479 if err != nil {480 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "run.uuid", err)481 }482 msg, err := client.PatchRun(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))483 return msg, metadata, err484}485func local_request_RunsV1_PatchRun_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {486 var protoReq RunBodyRequest487 var metadata runtime.ServerMetadata488 newReader, berr := utilities.IOReaderFactory(req.Body)489 if berr != nil {490 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)491 }492 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Run); err != nil && err != io.EOF {493 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)494 }495 var (496 val string497 ok bool498 err error499 _ = err500 )501 val, ok = pathParams["owner"]502 if !ok {503 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")504 }505 protoReq.Owner, err = runtime.String(val)506 if err != nil {507 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)508 }509 val, ok = pathParams["project"]510 if !ok {511 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")512 }513 protoReq.Project, err = runtime.String(val)514 if err != nil {515 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)516 }517 val, ok = pathParams["run.uuid"]518 if !ok {519 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "run.uuid")520 }521 err = runtime.PopulateFieldFromPath(&protoReq, "run.uuid", val)522 if err != nil {523 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "run.uuid", err)524 }525 msg, err := server.PatchRun(ctx, &protoReq)526 return msg, metadata, err527}528func request_RunsV1_DeleteRun_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {529 var protoReq EntityResourceRequest530 var metadata runtime.ServerMetadata531 var (532 val string533 ok bool534 err error535 _ = err536 )537 val, ok = pathParams["owner"]538 if !ok {539 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")540 }541 protoReq.Owner, err = runtime.String(val)542 if err != nil {543 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)544 }545 val, ok = pathParams["project"]546 if !ok {547 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")548 }549 protoReq.Project, err = runtime.String(val)550 if err != nil {551 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)552 }553 val, ok = pathParams["uuid"]554 if !ok {555 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")556 }557 protoReq.Uuid, err = runtime.String(val)558 if err != nil {559 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)560 }561 msg, err := client.DeleteRun(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))562 return msg, metadata, err563}564func local_request_RunsV1_DeleteRun_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {565 var protoReq EntityResourceRequest566 var metadata runtime.ServerMetadata567 var (568 val string569 ok bool570 err error571 _ = err572 )573 val, ok = pathParams["owner"]574 if !ok {575 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")576 }577 protoReq.Owner, err = runtime.String(val)578 if err != nil {579 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)580 }581 val, ok = pathParams["project"]582 if !ok {583 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")584 }585 protoReq.Project, err = runtime.String(val)586 if err != nil {587 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)588 }589 val, ok = pathParams["uuid"]590 if !ok {591 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")592 }593 protoReq.Uuid, err = runtime.String(val)594 if err != nil {595 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)596 }597 msg, err := server.DeleteRun(ctx, &protoReq)598 return msg, metadata, err599}600func request_RunsV1_DeleteRuns_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {601 var protoReq ProjectResourceUuidsBodyRequest602 var metadata runtime.ServerMetadata603 newReader, berr := utilities.IOReaderFactory(req.Body)604 if berr != nil {605 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)606 }607 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Uuids); err != nil && err != io.EOF {608 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)609 }610 var (611 val string612 ok bool613 err error614 _ = err615 )616 val, ok = pathParams["owner"]617 if !ok {618 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")619 }620 protoReq.Owner, err = runtime.String(val)621 if err != nil {622 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)623 }624 val, ok = pathParams["project"]625 if !ok {626 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")627 }628 protoReq.Project, err = runtime.String(val)629 if err != nil {630 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)631 }632 msg, err := client.DeleteRuns(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))633 return msg, metadata, err634}635func local_request_RunsV1_DeleteRuns_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {636 var protoReq ProjectResourceUuidsBodyRequest637 var metadata runtime.ServerMetadata638 newReader, berr := utilities.IOReaderFactory(req.Body)639 if berr != nil {640 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)641 }642 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Uuids); err != nil && err != io.EOF {643 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)644 }645 var (646 val string647 ok bool648 err error649 _ = err650 )651 val, ok = pathParams["owner"]652 if !ok {653 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")654 }655 protoReq.Owner, err = runtime.String(val)656 if err != nil {657 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)658 }659 val, ok = pathParams["project"]660 if !ok {661 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")662 }663 protoReq.Project, err = runtime.String(val)664 if err != nil {665 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)666 }667 msg, err := server.DeleteRuns(ctx, &protoReq)668 return msg, metadata, err669}670func request_RunsV1_StopRun_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {671 var protoReq EntityResourceRequest672 var metadata runtime.ServerMetadata673 var (674 val string675 ok bool676 err error677 _ = err678 )679 val, ok = pathParams["owner"]680 if !ok {681 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")682 }683 protoReq.Owner, err = runtime.String(val)684 if err != nil {685 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)686 }687 val, ok = pathParams["project"]688 if !ok {689 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")690 }691 protoReq.Project, err = runtime.String(val)692 if err != nil {693 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)694 }695 val, ok = pathParams["uuid"]696 if !ok {697 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")698 }699 protoReq.Uuid, err = runtime.String(val)700 if err != nil {701 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)702 }703 msg, err := client.StopRun(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))704 return msg, metadata, err705}706func local_request_RunsV1_StopRun_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {707 var protoReq EntityResourceRequest708 var metadata runtime.ServerMetadata709 var (710 val string711 ok bool712 err error713 _ = err714 )715 val, ok = pathParams["owner"]716 if !ok {717 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")718 }719 protoReq.Owner, err = runtime.String(val)720 if err != nil {721 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)722 }723 val, ok = pathParams["project"]724 if !ok {725 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")726 }727 protoReq.Project, err = runtime.String(val)728 if err != nil {729 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)730 }731 val, ok = pathParams["uuid"]732 if !ok {733 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")734 }735 protoReq.Uuid, err = runtime.String(val)736 if err != nil {737 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)738 }739 msg, err := server.StopRun(ctx, &protoReq)740 return msg, metadata, err741}742func request_RunsV1_StopRuns_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {743 var protoReq ProjectResourceUuidsBodyRequest744 var metadata runtime.ServerMetadata745 newReader, berr := utilities.IOReaderFactory(req.Body)746 if berr != nil {747 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)748 }749 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Uuids); err != nil && err != io.EOF {750 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)751 }752 var (753 val string754 ok bool755 err error756 _ = err757 )758 val, ok = pathParams["owner"]759 if !ok {760 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")761 }762 protoReq.Owner, err = runtime.String(val)763 if err != nil {764 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)765 }766 val, ok = pathParams["project"]767 if !ok {768 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")769 }770 protoReq.Project, err = runtime.String(val)771 if err != nil {772 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)773 }774 msg, err := client.StopRuns(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))775 return msg, metadata, err776}777func local_request_RunsV1_StopRuns_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {778 var protoReq ProjectResourceUuidsBodyRequest779 var metadata runtime.ServerMetadata780 newReader, berr := utilities.IOReaderFactory(req.Body)781 if berr != nil {782 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)783 }784 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Uuids); err != nil && err != io.EOF {785 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)786 }787 var (788 val string789 ok bool790 err error791 _ = err792 )793 val, ok = pathParams["owner"]794 if !ok {795 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")796 }797 protoReq.Owner, err = runtime.String(val)798 if err != nil {799 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)800 }801 val, ok = pathParams["project"]802 if !ok {803 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")804 }805 protoReq.Project, err = runtime.String(val)806 if err != nil {807 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)808 }809 msg, err := server.StopRuns(ctx, &protoReq)810 return msg, metadata, err811}812func request_RunsV1_InvalidateRun_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {813 var protoReq EntityResourceRequest814 var metadata runtime.ServerMetadata815 newReader, berr := utilities.IOReaderFactory(req.Body)816 if berr != nil {817 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)818 }819 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF {820 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)821 }822 var (823 val string824 ok bool825 err error826 _ = err827 )828 val, ok = pathParams["owner"]829 if !ok {830 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")831 }832 protoReq.Owner, err = runtime.String(val)833 if err != nil {834 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)835 }836 val, ok = pathParams["project"]837 if !ok {838 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")839 }840 protoReq.Project, err = runtime.String(val)841 if err != nil {842 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)843 }844 val, ok = pathParams["uuid"]845 if !ok {846 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")847 }848 protoReq.Uuid, err = runtime.String(val)849 if err != nil {850 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)851 }852 msg, err := client.InvalidateRun(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))853 return msg, metadata, err854}855func local_request_RunsV1_InvalidateRun_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {856 var protoReq EntityResourceRequest857 var metadata runtime.ServerMetadata858 newReader, berr := utilities.IOReaderFactory(req.Body)859 if berr != nil {860 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)861 }862 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF {863 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)864 }865 var (866 val string867 ok bool868 err error869 _ = err870 )871 val, ok = pathParams["owner"]872 if !ok {873 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")874 }875 protoReq.Owner, err = runtime.String(val)876 if err != nil {877 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)878 }879 val, ok = pathParams["project"]880 if !ok {881 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")882 }883 protoReq.Project, err = runtime.String(val)884 if err != nil {885 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)886 }887 val, ok = pathParams["uuid"]888 if !ok {889 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")890 }891 protoReq.Uuid, err = runtime.String(val)892 if err != nil {893 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)894 }895 msg, err := server.InvalidateRun(ctx, &protoReq)896 return msg, metadata, err897}898func request_RunsV1_InvalidateRuns_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {899 var protoReq ProjectResourceUuidsBodyRequest900 var metadata runtime.ServerMetadata901 newReader, berr := utilities.IOReaderFactory(req.Body)902 if berr != nil {903 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)904 }905 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Uuids); err != nil && err != io.EOF {906 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)907 }908 var (909 val string910 ok bool911 err error912 _ = err913 )914 val, ok = pathParams["owner"]915 if !ok {916 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")917 }918 protoReq.Owner, err = runtime.String(val)919 if err != nil {920 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)921 }922 val, ok = pathParams["project"]923 if !ok {924 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")925 }926 protoReq.Project, err = runtime.String(val)927 if err != nil {928 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)929 }930 msg, err := client.InvalidateRuns(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))931 return msg, metadata, err932}933func local_request_RunsV1_InvalidateRuns_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {934 var protoReq ProjectResourceUuidsBodyRequest935 var metadata runtime.ServerMetadata936 newReader, berr := utilities.IOReaderFactory(req.Body)937 if berr != nil {938 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)939 }940 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Uuids); err != nil && err != io.EOF {941 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)942 }943 var (944 val string945 ok bool946 err error947 _ = err948 )949 val, ok = pathParams["owner"]950 if !ok {951 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")952 }953 protoReq.Owner, err = runtime.String(val)954 if err != nil {955 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)956 }957 val, ok = pathParams["project"]958 if !ok {959 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")960 }961 protoReq.Project, err = runtime.String(val)962 if err != nil {963 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)964 }965 msg, err := server.InvalidateRuns(ctx, &protoReq)966 return msg, metadata, err967}968var (969 filter_RunsV1_CopyRun_0 = &utilities.DoubleArray{Encoding: map[string]int{"run": 0, "entity": 1, "owner": 2, "project": 3, "uuid": 4}, Base: []int{1, 1, 1, 2, 3, 4, 0, 0, 0, 0}, Check: []int{0, 1, 1, 3, 3, 3, 2, 4, 5, 6}}970)971func request_RunsV1_CopyRun_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {972 var protoReq EntityRunBodyRequest973 var metadata runtime.ServerMetadata974 newReader, berr := utilities.IOReaderFactory(req.Body)975 if berr != nil {976 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)977 }978 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Run); err != nil && err != io.EOF {979 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)980 }981 var (982 val string983 ok bool984 err error985 _ = err986 )987 val, ok = pathParams["entity.owner"]988 if !ok {989 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "entity.owner")990 }991 err = runtime.PopulateFieldFromPath(&protoReq, "entity.owner", val)992 if err != nil {993 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "entity.owner", err)994 }995 val, ok = pathParams["entity.project"]996 if !ok {997 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "entity.project")998 }999 err = runtime.PopulateFieldFromPath(&protoReq, "entity.project", val)1000 if err != nil {1001 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "entity.project", err)1002 }1003 val, ok = pathParams["entity.uuid"]1004 if !ok {1005 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "entity.uuid")1006 }1007 err = runtime.PopulateFieldFromPath(&protoReq, "entity.uuid", val)1008 if err != nil {1009 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "entity.uuid", err)1010 }1011 if err := req.ParseForm(); err != nil {1012 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)1013 }1014 if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_RunsV1_CopyRun_0); err != nil {1015 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)1016 }1017 msg, err := client.CopyRun(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))1018 return msg, metadata, err1019}1020func local_request_RunsV1_CopyRun_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {1021 var protoReq EntityRunBodyRequest1022 var metadata runtime.ServerMetadata1023 newReader, berr := utilities.IOReaderFactory(req.Body)1024 if berr != nil {1025 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)1026 }1027 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Run); err != nil && err != io.EOF {1028 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)1029 }1030 var (1031 val string1032 ok bool1033 err error1034 _ = err1035 )1036 val, ok = pathParams["entity.owner"]1037 if !ok {1038 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "entity.owner")1039 }1040 err = runtime.PopulateFieldFromPath(&protoReq, "entity.owner", val)1041 if err != nil {1042 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "entity.owner", err)1043 }1044 val, ok = pathParams["entity.project"]1045 if !ok {1046 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "entity.project")1047 }1048 err = runtime.PopulateFieldFromPath(&protoReq, "entity.project", val)1049 if err != nil {1050 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "entity.project", err)1051 }1052 val, ok = pathParams["entity.uuid"]1053 if !ok {1054 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "entity.uuid")1055 }1056 err = runtime.PopulateFieldFromPath(&protoReq, "entity.uuid", val)1057 if err != nil {1058 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "entity.uuid", err)1059 }1060 if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_RunsV1_CopyRun_0); err != nil {1061 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)1062 }1063 msg, err := server.CopyRun(ctx, &protoReq)1064 return msg, metadata, err1065}1066var (1067 filter_RunsV1_RestartRun_0 = &utilities.DoubleArray{Encoding: map[string]int{"run": 0, "entity": 1, "owner": 2, "project": 3, "uuid": 4}, Base: []int{1, 1, 1, 2, 3, 4, 0, 0, 0, 0}, Check: []int{0, 1, 1, 3, 3, 3, 2, 4, 5, 6}}1068)1069func request_RunsV1_RestartRun_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {1070 var protoReq EntityRunBodyRequest1071 var metadata runtime.ServerMetadata1072 newReader, berr := utilities.IOReaderFactory(req.Body)1073 if berr != nil {1074 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)1075 }1076 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Run); err != nil && err != io.EOF {1077 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)1078 }1079 var (1080 val string1081 ok bool1082 err error1083 _ = err1084 )1085 val, ok = pathParams["entity.owner"]1086 if !ok {1087 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "entity.owner")1088 }1089 err = runtime.PopulateFieldFromPath(&protoReq, "entity.owner", val)1090 if err != nil {1091 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "entity.owner", err)1092 }1093 val, ok = pathParams["entity.project"]1094 if !ok {1095 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "entity.project")1096 }1097 err = runtime.PopulateFieldFromPath(&protoReq, "entity.project", val)1098 if err != nil {1099 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "entity.project", err)1100 }1101 val, ok = pathParams["entity.uuid"]1102 if !ok {1103 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "entity.uuid")1104 }1105 err = runtime.PopulateFieldFromPath(&protoReq, "entity.uuid", val)1106 if err != nil {1107 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "entity.uuid", err)1108 }1109 if err := req.ParseForm(); err != nil {1110 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)1111 }1112 if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_RunsV1_RestartRun_0); err != nil {1113 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)1114 }1115 msg, err := client.RestartRun(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))1116 return msg, metadata, err1117}1118func local_request_RunsV1_RestartRun_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {1119 var protoReq EntityRunBodyRequest1120 var metadata runtime.ServerMetadata1121 newReader, berr := utilities.IOReaderFactory(req.Body)1122 if berr != nil {1123 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)1124 }1125 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Run); err != nil && err != io.EOF {1126 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)1127 }1128 var (1129 val string1130 ok bool1131 err error1132 _ = err1133 )1134 val, ok = pathParams["entity.owner"]1135 if !ok {1136 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "entity.owner")1137 }1138 err = runtime.PopulateFieldFromPath(&protoReq, "entity.owner", val)1139 if err != nil {1140 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "entity.owner", err)1141 }1142 val, ok = pathParams["entity.project"]1143 if !ok {1144 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "entity.project")1145 }1146 err = runtime.PopulateFieldFromPath(&protoReq, "entity.project", val)1147 if err != nil {1148 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "entity.project", err)1149 }1150 val, ok = pathParams["entity.uuid"]1151 if !ok {1152 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "entity.uuid")1153 }1154 err = runtime.PopulateFieldFromPath(&protoReq, "entity.uuid", val)1155 if err != nil {1156 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "entity.uuid", err)1157 }1158 if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_RunsV1_RestartRun_0); err != nil {1159 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)1160 }1161 msg, err := server.RestartRun(ctx, &protoReq)1162 return msg, metadata, err1163}1164var (1165 filter_RunsV1_ResumeRun_0 = &utilities.DoubleArray{Encoding: map[string]int{"run": 0, "entity": 1, "owner": 2, "project": 3, "uuid": 4}, Base: []int{1, 1, 1, 2, 3, 4, 0, 0, 0, 0}, Check: []int{0, 1, 1, 3, 3, 3, 2, 4, 5, 6}}1166)1167func request_RunsV1_ResumeRun_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {1168 var protoReq EntityRunBodyRequest1169 var metadata runtime.ServerMetadata1170 newReader, berr := utilities.IOReaderFactory(req.Body)1171 if berr != nil {1172 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)1173 }1174 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Run); err != nil && err != io.EOF {1175 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)1176 }1177 var (1178 val string1179 ok bool1180 err error1181 _ = err1182 )1183 val, ok = pathParams["entity.owner"]1184 if !ok {1185 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "entity.owner")1186 }1187 err = runtime.PopulateFieldFromPath(&protoReq, "entity.owner", val)1188 if err != nil {1189 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "entity.owner", err)1190 }1191 val, ok = pathParams["entity.project"]1192 if !ok {1193 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "entity.project")1194 }1195 err = runtime.PopulateFieldFromPath(&protoReq, "entity.project", val)1196 if err != nil {1197 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "entity.project", err)1198 }1199 val, ok = pathParams["entity.uuid"]1200 if !ok {1201 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "entity.uuid")1202 }1203 err = runtime.PopulateFieldFromPath(&protoReq, "entity.uuid", val)1204 if err != nil {1205 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "entity.uuid", err)1206 }1207 if err := req.ParseForm(); err != nil {1208 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)1209 }1210 if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_RunsV1_ResumeRun_0); err != nil {1211 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)1212 }1213 msg, err := client.ResumeRun(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))1214 return msg, metadata, err1215}1216func local_request_RunsV1_ResumeRun_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {1217 var protoReq EntityRunBodyRequest1218 var metadata runtime.ServerMetadata1219 newReader, berr := utilities.IOReaderFactory(req.Body)1220 if berr != nil {1221 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)1222 }1223 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Run); err != nil && err != io.EOF {1224 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)1225 }1226 var (1227 val string1228 ok bool1229 err error1230 _ = err1231 )1232 val, ok = pathParams["entity.owner"]1233 if !ok {1234 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "entity.owner")1235 }1236 err = runtime.PopulateFieldFromPath(&protoReq, "entity.owner", val)1237 if err != nil {1238 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "entity.owner", err)1239 }1240 val, ok = pathParams["entity.project"]1241 if !ok {1242 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "entity.project")1243 }1244 err = runtime.PopulateFieldFromPath(&protoReq, "entity.project", val)1245 if err != nil {1246 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "entity.project", err)1247 }1248 val, ok = pathParams["entity.uuid"]1249 if !ok {1250 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "entity.uuid")1251 }1252 err = runtime.PopulateFieldFromPath(&protoReq, "entity.uuid", val)1253 if err != nil {1254 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "entity.uuid", err)1255 }1256 if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_RunsV1_ResumeRun_0); err != nil {1257 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)1258 }1259 msg, err := server.ResumeRun(ctx, &protoReq)1260 return msg, metadata, err1261}1262func request_RunsV1_ArchiveRun_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {1263 var protoReq EntityResourceRequest1264 var metadata runtime.ServerMetadata1265 var (1266 val string1267 ok bool1268 err error1269 _ = err1270 )1271 val, ok = pathParams["owner"]1272 if !ok {1273 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")1274 }1275 protoReq.Owner, err = runtime.String(val)1276 if err != nil {1277 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)1278 }1279 val, ok = pathParams["project"]1280 if !ok {1281 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")1282 }1283 protoReq.Project, err = runtime.String(val)1284 if err != nil {1285 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)1286 }1287 val, ok = pathParams["uuid"]1288 if !ok {1289 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")1290 }1291 protoReq.Uuid, err = runtime.String(val)1292 if err != nil {1293 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)1294 }1295 msg, err := client.ArchiveRun(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))1296 return msg, metadata, err1297}1298func local_request_RunsV1_ArchiveRun_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {1299 var protoReq EntityResourceRequest1300 var metadata runtime.ServerMetadata1301 var (1302 val string1303 ok bool1304 err error1305 _ = err1306 )1307 val, ok = pathParams["owner"]1308 if !ok {1309 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")1310 }1311 protoReq.Owner, err = runtime.String(val)1312 if err != nil {1313 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)1314 }1315 val, ok = pathParams["project"]1316 if !ok {1317 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")1318 }1319 protoReq.Project, err = runtime.String(val)1320 if err != nil {1321 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)1322 }1323 val, ok = pathParams["uuid"]1324 if !ok {1325 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")1326 }1327 protoReq.Uuid, err = runtime.String(val)1328 if err != nil {1329 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)1330 }1331 msg, err := server.ArchiveRun(ctx, &protoReq)1332 return msg, metadata, err1333}1334func request_RunsV1_RestoreRun_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {1335 var protoReq EntityResourceRequest1336 var metadata runtime.ServerMetadata1337 var (1338 val string1339 ok bool1340 err error1341 _ = err1342 )1343 val, ok = pathParams["owner"]1344 if !ok {1345 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")1346 }1347 protoReq.Owner, err = runtime.String(val)1348 if err != nil {1349 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)1350 }1351 val, ok = pathParams["project"]1352 if !ok {1353 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")1354 }1355 protoReq.Project, err = runtime.String(val)1356 if err != nil {1357 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)1358 }1359 val, ok = pathParams["uuid"]1360 if !ok {1361 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")1362 }1363 protoReq.Uuid, err = runtime.String(val)1364 if err != nil {1365 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)1366 }1367 msg, err := client.RestoreRun(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))1368 return msg, metadata, err1369}1370func local_request_RunsV1_RestoreRun_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {1371 var protoReq EntityResourceRequest1372 var metadata runtime.ServerMetadata1373 var (1374 val string1375 ok bool1376 err error1377 _ = err1378 )1379 val, ok = pathParams["owner"]1380 if !ok {1381 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")1382 }1383 protoReq.Owner, err = runtime.String(val)1384 if err != nil {1385 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)1386 }1387 val, ok = pathParams["project"]1388 if !ok {1389 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")1390 }1391 protoReq.Project, err = runtime.String(val)1392 if err != nil {1393 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)1394 }1395 val, ok = pathParams["uuid"]1396 if !ok {1397 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")1398 }1399 protoReq.Uuid, err = runtime.String(val)1400 if err != nil {1401 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)1402 }1403 msg, err := server.RestoreRun(ctx, &protoReq)1404 return msg, metadata, err1405}1406func request_RunsV1_BookmarkRun_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {1407 var protoReq EntityResourceRequest1408 var metadata runtime.ServerMetadata1409 var (1410 val string1411 ok bool1412 err error1413 _ = err1414 )1415 val, ok = pathParams["owner"]1416 if !ok {1417 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")1418 }1419 protoReq.Owner, err = runtime.String(val)1420 if err != nil {1421 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)1422 }1423 val, ok = pathParams["project"]1424 if !ok {1425 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")1426 }1427 protoReq.Project, err = runtime.String(val)1428 if err != nil {1429 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)1430 }1431 val, ok = pathParams["uuid"]1432 if !ok {1433 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")1434 }1435 protoReq.Uuid, err = runtime.String(val)1436 if err != nil {1437 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)1438 }1439 msg, err := client.BookmarkRun(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))1440 return msg, metadata, err1441}1442func local_request_RunsV1_BookmarkRun_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {1443 var protoReq EntityResourceRequest1444 var metadata runtime.ServerMetadata1445 var (1446 val string1447 ok bool1448 err error1449 _ = err1450 )1451 val, ok = pathParams["owner"]1452 if !ok {1453 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")1454 }1455 protoReq.Owner, err = runtime.String(val)1456 if err != nil {1457 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)1458 }1459 val, ok = pathParams["project"]1460 if !ok {1461 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")1462 }1463 protoReq.Project, err = runtime.String(val)1464 if err != nil {1465 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)1466 }1467 val, ok = pathParams["uuid"]1468 if !ok {1469 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")1470 }1471 protoReq.Uuid, err = runtime.String(val)1472 if err != nil {1473 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)1474 }1475 msg, err := server.BookmarkRun(ctx, &protoReq)1476 return msg, metadata, err1477}1478func request_RunsV1_UnbookmarkRun_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {1479 var protoReq EntityResourceRequest1480 var metadata runtime.ServerMetadata1481 var (1482 val string1483 ok bool1484 err error1485 _ = err1486 )1487 val, ok = pathParams["owner"]1488 if !ok {1489 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")1490 }1491 protoReq.Owner, err = runtime.String(val)1492 if err != nil {1493 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)1494 }1495 val, ok = pathParams["project"]1496 if !ok {1497 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")1498 }1499 protoReq.Project, err = runtime.String(val)1500 if err != nil {1501 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)1502 }1503 val, ok = pathParams["uuid"]1504 if !ok {1505 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")1506 }1507 protoReq.Uuid, err = runtime.String(val)1508 if err != nil {1509 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)1510 }1511 msg, err := client.UnbookmarkRun(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))1512 return msg, metadata, err1513}1514func local_request_RunsV1_UnbookmarkRun_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {1515 var protoReq EntityResourceRequest1516 var metadata runtime.ServerMetadata1517 var (1518 val string1519 ok bool1520 err error1521 _ = err1522 )1523 val, ok = pathParams["owner"]1524 if !ok {1525 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")1526 }1527 protoReq.Owner, err = runtime.String(val)1528 if err != nil {1529 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)1530 }1531 val, ok = pathParams["project"]1532 if !ok {1533 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")1534 }1535 protoReq.Project, err = runtime.String(val)1536 if err != nil {1537 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)1538 }1539 val, ok = pathParams["uuid"]1540 if !ok {1541 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")1542 }1543 protoReq.Uuid, err = runtime.String(val)1544 if err != nil {1545 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)1546 }1547 msg, err := server.UnbookmarkRun(ctx, &protoReq)1548 return msg, metadata, err1549}1550func request_RunsV1_StartRunTensorboard_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {1551 var protoReq EntityResourceRequest1552 var metadata runtime.ServerMetadata1553 newReader, berr := utilities.IOReaderFactory(req.Body)1554 if berr != nil {1555 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)1556 }1557 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF {1558 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)1559 }1560 var (1561 val string1562 ok bool1563 err error1564 _ = err1565 )1566 val, ok = pathParams["owner"]1567 if !ok {1568 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")1569 }1570 protoReq.Owner, err = runtime.String(val)1571 if err != nil {1572 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)1573 }1574 val, ok = pathParams["project"]1575 if !ok {1576 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")1577 }1578 protoReq.Project, err = runtime.String(val)1579 if err != nil {1580 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)1581 }1582 val, ok = pathParams["uuid"]1583 if !ok {1584 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")1585 }1586 protoReq.Uuid, err = runtime.String(val)1587 if err != nil {1588 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)1589 }1590 msg, err := client.StartRunTensorboard(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))1591 return msg, metadata, err1592}1593func local_request_RunsV1_StartRunTensorboard_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {1594 var protoReq EntityResourceRequest1595 var metadata runtime.ServerMetadata1596 newReader, berr := utilities.IOReaderFactory(req.Body)1597 if berr != nil {1598 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)1599 }1600 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF {1601 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)1602 }1603 var (1604 val string1605 ok bool1606 err error1607 _ = err1608 )1609 val, ok = pathParams["owner"]1610 if !ok {1611 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")1612 }1613 protoReq.Owner, err = runtime.String(val)1614 if err != nil {1615 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)1616 }1617 val, ok = pathParams["project"]1618 if !ok {1619 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")1620 }1621 protoReq.Project, err = runtime.String(val)1622 if err != nil {1623 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)1624 }1625 val, ok = pathParams["uuid"]1626 if !ok {1627 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")1628 }1629 protoReq.Uuid, err = runtime.String(val)1630 if err != nil {1631 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)1632 }1633 msg, err := server.StartRunTensorboard(ctx, &protoReq)1634 return msg, metadata, err1635}1636func request_RunsV1_StopRunTensorboard_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {1637 var protoReq EntityResourceRequest1638 var metadata runtime.ServerMetadata1639 var (1640 val string1641 ok bool1642 err error1643 _ = err1644 )1645 val, ok = pathParams["owner"]1646 if !ok {1647 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")1648 }1649 protoReq.Owner, err = runtime.String(val)1650 if err != nil {1651 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)1652 }1653 val, ok = pathParams["project"]1654 if !ok {1655 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")1656 }1657 protoReq.Project, err = runtime.String(val)1658 if err != nil {1659 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)1660 }1661 val, ok = pathParams["uuid"]1662 if !ok {1663 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")1664 }1665 protoReq.Uuid, err = runtime.String(val)1666 if err != nil {1667 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)1668 }1669 msg, err := client.StopRunTensorboard(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))1670 return msg, metadata, err1671}1672func local_request_RunsV1_StopRunTensorboard_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {1673 var protoReq EntityResourceRequest1674 var metadata runtime.ServerMetadata1675 var (1676 val string1677 ok bool1678 err error1679 _ = err1680 )1681 val, ok = pathParams["owner"]1682 if !ok {1683 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")1684 }1685 protoReq.Owner, err = runtime.String(val)1686 if err != nil {1687 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)1688 }1689 val, ok = pathParams["project"]1690 if !ok {1691 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")1692 }1693 protoReq.Project, err = runtime.String(val)1694 if err != nil {1695 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)1696 }1697 val, ok = pathParams["uuid"]1698 if !ok {1699 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")1700 }1701 protoReq.Uuid, err = runtime.String(val)1702 if err != nil {1703 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)1704 }1705 msg, err := server.StopRunTensorboard(ctx, &protoReq)1706 return msg, metadata, err1707}1708func request_RunsV1_GetRunStatuses_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {1709 var protoReq EntityResourceRequest1710 var metadata runtime.ServerMetadata1711 var (1712 val string1713 ok bool1714 err error1715 _ = err1716 )1717 val, ok = pathParams["owner"]1718 if !ok {1719 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")1720 }1721 protoReq.Owner, err = runtime.String(val)1722 if err != nil {1723 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)1724 }1725 val, ok = pathParams["project"]1726 if !ok {1727 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")1728 }1729 protoReq.Project, err = runtime.String(val)1730 if err != nil {1731 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)1732 }1733 val, ok = pathParams["uuid"]1734 if !ok {1735 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")1736 }1737 protoReq.Uuid, err = runtime.String(val)1738 if err != nil {1739 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)1740 }1741 msg, err := client.GetRunStatuses(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))1742 return msg, metadata, err1743}1744func local_request_RunsV1_GetRunStatuses_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {1745 var protoReq EntityResourceRequest1746 var metadata runtime.ServerMetadata1747 var (1748 val string1749 ok bool1750 err error1751 _ = err1752 )1753 val, ok = pathParams["owner"]1754 if !ok {1755 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")1756 }1757 protoReq.Owner, err = runtime.String(val)1758 if err != nil {1759 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)1760 }1761 val, ok = pathParams["project"]1762 if !ok {1763 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")1764 }1765 protoReq.Project, err = runtime.String(val)1766 if err != nil {1767 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)1768 }1769 val, ok = pathParams["uuid"]1770 if !ok {1771 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")1772 }1773 protoReq.Uuid, err = runtime.String(val)1774 if err != nil {1775 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)1776 }1777 msg, err := server.GetRunStatuses(ctx, &protoReq)1778 return msg, metadata, err1779}1780func request_RunsV1_CreateRunStatus_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {1781 var protoReq EntityStatusBodyRequest1782 var metadata runtime.ServerMetadata1783 newReader, berr := utilities.IOReaderFactory(req.Body)1784 if berr != nil {1785 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)1786 }1787 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Status); err != nil && err != io.EOF {1788 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)1789 }1790 var (1791 val string1792 ok bool1793 err error1794 _ = err1795 )1796 val, ok = pathParams["owner"]1797 if !ok {1798 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")1799 }1800 protoReq.Owner, err = runtime.String(val)1801 if err != nil {1802 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)1803 }1804 val, ok = pathParams["project"]1805 if !ok {1806 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")1807 }1808 protoReq.Project, err = runtime.String(val)1809 if err != nil {1810 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)1811 }1812 val, ok = pathParams["uuid"]1813 if !ok {1814 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")1815 }1816 protoReq.Uuid, err = runtime.String(val)1817 if err != nil {1818 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)1819 }1820 msg, err := client.CreateRunStatus(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))1821 return msg, metadata, err1822}1823func local_request_RunsV1_CreateRunStatus_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {1824 var protoReq EntityStatusBodyRequest1825 var metadata runtime.ServerMetadata1826 newReader, berr := utilities.IOReaderFactory(req.Body)1827 if berr != nil {1828 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)1829 }1830 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Status); err != nil && err != io.EOF {1831 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)1832 }1833 var (1834 val string1835 ok bool1836 err error1837 _ = err1838 )1839 val, ok = pathParams["owner"]1840 if !ok {1841 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")1842 }1843 protoReq.Owner, err = runtime.String(val)1844 if err != nil {1845 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)1846 }1847 val, ok = pathParams["project"]1848 if !ok {1849 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")1850 }1851 protoReq.Project, err = runtime.String(val)1852 if err != nil {1853 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)1854 }1855 val, ok = pathParams["uuid"]1856 if !ok {1857 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")1858 }1859 protoReq.Uuid, err = runtime.String(val)1860 if err != nil {1861 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)1862 }1863 msg, err := server.CreateRunStatus(ctx, &protoReq)1864 return msg, metadata, err1865}1866func request_RunsV1_GetRunCodeRefs_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {1867 var protoReq EntityResourceRequest1868 var metadata runtime.ServerMetadata1869 var (1870 val string1871 ok bool1872 err error1873 _ = err1874 )1875 val, ok = pathParams["owner"]1876 if !ok {1877 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")1878 }1879 protoReq.Owner, err = runtime.String(val)1880 if err != nil {1881 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)1882 }1883 val, ok = pathParams["project"]1884 if !ok {1885 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")1886 }1887 protoReq.Project, err = runtime.String(val)1888 if err != nil {1889 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)1890 }1891 val, ok = pathParams["uuid"]1892 if !ok {1893 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")1894 }1895 protoReq.Uuid, err = runtime.String(val)1896 if err != nil {1897 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)1898 }1899 msg, err := client.GetRunCodeRefs(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))1900 return msg, metadata, err1901}1902func local_request_RunsV1_GetRunCodeRefs_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {1903 var protoReq EntityResourceRequest1904 var metadata runtime.ServerMetadata1905 var (1906 val string1907 ok bool1908 err error1909 _ = err1910 )1911 val, ok = pathParams["owner"]1912 if !ok {1913 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")1914 }1915 protoReq.Owner, err = runtime.String(val)1916 if err != nil {1917 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)1918 }1919 val, ok = pathParams["project"]1920 if !ok {1921 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")1922 }1923 protoReq.Project, err = runtime.String(val)1924 if err != nil {1925 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)1926 }1927 val, ok = pathParams["uuid"]1928 if !ok {1929 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")1930 }1931 protoReq.Uuid, err = runtime.String(val)1932 if err != nil {1933 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)1934 }1935 msg, err := server.GetRunCodeRefs(ctx, &protoReq)1936 return msg, metadata, err1937}1938var (1939 filter_RunsV1_CreateRunCodeRef_0 = &utilities.DoubleArray{Encoding: map[string]int{"code_reference": 0, "entity": 1, "owner": 2, "project": 3, "uuid": 4}, Base: []int{1, 1, 1, 2, 3, 4, 0, 0, 0, 0}, Check: []int{0, 1, 1, 3, 3, 3, 2, 4, 5, 6}}1940)1941func request_RunsV1_CreateRunCodeRef_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {1942 var protoReq CodeRefBodyRequest1943 var metadata runtime.ServerMetadata1944 newReader, berr := utilities.IOReaderFactory(req.Body)1945 if berr != nil {1946 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)1947 }1948 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.CodeReference); err != nil && err != io.EOF {1949 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)1950 }1951 var (1952 val string1953 ok bool1954 err error1955 _ = err1956 )1957 val, ok = pathParams["entity.owner"]1958 if !ok {1959 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "entity.owner")1960 }1961 err = runtime.PopulateFieldFromPath(&protoReq, "entity.owner", val)1962 if err != nil {1963 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "entity.owner", err)1964 }1965 val, ok = pathParams["entity.project"]1966 if !ok {1967 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "entity.project")1968 }1969 err = runtime.PopulateFieldFromPath(&protoReq, "entity.project", val)1970 if err != nil {1971 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "entity.project", err)1972 }1973 val, ok = pathParams["entity.uuid"]1974 if !ok {1975 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "entity.uuid")1976 }1977 err = runtime.PopulateFieldFromPath(&protoReq, "entity.uuid", val)1978 if err != nil {1979 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "entity.uuid", err)1980 }1981 if err := req.ParseForm(); err != nil {1982 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)1983 }1984 if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_RunsV1_CreateRunCodeRef_0); err != nil {1985 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)1986 }1987 msg, err := client.CreateRunCodeRef(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))1988 return msg, metadata, err1989}1990func local_request_RunsV1_CreateRunCodeRef_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {1991 var protoReq CodeRefBodyRequest1992 var metadata runtime.ServerMetadata1993 newReader, berr := utilities.IOReaderFactory(req.Body)1994 if berr != nil {1995 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)1996 }1997 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.CodeReference); err != nil && err != io.EOF {1998 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)1999 }2000 var (2001 val string2002 ok bool2003 err error2004 _ = err2005 )2006 val, ok = pathParams["entity.owner"]2007 if !ok {2008 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "entity.owner")2009 }2010 err = runtime.PopulateFieldFromPath(&protoReq, "entity.owner", val)2011 if err != nil {2012 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "entity.owner", err)2013 }2014 val, ok = pathParams["entity.project"]2015 if !ok {2016 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "entity.project")2017 }2018 err = runtime.PopulateFieldFromPath(&protoReq, "entity.project", val)2019 if err != nil {2020 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "entity.project", err)2021 }2022 val, ok = pathParams["entity.uuid"]2023 if !ok {2024 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "entity.uuid")2025 }2026 err = runtime.PopulateFieldFromPath(&protoReq, "entity.uuid", val)2027 if err != nil {2028 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "entity.uuid", err)2029 }2030 if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_RunsV1_CreateRunCodeRef_0); err != nil {2031 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)2032 }2033 msg, err := server.CreateRunCodeRef(ctx, &protoReq)2034 return msg, metadata, err2035}2036func request_RunsV1_ImpersonateToken_0(ctx context.Context, marshaler runtime.Marshaler, client RunsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2037 var protoReq EntityResourceRequest2038 var metadata runtime.ServerMetadata2039 var (2040 val string2041 ok bool2042 err error2043 _ = err2044 )2045 val, ok = pathParams["owner"]2046 if !ok {2047 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2048 }2049 protoReq.Owner, err = runtime.String(val)2050 if err != nil {2051 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2052 }2053 val, ok = pathParams["project"]2054 if !ok {2055 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")2056 }2057 protoReq.Project, err = runtime.String(val)2058 if err != nil {2059 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)2060 }2061 val, ok = pathParams["uuid"]2062 if !ok {2063 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")2064 }2065 protoReq.Uuid, err = runtime.String(val)2066 if err != nil {2067 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)2068 }2069 msg, err := client.ImpersonateToken(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))2070 return msg, metadata, err2071}2072func local_request_RunsV1_ImpersonateToken_0(ctx context.Context, marshaler runtime.Marshaler, server RunsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2073 var protoReq EntityResourceRequest2074 var metadata runtime.ServerMetadata2075 var (2076 val string2077 ok bool2078 err error2079 _ = err2080 )2081 val, ok = pathParams["owner"]2082 if !ok {2083 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2084 }2085 protoReq.Owner, err = runtime.String(val)2086 if err != nil {2087 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2088 }2089 val, ok = pathParams["project"]2090 if !ok {2091 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")2092 }2093 protoReq.Project, err = runtime.String(val)2094 if err != nil {2095 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)2096 }2097 val, ok = pathParams["uuid"]2098 if !ok {2099 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "uuid")2100 }2101 protoReq.Uuid, err = runtime.String(val)2102 if err != nil {2103 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "uuid", err)2104 }2105 msg, err := server.ImpersonateToken(ctx, &protoReq)2106 return msg, metadata, err2107}2108var (2109 filter_ProjectsV1_ListProjects_0 = &utilities.DoubleArray{Encoding: map[string]int{"owner": 0}, Base: []int{1, 1, 0}, Check: []int{0, 1, 2}}2110)2111func request_ProjectsV1_ListProjects_0(ctx context.Context, marshaler runtime.Marshaler, client ProjectsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2112 var protoReq OwnerResouceListRequest2113 var metadata runtime.ServerMetadata2114 var (2115 val string2116 ok bool2117 err error2118 _ = err2119 )2120 val, ok = pathParams["owner"]2121 if !ok {2122 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2123 }2124 protoReq.Owner, err = runtime.String(val)2125 if err != nil {2126 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2127 }2128 if err := req.ParseForm(); err != nil {2129 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)2130 }2131 if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_ProjectsV1_ListProjects_0); err != nil {2132 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)2133 }2134 msg, err := client.ListProjects(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))2135 return msg, metadata, err2136}2137func local_request_ProjectsV1_ListProjects_0(ctx context.Context, marshaler runtime.Marshaler, server ProjectsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2138 var protoReq OwnerResouceListRequest2139 var metadata runtime.ServerMetadata2140 var (2141 val string2142 ok bool2143 err error2144 _ = err2145 )2146 val, ok = pathParams["owner"]2147 if !ok {2148 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2149 }2150 protoReq.Owner, err = runtime.String(val)2151 if err != nil {2152 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2153 }2154 if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_ProjectsV1_ListProjects_0); err != nil {2155 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)2156 }2157 msg, err := server.ListProjects(ctx, &protoReq)2158 return msg, metadata, err2159}2160var (2161 filter_ProjectsV1_ListProjectNames_0 = &utilities.DoubleArray{Encoding: map[string]int{"owner": 0}, Base: []int{1, 1, 0}, Check: []int{0, 1, 2}}2162)2163func request_ProjectsV1_ListProjectNames_0(ctx context.Context, marshaler runtime.Marshaler, client ProjectsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2164 var protoReq OwnerResouceListRequest2165 var metadata runtime.ServerMetadata2166 var (2167 val string2168 ok bool2169 err error2170 _ = err2171 )2172 val, ok = pathParams["owner"]2173 if !ok {2174 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2175 }2176 protoReq.Owner, err = runtime.String(val)2177 if err != nil {2178 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2179 }2180 if err := req.ParseForm(); err != nil {2181 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)2182 }2183 if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_ProjectsV1_ListProjectNames_0); err != nil {2184 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)2185 }2186 msg, err := client.ListProjectNames(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))2187 return msg, metadata, err2188}2189func local_request_ProjectsV1_ListProjectNames_0(ctx context.Context, marshaler runtime.Marshaler, server ProjectsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2190 var protoReq OwnerResouceListRequest2191 var metadata runtime.ServerMetadata2192 var (2193 val string2194 ok bool2195 err error2196 _ = err2197 )2198 val, ok = pathParams["owner"]2199 if !ok {2200 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2201 }2202 protoReq.Owner, err = runtime.String(val)2203 if err != nil {2204 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2205 }2206 if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_ProjectsV1_ListProjectNames_0); err != nil {2207 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)2208 }2209 msg, err := server.ListProjectNames(ctx, &protoReq)2210 return msg, metadata, err2211}2212var (2213 filter_ProjectsV1_ListBookmarkedProjects_0 = &utilities.DoubleArray{Encoding: map[string]int{"user": 0}, Base: []int{1, 1, 0}, Check: []int{0, 1, 2}}2214)2215func request_ProjectsV1_ListBookmarkedProjects_0(ctx context.Context, marshaler runtime.Marshaler, client ProjectsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2216 var protoReq UserResouceListRequest2217 var metadata runtime.ServerMetadata2218 var (2219 val string2220 ok bool2221 err error2222 _ = err2223 )2224 val, ok = pathParams["user"]2225 if !ok {2226 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "user")2227 }2228 protoReq.User, err = runtime.String(val)2229 if err != nil {2230 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "user", err)2231 }2232 if err := req.ParseForm(); err != nil {2233 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)2234 }2235 if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_ProjectsV1_ListBookmarkedProjects_0); err != nil {2236 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)2237 }2238 msg, err := client.ListBookmarkedProjects(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))2239 return msg, metadata, err2240}2241func local_request_ProjectsV1_ListBookmarkedProjects_0(ctx context.Context, marshaler runtime.Marshaler, server ProjectsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2242 var protoReq UserResouceListRequest2243 var metadata runtime.ServerMetadata2244 var (2245 val string2246 ok bool2247 err error2248 _ = err2249 )2250 val, ok = pathParams["user"]2251 if !ok {2252 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "user")2253 }2254 protoReq.User, err = runtime.String(val)2255 if err != nil {2256 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "user", err)2257 }2258 if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_ProjectsV1_ListBookmarkedProjects_0); err != nil {2259 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)2260 }2261 msg, err := server.ListBookmarkedProjects(ctx, &protoReq)2262 return msg, metadata, err2263}2264var (2265 filter_ProjectsV1_ListArchivedProjects_0 = &utilities.DoubleArray{Encoding: map[string]int{"user": 0}, Base: []int{1, 1, 0}, Check: []int{0, 1, 2}}2266)2267func request_ProjectsV1_ListArchivedProjects_0(ctx context.Context, marshaler runtime.Marshaler, client ProjectsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2268 var protoReq UserResouceListRequest2269 var metadata runtime.ServerMetadata2270 var (2271 val string2272 ok bool2273 err error2274 _ = err2275 )2276 val, ok = pathParams["user"]2277 if !ok {2278 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "user")2279 }2280 protoReq.User, err = runtime.String(val)2281 if err != nil {2282 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "user", err)2283 }2284 if err := req.ParseForm(); err != nil {2285 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)2286 }2287 if err := runtime.PopulateQueryParameters(&protoReq, req.Form, filter_ProjectsV1_ListArchivedProjects_0); err != nil {2288 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)2289 }2290 msg, err := client.ListArchivedProjects(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))2291 return msg, metadata, err2292}2293func local_request_ProjectsV1_ListArchivedProjects_0(ctx context.Context, marshaler runtime.Marshaler, server ProjectsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2294 var protoReq UserResouceListRequest2295 var metadata runtime.ServerMetadata2296 var (2297 val string2298 ok bool2299 err error2300 _ = err2301 )2302 val, ok = pathParams["user"]2303 if !ok {2304 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "user")2305 }2306 protoReq.User, err = runtime.String(val)2307 if err != nil {2308 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "user", err)2309 }2310 if err := runtime.PopulateQueryParameters(&protoReq, req.URL.Query(), filter_ProjectsV1_ListArchivedProjects_0); err != nil {2311 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)2312 }2313 msg, err := server.ListArchivedProjects(ctx, &protoReq)2314 return msg, metadata, err2315}2316func request_ProjectsV1_CreateProject_0(ctx context.Context, marshaler runtime.Marshaler, client ProjectsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2317 var protoReq ProjectBodyRequest2318 var metadata runtime.ServerMetadata2319 newReader, berr := utilities.IOReaderFactory(req.Body)2320 if berr != nil {2321 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)2322 }2323 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Project); err != nil && err != io.EOF {2324 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)2325 }2326 var (2327 val string2328 ok bool2329 err error2330 _ = err2331 )2332 val, ok = pathParams["owner"]2333 if !ok {2334 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2335 }2336 protoReq.Owner, err = runtime.String(val)2337 if err != nil {2338 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2339 }2340 msg, err := client.CreateProject(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))2341 return msg, metadata, err2342}2343func local_request_ProjectsV1_CreateProject_0(ctx context.Context, marshaler runtime.Marshaler, server ProjectsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2344 var protoReq ProjectBodyRequest2345 var metadata runtime.ServerMetadata2346 newReader, berr := utilities.IOReaderFactory(req.Body)2347 if berr != nil {2348 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)2349 }2350 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Project); err != nil && err != io.EOF {2351 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)2352 }2353 var (2354 val string2355 ok bool2356 err error2357 _ = err2358 )2359 val, ok = pathParams["owner"]2360 if !ok {2361 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2362 }2363 protoReq.Owner, err = runtime.String(val)2364 if err != nil {2365 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2366 }2367 msg, err := server.CreateProject(ctx, &protoReq)2368 return msg, metadata, err2369}2370func request_ProjectsV1_GetProject_0(ctx context.Context, marshaler runtime.Marshaler, client ProjectsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2371 var protoReq ProjectResourceRequest2372 var metadata runtime.ServerMetadata2373 var (2374 val string2375 ok bool2376 err error2377 _ = err2378 )2379 val, ok = pathParams["owner"]2380 if !ok {2381 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2382 }2383 protoReq.Owner, err = runtime.String(val)2384 if err != nil {2385 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2386 }2387 val, ok = pathParams["project"]2388 if !ok {2389 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")2390 }2391 protoReq.Project, err = runtime.String(val)2392 if err != nil {2393 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)2394 }2395 msg, err := client.GetProject(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))2396 return msg, metadata, err2397}2398func local_request_ProjectsV1_GetProject_0(ctx context.Context, marshaler runtime.Marshaler, server ProjectsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2399 var protoReq ProjectResourceRequest2400 var metadata runtime.ServerMetadata2401 var (2402 val string2403 ok bool2404 err error2405 _ = err2406 )2407 val, ok = pathParams["owner"]2408 if !ok {2409 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2410 }2411 protoReq.Owner, err = runtime.String(val)2412 if err != nil {2413 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2414 }2415 val, ok = pathParams["project"]2416 if !ok {2417 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")2418 }2419 protoReq.Project, err = runtime.String(val)2420 if err != nil {2421 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)2422 }2423 msg, err := server.GetProject(ctx, &protoReq)2424 return msg, metadata, err2425}2426func request_ProjectsV1_UpdateProject_0(ctx context.Context, marshaler runtime.Marshaler, client ProjectsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2427 var protoReq ProjectBodyRequest2428 var metadata runtime.ServerMetadata2429 newReader, berr := utilities.IOReaderFactory(req.Body)2430 if berr != nil {2431 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)2432 }2433 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Project); err != nil && err != io.EOF {2434 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)2435 }2436 var (2437 val string2438 ok bool2439 err error2440 _ = err2441 )2442 val, ok = pathParams["owner"]2443 if !ok {2444 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2445 }2446 protoReq.Owner, err = runtime.String(val)2447 if err != nil {2448 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2449 }2450 val, ok = pathParams["project.name"]2451 if !ok {2452 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project.name")2453 }2454 err = runtime.PopulateFieldFromPath(&protoReq, "project.name", val)2455 if err != nil {2456 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project.name", err)2457 }2458 msg, err := client.UpdateProject(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))2459 return msg, metadata, err2460}2461func local_request_ProjectsV1_UpdateProject_0(ctx context.Context, marshaler runtime.Marshaler, server ProjectsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2462 var protoReq ProjectBodyRequest2463 var metadata runtime.ServerMetadata2464 newReader, berr := utilities.IOReaderFactory(req.Body)2465 if berr != nil {2466 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)2467 }2468 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Project); err != nil && err != io.EOF {2469 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)2470 }2471 var (2472 val string2473 ok bool2474 err error2475 _ = err2476 )2477 val, ok = pathParams["owner"]2478 if !ok {2479 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2480 }2481 protoReq.Owner, err = runtime.String(val)2482 if err != nil {2483 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2484 }2485 val, ok = pathParams["project.name"]2486 if !ok {2487 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project.name")2488 }2489 err = runtime.PopulateFieldFromPath(&protoReq, "project.name", val)2490 if err != nil {2491 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project.name", err)2492 }2493 msg, err := server.UpdateProject(ctx, &protoReq)2494 return msg, metadata, err2495}2496func request_ProjectsV1_PatchProject_0(ctx context.Context, marshaler runtime.Marshaler, client ProjectsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2497 var protoReq ProjectBodyRequest2498 var metadata runtime.ServerMetadata2499 newReader, berr := utilities.IOReaderFactory(req.Body)2500 if berr != nil {2501 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)2502 }2503 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Project); err != nil && err != io.EOF {2504 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)2505 }2506 var (2507 val string2508 ok bool2509 err error2510 _ = err2511 )2512 val, ok = pathParams["owner"]2513 if !ok {2514 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2515 }2516 protoReq.Owner, err = runtime.String(val)2517 if err != nil {2518 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2519 }2520 val, ok = pathParams["project.name"]2521 if !ok {2522 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project.name")2523 }2524 err = runtime.PopulateFieldFromPath(&protoReq, "project.name", val)2525 if err != nil {2526 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project.name", err)2527 }2528 msg, err := client.PatchProject(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))2529 return msg, metadata, err2530}2531func local_request_ProjectsV1_PatchProject_0(ctx context.Context, marshaler runtime.Marshaler, server ProjectsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2532 var protoReq ProjectBodyRequest2533 var metadata runtime.ServerMetadata2534 newReader, berr := utilities.IOReaderFactory(req.Body)2535 if berr != nil {2536 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)2537 }2538 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq.Project); err != nil && err != io.EOF {2539 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)2540 }2541 var (2542 val string2543 ok bool2544 err error2545 _ = err2546 )2547 val, ok = pathParams["owner"]2548 if !ok {2549 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2550 }2551 protoReq.Owner, err = runtime.String(val)2552 if err != nil {2553 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2554 }2555 val, ok = pathParams["project.name"]2556 if !ok {2557 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project.name")2558 }2559 err = runtime.PopulateFieldFromPath(&protoReq, "project.name", val)2560 if err != nil {2561 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project.name", err)2562 }2563 msg, err := server.PatchProject(ctx, &protoReq)2564 return msg, metadata, err2565}2566func request_ProjectsV1_DeleteProject_0(ctx context.Context, marshaler runtime.Marshaler, client ProjectsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2567 var protoReq ProjectResourceRequest2568 var metadata runtime.ServerMetadata2569 var (2570 val string2571 ok bool2572 err error2573 _ = err2574 )2575 val, ok = pathParams["owner"]2576 if !ok {2577 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2578 }2579 protoReq.Owner, err = runtime.String(val)2580 if err != nil {2581 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2582 }2583 val, ok = pathParams["project"]2584 if !ok {2585 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")2586 }2587 protoReq.Project, err = runtime.String(val)2588 if err != nil {2589 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)2590 }2591 msg, err := client.DeleteProject(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))2592 return msg, metadata, err2593}2594func local_request_ProjectsV1_DeleteProject_0(ctx context.Context, marshaler runtime.Marshaler, server ProjectsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2595 var protoReq ProjectResourceRequest2596 var metadata runtime.ServerMetadata2597 var (2598 val string2599 ok bool2600 err error2601 _ = err2602 )2603 val, ok = pathParams["owner"]2604 if !ok {2605 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2606 }2607 protoReq.Owner, err = runtime.String(val)2608 if err != nil {2609 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2610 }2611 val, ok = pathParams["project"]2612 if !ok {2613 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")2614 }2615 protoReq.Project, err = runtime.String(val)2616 if err != nil {2617 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)2618 }2619 msg, err := server.DeleteProject(ctx, &protoReq)2620 return msg, metadata, err2621}2622func request_ProjectsV1_ArchiveProject_0(ctx context.Context, marshaler runtime.Marshaler, client ProjectsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2623 var protoReq ProjectResourceRequest2624 var metadata runtime.ServerMetadata2625 var (2626 val string2627 ok bool2628 err error2629 _ = err2630 )2631 val, ok = pathParams["owner"]2632 if !ok {2633 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2634 }2635 protoReq.Owner, err = runtime.String(val)2636 if err != nil {2637 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2638 }2639 val, ok = pathParams["project"]2640 if !ok {2641 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")2642 }2643 protoReq.Project, err = runtime.String(val)2644 if err != nil {2645 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)2646 }2647 msg, err := client.ArchiveProject(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))2648 return msg, metadata, err2649}2650func local_request_ProjectsV1_ArchiveProject_0(ctx context.Context, marshaler runtime.Marshaler, server ProjectsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2651 var protoReq ProjectResourceRequest2652 var metadata runtime.ServerMetadata2653 var (2654 val string2655 ok bool2656 err error2657 _ = err2658 )2659 val, ok = pathParams["owner"]2660 if !ok {2661 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2662 }2663 protoReq.Owner, err = runtime.String(val)2664 if err != nil {2665 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2666 }2667 val, ok = pathParams["project"]2668 if !ok {2669 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")2670 }2671 protoReq.Project, err = runtime.String(val)2672 if err != nil {2673 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)2674 }2675 msg, err := server.ArchiveProject(ctx, &protoReq)2676 return msg, metadata, err2677}2678func request_ProjectsV1_RestoreExperiment_0(ctx context.Context, marshaler runtime.Marshaler, client ProjectsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2679 var protoReq ProjectResourceRequest2680 var metadata runtime.ServerMetadata2681 var (2682 val string2683 ok bool2684 err error2685 _ = err2686 )2687 val, ok = pathParams["owner"]2688 if !ok {2689 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2690 }2691 protoReq.Owner, err = runtime.String(val)2692 if err != nil {2693 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2694 }2695 val, ok = pathParams["project"]2696 if !ok {2697 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")2698 }2699 protoReq.Project, err = runtime.String(val)2700 if err != nil {2701 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)2702 }2703 msg, err := client.RestoreExperiment(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))2704 return msg, metadata, err2705}2706func local_request_ProjectsV1_RestoreExperiment_0(ctx context.Context, marshaler runtime.Marshaler, server ProjectsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2707 var protoReq ProjectResourceRequest2708 var metadata runtime.ServerMetadata2709 var (2710 val string2711 ok bool2712 err error2713 _ = err2714 )2715 val, ok = pathParams["owner"]2716 if !ok {2717 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2718 }2719 protoReq.Owner, err = runtime.String(val)2720 if err != nil {2721 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2722 }2723 val, ok = pathParams["project"]2724 if !ok {2725 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")2726 }2727 protoReq.Project, err = runtime.String(val)2728 if err != nil {2729 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)2730 }2731 msg, err := server.RestoreExperiment(ctx, &protoReq)2732 return msg, metadata, err2733}2734func request_ProjectsV1_BookmarkProject_0(ctx context.Context, marshaler runtime.Marshaler, client ProjectsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2735 var protoReq ProjectResourceRequest2736 var metadata runtime.ServerMetadata2737 var (2738 val string2739 ok bool2740 err error2741 _ = err2742 )2743 val, ok = pathParams["owner"]2744 if !ok {2745 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2746 }2747 protoReq.Owner, err = runtime.String(val)2748 if err != nil {2749 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2750 }2751 val, ok = pathParams["project"]2752 if !ok {2753 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")2754 }2755 protoReq.Project, err = runtime.String(val)2756 if err != nil {2757 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)2758 }2759 msg, err := client.BookmarkProject(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))2760 return msg, metadata, err2761}2762func local_request_ProjectsV1_BookmarkProject_0(ctx context.Context, marshaler runtime.Marshaler, server ProjectsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2763 var protoReq ProjectResourceRequest2764 var metadata runtime.ServerMetadata2765 var (2766 val string2767 ok bool2768 err error2769 _ = err2770 )2771 val, ok = pathParams["owner"]2772 if !ok {2773 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2774 }2775 protoReq.Owner, err = runtime.String(val)2776 if err != nil {2777 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2778 }2779 val, ok = pathParams["project"]2780 if !ok {2781 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")2782 }2783 protoReq.Project, err = runtime.String(val)2784 if err != nil {2785 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)2786 }2787 msg, err := server.BookmarkProject(ctx, &protoReq)2788 return msg, metadata, err2789}2790func request_ProjectsV1_UnbookmarkProject_0(ctx context.Context, marshaler runtime.Marshaler, client ProjectsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2791 var protoReq ProjectResourceRequest2792 var metadata runtime.ServerMetadata2793 var (2794 val string2795 ok bool2796 err error2797 _ = err2798 )2799 val, ok = pathParams["owner"]2800 if !ok {2801 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2802 }2803 protoReq.Owner, err = runtime.String(val)2804 if err != nil {2805 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2806 }2807 val, ok = pathParams["project"]2808 if !ok {2809 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")2810 }2811 protoReq.Project, err = runtime.String(val)2812 if err != nil {2813 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)2814 }2815 msg, err := client.UnbookmarkProject(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))2816 return msg, metadata, err2817}2818func local_request_ProjectsV1_UnbookmarkProject_0(ctx context.Context, marshaler runtime.Marshaler, server ProjectsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2819 var protoReq ProjectResourceRequest2820 var metadata runtime.ServerMetadata2821 var (2822 val string2823 ok bool2824 err error2825 _ = err2826 )2827 val, ok = pathParams["owner"]2828 if !ok {2829 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2830 }2831 protoReq.Owner, err = runtime.String(val)2832 if err != nil {2833 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2834 }2835 val, ok = pathParams["project"]2836 if !ok {2837 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")2838 }2839 protoReq.Project, err = runtime.String(val)2840 if err != nil {2841 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)2842 }2843 msg, err := server.UnbookmarkProject(ctx, &protoReq)2844 return msg, metadata, err2845}2846func request_ProjectsV1_EnableProjectCI_0(ctx context.Context, marshaler runtime.Marshaler, client ProjectsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2847 var protoReq ProjectResourceRequest2848 var metadata runtime.ServerMetadata2849 var (2850 val string2851 ok bool2852 err error2853 _ = err2854 )2855 val, ok = pathParams["owner"]2856 if !ok {2857 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2858 }2859 protoReq.Owner, err = runtime.String(val)2860 if err != nil {2861 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2862 }2863 val, ok = pathParams["project"]2864 if !ok {2865 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")2866 }2867 protoReq.Project, err = runtime.String(val)2868 if err != nil {2869 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)2870 }2871 msg, err := client.EnableProjectCI(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))2872 return msg, metadata, err2873}2874func local_request_ProjectsV1_EnableProjectCI_0(ctx context.Context, marshaler runtime.Marshaler, server ProjectsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2875 var protoReq ProjectResourceRequest2876 var metadata runtime.ServerMetadata2877 var (2878 val string2879 ok bool2880 err error2881 _ = err2882 )2883 val, ok = pathParams["owner"]2884 if !ok {2885 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2886 }2887 protoReq.Owner, err = runtime.String(val)2888 if err != nil {2889 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2890 }2891 val, ok = pathParams["project"]2892 if !ok {2893 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")2894 }2895 protoReq.Project, err = runtime.String(val)2896 if err != nil {2897 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)2898 }2899 msg, err := server.EnableProjectCI(ctx, &protoReq)2900 return msg, metadata, err2901}2902func request_ProjectsV1_DisableProjectCI_0(ctx context.Context, marshaler runtime.Marshaler, client ProjectsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2903 var protoReq ProjectResourceRequest2904 var metadata runtime.ServerMetadata2905 var (2906 val string2907 ok bool2908 err error2909 _ = err2910 )2911 val, ok = pathParams["owner"]2912 if !ok {2913 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2914 }2915 protoReq.Owner, err = runtime.String(val)2916 if err != nil {2917 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2918 }2919 val, ok = pathParams["project"]2920 if !ok {2921 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")2922 }2923 protoReq.Project, err = runtime.String(val)2924 if err != nil {2925 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)2926 }2927 msg, err := client.DisableProjectCI(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))2928 return msg, metadata, err2929}2930func local_request_ProjectsV1_DisableProjectCI_0(ctx context.Context, marshaler runtime.Marshaler, server ProjectsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2931 var protoReq ProjectResourceRequest2932 var metadata runtime.ServerMetadata2933 var (2934 val string2935 ok bool2936 err error2937 _ = err2938 )2939 val, ok = pathParams["owner"]2940 if !ok {2941 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "owner")2942 }2943 protoReq.Owner, err = runtime.String(val)2944 if err != nil {2945 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "owner", err)2946 }2947 val, ok = pathParams["project"]2948 if !ok {2949 return nil, metadata, status.Errorf(codes.InvalidArgument, "missing parameter %s", "project")2950 }2951 protoReq.Project, err = runtime.String(val)2952 if err != nil {2953 return nil, metadata, status.Errorf(codes.InvalidArgument, "type mismatch, parameter: %s, error: %v", "project", err)2954 }2955 msg, err := server.DisableProjectCI(ctx, &protoReq)2956 return msg, metadata, err2957}2958func request_AuthV1_Login_0(ctx context.Context, marshaler runtime.Marshaler, client AuthV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2959 var protoReq CredsBodyRequest2960 var metadata runtime.ServerMetadata2961 newReader, berr := utilities.IOReaderFactory(req.Body)2962 if berr != nil {2963 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)2964 }2965 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF {2966 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)2967 }2968 msg, err := client.Login(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))2969 return msg, metadata, err2970}2971func local_request_AuthV1_Login_0(ctx context.Context, marshaler runtime.Marshaler, server AuthV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2972 var protoReq CredsBodyRequest2973 var metadata runtime.ServerMetadata2974 newReader, berr := utilities.IOReaderFactory(req.Body)2975 if berr != nil {2976 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", berr)2977 }2978 if err := marshaler.NewDecoder(newReader()).Decode(&protoReq); err != nil && err != io.EOF {2979 return nil, metadata, status.Errorf(codes.InvalidArgument, "%v", err)2980 }2981 msg, err := server.Login(ctx, &protoReq)2982 return msg, metadata, err2983}2984func request_UsersV1_GetUser_0(ctx context.Context, marshaler runtime.Marshaler, client UsersV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2985 var protoReq empty.Empty2986 var metadata runtime.ServerMetadata2987 msg, err := client.GetUser(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))2988 return msg, metadata, err2989}2990func local_request_UsersV1_GetUser_0(ctx context.Context, marshaler runtime.Marshaler, server UsersV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2991 var protoReq empty.Empty2992 var metadata runtime.ServerMetadata2993 msg, err := server.GetUser(ctx, &protoReq)2994 return msg, metadata, err2995}2996func request_VersionsV1_GetVersions_0(ctx context.Context, marshaler runtime.Marshaler, client VersionsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {2997 var protoReq empty.Empty2998 var metadata runtime.ServerMetadata2999 msg, err := client.GetVersions(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))3000 return msg, metadata, err3001}3002func local_request_VersionsV1_GetVersions_0(ctx context.Context, marshaler runtime.Marshaler, server VersionsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {3003 var protoReq empty.Empty3004 var metadata runtime.ServerMetadata3005 msg, err := server.GetVersions(ctx, &protoReq)3006 return msg, metadata, err3007}3008func request_VersionsV1_GetLogHandler_0(ctx context.Context, marshaler runtime.Marshaler, client VersionsV1Client, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {3009 var protoReq empty.Empty3010 var metadata runtime.ServerMetadata3011 msg, err := client.GetLogHandler(ctx, &protoReq, grpc.Header(&metadata.HeaderMD), grpc.Trailer(&metadata.TrailerMD))3012 return msg, metadata, err3013}3014func local_request_VersionsV1_GetLogHandler_0(ctx context.Context, marshaler runtime.Marshaler, server VersionsV1Server, req *http.Request, pathParams map[string]string) (proto.Message, runtime.ServerMetadata, error) {3015 var protoReq empty.Empty3016 var metadata runtime.ServerMetadata3017 msg, err := server.GetLogHandler(ctx, &protoReq)3018 return msg, metadata, err3019}3020// RegisterRunsV1HandlerServer registers the http handlers for service RunsV1 to "mux".3021// UnaryRPC :call RunsV1Server directly.3022// StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906.3023func RegisterRunsV1HandlerServer(ctx context.Context, mux *runtime.ServeMux, server RunsV1Server) error {3024 mux.Handle("GET", pattern_RunsV1_ListBookmarkedRuns_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3025 ctx, cancel := context.WithCancel(req.Context())3026 defer cancel()3027 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3028 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3029 if err != nil {3030 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3031 return3032 }3033 resp, md, err := local_request_RunsV1_ListBookmarkedRuns_0(rctx, inboundMarshaler, server, req, pathParams)3034 ctx = runtime.NewServerMetadataContext(ctx, md)3035 if err != nil {3036 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3037 return3038 }3039 forward_RunsV1_ListBookmarkedRuns_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3040 })3041 mux.Handle("GET", pattern_RunsV1_ListArchivedRuns_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3042 ctx, cancel := context.WithCancel(req.Context())3043 defer cancel()3044 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3045 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3046 if err != nil {3047 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3048 return3049 }3050 resp, md, err := local_request_RunsV1_ListArchivedRuns_0(rctx, inboundMarshaler, server, req, pathParams)3051 ctx = runtime.NewServerMetadataContext(ctx, md)3052 if err != nil {3053 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3054 return3055 }3056 forward_RunsV1_ListArchivedRuns_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3057 })3058 mux.Handle("GET", pattern_RunsV1_ListRuns_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3059 ctx, cancel := context.WithCancel(req.Context())3060 defer cancel()3061 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3062 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3063 if err != nil {3064 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3065 return3066 }3067 resp, md, err := local_request_RunsV1_ListRuns_0(rctx, inboundMarshaler, server, req, pathParams)3068 ctx = runtime.NewServerMetadataContext(ctx, md)3069 if err != nil {3070 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3071 return3072 }3073 forward_RunsV1_ListRuns_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3074 })3075 mux.Handle("POST", pattern_RunsV1_CreateRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3076 ctx, cancel := context.WithCancel(req.Context())3077 defer cancel()3078 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3079 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3080 if err != nil {3081 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3082 return3083 }3084 resp, md, err := local_request_RunsV1_CreateRun_0(rctx, inboundMarshaler, server, req, pathParams)3085 ctx = runtime.NewServerMetadataContext(ctx, md)3086 if err != nil {3087 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3088 return3089 }3090 forward_RunsV1_CreateRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3091 })3092 mux.Handle("GET", pattern_RunsV1_GetRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3093 ctx, cancel := context.WithCancel(req.Context())3094 defer cancel()3095 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3096 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3097 if err != nil {3098 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3099 return3100 }3101 resp, md, err := local_request_RunsV1_GetRun_0(rctx, inboundMarshaler, server, req, pathParams)3102 ctx = runtime.NewServerMetadataContext(ctx, md)3103 if err != nil {3104 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3105 return3106 }3107 forward_RunsV1_GetRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3108 })3109 mux.Handle("PUT", pattern_RunsV1_UpdateRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3110 ctx, cancel := context.WithCancel(req.Context())3111 defer cancel()3112 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3113 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3114 if err != nil {3115 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3116 return3117 }3118 resp, md, err := local_request_RunsV1_UpdateRun_0(rctx, inboundMarshaler, server, req, pathParams)3119 ctx = runtime.NewServerMetadataContext(ctx, md)3120 if err != nil {3121 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3122 return3123 }3124 forward_RunsV1_UpdateRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3125 })3126 mux.Handle("PATCH", pattern_RunsV1_PatchRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3127 ctx, cancel := context.WithCancel(req.Context())3128 defer cancel()3129 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3130 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3131 if err != nil {3132 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3133 return3134 }3135 resp, md, err := local_request_RunsV1_PatchRun_0(rctx, inboundMarshaler, server, req, pathParams)3136 ctx = runtime.NewServerMetadataContext(ctx, md)3137 if err != nil {3138 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3139 return3140 }3141 forward_RunsV1_PatchRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3142 })3143 mux.Handle("DELETE", pattern_RunsV1_DeleteRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3144 ctx, cancel := context.WithCancel(req.Context())3145 defer cancel()3146 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3147 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3148 if err != nil {3149 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3150 return3151 }3152 resp, md, err := local_request_RunsV1_DeleteRun_0(rctx, inboundMarshaler, server, req, pathParams)3153 ctx = runtime.NewServerMetadataContext(ctx, md)3154 if err != nil {3155 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3156 return3157 }3158 forward_RunsV1_DeleteRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3159 })3160 mux.Handle("DELETE", pattern_RunsV1_DeleteRuns_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3161 ctx, cancel := context.WithCancel(req.Context())3162 defer cancel()3163 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3164 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3165 if err != nil {3166 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3167 return3168 }3169 resp, md, err := local_request_RunsV1_DeleteRuns_0(rctx, inboundMarshaler, server, req, pathParams)3170 ctx = runtime.NewServerMetadataContext(ctx, md)3171 if err != nil {3172 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3173 return3174 }3175 forward_RunsV1_DeleteRuns_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3176 })3177 mux.Handle("POST", pattern_RunsV1_StopRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3178 ctx, cancel := context.WithCancel(req.Context())3179 defer cancel()3180 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3181 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3182 if err != nil {3183 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3184 return3185 }3186 resp, md, err := local_request_RunsV1_StopRun_0(rctx, inboundMarshaler, server, req, pathParams)3187 ctx = runtime.NewServerMetadataContext(ctx, md)3188 if err != nil {3189 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3190 return3191 }3192 forward_RunsV1_StopRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3193 })3194 mux.Handle("POST", pattern_RunsV1_StopRuns_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3195 ctx, cancel := context.WithCancel(req.Context())3196 defer cancel()3197 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3198 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3199 if err != nil {3200 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3201 return3202 }3203 resp, md, err := local_request_RunsV1_StopRuns_0(rctx, inboundMarshaler, server, req, pathParams)3204 ctx = runtime.NewServerMetadataContext(ctx, md)3205 if err != nil {3206 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3207 return3208 }3209 forward_RunsV1_StopRuns_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3210 })3211 mux.Handle("POST", pattern_RunsV1_InvalidateRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3212 ctx, cancel := context.WithCancel(req.Context())3213 defer cancel()3214 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3215 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3216 if err != nil {3217 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3218 return3219 }3220 resp, md, err := local_request_RunsV1_InvalidateRun_0(rctx, inboundMarshaler, server, req, pathParams)3221 ctx = runtime.NewServerMetadataContext(ctx, md)3222 if err != nil {3223 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3224 return3225 }3226 forward_RunsV1_InvalidateRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3227 })3228 mux.Handle("POST", pattern_RunsV1_InvalidateRuns_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3229 ctx, cancel := context.WithCancel(req.Context())3230 defer cancel()3231 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3232 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3233 if err != nil {3234 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3235 return3236 }3237 resp, md, err := local_request_RunsV1_InvalidateRuns_0(rctx, inboundMarshaler, server, req, pathParams)3238 ctx = runtime.NewServerMetadataContext(ctx, md)3239 if err != nil {3240 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3241 return3242 }3243 forward_RunsV1_InvalidateRuns_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3244 })3245 mux.Handle("POST", pattern_RunsV1_CopyRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3246 ctx, cancel := context.WithCancel(req.Context())3247 defer cancel()3248 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3249 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3250 if err != nil {3251 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3252 return3253 }3254 resp, md, err := local_request_RunsV1_CopyRun_0(rctx, inboundMarshaler, server, req, pathParams)3255 ctx = runtime.NewServerMetadataContext(ctx, md)3256 if err != nil {3257 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3258 return3259 }3260 forward_RunsV1_CopyRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3261 })3262 mux.Handle("POST", pattern_RunsV1_RestartRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3263 ctx, cancel := context.WithCancel(req.Context())3264 defer cancel()3265 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3266 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3267 if err != nil {3268 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3269 return3270 }3271 resp, md, err := local_request_RunsV1_RestartRun_0(rctx, inboundMarshaler, server, req, pathParams)3272 ctx = runtime.NewServerMetadataContext(ctx, md)3273 if err != nil {3274 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3275 return3276 }3277 forward_RunsV1_RestartRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3278 })3279 mux.Handle("POST", pattern_RunsV1_ResumeRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3280 ctx, cancel := context.WithCancel(req.Context())3281 defer cancel()3282 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3283 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3284 if err != nil {3285 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3286 return3287 }3288 resp, md, err := local_request_RunsV1_ResumeRun_0(rctx, inboundMarshaler, server, req, pathParams)3289 ctx = runtime.NewServerMetadataContext(ctx, md)3290 if err != nil {3291 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3292 return3293 }3294 forward_RunsV1_ResumeRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3295 })3296 mux.Handle("POST", pattern_RunsV1_ArchiveRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3297 ctx, cancel := context.WithCancel(req.Context())3298 defer cancel()3299 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3300 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3301 if err != nil {3302 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3303 return3304 }3305 resp, md, err := local_request_RunsV1_ArchiveRun_0(rctx, inboundMarshaler, server, req, pathParams)3306 ctx = runtime.NewServerMetadataContext(ctx, md)3307 if err != nil {3308 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3309 return3310 }3311 forward_RunsV1_ArchiveRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3312 })3313 mux.Handle("POST", pattern_RunsV1_RestoreRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3314 ctx, cancel := context.WithCancel(req.Context())3315 defer cancel()3316 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3317 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3318 if err != nil {3319 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3320 return3321 }3322 resp, md, err := local_request_RunsV1_RestoreRun_0(rctx, inboundMarshaler, server, req, pathParams)3323 ctx = runtime.NewServerMetadataContext(ctx, md)3324 if err != nil {3325 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3326 return3327 }3328 forward_RunsV1_RestoreRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3329 })3330 mux.Handle("POST", pattern_RunsV1_BookmarkRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3331 ctx, cancel := context.WithCancel(req.Context())3332 defer cancel()3333 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3334 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3335 if err != nil {3336 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3337 return3338 }3339 resp, md, err := local_request_RunsV1_BookmarkRun_0(rctx, inboundMarshaler, server, req, pathParams)3340 ctx = runtime.NewServerMetadataContext(ctx, md)3341 if err != nil {3342 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3343 return3344 }3345 forward_RunsV1_BookmarkRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3346 })3347 mux.Handle("DELETE", pattern_RunsV1_UnbookmarkRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3348 ctx, cancel := context.WithCancel(req.Context())3349 defer cancel()3350 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3351 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3352 if err != nil {3353 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3354 return3355 }3356 resp, md, err := local_request_RunsV1_UnbookmarkRun_0(rctx, inboundMarshaler, server, req, pathParams)3357 ctx = runtime.NewServerMetadataContext(ctx, md)3358 if err != nil {3359 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3360 return3361 }3362 forward_RunsV1_UnbookmarkRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3363 })3364 mux.Handle("POST", pattern_RunsV1_StartRunTensorboard_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3365 ctx, cancel := context.WithCancel(req.Context())3366 defer cancel()3367 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3368 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3369 if err != nil {3370 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3371 return3372 }3373 resp, md, err := local_request_RunsV1_StartRunTensorboard_0(rctx, inboundMarshaler, server, req, pathParams)3374 ctx = runtime.NewServerMetadataContext(ctx, md)3375 if err != nil {3376 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3377 return3378 }3379 forward_RunsV1_StartRunTensorboard_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3380 })3381 mux.Handle("DELETE", pattern_RunsV1_StopRunTensorboard_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3382 ctx, cancel := context.WithCancel(req.Context())3383 defer cancel()3384 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3385 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3386 if err != nil {3387 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3388 return3389 }3390 resp, md, err := local_request_RunsV1_StopRunTensorboard_0(rctx, inboundMarshaler, server, req, pathParams)3391 ctx = runtime.NewServerMetadataContext(ctx, md)3392 if err != nil {3393 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3394 return3395 }3396 forward_RunsV1_StopRunTensorboard_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3397 })3398 mux.Handle("GET", pattern_RunsV1_GetRunStatuses_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3399 ctx, cancel := context.WithCancel(req.Context())3400 defer cancel()3401 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3402 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3403 if err != nil {3404 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3405 return3406 }3407 resp, md, err := local_request_RunsV1_GetRunStatuses_0(rctx, inboundMarshaler, server, req, pathParams)3408 ctx = runtime.NewServerMetadataContext(ctx, md)3409 if err != nil {3410 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3411 return3412 }3413 forward_RunsV1_GetRunStatuses_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3414 })3415 mux.Handle("POST", pattern_RunsV1_CreateRunStatus_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3416 ctx, cancel := context.WithCancel(req.Context())3417 defer cancel()3418 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3419 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3420 if err != nil {3421 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3422 return3423 }3424 resp, md, err := local_request_RunsV1_CreateRunStatus_0(rctx, inboundMarshaler, server, req, pathParams)3425 ctx = runtime.NewServerMetadataContext(ctx, md)3426 if err != nil {3427 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3428 return3429 }3430 forward_RunsV1_CreateRunStatus_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3431 })3432 mux.Handle("GET", pattern_RunsV1_GetRunCodeRefs_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3433 ctx, cancel := context.WithCancel(req.Context())3434 defer cancel()3435 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3436 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3437 if err != nil {3438 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3439 return3440 }3441 resp, md, err := local_request_RunsV1_GetRunCodeRefs_0(rctx, inboundMarshaler, server, req, pathParams)3442 ctx = runtime.NewServerMetadataContext(ctx, md)3443 if err != nil {3444 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3445 return3446 }3447 forward_RunsV1_GetRunCodeRefs_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3448 })3449 mux.Handle("POST", pattern_RunsV1_CreateRunCodeRef_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3450 ctx, cancel := context.WithCancel(req.Context())3451 defer cancel()3452 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3453 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3454 if err != nil {3455 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3456 return3457 }3458 resp, md, err := local_request_RunsV1_CreateRunCodeRef_0(rctx, inboundMarshaler, server, req, pathParams)3459 ctx = runtime.NewServerMetadataContext(ctx, md)3460 if err != nil {3461 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3462 return3463 }3464 forward_RunsV1_CreateRunCodeRef_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3465 })3466 mux.Handle("POST", pattern_RunsV1_ImpersonateToken_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3467 ctx, cancel := context.WithCancel(req.Context())3468 defer cancel()3469 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3470 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3471 if err != nil {3472 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3473 return3474 }3475 resp, md, err := local_request_RunsV1_ImpersonateToken_0(rctx, inboundMarshaler, server, req, pathParams)3476 ctx = runtime.NewServerMetadataContext(ctx, md)3477 if err != nil {3478 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3479 return3480 }3481 forward_RunsV1_ImpersonateToken_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3482 })3483 return nil3484}3485// RegisterProjectsV1HandlerServer registers the http handlers for service ProjectsV1 to "mux".3486// UnaryRPC :call ProjectsV1Server directly.3487// StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906.3488func RegisterProjectsV1HandlerServer(ctx context.Context, mux *runtime.ServeMux, server ProjectsV1Server) error {3489 mux.Handle("GET", pattern_ProjectsV1_ListProjects_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3490 ctx, cancel := context.WithCancel(req.Context())3491 defer cancel()3492 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3493 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3494 if err != nil {3495 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3496 return3497 }3498 resp, md, err := local_request_ProjectsV1_ListProjects_0(rctx, inboundMarshaler, server, req, pathParams)3499 ctx = runtime.NewServerMetadataContext(ctx, md)3500 if err != nil {3501 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3502 return3503 }3504 forward_ProjectsV1_ListProjects_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3505 })3506 mux.Handle("GET", pattern_ProjectsV1_ListProjectNames_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3507 ctx, cancel := context.WithCancel(req.Context())3508 defer cancel()3509 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3510 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3511 if err != nil {3512 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3513 return3514 }3515 resp, md, err := local_request_ProjectsV1_ListProjectNames_0(rctx, inboundMarshaler, server, req, pathParams)3516 ctx = runtime.NewServerMetadataContext(ctx, md)3517 if err != nil {3518 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3519 return3520 }3521 forward_ProjectsV1_ListProjectNames_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3522 })3523 mux.Handle("GET", pattern_ProjectsV1_ListBookmarkedProjects_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3524 ctx, cancel := context.WithCancel(req.Context())3525 defer cancel()3526 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3527 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3528 if err != nil {3529 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3530 return3531 }3532 resp, md, err := local_request_ProjectsV1_ListBookmarkedProjects_0(rctx, inboundMarshaler, server, req, pathParams)3533 ctx = runtime.NewServerMetadataContext(ctx, md)3534 if err != nil {3535 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3536 return3537 }3538 forward_ProjectsV1_ListBookmarkedProjects_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3539 })3540 mux.Handle("GET", pattern_ProjectsV1_ListArchivedProjects_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3541 ctx, cancel := context.WithCancel(req.Context())3542 defer cancel()3543 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3544 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3545 if err != nil {3546 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3547 return3548 }3549 resp, md, err := local_request_ProjectsV1_ListArchivedProjects_0(rctx, inboundMarshaler, server, req, pathParams)3550 ctx = runtime.NewServerMetadataContext(ctx, md)3551 if err != nil {3552 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3553 return3554 }3555 forward_ProjectsV1_ListArchivedProjects_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3556 })3557 mux.Handle("POST", pattern_ProjectsV1_CreateProject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3558 ctx, cancel := context.WithCancel(req.Context())3559 defer cancel()3560 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3561 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3562 if err != nil {3563 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3564 return3565 }3566 resp, md, err := local_request_ProjectsV1_CreateProject_0(rctx, inboundMarshaler, server, req, pathParams)3567 ctx = runtime.NewServerMetadataContext(ctx, md)3568 if err != nil {3569 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3570 return3571 }3572 forward_ProjectsV1_CreateProject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3573 })3574 mux.Handle("GET", pattern_ProjectsV1_GetProject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3575 ctx, cancel := context.WithCancel(req.Context())3576 defer cancel()3577 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3578 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3579 if err != nil {3580 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3581 return3582 }3583 resp, md, err := local_request_ProjectsV1_GetProject_0(rctx, inboundMarshaler, server, req, pathParams)3584 ctx = runtime.NewServerMetadataContext(ctx, md)3585 if err != nil {3586 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3587 return3588 }3589 forward_ProjectsV1_GetProject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3590 })3591 mux.Handle("PUT", pattern_ProjectsV1_UpdateProject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3592 ctx, cancel := context.WithCancel(req.Context())3593 defer cancel()3594 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3595 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3596 if err != nil {3597 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3598 return3599 }3600 resp, md, err := local_request_ProjectsV1_UpdateProject_0(rctx, inboundMarshaler, server, req, pathParams)3601 ctx = runtime.NewServerMetadataContext(ctx, md)3602 if err != nil {3603 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3604 return3605 }3606 forward_ProjectsV1_UpdateProject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3607 })3608 mux.Handle("PATCH", pattern_ProjectsV1_PatchProject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3609 ctx, cancel := context.WithCancel(req.Context())3610 defer cancel()3611 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3612 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3613 if err != nil {3614 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3615 return3616 }3617 resp, md, err := local_request_ProjectsV1_PatchProject_0(rctx, inboundMarshaler, server, req, pathParams)3618 ctx = runtime.NewServerMetadataContext(ctx, md)3619 if err != nil {3620 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3621 return3622 }3623 forward_ProjectsV1_PatchProject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3624 })3625 mux.Handle("DELETE", pattern_ProjectsV1_DeleteProject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3626 ctx, cancel := context.WithCancel(req.Context())3627 defer cancel()3628 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3629 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3630 if err != nil {3631 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3632 return3633 }3634 resp, md, err := local_request_ProjectsV1_DeleteProject_0(rctx, inboundMarshaler, server, req, pathParams)3635 ctx = runtime.NewServerMetadataContext(ctx, md)3636 if err != nil {3637 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3638 return3639 }3640 forward_ProjectsV1_DeleteProject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3641 })3642 mux.Handle("POST", pattern_ProjectsV1_ArchiveProject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3643 ctx, cancel := context.WithCancel(req.Context())3644 defer cancel()3645 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3646 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3647 if err != nil {3648 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3649 return3650 }3651 resp, md, err := local_request_ProjectsV1_ArchiveProject_0(rctx, inboundMarshaler, server, req, pathParams)3652 ctx = runtime.NewServerMetadataContext(ctx, md)3653 if err != nil {3654 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3655 return3656 }3657 forward_ProjectsV1_ArchiveProject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3658 })3659 mux.Handle("POST", pattern_ProjectsV1_RestoreExperiment_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3660 ctx, cancel := context.WithCancel(req.Context())3661 defer cancel()3662 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3663 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3664 if err != nil {3665 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3666 return3667 }3668 resp, md, err := local_request_ProjectsV1_RestoreExperiment_0(rctx, inboundMarshaler, server, req, pathParams)3669 ctx = runtime.NewServerMetadataContext(ctx, md)3670 if err != nil {3671 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3672 return3673 }3674 forward_ProjectsV1_RestoreExperiment_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3675 })3676 mux.Handle("POST", pattern_ProjectsV1_BookmarkProject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3677 ctx, cancel := context.WithCancel(req.Context())3678 defer cancel()3679 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3680 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3681 if err != nil {3682 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3683 return3684 }3685 resp, md, err := local_request_ProjectsV1_BookmarkProject_0(rctx, inboundMarshaler, server, req, pathParams)3686 ctx = runtime.NewServerMetadataContext(ctx, md)3687 if err != nil {3688 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3689 return3690 }3691 forward_ProjectsV1_BookmarkProject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3692 })3693 mux.Handle("DELETE", pattern_ProjectsV1_UnbookmarkProject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3694 ctx, cancel := context.WithCancel(req.Context())3695 defer cancel()3696 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3697 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3698 if err != nil {3699 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3700 return3701 }3702 resp, md, err := local_request_ProjectsV1_UnbookmarkProject_0(rctx, inboundMarshaler, server, req, pathParams)3703 ctx = runtime.NewServerMetadataContext(ctx, md)3704 if err != nil {3705 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3706 return3707 }3708 forward_ProjectsV1_UnbookmarkProject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3709 })3710 mux.Handle("POST", pattern_ProjectsV1_EnableProjectCI_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3711 ctx, cancel := context.WithCancel(req.Context())3712 defer cancel()3713 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3714 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3715 if err != nil {3716 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3717 return3718 }3719 resp, md, err := local_request_ProjectsV1_EnableProjectCI_0(rctx, inboundMarshaler, server, req, pathParams)3720 ctx = runtime.NewServerMetadataContext(ctx, md)3721 if err != nil {3722 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3723 return3724 }3725 forward_ProjectsV1_EnableProjectCI_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3726 })3727 mux.Handle("DELETE", pattern_ProjectsV1_DisableProjectCI_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3728 ctx, cancel := context.WithCancel(req.Context())3729 defer cancel()3730 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3731 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3732 if err != nil {3733 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3734 return3735 }3736 resp, md, err := local_request_ProjectsV1_DisableProjectCI_0(rctx, inboundMarshaler, server, req, pathParams)3737 ctx = runtime.NewServerMetadataContext(ctx, md)3738 if err != nil {3739 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3740 return3741 }3742 forward_ProjectsV1_DisableProjectCI_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3743 })3744 return nil3745}3746// RegisterAuthV1HandlerServer registers the http handlers for service AuthV1 to "mux".3747// UnaryRPC :call AuthV1Server directly.3748// StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906.3749func RegisterAuthV1HandlerServer(ctx context.Context, mux *runtime.ServeMux, server AuthV1Server) error {3750 mux.Handle("POST", pattern_AuthV1_Login_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3751 ctx, cancel := context.WithCancel(req.Context())3752 defer cancel()3753 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3754 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3755 if err != nil {3756 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3757 return3758 }3759 resp, md, err := local_request_AuthV1_Login_0(rctx, inboundMarshaler, server, req, pathParams)3760 ctx = runtime.NewServerMetadataContext(ctx, md)3761 if err != nil {3762 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3763 return3764 }3765 forward_AuthV1_Login_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3766 })3767 return nil3768}3769// RegisterUsersV1HandlerServer registers the http handlers for service UsersV1 to "mux".3770// UnaryRPC :call UsersV1Server directly.3771// StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906.3772func RegisterUsersV1HandlerServer(ctx context.Context, mux *runtime.ServeMux, server UsersV1Server) error {3773 mux.Handle("GET", pattern_UsersV1_GetUser_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3774 ctx, cancel := context.WithCancel(req.Context())3775 defer cancel()3776 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3777 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3778 if err != nil {3779 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3780 return3781 }3782 resp, md, err := local_request_UsersV1_GetUser_0(rctx, inboundMarshaler, server, req, pathParams)3783 ctx = runtime.NewServerMetadataContext(ctx, md)3784 if err != nil {3785 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3786 return3787 }3788 forward_UsersV1_GetUser_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3789 })3790 return nil3791}3792// RegisterVersionsV1HandlerServer registers the http handlers for service VersionsV1 to "mux".3793// UnaryRPC :call VersionsV1Server directly.3794// StreamingRPC :currently unsupported pending https://github.com/grpc/grpc-go/issues/906.3795func RegisterVersionsV1HandlerServer(ctx context.Context, mux *runtime.ServeMux, server VersionsV1Server) error {3796 mux.Handle("GET", pattern_VersionsV1_GetVersions_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3797 ctx, cancel := context.WithCancel(req.Context())3798 defer cancel()3799 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3800 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3801 if err != nil {3802 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3803 return3804 }3805 resp, md, err := local_request_VersionsV1_GetVersions_0(rctx, inboundMarshaler, server, req, pathParams)3806 ctx = runtime.NewServerMetadataContext(ctx, md)3807 if err != nil {3808 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3809 return3810 }3811 forward_VersionsV1_GetVersions_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3812 })3813 mux.Handle("GET", pattern_VersionsV1_GetLogHandler_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3814 ctx, cancel := context.WithCancel(req.Context())3815 defer cancel()3816 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3817 rctx, err := runtime.AnnotateIncomingContext(ctx, mux, req)3818 if err != nil {3819 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3820 return3821 }3822 resp, md, err := local_request_VersionsV1_GetLogHandler_0(rctx, inboundMarshaler, server, req, pathParams)3823 ctx = runtime.NewServerMetadataContext(ctx, md)3824 if err != nil {3825 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3826 return3827 }3828 forward_VersionsV1_GetLogHandler_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3829 })3830 return nil3831}3832// RegisterRunsV1HandlerFromEndpoint is same as RegisterRunsV1Handler but3833// automatically dials to "endpoint" and closes the connection when "ctx" gets done.3834func RegisterRunsV1HandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) {3835 conn, err := grpc.Dial(endpoint, opts...)3836 if err != nil {3837 return err3838 }3839 defer func() {3840 if err != nil {3841 if cerr := conn.Close(); cerr != nil {3842 grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr)3843 }3844 return3845 }3846 go func() {3847 <-ctx.Done()3848 if cerr := conn.Close(); cerr != nil {3849 grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr)3850 }3851 }()3852 }()3853 return RegisterRunsV1Handler(ctx, mux, conn)3854}3855// RegisterRunsV1Handler registers the http handlers for service RunsV1 to "mux".3856// The handlers forward requests to the grpc endpoint over "conn".3857func RegisterRunsV1Handler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error {3858 return RegisterRunsV1HandlerClient(ctx, mux, NewRunsV1Client(conn))3859}3860// RegisterRunsV1HandlerClient registers the http handlers for service RunsV13861// to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "RunsV1Client".3862// Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "RunsV1Client"3863// doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in3864// "RunsV1Client" to call the correct interceptors.3865func RegisterRunsV1HandlerClient(ctx context.Context, mux *runtime.ServeMux, client RunsV1Client) error {3866 mux.Handle("GET", pattern_RunsV1_ListBookmarkedRuns_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3867 ctx, cancel := context.WithCancel(req.Context())3868 defer cancel()3869 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3870 rctx, err := runtime.AnnotateContext(ctx, mux, req)3871 if err != nil {3872 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3873 return3874 }3875 resp, md, err := request_RunsV1_ListBookmarkedRuns_0(rctx, inboundMarshaler, client, req, pathParams)3876 ctx = runtime.NewServerMetadataContext(ctx, md)3877 if err != nil {3878 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3879 return3880 }3881 forward_RunsV1_ListBookmarkedRuns_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3882 })3883 mux.Handle("GET", pattern_RunsV1_ListArchivedRuns_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3884 ctx, cancel := context.WithCancel(req.Context())3885 defer cancel()3886 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3887 rctx, err := runtime.AnnotateContext(ctx, mux, req)3888 if err != nil {3889 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3890 return3891 }3892 resp, md, err := request_RunsV1_ListArchivedRuns_0(rctx, inboundMarshaler, client, req, pathParams)3893 ctx = runtime.NewServerMetadataContext(ctx, md)3894 if err != nil {3895 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3896 return3897 }3898 forward_RunsV1_ListArchivedRuns_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3899 })3900 mux.Handle("GET", pattern_RunsV1_ListRuns_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3901 ctx, cancel := context.WithCancel(req.Context())3902 defer cancel()3903 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3904 rctx, err := runtime.AnnotateContext(ctx, mux, req)3905 if err != nil {3906 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3907 return3908 }3909 resp, md, err := request_RunsV1_ListRuns_0(rctx, inboundMarshaler, client, req, pathParams)3910 ctx = runtime.NewServerMetadataContext(ctx, md)3911 if err != nil {3912 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3913 return3914 }3915 forward_RunsV1_ListRuns_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3916 })3917 mux.Handle("POST", pattern_RunsV1_CreateRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3918 ctx, cancel := context.WithCancel(req.Context())3919 defer cancel()3920 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3921 rctx, err := runtime.AnnotateContext(ctx, mux, req)3922 if err != nil {3923 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3924 return3925 }3926 resp, md, err := request_RunsV1_CreateRun_0(rctx, inboundMarshaler, client, req, pathParams)3927 ctx = runtime.NewServerMetadataContext(ctx, md)3928 if err != nil {3929 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3930 return3931 }3932 forward_RunsV1_CreateRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3933 })3934 mux.Handle("GET", pattern_RunsV1_GetRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3935 ctx, cancel := context.WithCancel(req.Context())3936 defer cancel()3937 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3938 rctx, err := runtime.AnnotateContext(ctx, mux, req)3939 if err != nil {3940 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3941 return3942 }3943 resp, md, err := request_RunsV1_GetRun_0(rctx, inboundMarshaler, client, req, pathParams)3944 ctx = runtime.NewServerMetadataContext(ctx, md)3945 if err != nil {3946 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3947 return3948 }3949 forward_RunsV1_GetRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3950 })3951 mux.Handle("PUT", pattern_RunsV1_UpdateRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3952 ctx, cancel := context.WithCancel(req.Context())3953 defer cancel()3954 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3955 rctx, err := runtime.AnnotateContext(ctx, mux, req)3956 if err != nil {3957 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3958 return3959 }3960 resp, md, err := request_RunsV1_UpdateRun_0(rctx, inboundMarshaler, client, req, pathParams)3961 ctx = runtime.NewServerMetadataContext(ctx, md)3962 if err != nil {3963 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3964 return3965 }3966 forward_RunsV1_UpdateRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3967 })3968 mux.Handle("PATCH", pattern_RunsV1_PatchRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3969 ctx, cancel := context.WithCancel(req.Context())3970 defer cancel()3971 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3972 rctx, err := runtime.AnnotateContext(ctx, mux, req)3973 if err != nil {3974 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3975 return3976 }3977 resp, md, err := request_RunsV1_PatchRun_0(rctx, inboundMarshaler, client, req, pathParams)3978 ctx = runtime.NewServerMetadataContext(ctx, md)3979 if err != nil {3980 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3981 return3982 }3983 forward_RunsV1_PatchRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)3984 })3985 mux.Handle("DELETE", pattern_RunsV1_DeleteRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {3986 ctx, cancel := context.WithCancel(req.Context())3987 defer cancel()3988 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)3989 rctx, err := runtime.AnnotateContext(ctx, mux, req)3990 if err != nil {3991 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3992 return3993 }3994 resp, md, err := request_RunsV1_DeleteRun_0(rctx, inboundMarshaler, client, req, pathParams)3995 ctx = runtime.NewServerMetadataContext(ctx, md)3996 if err != nil {3997 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)3998 return3999 }4000 forward_RunsV1_DeleteRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4001 })4002 mux.Handle("DELETE", pattern_RunsV1_DeleteRuns_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4003 ctx, cancel := context.WithCancel(req.Context())4004 defer cancel()4005 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4006 rctx, err := runtime.AnnotateContext(ctx, mux, req)4007 if err != nil {4008 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4009 return4010 }4011 resp, md, err := request_RunsV1_DeleteRuns_0(rctx, inboundMarshaler, client, req, pathParams)4012 ctx = runtime.NewServerMetadataContext(ctx, md)4013 if err != nil {4014 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4015 return4016 }4017 forward_RunsV1_DeleteRuns_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4018 })4019 mux.Handle("POST", pattern_RunsV1_StopRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4020 ctx, cancel := context.WithCancel(req.Context())4021 defer cancel()4022 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4023 rctx, err := runtime.AnnotateContext(ctx, mux, req)4024 if err != nil {4025 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4026 return4027 }4028 resp, md, err := request_RunsV1_StopRun_0(rctx, inboundMarshaler, client, req, pathParams)4029 ctx = runtime.NewServerMetadataContext(ctx, md)4030 if err != nil {4031 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4032 return4033 }4034 forward_RunsV1_StopRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4035 })4036 mux.Handle("POST", pattern_RunsV1_StopRuns_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4037 ctx, cancel := context.WithCancel(req.Context())4038 defer cancel()4039 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4040 rctx, err := runtime.AnnotateContext(ctx, mux, req)4041 if err != nil {4042 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4043 return4044 }4045 resp, md, err := request_RunsV1_StopRuns_0(rctx, inboundMarshaler, client, req, pathParams)4046 ctx = runtime.NewServerMetadataContext(ctx, md)4047 if err != nil {4048 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4049 return4050 }4051 forward_RunsV1_StopRuns_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4052 })4053 mux.Handle("POST", pattern_RunsV1_InvalidateRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4054 ctx, cancel := context.WithCancel(req.Context())4055 defer cancel()4056 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4057 rctx, err := runtime.AnnotateContext(ctx, mux, req)4058 if err != nil {4059 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4060 return4061 }4062 resp, md, err := request_RunsV1_InvalidateRun_0(rctx, inboundMarshaler, client, req, pathParams)4063 ctx = runtime.NewServerMetadataContext(ctx, md)4064 if err != nil {4065 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4066 return4067 }4068 forward_RunsV1_InvalidateRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4069 })4070 mux.Handle("POST", pattern_RunsV1_InvalidateRuns_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4071 ctx, cancel := context.WithCancel(req.Context())4072 defer cancel()4073 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4074 rctx, err := runtime.AnnotateContext(ctx, mux, req)4075 if err != nil {4076 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4077 return4078 }4079 resp, md, err := request_RunsV1_InvalidateRuns_0(rctx, inboundMarshaler, client, req, pathParams)4080 ctx = runtime.NewServerMetadataContext(ctx, md)4081 if err != nil {4082 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4083 return4084 }4085 forward_RunsV1_InvalidateRuns_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4086 })4087 mux.Handle("POST", pattern_RunsV1_CopyRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4088 ctx, cancel := context.WithCancel(req.Context())4089 defer cancel()4090 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4091 rctx, err := runtime.AnnotateContext(ctx, mux, req)4092 if err != nil {4093 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4094 return4095 }4096 resp, md, err := request_RunsV1_CopyRun_0(rctx, inboundMarshaler, client, req, pathParams)4097 ctx = runtime.NewServerMetadataContext(ctx, md)4098 if err != nil {4099 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4100 return4101 }4102 forward_RunsV1_CopyRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4103 })4104 mux.Handle("POST", pattern_RunsV1_RestartRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4105 ctx, cancel := context.WithCancel(req.Context())4106 defer cancel()4107 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4108 rctx, err := runtime.AnnotateContext(ctx, mux, req)4109 if err != nil {4110 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4111 return4112 }4113 resp, md, err := request_RunsV1_RestartRun_0(rctx, inboundMarshaler, client, req, pathParams)4114 ctx = runtime.NewServerMetadataContext(ctx, md)4115 if err != nil {4116 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4117 return4118 }4119 forward_RunsV1_RestartRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4120 })4121 mux.Handle("POST", pattern_RunsV1_ResumeRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4122 ctx, cancel := context.WithCancel(req.Context())4123 defer cancel()4124 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4125 rctx, err := runtime.AnnotateContext(ctx, mux, req)4126 if err != nil {4127 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4128 return4129 }4130 resp, md, err := request_RunsV1_ResumeRun_0(rctx, inboundMarshaler, client, req, pathParams)4131 ctx = runtime.NewServerMetadataContext(ctx, md)4132 if err != nil {4133 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4134 return4135 }4136 forward_RunsV1_ResumeRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4137 })4138 mux.Handle("POST", pattern_RunsV1_ArchiveRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4139 ctx, cancel := context.WithCancel(req.Context())4140 defer cancel()4141 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4142 rctx, err := runtime.AnnotateContext(ctx, mux, req)4143 if err != nil {4144 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4145 return4146 }4147 resp, md, err := request_RunsV1_ArchiveRun_0(rctx, inboundMarshaler, client, req, pathParams)4148 ctx = runtime.NewServerMetadataContext(ctx, md)4149 if err != nil {4150 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4151 return4152 }4153 forward_RunsV1_ArchiveRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4154 })4155 mux.Handle("POST", pattern_RunsV1_RestoreRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4156 ctx, cancel := context.WithCancel(req.Context())4157 defer cancel()4158 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4159 rctx, err := runtime.AnnotateContext(ctx, mux, req)4160 if err != nil {4161 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4162 return4163 }4164 resp, md, err := request_RunsV1_RestoreRun_0(rctx, inboundMarshaler, client, req, pathParams)4165 ctx = runtime.NewServerMetadataContext(ctx, md)4166 if err != nil {4167 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4168 return4169 }4170 forward_RunsV1_RestoreRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4171 })4172 mux.Handle("POST", pattern_RunsV1_BookmarkRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4173 ctx, cancel := context.WithCancel(req.Context())4174 defer cancel()4175 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4176 rctx, err := runtime.AnnotateContext(ctx, mux, req)4177 if err != nil {4178 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4179 return4180 }4181 resp, md, err := request_RunsV1_BookmarkRun_0(rctx, inboundMarshaler, client, req, pathParams)4182 ctx = runtime.NewServerMetadataContext(ctx, md)4183 if err != nil {4184 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4185 return4186 }4187 forward_RunsV1_BookmarkRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4188 })4189 mux.Handle("DELETE", pattern_RunsV1_UnbookmarkRun_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4190 ctx, cancel := context.WithCancel(req.Context())4191 defer cancel()4192 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4193 rctx, err := runtime.AnnotateContext(ctx, mux, req)4194 if err != nil {4195 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4196 return4197 }4198 resp, md, err := request_RunsV1_UnbookmarkRun_0(rctx, inboundMarshaler, client, req, pathParams)4199 ctx = runtime.NewServerMetadataContext(ctx, md)4200 if err != nil {4201 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4202 return4203 }4204 forward_RunsV1_UnbookmarkRun_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4205 })4206 mux.Handle("POST", pattern_RunsV1_StartRunTensorboard_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4207 ctx, cancel := context.WithCancel(req.Context())4208 defer cancel()4209 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4210 rctx, err := runtime.AnnotateContext(ctx, mux, req)4211 if err != nil {4212 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4213 return4214 }4215 resp, md, err := request_RunsV1_StartRunTensorboard_0(rctx, inboundMarshaler, client, req, pathParams)4216 ctx = runtime.NewServerMetadataContext(ctx, md)4217 if err != nil {4218 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4219 return4220 }4221 forward_RunsV1_StartRunTensorboard_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4222 })4223 mux.Handle("DELETE", pattern_RunsV1_StopRunTensorboard_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4224 ctx, cancel := context.WithCancel(req.Context())4225 defer cancel()4226 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4227 rctx, err := runtime.AnnotateContext(ctx, mux, req)4228 if err != nil {4229 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4230 return4231 }4232 resp, md, err := request_RunsV1_StopRunTensorboard_0(rctx, inboundMarshaler, client, req, pathParams)4233 ctx = runtime.NewServerMetadataContext(ctx, md)4234 if err != nil {4235 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4236 return4237 }4238 forward_RunsV1_StopRunTensorboard_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4239 })4240 mux.Handle("GET", pattern_RunsV1_GetRunStatuses_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4241 ctx, cancel := context.WithCancel(req.Context())4242 defer cancel()4243 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4244 rctx, err := runtime.AnnotateContext(ctx, mux, req)4245 if err != nil {4246 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4247 return4248 }4249 resp, md, err := request_RunsV1_GetRunStatuses_0(rctx, inboundMarshaler, client, req, pathParams)4250 ctx = runtime.NewServerMetadataContext(ctx, md)4251 if err != nil {4252 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4253 return4254 }4255 forward_RunsV1_GetRunStatuses_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4256 })4257 mux.Handle("POST", pattern_RunsV1_CreateRunStatus_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4258 ctx, cancel := context.WithCancel(req.Context())4259 defer cancel()4260 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4261 rctx, err := runtime.AnnotateContext(ctx, mux, req)4262 if err != nil {4263 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4264 return4265 }4266 resp, md, err := request_RunsV1_CreateRunStatus_0(rctx, inboundMarshaler, client, req, pathParams)4267 ctx = runtime.NewServerMetadataContext(ctx, md)4268 if err != nil {4269 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4270 return4271 }4272 forward_RunsV1_CreateRunStatus_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4273 })4274 mux.Handle("GET", pattern_RunsV1_GetRunCodeRefs_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4275 ctx, cancel := context.WithCancel(req.Context())4276 defer cancel()4277 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4278 rctx, err := runtime.AnnotateContext(ctx, mux, req)4279 if err != nil {4280 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4281 return4282 }4283 resp, md, err := request_RunsV1_GetRunCodeRefs_0(rctx, inboundMarshaler, client, req, pathParams)4284 ctx = runtime.NewServerMetadataContext(ctx, md)4285 if err != nil {4286 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4287 return4288 }4289 forward_RunsV1_GetRunCodeRefs_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4290 })4291 mux.Handle("POST", pattern_RunsV1_CreateRunCodeRef_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4292 ctx, cancel := context.WithCancel(req.Context())4293 defer cancel()4294 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4295 rctx, err := runtime.AnnotateContext(ctx, mux, req)4296 if err != nil {4297 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4298 return4299 }4300 resp, md, err := request_RunsV1_CreateRunCodeRef_0(rctx, inboundMarshaler, client, req, pathParams)4301 ctx = runtime.NewServerMetadataContext(ctx, md)4302 if err != nil {4303 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4304 return4305 }4306 forward_RunsV1_CreateRunCodeRef_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4307 })4308 mux.Handle("POST", pattern_RunsV1_ImpersonateToken_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4309 ctx, cancel := context.WithCancel(req.Context())4310 defer cancel()4311 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4312 rctx, err := runtime.AnnotateContext(ctx, mux, req)4313 if err != nil {4314 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4315 return4316 }4317 resp, md, err := request_RunsV1_ImpersonateToken_0(rctx, inboundMarshaler, client, req, pathParams)4318 ctx = runtime.NewServerMetadataContext(ctx, md)4319 if err != nil {4320 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4321 return4322 }4323 forward_RunsV1_ImpersonateToken_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4324 })4325 return nil4326}4327var (4328 pattern_RunsV1_ListBookmarkedRuns_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3, 2, 4}, []string{"api", "v1", "bookmarks", "user", "runs"}, "", runtime.AssumeColonVerbOpt(true)))4329 pattern_RunsV1_ListArchivedRuns_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3, 2, 4}, []string{"api", "v1", "archives", "user", "runs"}, "", runtime.AssumeColonVerbOpt(true)))4330 pattern_RunsV1_ListRuns_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4, 2, 5}, []string{"api", "v1", "owner", "project", "runs", "list"}, "", runtime.AssumeColonVerbOpt(true)))4331 pattern_RunsV1_CreateRun_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4, 2, 5}, []string{"api", "v1", "owner", "project", "runs", "create"}, "", runtime.AssumeColonVerbOpt(true)))4332 pattern_RunsV1_GetRun_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4, 1, 0, 4, 1, 5, 5}, []string{"api", "v1", "owner", "project", "runs", "uuid"}, "", runtime.AssumeColonVerbOpt(true)))4333 pattern_RunsV1_UpdateRun_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4, 1, 0, 4, 1, 5, 5}, []string{"api", "v1", "owner", "project", "runs", "run.uuid"}, "", runtime.AssumeColonVerbOpt(true)))4334 pattern_RunsV1_PatchRun_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4, 1, 0, 4, 1, 5, 5}, []string{"api", "v1", "owner", "project", "runs", "run.uuid"}, "", runtime.AssumeColonVerbOpt(true)))4335 pattern_RunsV1_DeleteRun_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4, 1, 0, 4, 1, 5, 5}, []string{"api", "v1", "owner", "project", "runs", "uuid"}, "", runtime.AssumeColonVerbOpt(true)))4336 pattern_RunsV1_DeleteRuns_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4, 2, 5}, []string{"api", "v1", "owner", "project", "runs", "delete"}, "", runtime.AssumeColonVerbOpt(true)))4337 pattern_RunsV1_StopRun_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6}, []string{"api", "v1", "owner", "project", "runs", "uuid", "stop"}, "", runtime.AssumeColonVerbOpt(true)))4338 pattern_RunsV1_StopRuns_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4, 2, 5}, []string{"api", "v1", "owner", "project", "runs", "stop"}, "", runtime.AssumeColonVerbOpt(true)))4339 pattern_RunsV1_InvalidateRun_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6}, []string{"api", "v1", "owner", "project", "runs", "uuid", "invalidate"}, "", runtime.AssumeColonVerbOpt(true)))4340 pattern_RunsV1_InvalidateRuns_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4, 2, 5}, []string{"api", "v1", "owner", "project", "runs", "invalidate"}, "", runtime.AssumeColonVerbOpt(true)))4341 pattern_RunsV1_CopyRun_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6}, []string{"api", "v1", "entity.owner", "entity.project", "runs", "entity.uuid", "copy"}, "", runtime.AssumeColonVerbOpt(true)))4342 pattern_RunsV1_RestartRun_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6}, []string{"api", "v1", "entity.owner", "entity.project", "runs", "entity.uuid", "restart"}, "", runtime.AssumeColonVerbOpt(true)))4343 pattern_RunsV1_ResumeRun_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6}, []string{"api", "v1", "entity.owner", "entity.project", "runs", "entity.uuid", "resume"}, "", runtime.AssumeColonVerbOpt(true)))4344 pattern_RunsV1_ArchiveRun_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6}, []string{"api", "v1", "owner", "project", "runs", "uuid", "archive"}, "", runtime.AssumeColonVerbOpt(true)))4345 pattern_RunsV1_RestoreRun_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6}, []string{"api", "v1", "owner", "project", "runs", "uuid", "restore"}, "", runtime.AssumeColonVerbOpt(true)))4346 pattern_RunsV1_BookmarkRun_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6}, []string{"api", "v1", "owner", "project", "runs", "uuid", "bookmark"}, "", runtime.AssumeColonVerbOpt(true)))4347 pattern_RunsV1_UnbookmarkRun_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6}, []string{"api", "v1", "owner", "project", "runs", "uuid", "unbookmark"}, "", runtime.AssumeColonVerbOpt(true)))4348 pattern_RunsV1_StartRunTensorboard_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6, 2, 7}, []string{"api", "v1", "owner", "project", "runs", "uuid", "tensorboard", "start"}, "", runtime.AssumeColonVerbOpt(true)))4349 pattern_RunsV1_StopRunTensorboard_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6, 2, 7}, []string{"api", "v1", "owner", "project", "runs", "uuid", "tensorboard", "stop"}, "", runtime.AssumeColonVerbOpt(true)))4350 pattern_RunsV1_GetRunStatuses_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6}, []string{"api", "v1", "owner", "project", "runs", "uuid", "statuses"}, "", runtime.AssumeColonVerbOpt(true)))4351 pattern_RunsV1_CreateRunStatus_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6}, []string{"api", "v1", "owner", "project", "runs", "uuid", "statuses"}, "", runtime.AssumeColonVerbOpt(true)))4352 pattern_RunsV1_GetRunCodeRefs_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6}, []string{"api", "v1", "owner", "project", "runs", "uuid", "coderef"}, "", runtime.AssumeColonVerbOpt(true)))4353 pattern_RunsV1_CreateRunCodeRef_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6}, []string{"api", "v1", "entity.owner", "entity.project", "runs", "entity.uuid", "coderef"}, "", runtime.AssumeColonVerbOpt(true)))4354 pattern_RunsV1_ImpersonateToken_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4, 1, 0, 4, 1, 5, 5, 2, 6}, []string{"api", "v1", "owner", "project", "runs", "uuid", "impersonatetoken"}, "", runtime.AssumeColonVerbOpt(true)))4355)4356var (4357 forward_RunsV1_ListBookmarkedRuns_0 = runtime.ForwardResponseMessage4358 forward_RunsV1_ListArchivedRuns_0 = runtime.ForwardResponseMessage4359 forward_RunsV1_ListRuns_0 = runtime.ForwardResponseMessage4360 forward_RunsV1_CreateRun_0 = runtime.ForwardResponseMessage4361 forward_RunsV1_GetRun_0 = runtime.ForwardResponseMessage4362 forward_RunsV1_UpdateRun_0 = runtime.ForwardResponseMessage4363 forward_RunsV1_PatchRun_0 = runtime.ForwardResponseMessage4364 forward_RunsV1_DeleteRun_0 = runtime.ForwardResponseMessage4365 forward_RunsV1_DeleteRuns_0 = runtime.ForwardResponseMessage4366 forward_RunsV1_StopRun_0 = runtime.ForwardResponseMessage4367 forward_RunsV1_StopRuns_0 = runtime.ForwardResponseMessage4368 forward_RunsV1_InvalidateRun_0 = runtime.ForwardResponseMessage4369 forward_RunsV1_InvalidateRuns_0 = runtime.ForwardResponseMessage4370 forward_RunsV1_CopyRun_0 = runtime.ForwardResponseMessage4371 forward_RunsV1_RestartRun_0 = runtime.ForwardResponseMessage4372 forward_RunsV1_ResumeRun_0 = runtime.ForwardResponseMessage4373 forward_RunsV1_ArchiveRun_0 = runtime.ForwardResponseMessage4374 forward_RunsV1_RestoreRun_0 = runtime.ForwardResponseMessage4375 forward_RunsV1_BookmarkRun_0 = runtime.ForwardResponseMessage4376 forward_RunsV1_UnbookmarkRun_0 = runtime.ForwardResponseMessage4377 forward_RunsV1_StartRunTensorboard_0 = runtime.ForwardResponseMessage4378 forward_RunsV1_StopRunTensorboard_0 = runtime.ForwardResponseMessage4379 forward_RunsV1_GetRunStatuses_0 = runtime.ForwardResponseMessage4380 forward_RunsV1_CreateRunStatus_0 = runtime.ForwardResponseMessage4381 forward_RunsV1_GetRunCodeRefs_0 = runtime.ForwardResponseMessage4382 forward_RunsV1_CreateRunCodeRef_0 = runtime.ForwardResponseMessage4383 forward_RunsV1_ImpersonateToken_0 = runtime.ForwardResponseMessage4384)4385// RegisterProjectsV1HandlerFromEndpoint is same as RegisterProjectsV1Handler but4386// automatically dials to "endpoint" and closes the connection when "ctx" gets done.4387func RegisterProjectsV1HandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) {4388 conn, err := grpc.Dial(endpoint, opts...)4389 if err != nil {4390 return err4391 }4392 defer func() {4393 if err != nil {4394 if cerr := conn.Close(); cerr != nil {4395 grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr)4396 }4397 return4398 }4399 go func() {4400 <-ctx.Done()4401 if cerr := conn.Close(); cerr != nil {4402 grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr)4403 }4404 }()4405 }()4406 return RegisterProjectsV1Handler(ctx, mux, conn)4407}4408// RegisterProjectsV1Handler registers the http handlers for service ProjectsV1 to "mux".4409// The handlers forward requests to the grpc endpoint over "conn".4410func RegisterProjectsV1Handler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error {4411 return RegisterProjectsV1HandlerClient(ctx, mux, NewProjectsV1Client(conn))4412}4413// RegisterProjectsV1HandlerClient registers the http handlers for service ProjectsV14414// to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "ProjectsV1Client".4415// Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "ProjectsV1Client"4416// doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in4417// "ProjectsV1Client" to call the correct interceptors.4418func RegisterProjectsV1HandlerClient(ctx context.Context, mux *runtime.ServeMux, client ProjectsV1Client) error {4419 mux.Handle("GET", pattern_ProjectsV1_ListProjects_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4420 ctx, cancel := context.WithCancel(req.Context())4421 defer cancel()4422 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4423 rctx, err := runtime.AnnotateContext(ctx, mux, req)4424 if err != nil {4425 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4426 return4427 }4428 resp, md, err := request_ProjectsV1_ListProjects_0(rctx, inboundMarshaler, client, req, pathParams)4429 ctx = runtime.NewServerMetadataContext(ctx, md)4430 if err != nil {4431 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4432 return4433 }4434 forward_ProjectsV1_ListProjects_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4435 })4436 mux.Handle("GET", pattern_ProjectsV1_ListProjectNames_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4437 ctx, cancel := context.WithCancel(req.Context())4438 defer cancel()4439 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4440 rctx, err := runtime.AnnotateContext(ctx, mux, req)4441 if err != nil {4442 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4443 return4444 }4445 resp, md, err := request_ProjectsV1_ListProjectNames_0(rctx, inboundMarshaler, client, req, pathParams)4446 ctx = runtime.NewServerMetadataContext(ctx, md)4447 if err != nil {4448 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4449 return4450 }4451 forward_ProjectsV1_ListProjectNames_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4452 })4453 mux.Handle("GET", pattern_ProjectsV1_ListBookmarkedProjects_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4454 ctx, cancel := context.WithCancel(req.Context())4455 defer cancel()4456 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4457 rctx, err := runtime.AnnotateContext(ctx, mux, req)4458 if err != nil {4459 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4460 return4461 }4462 resp, md, err := request_ProjectsV1_ListBookmarkedProjects_0(rctx, inboundMarshaler, client, req, pathParams)4463 ctx = runtime.NewServerMetadataContext(ctx, md)4464 if err != nil {4465 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4466 return4467 }4468 forward_ProjectsV1_ListBookmarkedProjects_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4469 })4470 mux.Handle("GET", pattern_ProjectsV1_ListArchivedProjects_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4471 ctx, cancel := context.WithCancel(req.Context())4472 defer cancel()4473 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4474 rctx, err := runtime.AnnotateContext(ctx, mux, req)4475 if err != nil {4476 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4477 return4478 }4479 resp, md, err := request_ProjectsV1_ListArchivedProjects_0(rctx, inboundMarshaler, client, req, pathParams)4480 ctx = runtime.NewServerMetadataContext(ctx, md)4481 if err != nil {4482 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4483 return4484 }4485 forward_ProjectsV1_ListArchivedProjects_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4486 })4487 mux.Handle("POST", pattern_ProjectsV1_CreateProject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4488 ctx, cancel := context.WithCancel(req.Context())4489 defer cancel()4490 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4491 rctx, err := runtime.AnnotateContext(ctx, mux, req)4492 if err != nil {4493 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4494 return4495 }4496 resp, md, err := request_ProjectsV1_CreateProject_0(rctx, inboundMarshaler, client, req, pathParams)4497 ctx = runtime.NewServerMetadataContext(ctx, md)4498 if err != nil {4499 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4500 return4501 }4502 forward_ProjectsV1_CreateProject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4503 })4504 mux.Handle("GET", pattern_ProjectsV1_GetProject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4505 ctx, cancel := context.WithCancel(req.Context())4506 defer cancel()4507 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4508 rctx, err := runtime.AnnotateContext(ctx, mux, req)4509 if err != nil {4510 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4511 return4512 }4513 resp, md, err := request_ProjectsV1_GetProject_0(rctx, inboundMarshaler, client, req, pathParams)4514 ctx = runtime.NewServerMetadataContext(ctx, md)4515 if err != nil {4516 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4517 return4518 }4519 forward_ProjectsV1_GetProject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4520 })4521 mux.Handle("PUT", pattern_ProjectsV1_UpdateProject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4522 ctx, cancel := context.WithCancel(req.Context())4523 defer cancel()4524 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4525 rctx, err := runtime.AnnotateContext(ctx, mux, req)4526 if err != nil {4527 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4528 return4529 }4530 resp, md, err := request_ProjectsV1_UpdateProject_0(rctx, inboundMarshaler, client, req, pathParams)4531 ctx = runtime.NewServerMetadataContext(ctx, md)4532 if err != nil {4533 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4534 return4535 }4536 forward_ProjectsV1_UpdateProject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4537 })4538 mux.Handle("PATCH", pattern_ProjectsV1_PatchProject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4539 ctx, cancel := context.WithCancel(req.Context())4540 defer cancel()4541 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4542 rctx, err := runtime.AnnotateContext(ctx, mux, req)4543 if err != nil {4544 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4545 return4546 }4547 resp, md, err := request_ProjectsV1_PatchProject_0(rctx, inboundMarshaler, client, req, pathParams)4548 ctx = runtime.NewServerMetadataContext(ctx, md)4549 if err != nil {4550 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4551 return4552 }4553 forward_ProjectsV1_PatchProject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4554 })4555 mux.Handle("DELETE", pattern_ProjectsV1_DeleteProject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4556 ctx, cancel := context.WithCancel(req.Context())4557 defer cancel()4558 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4559 rctx, err := runtime.AnnotateContext(ctx, mux, req)4560 if err != nil {4561 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4562 return4563 }4564 resp, md, err := request_ProjectsV1_DeleteProject_0(rctx, inboundMarshaler, client, req, pathParams)4565 ctx = runtime.NewServerMetadataContext(ctx, md)4566 if err != nil {4567 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4568 return4569 }4570 forward_ProjectsV1_DeleteProject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4571 })4572 mux.Handle("POST", pattern_ProjectsV1_ArchiveProject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4573 ctx, cancel := context.WithCancel(req.Context())4574 defer cancel()4575 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4576 rctx, err := runtime.AnnotateContext(ctx, mux, req)4577 if err != nil {4578 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4579 return4580 }4581 resp, md, err := request_ProjectsV1_ArchiveProject_0(rctx, inboundMarshaler, client, req, pathParams)4582 ctx = runtime.NewServerMetadataContext(ctx, md)4583 if err != nil {4584 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4585 return4586 }4587 forward_ProjectsV1_ArchiveProject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4588 })4589 mux.Handle("POST", pattern_ProjectsV1_RestoreExperiment_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4590 ctx, cancel := context.WithCancel(req.Context())4591 defer cancel()4592 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4593 rctx, err := runtime.AnnotateContext(ctx, mux, req)4594 if err != nil {4595 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4596 return4597 }4598 resp, md, err := request_ProjectsV1_RestoreExperiment_0(rctx, inboundMarshaler, client, req, pathParams)4599 ctx = runtime.NewServerMetadataContext(ctx, md)4600 if err != nil {4601 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4602 return4603 }4604 forward_ProjectsV1_RestoreExperiment_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4605 })4606 mux.Handle("POST", pattern_ProjectsV1_BookmarkProject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4607 ctx, cancel := context.WithCancel(req.Context())4608 defer cancel()4609 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4610 rctx, err := runtime.AnnotateContext(ctx, mux, req)4611 if err != nil {4612 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4613 return4614 }4615 resp, md, err := request_ProjectsV1_BookmarkProject_0(rctx, inboundMarshaler, client, req, pathParams)4616 ctx = runtime.NewServerMetadataContext(ctx, md)4617 if err != nil {4618 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4619 return4620 }4621 forward_ProjectsV1_BookmarkProject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4622 })4623 mux.Handle("DELETE", pattern_ProjectsV1_UnbookmarkProject_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4624 ctx, cancel := context.WithCancel(req.Context())4625 defer cancel()4626 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4627 rctx, err := runtime.AnnotateContext(ctx, mux, req)4628 if err != nil {4629 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4630 return4631 }4632 resp, md, err := request_ProjectsV1_UnbookmarkProject_0(rctx, inboundMarshaler, client, req, pathParams)4633 ctx = runtime.NewServerMetadataContext(ctx, md)4634 if err != nil {4635 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4636 return4637 }4638 forward_ProjectsV1_UnbookmarkProject_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4639 })4640 mux.Handle("POST", pattern_ProjectsV1_EnableProjectCI_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4641 ctx, cancel := context.WithCancel(req.Context())4642 defer cancel()4643 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4644 rctx, err := runtime.AnnotateContext(ctx, mux, req)4645 if err != nil {4646 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4647 return4648 }4649 resp, md, err := request_ProjectsV1_EnableProjectCI_0(rctx, inboundMarshaler, client, req, pathParams)4650 ctx = runtime.NewServerMetadataContext(ctx, md)4651 if err != nil {4652 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4653 return4654 }4655 forward_ProjectsV1_EnableProjectCI_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4656 })4657 mux.Handle("DELETE", pattern_ProjectsV1_DisableProjectCI_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4658 ctx, cancel := context.WithCancel(req.Context())4659 defer cancel()4660 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4661 rctx, err := runtime.AnnotateContext(ctx, mux, req)4662 if err != nil {4663 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4664 return4665 }4666 resp, md, err := request_ProjectsV1_DisableProjectCI_0(rctx, inboundMarshaler, client, req, pathParams)4667 ctx = runtime.NewServerMetadataContext(ctx, md)4668 if err != nil {4669 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4670 return4671 }4672 forward_ProjectsV1_DisableProjectCI_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4673 })4674 return nil4675}4676var (4677 pattern_ProjectsV1_ListProjects_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 2, 3, 2, 4}, []string{"api", "v1", "owner", "projects", "list"}, "", runtime.AssumeColonVerbOpt(true)))4678 pattern_ProjectsV1_ListProjectNames_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 2, 3, 2, 4}, []string{"api", "v1", "owner", "projects", "names"}, "", runtime.AssumeColonVerbOpt(true)))4679 pattern_ProjectsV1_ListBookmarkedProjects_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3, 2, 4}, []string{"api", "v1", "bookmarks", "user", "projects"}, "", runtime.AssumeColonVerbOpt(true)))4680 pattern_ProjectsV1_ListArchivedProjects_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 1, 0, 4, 1, 5, 3, 2, 4}, []string{"api", "v1", "archives", "user", "projects"}, "", runtime.AssumeColonVerbOpt(true)))4681 pattern_ProjectsV1_CreateProject_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 2, 3, 2, 4}, []string{"api", "v1", "owner", "projects", "create"}, "", runtime.AssumeColonVerbOpt(true)))4682 pattern_ProjectsV1_GetProject_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3}, []string{"api", "v1", "owner", "project"}, "", runtime.AssumeColonVerbOpt(true)))4683 pattern_ProjectsV1_UpdateProject_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3}, []string{"api", "v1", "owner", "project.name"}, "", runtime.AssumeColonVerbOpt(true)))4684 pattern_ProjectsV1_PatchProject_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3}, []string{"api", "v1", "owner", "project.name"}, "", runtime.AssumeColonVerbOpt(true)))4685 pattern_ProjectsV1_DeleteProject_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3}, []string{"api", "v1", "owner", "project"}, "", runtime.AssumeColonVerbOpt(true)))4686 pattern_ProjectsV1_ArchiveProject_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4}, []string{"api", "v1", "owner", "project", "archive"}, "", runtime.AssumeColonVerbOpt(true)))4687 pattern_ProjectsV1_RestoreExperiment_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4}, []string{"api", "v1", "owner", "project", "restore"}, "", runtime.AssumeColonVerbOpt(true)))4688 pattern_ProjectsV1_BookmarkProject_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4}, []string{"api", "v1", "owner", "project", "bookmark"}, "", runtime.AssumeColonVerbOpt(true)))4689 pattern_ProjectsV1_UnbookmarkProject_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4}, []string{"api", "v1", "owner", "project", "unbookmark"}, "", runtime.AssumeColonVerbOpt(true)))4690 pattern_ProjectsV1_EnableProjectCI_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4}, []string{"api", "v1", "owner", "project", "ci"}, "", runtime.AssumeColonVerbOpt(true)))4691 pattern_ProjectsV1_DisableProjectCI_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 1, 0, 4, 1, 5, 2, 1, 0, 4, 1, 5, 3, 2, 4}, []string{"api", "v1", "owner", "project", "ci"}, "", runtime.AssumeColonVerbOpt(true)))4692)4693var (4694 forward_ProjectsV1_ListProjects_0 = runtime.ForwardResponseMessage4695 forward_ProjectsV1_ListProjectNames_0 = runtime.ForwardResponseMessage4696 forward_ProjectsV1_ListBookmarkedProjects_0 = runtime.ForwardResponseMessage4697 forward_ProjectsV1_ListArchivedProjects_0 = runtime.ForwardResponseMessage4698 forward_ProjectsV1_CreateProject_0 = runtime.ForwardResponseMessage4699 forward_ProjectsV1_GetProject_0 = runtime.ForwardResponseMessage4700 forward_ProjectsV1_UpdateProject_0 = runtime.ForwardResponseMessage4701 forward_ProjectsV1_PatchProject_0 = runtime.ForwardResponseMessage4702 forward_ProjectsV1_DeleteProject_0 = runtime.ForwardResponseMessage4703 forward_ProjectsV1_ArchiveProject_0 = runtime.ForwardResponseMessage4704 forward_ProjectsV1_RestoreExperiment_0 = runtime.ForwardResponseMessage4705 forward_ProjectsV1_BookmarkProject_0 = runtime.ForwardResponseMessage4706 forward_ProjectsV1_UnbookmarkProject_0 = runtime.ForwardResponseMessage4707 forward_ProjectsV1_EnableProjectCI_0 = runtime.ForwardResponseMessage4708 forward_ProjectsV1_DisableProjectCI_0 = runtime.ForwardResponseMessage4709)4710// RegisterAuthV1HandlerFromEndpoint is same as RegisterAuthV1Handler but4711// automatically dials to "endpoint" and closes the connection when "ctx" gets done.4712func RegisterAuthV1HandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) {4713 conn, err := grpc.Dial(endpoint, opts...)4714 if err != nil {4715 return err4716 }4717 defer func() {4718 if err != nil {4719 if cerr := conn.Close(); cerr != nil {4720 grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr)4721 }4722 return4723 }4724 go func() {4725 <-ctx.Done()4726 if cerr := conn.Close(); cerr != nil {4727 grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr)4728 }4729 }()4730 }()4731 return RegisterAuthV1Handler(ctx, mux, conn)4732}4733// RegisterAuthV1Handler registers the http handlers for service AuthV1 to "mux".4734// The handlers forward requests to the grpc endpoint over "conn".4735func RegisterAuthV1Handler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error {4736 return RegisterAuthV1HandlerClient(ctx, mux, NewAuthV1Client(conn))4737}4738// RegisterAuthV1HandlerClient registers the http handlers for service AuthV14739// to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "AuthV1Client".4740// Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "AuthV1Client"4741// doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in4742// "AuthV1Client" to call the correct interceptors.4743func RegisterAuthV1HandlerClient(ctx context.Context, mux *runtime.ServeMux, client AuthV1Client) error {4744 mux.Handle("POST", pattern_AuthV1_Login_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4745 ctx, cancel := context.WithCancel(req.Context())4746 defer cancel()4747 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4748 rctx, err := runtime.AnnotateContext(ctx, mux, req)4749 if err != nil {4750 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4751 return4752 }4753 resp, md, err := request_AuthV1_Login_0(rctx, inboundMarshaler, client, req, pathParams)4754 ctx = runtime.NewServerMetadataContext(ctx, md)4755 if err != nil {4756 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4757 return4758 }4759 forward_AuthV1_Login_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4760 })4761 return nil4762}4763var (4764 pattern_AuthV1_Login_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2, 2, 3}, []string{"api", "v1", "users", "token"}, "", runtime.AssumeColonVerbOpt(true)))4765)4766var (4767 forward_AuthV1_Login_0 = runtime.ForwardResponseMessage4768)4769// RegisterUsersV1HandlerFromEndpoint is same as RegisterUsersV1Handler but4770// automatically dials to "endpoint" and closes the connection when "ctx" gets done.4771func RegisterUsersV1HandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) {4772 conn, err := grpc.Dial(endpoint, opts...)4773 if err != nil {4774 return err4775 }4776 defer func() {4777 if err != nil {4778 if cerr := conn.Close(); cerr != nil {4779 grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr)4780 }4781 return4782 }4783 go func() {4784 <-ctx.Done()4785 if cerr := conn.Close(); cerr != nil {4786 grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr)4787 }4788 }()4789 }()4790 return RegisterUsersV1Handler(ctx, mux, conn)4791}4792// RegisterUsersV1Handler registers the http handlers for service UsersV1 to "mux".4793// The handlers forward requests to the grpc endpoint over "conn".4794func RegisterUsersV1Handler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error {4795 return RegisterUsersV1HandlerClient(ctx, mux, NewUsersV1Client(conn))4796}4797// RegisterUsersV1HandlerClient registers the http handlers for service UsersV14798// to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "UsersV1Client".4799// Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "UsersV1Client"4800// doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in4801// "UsersV1Client" to call the correct interceptors.4802func RegisterUsersV1HandlerClient(ctx context.Context, mux *runtime.ServeMux, client UsersV1Client) error {4803 mux.Handle("GET", pattern_UsersV1_GetUser_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4804 ctx, cancel := context.WithCancel(req.Context())4805 defer cancel()4806 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4807 rctx, err := runtime.AnnotateContext(ctx, mux, req)4808 if err != nil {4809 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4810 return4811 }4812 resp, md, err := request_UsersV1_GetUser_0(rctx, inboundMarshaler, client, req, pathParams)4813 ctx = runtime.NewServerMetadataContext(ctx, md)4814 if err != nil {4815 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4816 return4817 }4818 forward_UsersV1_GetUser_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4819 })4820 return nil4821}4822var (4823 pattern_UsersV1_GetUser_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"api", "v1", "users"}, "", runtime.AssumeColonVerbOpt(true)))4824)4825var (4826 forward_UsersV1_GetUser_0 = runtime.ForwardResponseMessage4827)4828// RegisterVersionsV1HandlerFromEndpoint is same as RegisterVersionsV1Handler but4829// automatically dials to "endpoint" and closes the connection when "ctx" gets done.4830func RegisterVersionsV1HandlerFromEndpoint(ctx context.Context, mux *runtime.ServeMux, endpoint string, opts []grpc.DialOption) (err error) {4831 conn, err := grpc.Dial(endpoint, opts...)4832 if err != nil {4833 return err4834 }4835 defer func() {4836 if err != nil {4837 if cerr := conn.Close(); cerr != nil {4838 grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr)4839 }4840 return4841 }4842 go func() {4843 <-ctx.Done()4844 if cerr := conn.Close(); cerr != nil {4845 grpclog.Infof("Failed to close conn to %s: %v", endpoint, cerr)4846 }4847 }()4848 }()4849 return RegisterVersionsV1Handler(ctx, mux, conn)4850}4851// RegisterVersionsV1Handler registers the http handlers for service VersionsV1 to "mux".4852// The handlers forward requests to the grpc endpoint over "conn".4853func RegisterVersionsV1Handler(ctx context.Context, mux *runtime.ServeMux, conn *grpc.ClientConn) error {4854 return RegisterVersionsV1HandlerClient(ctx, mux, NewVersionsV1Client(conn))4855}4856// RegisterVersionsV1HandlerClient registers the http handlers for service VersionsV14857// to "mux". The handlers forward requests to the grpc endpoint over the given implementation of "VersionsV1Client".4858// Note: the gRPC framework executes interceptors within the gRPC handler. If the passed in "VersionsV1Client"4859// doesn't go through the normal gRPC flow (creating a gRPC client etc.) then it will be up to the passed in4860// "VersionsV1Client" to call the correct interceptors.4861func RegisterVersionsV1HandlerClient(ctx context.Context, mux *runtime.ServeMux, client VersionsV1Client) error {4862 mux.Handle("GET", pattern_VersionsV1_GetVersions_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4863 ctx, cancel := context.WithCancel(req.Context())4864 defer cancel()4865 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4866 rctx, err := runtime.AnnotateContext(ctx, mux, req)4867 if err != nil {4868 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4869 return4870 }4871 resp, md, err := request_VersionsV1_GetVersions_0(rctx, inboundMarshaler, client, req, pathParams)4872 ctx = runtime.NewServerMetadataContext(ctx, md)4873 if err != nil {4874 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4875 return4876 }4877 forward_VersionsV1_GetVersions_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4878 })4879 mux.Handle("GET", pattern_VersionsV1_GetLogHandler_0, func(w http.ResponseWriter, req *http.Request, pathParams map[string]string) {4880 ctx, cancel := context.WithCancel(req.Context())4881 defer cancel()4882 inboundMarshaler, outboundMarshaler := runtime.MarshalerForRequest(mux, req)4883 rctx, err := runtime.AnnotateContext(ctx, mux, req)4884 if err != nil {4885 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4886 return4887 }4888 resp, md, err := request_VersionsV1_GetLogHandler_0(rctx, inboundMarshaler, client, req, pathParams)4889 ctx = runtime.NewServerMetadataContext(ctx, md)4890 if err != nil {4891 runtime.HTTPError(ctx, mux, outboundMarshaler, w, req, err)4892 return4893 }4894 forward_VersionsV1_GetLogHandler_0(ctx, mux, outboundMarshaler, w, req, resp, mux.GetForwardResponseOptions()...)4895 })4896 return nil4897}4898var (4899 pattern_VersionsV1_GetVersions_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"api", "v1", "versions"}, "", runtime.AssumeColonVerbOpt(true)))4900 pattern_VersionsV1_GetLogHandler_0 = runtime.MustPattern(runtime.NewPattern(1, []int{2, 0, 2, 1, 2, 2}, []string{"api", "v1", "log_handler"}, "", runtime.AssumeColonVerbOpt(true)))4901)4902var (4903 forward_VersionsV1_GetVersions_0 = runtime.ForwardResponseMessage4904 forward_VersionsV1_GetLogHandler_0 = runtime.ForwardResponseMessage4905)...
handlers.go
Source:handlers.go
1/*2Copyright (c) Facebook, Inc. and its affiliates.3All rights reserved.4This source code is licensed under the BSD-style license found in the5LICENSE file in the root directory of this source tree.6*/7package gy8import (9 "github.com/fiorix/go-diameter/v4/diam"10 "github.com/golang/glog"11 "golang.org/x/net/context"12 "magma/feg/gateway/diameter"13 "magma/feg/gateway/services/session_proxy/relay"14 "magma/gateway/service_registry"15 "magma/lte/cloud/go/protos"16)17// GetGyReAuthHandler returns the default handler for RAR messages by relaying18// them to the gateway, where session proxy will initiate a credit update and respond19// with an RAA20func GetGyReAuthHandler(cloudRegistry service_registry.GatewayRegistry) ChargingReAuthHandler {21 return ChargingReAuthHandler(func(request *ChargingReAuthRequest) *ChargingReAuthAnswer {22 sid := diameter.DecodeSessionID(request.SessionID)23 imsi, err := protos.GetIMSIwithPrefixFromSessionId(sid)24 if err != nil {25 glog.Errorf("Error retreiving IMSI from Session ID %s: %s", request.SessionID, err)26 return &ChargingReAuthAnswer{27 SessionID: request.SessionID,28 ResultCode: diam.UnknownSessionID,29 }30 }31 client, err := relay.GetSessionProxyResponderClient(cloudRegistry)32 if err != nil {33 glog.Error(err)34 return &ChargingReAuthAnswer{SessionID: request.SessionID, ResultCode: diam.UnableToDeliver}35 }36 defer client.Close()37 ans, err := client.ChargingReAuth(context.Background(), getGyReAuthRequestProto(request, imsi, sid))38 if err != nil {39 glog.Errorf("Error relaying reauth request to gateway: %s", err)40 }41 return getGyReAuthAnswerDiamMsg(request.SessionID, ans)42 })43}44func getGyReAuthRequestProto(diamReq *ChargingReAuthRequest, imsi, sid string) *protos.ChargingReAuthRequest {45 protoReq := &protos.ChargingReAuthRequest{46 SessionId: sid,47 Sid: imsi,48 }49 if diamReq.RatingGroup != nil {50 protoReq.ChargingKey = *diamReq.RatingGroup51 protoReq.Type = protos.ChargingReAuthRequest_SINGLE_SERVICE52 if diamReq.ServiceIdentifier != nil {53 protoReq.ServiceIdentifier = &protos.ServiceIdentifier{Value: *diamReq.ServiceIdentifier}54 }55 } else {56 protoReq.ChargingKey = 057 protoReq.Type = protos.ChargingReAuthRequest_ENTIRE_SESSION58 }59 return protoReq60}61func getGyReAuthAnswerDiamMsg(62 sessionID string,63 protoAns *protos.ChargingReAuthAnswer,64) *ChargingReAuthAnswer {65 var resultCode uint3266 if protoAns.Result == protos.ReAuthResult_UPDATE_INITIATED {67 resultCode = diam.LimitedSuccess68 } else if protoAns.Result == protos.ReAuthResult_UPDATE_NOT_NEEDED {69 resultCode = diam.Success70 } else if protoAns.Result == protos.ReAuthResult_SESSION_NOT_FOUND {71 resultCode = diam.UnknownSessionID72 } else { // ReAuthResult_OTHER_FAILURE73 resultCode = diam.UnableToComply74 }75 return &ChargingReAuthAnswer{76 SessionID: sessionID,77 ResultCode: resultCode,78 }79}...
defaults.go
Source:defaults.go
1package http2import (3 "context"4 "encoding/json"5 "io"6 "io/ioutil"7 "net/http"8 "time"9 "github.com/carousell/Orion/orion/modifiers"10 "github.com/golang/protobuf/jsonpb"11 "github.com/golang/protobuf/proto"12 "github.com/gorilla/mux"13 "github.com/gorilla/websocket"14 "github.com/mitchellh/mapstructure"15)16// DefaultEncoder encodes a HTTP request if none are registered. This encoder17// populates the proto message with URL route variables or fields from a JSON18// body if either are available. If JSONPB is true, JSON requests are encoded19// using the jsonpb package.20func DefaultEncoder(req *http.Request, r interface{}, JSONPB bool) error {21 // check and map url params to request22 params := mux.Vars(req)23 if len(params) > 0 {24 mapstructure.Decode(params, r)25 }26 data, err := ioutil.ReadAll(req.Body)27 if err != nil {28 if err == io.EOF {29 return nil30 }31 return err32 }33 if req.Method == http.MethodGet && len(data) == 0 {34 return nil35 }36 return deserialize(req.Context(), data, r, JSONPB)37}38func deserialize(ctx context.Context, data []byte, r interface{}, JSONPB bool) error {39 serType := ContentTypeFromHeaders(ctx)40 switch serType {41 case modifiers.ProtoBuf:42 if protoReq, ok := r.(proto.Message); ok {43 return proto.Unmarshal(data, protoReq)44 }45 fallthrough46 case modifiers.JSONPB:47 if protoReq, ok := r.(proto.Message); ok {48 return jsonpb.UnmarshalString(string(data), protoReq)49 }50 fallthrough51 default:52 // if server preference is JSONPB, JSONPB should be used instead of JSON for unmarshalling53 if JSONPB {54 if protoReq, ok := r.(proto.Message); ok {55 return jsonpb.UnmarshalString(string(data), protoReq)56 }57 }58 return json.Unmarshal(data, r)59 }60}61// DefaultWSUpgrader upgrades a websocket if none are registered.62func DefaultWSUpgrader(w http.ResponseWriter, r *http.Request, responseHeader http.Header) (*websocket.Conn, error) {63 up := websocket.Upgrader{64 HandshakeTimeout: time.Second * 2,65 ReadBufferSize: 1024,66 WriteBufferSize: 1024,67 }68 return up.Upgrade(w, r, responseHeader)69}...
ProtoReq
Using AI Code Generation
1import (2func main() {3 fmt.Println("Hello")4 proto.ProtoReq()5}6import (7func main() {8 fmt.Println("Hello")9 proto.ProtoReq()10}11import (12func ProtoReq() {13 fmt.Println("Hello")14}15import (16func ProtoReq() {17 fmt.Println("Hello")18}19import (20func ProtoReq() {21 fmt.Println("Hello")22}23import (24func ProtoReq() {25 fmt.Println("Hello")26}27import (28func TestProtoReq(t *testing.T) {29 ProtoReq()30}31import (32func TestProtoReq(t *testing.T) {33 ProtoReq()34}35import (36func TestProtoReq(t *testing.T) {37 ProtoReq()38}39import (40func TestProtoReq(t *testing.T) {41 ProtoReq()42}43import (44func BenchmarkProtoReq(b *testing.B) {45 ProtoReq()46}47import (48func BenchmarkProtoReq(b *testing.B) {49 ProtoReq()50}51import (52func BenchmarkProtoReq(b *testing.B) {53 ProtoReq()54}55import (56func BenchmarkProtoReq(b *testing.B) {57 ProtoReq()58}
ProtoReq
Using AI Code Generation
1import (2func main() {3 fmt.Println(proto.ProtoReq("2"))4}5import (6func ProtoReq(arg string) string {7 return fmt.Sprintf("ProtoReq called with arg %s", arg)8}
ProtoReq
Using AI Code Generation
1import (2func main() {3 req := proto.ProtoReq{4 }5 fmt.Println(req)6}7type ProtoReq struct {8}9type Proto interface {10 ProtoReq() ProtoReq11}12type TCP struct {13}14func (p *TCP) ProtoReq() ProtoReq {15}16func NewProto(proto string) Proto {17 return &TCP{18 ProtoReq: ProtoReq{19 },20 }21}22import (23func TestNewProto(t *testing.T) {24 req := proto.NewProto("tcp")25 fmt.Println(req)26}
ProtoReq
Using AI Code Generation
1import (2func main() {3 p := proto.ProtoReq{}4 p.SetReq("hello")5 fmt.Println(p.GetReq())6}
ProtoReq
Using AI Code Generation
1import (2func main() {3 p := &protoclasses.Person{4 }5 pr := &protoclasses.ProtoReq{6 }7 data, err := proto.Marshal(pr)8 if err != nil {9 fmt.Println("marshaling error: ", err)10 }11 newPr := &protoclasses.ProtoReq{}12 err = proto.Unmarshal(data, newPr)13 if err != nil {14 fmt.Println("unmarshaling error: ", err)15 }16 fmt.Println(newPr)17}18import proto "github.com/golang/protobuf/proto"19import fmt "fmt"20import math "math"21import (
Learn to execute automation testing from scratch with LambdaTest Learning Hub. Right from setting up the prerequisites to run your first automation test, to following best practices and diving deeper into advanced test scenarios. LambdaTest Learning Hubs compile a list of step-by-step guides to help you be proficient with different test automation frameworks i.e. Selenium, Cypress, TestNG etc.
You could also refer to video tutorials over LambdaTest YouTube channel to get step by step demonstration from industry experts.
Get 100 minutes of automation test minutes FREE!!