"""
@generated by mypy-protobuf.  Do not edit manually!
isort:skip_file
"""

import abc
import collections.abc
import grpc
import grpc.aio
import typing
import yandex.cloud.access.access_pb2
import yandex.cloud.compute.v1.gpu_cluster_pb2
import yandex.cloud.compute.v1.gpu_cluster_service_pb2
import yandex.cloud.operation.operation_pb2

_T = typing.TypeVar("_T")

class _MaybeAsyncIterator(collections.abc.AsyncIterator[_T], collections.abc.Iterator[_T], metaclass=abc.ABCMeta): ...

class _ServicerContext(grpc.ServicerContext, grpc.aio.ServicerContext):  # type: ignore[misc, type-arg]
    ...

class GpuClusterServiceStub:
    """A set of methods for managing GPU clusters."""

    def __init__(self, channel: typing.Union[grpc.Channel, grpc.aio.Channel]) -> None: ...
    Get: grpc.UnaryUnaryMultiCallable[
        yandex.cloud.compute.v1.gpu_cluster_service_pb2.GetGpuClusterRequest,
        yandex.cloud.compute.v1.gpu_cluster_pb2.GpuCluster,
    ]
    """Returns the specified GPU cluster.

    To get the list of available GPU clusters, make a [List] request.
    """

    List: grpc.UnaryUnaryMultiCallable[
        yandex.cloud.compute.v1.gpu_cluster_service_pb2.ListGpuClustersRequest,
        yandex.cloud.compute.v1.gpu_cluster_service_pb2.ListGpuClustersResponse,
    ]
    """Retrieves the list of GPU clusters in the specified folder."""

    Create: grpc.UnaryUnaryMultiCallable[
        yandex.cloud.compute.v1.gpu_cluster_service_pb2.CreateGpuClusterRequest,
        yandex.cloud.operation.operation_pb2.Operation,
    ]
    """Creates a GPU cluster in the specified folder."""

    Update: grpc.UnaryUnaryMultiCallable[
        yandex.cloud.compute.v1.gpu_cluster_service_pb2.UpdateGpuClusterRequest,
        yandex.cloud.operation.operation_pb2.Operation,
    ]
    """Updates the specified GPU cluster.

    Currently only name, description and labels can be updated.
    """

    Delete: grpc.UnaryUnaryMultiCallable[
        yandex.cloud.compute.v1.gpu_cluster_service_pb2.DeleteGpuClusterRequest,
        yandex.cloud.operation.operation_pb2.Operation,
    ]
    """Deletes the specified GPU cluster.

    GPU cluster can be deleted only if it doesn't have any instances associated with it.
    """

    ListOperations: grpc.UnaryUnaryMultiCallable[
        yandex.cloud.compute.v1.gpu_cluster_service_pb2.ListGpuClusterOperationsRequest,
        yandex.cloud.compute.v1.gpu_cluster_service_pb2.ListGpuClusterOperationsResponse,
    ]
    """Lists operations for the specified GPU cluster."""

    ListInstances: grpc.UnaryUnaryMultiCallable[
        yandex.cloud.compute.v1.gpu_cluster_service_pb2.ListGpuClusterInstancesRequest,
        yandex.cloud.compute.v1.gpu_cluster_service_pb2.ListGpuClusterInstancesResponse,
    ]
    """List instances created in this GPU cluster."""

    ListAccessBindings: grpc.UnaryUnaryMultiCallable[
        yandex.cloud.access.access_pb2.ListAccessBindingsRequest,
        yandex.cloud.access.access_pb2.ListAccessBindingsResponse,
    ]
    """access

    Lists access bindings for the GPU cluster.
    """

    SetAccessBindings: grpc.UnaryUnaryMultiCallable[
        yandex.cloud.access.access_pb2.SetAccessBindingsRequest,
        yandex.cloud.operation.operation_pb2.Operation,
    ]
    """Sets access bindings for the GPU cluster."""

    UpdateAccessBindings: grpc.UnaryUnaryMultiCallable[
        yandex.cloud.access.access_pb2.UpdateAccessBindingsRequest,
        yandex.cloud.operation.operation_pb2.Operation,
    ]
    """Updates access bindings for the GPU cluster."""

