"""
@generated by mypy-protobuf.  Do not edit manually!
isort:skip_file
"""
import abc
import collections.abc
import common.common_pb2
import google.protobuf.empty_pb2
import google.protobuf.wrappers_pb2
import grpc
import jobs.job_pb2
import jobs.nbox_ws_pb2

class WSJobServiceStub:
    """
    WSJobService is used by nbox to interface with Web Server. WSJobService
    manages DB and NBX Platform Information. All compute resource related actions
    are fowarded to WSJobsService running on AWS.

    // Generated according to
    https://cloud.google.com/apis/design/standard_methods
    """

    def __init__(self, channel: grpc.Channel) -> None: ...
    GetJob: grpc.UnaryUnaryMultiCallable[
        jobs.nbox_ws_pb2.JobRequest,
        jobs.job_pb2.Job,
    ]
    """GetJob returns the job with the given info"""
    ListJobs: grpc.UnaryUnaryMultiCallable[
        jobs.nbox_ws_pb2.ListJobsRequest,
        jobs.nbox_ws_pb2.ListJobsResponse,
    ]
    """ListJobs returns a list of jobs for the given workspace/user"""
    UploadJobCode: grpc.UnaryUnaryMultiCallable[
        jobs.nbox_ws_pb2.JobRequest,
        jobs.job_pb2.Job,
    ]
    """To upload Job Code to S3"""
    CreateJob: grpc.UnaryUnaryMultiCallable[
        jobs.nbox_ws_pb2.JobRequest,
        jobs.job_pb2.Job,
    ]
    """CreateJob creates a new job"""
    UpdateJob: grpc.UnaryUnaryMultiCallable[
        jobs.nbox_ws_pb2.UpdateJobRequest,
        jobs.job_pb2.Job,
    ]
    """UpdateJob updates the given job"""
    DeleteJob: grpc.UnaryUnaryMultiCallable[
        jobs.nbox_ws_pb2.JobRequest,
        google.protobuf.empty_pb2.Empty,
    ]
    """DeleteJob deletes the given job"""
    GetJobLogs: grpc.UnaryStreamMultiCallable[
        jobs.nbox_ws_pb2.JobRequest,
        common.common_pb2.Log,
    ]
    """GetJobLogs returns logs from given job"""
    TriggerJob: grpc.UnaryUnaryMultiCallable[
        jobs.nbox_ws_pb2.JobRequest,
        google.protobuf.wrappers_pb2.BoolValue,
    ]
    """TriggerJob triggers the given job"""
    UpdateRun: grpc.UnaryUnaryMultiCallable[
        jobs.nbox_ws_pb2.UpdateRunRequest,
        google.protobuf.empty_pb2.Empty,
    ]
    """UpdateRun update the run for given job"""
    GetRunToken: grpc.UnaryUnaryMultiCallable[
        jobs.nbox_ws_pb2.JobRequest,
        google.protobuf.wrappers_pb2.StringValue,
    ]
    """GetRunToken returns a tokn to be used for `/UpdateRun`"""

class WSJobServiceServicer(metaclass=abc.ABCMeta):
    """
    WSJobService is used by nbox to interface with Web Server. WSJobService
    manages DB and NBX Platform Information. All compute resource related actions
    are fowarded to WSJobsService running on AWS.

    // Generated according to
    https://cloud.google.com/apis/design/standard_methods
    """

    @abc.abstractmethod
    def GetJob(
        self,
        request: jobs.nbox_ws_pb2.JobRequest,
        context: grpc.ServicerContext,
    ) -> jobs.job_pb2.Job:
        """GetJob returns the job with the given info"""
    @abc.abstractmethod
    def ListJobs(
        self,
        request: jobs.nbox_ws_pb2.ListJobsRequest,
        context: grpc.ServicerContext,
    ) -> jobs.nbox_ws_pb2.ListJobsResponse:
        """ListJobs returns a list of jobs for the given workspace/user"""
    @abc.abstractmethod
    def UploadJobCode(
        self,
        request: jobs.nbox_ws_pb2.JobRequest,
        context: grpc.ServicerContext,
    ) -> jobs.job_pb2.Job:
        """To upload Job Code to S3"""
    @abc.abstractmethod
    def CreateJob(
        self,
        request: jobs.nbox_ws_pb2.JobRequest,
        context: grpc.ServicerContext,
    ) -> jobs.job_pb2.Job:
        """CreateJob creates a new job"""
    @abc.abstractmethod
    def UpdateJob(
        self,
        request: jobs.nbox_ws_pb2.UpdateJobRequest,
        context: grpc.ServicerContext,
    ) -> jobs.job_pb2.Job:
        """UpdateJob updates the given job"""
    @abc.abstractmethod
    def DeleteJob(
        self,
        request: jobs.nbox_ws_pb2.JobRequest,
        context: grpc.ServicerContext,
    ) -> google.protobuf.empty_pb2.Empty:
        """DeleteJob deletes the given job"""
    @abc.abstractmethod
    def GetJobLogs(
        self,
        request: jobs.nbox_ws_pb2.JobRequest,
        context: grpc.ServicerContext,
    ) -> collections.abc.Iterator[common.common_pb2.Log]:
        """GetJobLogs returns logs from given job"""
    @abc.abstractmethod
    def TriggerJob(
        self,
        request: jobs.nbox_ws_pb2.JobRequest,
        context: grpc.ServicerContext,
    ) -> google.protobuf.wrappers_pb2.BoolValue:
        """TriggerJob triggers the given job"""
    @abc.abstractmethod
    def UpdateRun(
        self,
        request: jobs.nbox_ws_pb2.UpdateRunRequest,
        context: grpc.ServicerContext,
    ) -> google.protobuf.empty_pb2.Empty:
        """UpdateRun update the run for given job"""
    @abc.abstractmethod
    def GetRunToken(
        self,
        request: jobs.nbox_ws_pb2.JobRequest,
        context: grpc.ServicerContext,
    ) -> google.protobuf.wrappers_pb2.StringValue:
        """GetRunToken returns a tokn to be used for `/UpdateRun`"""

def add_WSJobServiceServicer_to_server(servicer: WSJobServiceServicer, server: grpc.Server) -> None: ...
