cloud.google.com/go/aiplatform@v1.106.0/apiv1/aiplatformpb/endpoint_service_grpc.pb.go (about) 1 // Copyright 2025 Google LLC 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 at 6 // 7 // http://www.apache.org/licenses/LICENSE-2.0 8 // 9 // Unless required by applicable law or agreed to in writing, software 10 // 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 and 13 // limitations under the License. 14 15 // Code generated by protoc-gen-go-grpc. DO NOT EDIT. 16 // versions: 17 // - protoc-gen-go-grpc v1.3.0 18 // - protoc v4.25.7 19 // source: google/cloud/aiplatform/v1/endpoint_service.proto 20 21 package aiplatformpb 22 23 import ( 24 longrunningpb "cloud.google.com/go/longrunning/autogen/longrunningpb" 25 context "context" 26 grpc "google.golang.org/grpc" 27 codes "google.golang.org/grpc/codes" 28 status "google.golang.org/grpc/status" 29 ) 30 31 // This is a compile-time assertion to ensure that this generated file 32 // is compatible with the grpc package it is being compiled against. 33 // Requires gRPC-Go v1.32.0 or later. 34 const _ = grpc.SupportPackageIsVersion7 35 36 const ( 37 EndpointService_CreateEndpoint_FullMethodName = "/google.cloud.aiplatform.v1.EndpointService/CreateEndpoint" 38 EndpointService_GetEndpoint_FullMethodName = "/google.cloud.aiplatform.v1.EndpointService/GetEndpoint" 39 EndpointService_ListEndpoints_FullMethodName = "/google.cloud.aiplatform.v1.EndpointService/ListEndpoints" 40 EndpointService_UpdateEndpoint_FullMethodName = "/google.cloud.aiplatform.v1.EndpointService/UpdateEndpoint" 41 EndpointService_UpdateEndpointLongRunning_FullMethodName = "/google.cloud.aiplatform.v1.EndpointService/UpdateEndpointLongRunning" 42 EndpointService_DeleteEndpoint_FullMethodName = "/google.cloud.aiplatform.v1.EndpointService/DeleteEndpoint" 43 EndpointService_DeployModel_FullMethodName = "/google.cloud.aiplatform.v1.EndpointService/DeployModel" 44 EndpointService_UndeployModel_FullMethodName = "/google.cloud.aiplatform.v1.EndpointService/UndeployModel" 45 EndpointService_MutateDeployedModel_FullMethodName = "/google.cloud.aiplatform.v1.EndpointService/MutateDeployedModel" 46 ) 47 48 // EndpointServiceClient is the client API for EndpointService service. 49 // 50 // For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream. 51 type EndpointServiceClient interface { 52 // Creates an Endpoint. 53 CreateEndpoint(ctx context.Context, in *CreateEndpointRequest, opts ...grpc.CallOption) (*longrunningpb.Operation, error) 54 // Gets an Endpoint. 55 GetEndpoint(ctx context.Context, in *GetEndpointRequest, opts ...grpc.CallOption) (*Endpoint, error) 56 // Lists Endpoints in a Location. 57 ListEndpoints(ctx context.Context, in *ListEndpointsRequest, opts ...grpc.CallOption) (*ListEndpointsResponse, error) 58 // Updates an Endpoint. 59 UpdateEndpoint(ctx context.Context, in *UpdateEndpointRequest, opts ...grpc.CallOption) (*Endpoint, error) 60 // Updates an Endpoint with a long running operation. 61 UpdateEndpointLongRunning(ctx context.Context, in *UpdateEndpointLongRunningRequest, opts ...grpc.CallOption) (*longrunningpb.Operation, error) 62 // Deletes an Endpoint. 63 DeleteEndpoint(ctx context.Context, in *DeleteEndpointRequest, opts ...grpc.CallOption) (*longrunningpb.Operation, error) 64 // Deploys a Model into this Endpoint, creating a DeployedModel within it. 65 DeployModel(ctx context.Context, in *DeployModelRequest, opts ...grpc.CallOption) (*longrunningpb.Operation, error) 66 // Undeploys a Model from an Endpoint, removing a DeployedModel from it, and 67 // freeing all resources it's using. 68 UndeployModel(ctx context.Context, in *UndeployModelRequest, opts ...grpc.CallOption) (*longrunningpb.Operation, error) 69 // Updates an existing deployed model. Updatable fields include 70 // `min_replica_count`, `max_replica_count`, `required_replica_count`, 71 // `autoscaling_metric_specs`, `disable_container_logging` (v1 only), and 72 // `enable_container_logging` (v1beta1 only). 73 MutateDeployedModel(ctx context.Context, in *MutateDeployedModelRequest, opts ...grpc.CallOption) (*longrunningpb.Operation, error) 74 } 75 76 type endpointServiceClient struct { 77 cc grpc.ClientConnInterface 78 } 79 80 func NewEndpointServiceClient(cc grpc.ClientConnInterface) EndpointServiceClient { 81 return &endpointServiceClient{cc} 82 } 83 84 func (c *endpointServiceClient) CreateEndpoint(ctx context.Context, in *CreateEndpointRequest, opts ...grpc.CallOption) (*longrunningpb.Operation, error) { 85 out := new(longrunningpb.Operation) 86 err := c.cc.Invoke(ctx, EndpointService_CreateEndpoint_FullMethodName, in, out, opts...) 87 if err != nil { 88 return nil, err 89 } 90 return out, nil 91 } 92 93 func (c *endpointServiceClient) GetEndpoint(ctx context.Context, in *GetEndpointRequest, opts ...grpc.CallOption) (*Endpoint, error) { 94 out := new(Endpoint) 95 err := c.cc.Invoke(ctx, EndpointService_GetEndpoint_FullMethodName, in, out, opts...) 96 if err != nil { 97 return nil, err 98 } 99 return out, nil 100 } 101 102 func (c *endpointServiceClient) ListEndpoints(ctx context.Context, in *ListEndpointsRequest, opts ...grpc.CallOption) (*ListEndpointsResponse, error) { 103 out := new(ListEndpointsResponse) 104 err := c.cc.Invoke(ctx, EndpointService_ListEndpoints_FullMethodName, in, out, opts...) 105 if err != nil { 106 return nil, err 107 } 108 return out, nil 109 } 110 111 func (c *endpointServiceClient) UpdateEndpoint(ctx context.Context, in *UpdateEndpointRequest, opts ...grpc.CallOption) (*Endpoint, error) { 112 out := new(Endpoint) 113 err := c.cc.Invoke(ctx, EndpointService_UpdateEndpoint_FullMethodName, in, out, opts...) 114 if err != nil { 115 return nil, err 116 } 117 return out, nil 118 } 119 120 func (c *endpointServiceClient) UpdateEndpointLongRunning(ctx context.Context, in *UpdateEndpointLongRunningRequest, opts ...grpc.CallOption) (*longrunningpb.Operation, error) { 121 out := new(longrunningpb.Operation) 122 err := c.cc.Invoke(ctx, EndpointService_UpdateEndpointLongRunning_FullMethodName, in, out, opts...) 123 if err != nil { 124 return nil, err 125 } 126 return out, nil 127 } 128 129 func (c *endpointServiceClient) DeleteEndpoint(ctx context.Context, in *DeleteEndpointRequest, opts ...grpc.CallOption) (*longrunningpb.Operation, error) { 130 out := new(longrunningpb.Operation) 131 err := c.cc.Invoke(ctx, EndpointService_DeleteEndpoint_FullMethodName, in, out, opts...) 132 if err != nil { 133 return nil, err 134 } 135 return out, nil 136 } 137 138 func (c *endpointServiceClient) DeployModel(ctx context.Context, in *DeployModelRequest, opts ...grpc.CallOption) (*longrunningpb.Operation, error) { 139 out := new(longrunningpb.Operation) 140 err := c.cc.Invoke(ctx, EndpointService_DeployModel_FullMethodName, in, out, opts...) 141 if err != nil { 142 return nil, err 143 } 144 return out, nil 145 } 146 147 func (c *endpointServiceClient) UndeployModel(ctx context.Context, in *UndeployModelRequest, opts ...grpc.CallOption) (*longrunningpb.Operation, error) { 148 out := new(longrunningpb.Operation) 149 err := c.cc.Invoke(ctx, EndpointService_UndeployModel_FullMethodName, in, out, opts...) 150 if err != nil { 151 return nil, err 152 } 153 return out, nil 154 } 155 156 func (c *endpointServiceClient) MutateDeployedModel(ctx context.Context, in *MutateDeployedModelRequest, opts ...grpc.CallOption) (*longrunningpb.Operation, error) { 157 out := new(longrunningpb.Operation) 158 err := c.cc.Invoke(ctx, EndpointService_MutateDeployedModel_FullMethodName, in, out, opts...) 159 if err != nil { 160 return nil, err 161 } 162 return out, nil 163 } 164 165 // EndpointServiceServer is the server API for EndpointService service. 166 // All implementations should embed UnimplementedEndpointServiceServer 167 // for forward compatibility 168 type EndpointServiceServer interface { 169 // Creates an Endpoint. 170 CreateEndpoint(context.Context, *CreateEndpointRequest) (*longrunningpb.Operation, error) 171 // Gets an Endpoint. 172 GetEndpoint(context.Context, *GetEndpointRequest) (*Endpoint, error) 173 // Lists Endpoints in a Location. 174 ListEndpoints(context.Context, *ListEndpointsRequest) (*ListEndpointsResponse, error) 175 // Updates an Endpoint. 176 UpdateEndpoint(context.Context, *UpdateEndpointRequest) (*Endpoint, error) 177 // Updates an Endpoint with a long running operation. 178 UpdateEndpointLongRunning(context.Context, *UpdateEndpointLongRunningRequest) (*longrunningpb.Operation, error) 179 // Deletes an Endpoint. 180 DeleteEndpoint(context.Context, *DeleteEndpointRequest) (*longrunningpb.Operation, error) 181 // Deploys a Model into this Endpoint, creating a DeployedModel within it. 182 DeployModel(context.Context, *DeployModelRequest) (*longrunningpb.Operation, error) 183 // Undeploys a Model from an Endpoint, removing a DeployedModel from it, and 184 // freeing all resources it's using. 185 UndeployModel(context.Context, *UndeployModelRequest) (*longrunningpb.Operation, error) 186 // Updates an existing deployed model. Updatable fields include 187 // `min_replica_count`, `max_replica_count`, `required_replica_count`, 188 // `autoscaling_metric_specs`, `disable_container_logging` (v1 only), and 189 // `enable_container_logging` (v1beta1 only). 190 MutateDeployedModel(context.Context, *MutateDeployedModelRequest) (*longrunningpb.Operation, error) 191 } 192 193 // UnimplementedEndpointServiceServer should be embedded to have forward compatible implementations. 194 type UnimplementedEndpointServiceServer struct { 195 } 196 197 func (UnimplementedEndpointServiceServer) CreateEndpoint(context.Context, *CreateEndpointRequest) (*longrunningpb.Operation, error) { 198 return nil, status.Errorf(codes.Unimplemented, "method CreateEndpoint not implemented") 199 } 200 func (UnimplementedEndpointServiceServer) GetEndpoint(context.Context, *GetEndpointRequest) (*Endpoint, error) { 201 return nil, status.Errorf(codes.Unimplemented, "method GetEndpoint not implemented") 202 } 203 func (UnimplementedEndpointServiceServer) ListEndpoints(context.Context, *ListEndpointsRequest) (*ListEndpointsResponse, error) { 204 return nil, status.Errorf(codes.Unimplemented, "method ListEndpoints not implemented") 205 } 206 func (UnimplementedEndpointServiceServer) UpdateEndpoint(context.Context, *UpdateEndpointRequest) (*Endpoint, error) { 207 return nil, status.Errorf(codes.Unimplemented, "method UpdateEndpoint not implemented") 208 } 209 func (UnimplementedEndpointServiceServer) UpdateEndpointLongRunning(context.Context, *UpdateEndpointLongRunningRequest) (*longrunningpb.Operation, error) { 210 return nil, status.Errorf(codes.Unimplemented, "method UpdateEndpointLongRunning not implemented") 211 } 212 func (UnimplementedEndpointServiceServer) DeleteEndpoint(context.Context, *DeleteEndpointRequest) (*longrunningpb.Operation, error) { 213 return nil, status.Errorf(codes.Unimplemented, "method DeleteEndpoint not implemented") 214 } 215 func (UnimplementedEndpointServiceServer) DeployModel(context.Context, *DeployModelRequest) (*longrunningpb.Operation, error) { 216 return nil, status.Errorf(codes.Unimplemented, "method DeployModel not implemented") 217 } 218 func (UnimplementedEndpointServiceServer) UndeployModel(context.Context, *UndeployModelRequest) (*longrunningpb.Operation, error) { 219 return nil, status.Errorf(codes.Unimplemented, "method UndeployModel not implemented") 220 } 221 func (UnimplementedEndpointServiceServer) MutateDeployedModel(context.Context, *MutateDeployedModelRequest) (*longrunningpb.Operation, error) { 222 return nil, status.Errorf(codes.Unimplemented, "method MutateDeployedModel not implemented") 223 } 224 225 // UnsafeEndpointServiceServer may be embedded to opt out of forward compatibility for this service. 226 // Use of this interface is not recommended, as added methods to EndpointServiceServer will 227 // result in compilation errors. 228 type UnsafeEndpointServiceServer interface { 229 mustEmbedUnimplementedEndpointServiceServer() 230 } 231 232 func RegisterEndpointServiceServer(s grpc.ServiceRegistrar, srv EndpointServiceServer) { 233 s.RegisterService(&EndpointService_ServiceDesc, srv) 234 } 235 236 func _EndpointService_CreateEndpoint_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { 237 in := new(CreateEndpointRequest) 238 if err := dec(in); err != nil { 239 return nil, err 240 } 241 if interceptor == nil { 242 return srv.(EndpointServiceServer).CreateEndpoint(ctx, in) 243 } 244 info := &grpc.UnaryServerInfo{ 245 Server: srv, 246 FullMethod: EndpointService_CreateEndpoint_FullMethodName, 247 } 248 handler := func(ctx context.Context, req interface{}) (interface{}, error) { 249 return srv.(EndpointServiceServer).CreateEndpoint(ctx, req.(*CreateEndpointRequest)) 250 } 251 return interceptor(ctx, in, info, handler) 252 } 253 254 func _EndpointService_GetEndpoint_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { 255 in := new(GetEndpointRequest) 256 if err := dec(in); err != nil { 257 return nil, err 258 } 259 if interceptor == nil { 260 return srv.(EndpointServiceServer).GetEndpoint(ctx, in) 261 } 262 info := &grpc.UnaryServerInfo{ 263 Server: srv, 264 FullMethod: EndpointService_GetEndpoint_FullMethodName, 265 } 266 handler := func(ctx context.Context, req interface{}) (interface{}, error) { 267 return srv.(EndpointServiceServer).GetEndpoint(ctx, req.(*GetEndpointRequest)) 268 } 269 return interceptor(ctx, in, info, handler) 270 } 271 272 func _EndpointService_ListEndpoints_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { 273 in := new(ListEndpointsRequest) 274 if err := dec(in); err != nil { 275 return nil, err 276 } 277 if interceptor == nil { 278 return srv.(EndpointServiceServer).ListEndpoints(ctx, in) 279 } 280 info := &grpc.UnaryServerInfo{ 281 Server: srv, 282 FullMethod: EndpointService_ListEndpoints_FullMethodName, 283 } 284 handler := func(ctx context.Context, req interface{}) (interface{}, error) { 285 return srv.(EndpointServiceServer).ListEndpoints(ctx, req.(*ListEndpointsRequest)) 286 } 287 return interceptor(ctx, in, info, handler) 288 } 289 290 func _EndpointService_UpdateEndpoint_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { 291 in := new(UpdateEndpointRequest) 292 if err := dec(in); err != nil { 293 return nil, err 294 } 295 if interceptor == nil { 296 return srv.(EndpointServiceServer).UpdateEndpoint(ctx, in) 297 } 298 info := &grpc.UnaryServerInfo{ 299 Server: srv, 300 FullMethod: EndpointService_UpdateEndpoint_FullMethodName, 301 } 302 handler := func(ctx context.Context, req interface{}) (interface{}, error) { 303 return srv.(EndpointServiceServer).UpdateEndpoint(ctx, req.(*UpdateEndpointRequest)) 304 } 305 return interceptor(ctx, in, info, handler) 306 } 307 308 func _EndpointService_UpdateEndpointLongRunning_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { 309 in := new(UpdateEndpointLongRunningRequest) 310 if err := dec(in); err != nil { 311 return nil, err 312 } 313 if interceptor == nil { 314 return srv.(EndpointServiceServer).UpdateEndpointLongRunning(ctx, in) 315 } 316 info := &grpc.UnaryServerInfo{ 317 Server: srv, 318 FullMethod: EndpointService_UpdateEndpointLongRunning_FullMethodName, 319 } 320 handler := func(ctx context.Context, req interface{}) (interface{}, error) { 321 return srv.(EndpointServiceServer).UpdateEndpointLongRunning(ctx, req.(*UpdateEndpointLongRunningRequest)) 322 } 323 return interceptor(ctx, in, info, handler) 324 } 325 326 func _EndpointService_DeleteEndpoint_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { 327 in := new(DeleteEndpointRequest) 328 if err := dec(in); err != nil { 329 return nil, err 330 } 331 if interceptor == nil { 332 return srv.(EndpointServiceServer).DeleteEndpoint(ctx, in) 333 } 334 info := &grpc.UnaryServerInfo{ 335 Server: srv, 336 FullMethod: EndpointService_DeleteEndpoint_FullMethodName, 337 } 338 handler := func(ctx context.Context, req interface{}) (interface{}, error) { 339 return srv.(EndpointServiceServer).DeleteEndpoint(ctx, req.(*DeleteEndpointRequest)) 340 } 341 return interceptor(ctx, in, info, handler) 342 } 343 344 func _EndpointService_DeployModel_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { 345 in := new(DeployModelRequest) 346 if err := dec(in); err != nil { 347 return nil, err 348 } 349 if interceptor == nil { 350 return srv.(EndpointServiceServer).DeployModel(ctx, in) 351 } 352 info := &grpc.UnaryServerInfo{ 353 Server: srv, 354 FullMethod: EndpointService_DeployModel_FullMethodName, 355 } 356 handler := func(ctx context.Context, req interface{}) (interface{}, error) { 357 return srv.(EndpointServiceServer).DeployModel(ctx, req.(*DeployModelRequest)) 358 } 359 return interceptor(ctx, in, info, handler) 360 } 361 362 func _EndpointService_UndeployModel_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { 363 in := new(UndeployModelRequest) 364 if err := dec(in); err != nil { 365 return nil, err 366 } 367 if interceptor == nil { 368 return srv.(EndpointServiceServer).UndeployModel(ctx, in) 369 } 370 info := &grpc.UnaryServerInfo{ 371 Server: srv, 372 FullMethod: EndpointService_UndeployModel_FullMethodName, 373 } 374 handler := func(ctx context.Context, req interface{}) (interface{}, error) { 375 return srv.(EndpointServiceServer).UndeployModel(ctx, req.(*UndeployModelRequest)) 376 } 377 return interceptor(ctx, in, info, handler) 378 } 379 380 func _EndpointService_MutateDeployedModel_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) { 381 in := new(MutateDeployedModelRequest) 382 if err := dec(in); err != nil { 383 return nil, err 384 } 385 if interceptor == nil { 386 return srv.(EndpointServiceServer).MutateDeployedModel(ctx, in) 387 } 388 info := &grpc.UnaryServerInfo{ 389 Server: srv, 390 FullMethod: EndpointService_MutateDeployedModel_FullMethodName, 391 } 392 handler := func(ctx context.Context, req interface{}) (interface{}, error) { 393 return srv.(EndpointServiceServer).MutateDeployedModel(ctx, req.(*MutateDeployedModelRequest)) 394 } 395 return interceptor(ctx, in, info, handler) 396 } 397 398 // EndpointService_ServiceDesc is the grpc.ServiceDesc for EndpointService service. 399 // It's only intended for direct use with grpc.RegisterService, 400 // and not to be introspected or modified (even as a copy) 401 var EndpointService_ServiceDesc = grpc.ServiceDesc{ 402 ServiceName: "google.cloud.aiplatform.v1.EndpointService", 403 HandlerType: (*EndpointServiceServer)(nil), 404 Methods: []grpc.MethodDesc{ 405 { 406 MethodName: "CreateEndpoint", 407 Handler: _EndpointService_CreateEndpoint_Handler, 408 }, 409 { 410 MethodName: "GetEndpoint", 411 Handler: _EndpointService_GetEndpoint_Handler, 412 }, 413 { 414 MethodName: "ListEndpoints", 415 Handler: _EndpointService_ListEndpoints_Handler, 416 }, 417 { 418 MethodName: "UpdateEndpoint", 419 Handler: _EndpointService_UpdateEndpoint_Handler, 420 }, 421 { 422 MethodName: "UpdateEndpointLongRunning", 423 Handler: _EndpointService_UpdateEndpointLongRunning_Handler, 424 }, 425 { 426 MethodName: "DeleteEndpoint", 427 Handler: _EndpointService_DeleteEndpoint_Handler, 428 }, 429 { 430 MethodName: "DeployModel", 431 Handler: _EndpointService_DeployModel_Handler, 432 }, 433 { 434 MethodName: "UndeployModel", 435 Handler: _EndpointService_UndeployModel_Handler, 436 }, 437 { 438 MethodName: "MutateDeployedModel", 439 Handler: _EndpointService_MutateDeployedModel_Handler, 440 }, 441 }, 442 Streams: []grpc.StreamDesc{}, 443 Metadata: "google/cloud/aiplatform/v1/endpoint_service.proto", 444 }