class GpuClusterServiceAsyncStub:
    """A set of methods for managing GPU clusters."""

    Get: grpc.aio.UnaryUnaryMultiCallable[
        yandex.cloud.compute.v1.gpu_cluster_service_pb2.GetGpuClusterRequest,
        yandex.cloud.compute.v1.gpu_cluster_pb2.GpuCluster,
    ]
    """Returns the specified GPU cluster.

    To get the list of available GPU clusters, make a [List] request.
    """

    List: grpc.aio.UnaryUnaryMultiCallable[
        yandex.cloud.compute.v1.gpu_cluster_service_pb2.ListGpuClustersRequest,
        yandex.cloud.compute.v1.gpu_cluster_service_pb2.ListGpuClustersResponse,
    ]
    """Retrieves the list of GPU clusters in the specified folder."""

    Create: grpc.aio.UnaryUnaryMultiCallable[
        yandex.cloud.compute.v1.gpu_cluster_service_pb2.CreateGpuClusterRequest,
        yandex.cloud.operation.operation_pb2.Operation,
    ]
    """Creates a GPU cluster in the specified folder."""

    Update: grpc.aio.UnaryUnaryMultiCallable[
        yandex.cloud.compute.v1.gpu_cluster_service_pb2.UpdateGpuClusterRequest,
        yandex.cloud.operation.operation_pb2.Operation,
    ]
    """Updates the specified GPU cluster.

    Currently only name, description and labels can be updated.
    """

    Delete: grpc.aio.UnaryUnaryMultiCallable[
        yandex.cloud.compute.v1.gpu_cluster_service_pb2.DeleteGpuClusterRequest,
        yandex.cloud.operation.operation_pb2.Operation,
    ]
    """Deletes the specified GPU cluster.

    GPU cluster can be deleted only if it doesn't have any instances associated with it.
    """

    ListOperations: grpc.aio.UnaryUnaryMultiCallable[
        yandex.cloud.compute.v1.gpu_cluster_service_pb2.ListGpuClusterOperationsRequest,
        yandex.cloud.compute.v1.gpu_cluster_service_pb2.ListGpuClusterOperationsResponse,
    ]
    """Lists operations for the specified GPU cluster."""

    ListInstances: grpc.aio.UnaryUnaryMultiCallable[
        yandex.cloud.compute.v1.gpu_cluster_service_pb2.ListGpuClusterInstancesRequest,
        yandex.cloud.compute.v1.gpu_cluster_service_pb2.ListGpuClusterInstancesResponse,
    ]
    """List instances created in this GPU cluster."""

    ListAccessBindings: grpc.aio.UnaryUnaryMultiCallable[
        yandex.cloud.access.access_pb2.ListAccessBindingsRequest,
        yandex.cloud.access.access_pb2.ListAccessBindingsResponse,
    ]
    """access

    Lists access bindings for the GPU cluster.
    """

    SetAccessBindings: grpc.aio.UnaryUnaryMultiCallable[
        yandex.cloud.access.access_pb2.SetAccessBindingsRequest,
        yandex.cloud.operation.operation_pb2.Operation,
    ]
    """Sets access bindings for the GPU cluster."""

    UpdateAccessBindings: grpc.aio.UnaryUnaryMultiCallable[
        yandex.cloud.access.access_pb2.UpdateAccessBindingsRequest,
        yandex.cloud.operation.operation_pb2.Operation,
    ]
    """Updates access bindings for the GPU cluster."""

class GpuClusterServiceServicer(metaclass=abc.ABCMeta):
    """A set of methods for managing GPU clusters."""

    @abc.abstractmethod
    def Get(
        self,
        request: yandex.cloud.compute.v1.gpu_cluster_service_pb2.GetGpuClusterRequest,
        context: _ServicerContext,
    ) -> typing.Union[yandex.cloud.compute.v1.gpu_cluster_pb2.GpuCluster, collections.abc.Awaitable[yandex.cloud.compute.v1.gpu_cluster_pb2.GpuCluster]]:
        """Returns the specified GPU cluster.

        To get the list of available GPU clusters, make a [List] request.
        """

    @abc.abstractmethod
    def List(
        self,
        request: yandex.cloud.compute.v1.gpu_cluster_service_pb2.ListGpuClustersRequest,
        context: _ServicerContext,
    ) -> typing.Union[yandex.cloud.compute.v1.gpu_cluster_service_pb2.ListGpuClustersResponse, collections.abc.Awaitable[yandex.cloud.compute.v1.gpu_cluster_service_pb2.ListGpuClustersResponse]]:
        """Retrieves the list of GPU clusters in the specified folder."""

    @abc.abstractmethod
    def Create(
        self,
        request: yandex.cloud.compute.v1.gpu_cluster_service_pb2.CreateGpuClusterRequest,
        context: _ServicerContext,
    ) -> typing.Union[yandex.cloud.operation.operation_pb2.Operation, collections.abc.Awaitable[yandex.cloud.operation.operation_pb2.Operation]]:
        """Creates a GPU cluster in the specified folder."""

    @abc.abstractmethod
    def Update(
        self,
        request: yandex.cloud.compute.v1.gpu_cluster_service_pb2.UpdateGpuClusterRequest,
        context: _ServicerContext,
    ) -> typing.Union[yandex.cloud.operation.operation_pb2.Operation, collections.abc.Awaitable[yandex.cloud.operation.operation_pb2.Operation]]:
        """Updates the specified GPU cluster.

        Currently only name, description and labels can be updated.
        """

    @abc.abstractmethod
    def Delete(
        self,
        request: yandex.cloud.compute.v1.gpu_cluster_service_pb2.DeleteGpuClusterRequest,
        context: _ServicerContext,
    ) -> typing.Union[yandex.cloud.operation.operation_pb2.Operation, collections.abc.Awaitable[yandex.cloud.operation.operation_pb2.Operation]]:
        """Deletes the specified GPU cluster.

        GPU cluster can be deleted only if it doesn't have any instances associated with it.
        """

    @abc.abstractmethod
    def ListOperations(
        self,
        request: yandex.cloud.compute.v1.gpu_cluster_service_pb2.ListGpuClusterOperationsRequest,
        context: _ServicerContext,
    ) -> typing.Union[yandex.cloud.compute.v1.gpu_cluster_service_pb2.ListGpuClusterOperationsResponse, collections.abc.Awaitable[yandex.cloud.compute.v1.gpu_cluster_service_pb2.ListGpuClusterOperationsResponse]]:
        """Lists operations for the specified GPU cluster."""

    @abc.abstractmethod
    def ListInstances(
        self,
        request: yandex.cloud.compute.v1.gpu_cluster_service_pb2.ListGpuClusterInstancesRequest,
        context: _ServicerContext,
    ) -> typing.Union[yandex.cloud.compute.v1.gpu_cluster_service_pb2.ListGpuClusterInstancesResponse, collections.abc.Awaitable[yandex.cloud.compute.v1.gpu_cluster_service_pb2.ListGpuClusterInstancesResponse]]:
        """List instances created in this GPU cluster."""

    @abc.abstractmethod
    def ListAccessBindings(
        self,
        request: yandex.cloud.access.access_pb2.ListAccessBindingsRequest,
        context: _ServicerContext,
    ) -> typing.Union[yandex.cloud.access.access_pb2.ListAccessBindingsResponse, collections.abc.Awaitable[yandex.cloud.access.access_pb2.ListAccessBindingsResponse]]:
        """access

        Lists access bindings for the GPU cluster.
        """

    @abc.abstractmethod
    def SetAccessBindings(
        self,
        request: yandex.cloud.access.access_pb2.SetAccessBindingsRequest,
        context: _ServicerContext,
    ) -> typing.Union[yandex.cloud.operation.operation_pb2.Operation, collections.abc.Awaitable[yandex.cloud.operation.operation_pb2.Operation]]:
        """Sets access bindings for the GPU cluster."""

    @abc.abstractmethod
    def UpdateAccessBindings(
        self,
        request: yandex.cloud.access.access_pb2.UpdateAccessBindingsRequest,
        context: _ServicerContext,
    ) -> typing.Union[yandex.cloud.operation.operation_pb2.Operation, collections.abc.Awaitable[yandex.cloud.operation.operation_pb2.Operation]]:
        """Updates access bindings for the GPU cluster."""

def add_GpuClusterServiceServicer_to_server(servicer: GpuClusterServiceServicer, server: typing.Union[grpc.Server, grpc.aio.Server]) -> None: ...
