<gh_stars>10-100
# Generated by the Protocol Buffers compiler. DO NOT EDIT!
# source: umbra.proto
# plugin: grpclib.plugin.main
import abc
import typing

import grpclib.const
import grpclib.client
if typing.TYPE_CHECKING:
    import grpclib.server

import google.protobuf.struct_pb2
import google.protobuf.timestamp_pb2
from umbra.common.protobuf import umbra_pb2


class BrokerBase(abc.ABC):

    @abc.abstractmethod
    async def Execute(self, stream: 'grpclib.server.Stream[umbra_pb2.Config, umbra_pb2.Report]') -> None:
        pass

    @abc.abstractmethod
    async def Collect(self, stream: 'grpclib.server.Stream[umbra_pb2.Stats, umbra_pb2.Status]') -> None:
        pass

    def __mapping__(self) -> typing.Dict[str, grpclib.const.Handler]:
        return {
            '/umbra.Broker/Execute': grpclib.const.Handler(
                self.Execute,
                grpclib.const.Cardinality.UNARY_UNARY,
                umbra_pb2.Config,
                umbra_pb2.Report,
            ),
            '/umbra.Broker/Collect': grpclib.const.Handler(
                self.Collect,
                grpclib.const.Cardinality.UNARY_UNARY,
                umbra_pb2.Stats,
                umbra_pb2.Status,
            ),
        }


class BrokerStub:

    def __init__(self, channel: grpclib.client.Channel) -> None:
        self.Execute = grpclib.client.UnaryUnaryMethod(
            channel,
            '/umbra.Broker/Execute',
            umbra_pb2.Config,
            umbra_pb2.Report,
        )
        self.Collect = grpclib.client.UnaryUnaryMethod(
            channel,
            '/umbra.Broker/Collect',
            umbra_pb2.Stats,
            umbra_pb2.Status,
        )


class ScenarioBase(abc.ABC):

    @abc.abstractmethod
    async def Establish(self, stream: 'grpclib.server.Stream[umbra_pb2.Workflow, umbra_pb2.Status]') -> None:
        pass

    @abc.abstractmethod
    async def Stats(self, stream: 'grpclib.server.Stream[umbra_pb2.Workflow, umbra_pb2.Status]') -> None:
        pass

    def __mapping__(self) -> typing.Dict[str, grpclib.const.Handler]:
        return {
            '/umbra.Scenario/Establish': grpclib.const.Handler(
                self.Establish,
                grpclib.const.Cardinality.UNARY_UNARY,
                umbra_pb2.Workflow,
                umbra_pb2.Status,
            ),
            '/umbra.Scenario/Stats': grpclib.const.Handler(
                self.Stats,
                grpclib.const.Cardinality.UNARY_UNARY,
                umbra_pb2.Workflow,
                umbra_pb2.Status,
            ),
        }


class ScenarioStub:

    def __init__(self, channel: grpclib.client.Channel) -> None:
        self.Establish = grpclib.client.UnaryUnaryMethod(
            channel,
            '/umbra.Scenario/Establish',
            umbra_pb2.Workflow,
            umbra_pb2.Status,
        )
        self.Stats = grpclib.client.UnaryUnaryMethod(
            channel,
            '/umbra.Scenario/Stats',
            umbra_pb2.Workflow,
            umbra_pb2.Status,
        )


class MonitorBase(abc.ABC):

    @abc.abstractmethod
    async def Measure(self, stream: 'grpclib.server.Stream[umbra_pb2.Directrix, umbra_pb2.Status]') -> None:
        pass

    def __mapping__(self) -> typing.Dict[str, grpclib.const.Handler]:
        return {
            '/umbra.Monitor/Measure': grpclib.const.Handler(
                self.Measure,
                grpclib.const.Cardinality.UNARY_UNARY,
                umbra_pb2.Directrix,
                umbra_pb2.Status,
            ),
        }


class MonitorStub:

    def __init__(self, channel: grpclib.client.Channel) -> None:
        self.Measure = grpclib.client.UnaryUnaryMethod(
            channel,
            '/umbra.Monitor/Measure',
            umbra_pb2.Directrix,
            umbra_pb2.Status,
        )


class AgentBase(abc.ABC):

    @abc.abstractmethod
    async def Probe(self, stream: 'grpclib.server.Stream[umbra_pb2.Instruction, umbra_pb2.Snapshot]') -> None:
        pass

    def __mapping__(self) -> typing.Dict[str, grpclib.const.Handler]:
        return {
            '/umbra.Agent/Probe': grpclib.const.Handler(
                self.Probe,
                grpclib.const.Cardinality.UNARY_UNARY,
                umbra_pb2.Instruction,
                umbra_pb2.Snapshot,
            ),
        }


class AgentStub:

    def __init__(self, channel: grpclib.client.Channel) -> None:
        self.Probe = grpclib.client.UnaryUnaryMethod(
            channel,
            '/umbra.Agent/Probe',
            umbra_pb2.Instruction,
            umbra_pb2.Snapshot,
        )


class CLIBase(abc.ABC):

    @abc.abstractmethod
    async def Inform(self, stream: 'grpclib.server.Stream[umbra_pb2.State, umbra_pb2.Status]') -> None:
        pass

    def __mapping__(self) -> typing.Dict[str, grpclib.const.Handler]:
        return {
            '/umbra.CLI/Inform': grpclib.const.Handler(
                self.Inform,
                grpclib.const.Cardinality.UNARY_UNARY,
                umbra_pb2.State,
                umbra_pb2.Status,
            ),
        }


class CLIStub:

    def __init__(self, channel: grpclib.client.Channel) -> None:
        self.Inform = grpclib.client.UnaryUnaryMethod(
            channel,
            '/umbra.CLI/Inform',
            umbra_pb2.State,
            umbra_pb2.Status,
        )

# Generated by the Protocol Buffers compiler. DO NOT EDIT!
# source: umbra.proto
# plugin: grpclib.plugin.main
import abc
import typing

import grpclib.const
import grpclib.client
if typing.TYPE_CHECKING:
    import grpclib.server

import google.protobuf.struct_pb2
import google.protobuf.timestamp_pb2
from umbra.common.protobuf import umbra_pb2


class BrokerBase(abc.ABC):

    @abc.abstractmethod
    async def Execute(self, stream: 'grpclib.server.Stream[umbra_pb2.Config, umbra_pb2.Report]') -> None:
        pass

    @abc.abstractmethod
    async def Collect(self, stream: 'grpclib.server.Stream[umbra_pb2.Stats, umbra_pb2.Status]') -> None:
        pass

    def __mapping__(self) -> typing.Dict[str, grpclib.const.Handler]:
        return {
            '/umbra.Broker/Execute': grpclib.const.Handler(
                self.Execute,
                grpclib.const.Cardinality.UNARY_UNARY,
                umbra_pb2.Config,
                umbra_pb2.Report,
            ),
            '/umbra.Broker/Collect': grpclib.const.Handler(
                self.Collect,
                grpclib.const.Cardinality.UNARY_UNARY,
                umbra_pb2.Stats,
                umbra_pb2.Status,
            ),
        }


class BrokerStub:

    def __init__(self, channel: grpclib.client.Channel) -> None:
        self.Execute = grpclib.client.UnaryUnaryMethod(
            channel,
            '/umbra.Broker/Execute',
            umbra_pb2.Config,
            umbra_pb2.Report,
        )
        self.Collect = grpclib.client.UnaryUnaryMethod(
            channel,
            '/umbra.Broker/Collect',
            umbra_pb2.Stats,
            umbra_pb2.Status,
        )


class ScenarioBase(abc.ABC):

    @abc.abstractmethod
    async def Establish(self, stream: 'grpclib.server.Stream[umbra_pb2.Workflow, umbra_pb2.Status]') -> None:
        pass

    @abc.abstractmethod
    async def Stats(self, stream: 'grpclib.server.Stream[umbra_pb2.Workflow, umbra_pb2.Status]') -> None:
        pass

    def __mapping__(self) -> typing.Dict[str, grpclib.const.Handler]:
        return {
            '/umbra.Scenario/Establish': grpclib.const.Handler(
                self.Establish,
                grpclib.const.Cardinality.UNARY_UNARY,
                umbra_pb2.Workflow,
                umbra_pb2.Status,
            ),
            '/umbra.Scenario/Stats': grpclib.const.Handler(
                self.Stats,
                grpclib.const.Cardinality.UNARY_UNARY,
                umbra_pb2.Workflow,
                umbra_pb2.Status,
            ),
        }


class ScenarioStub:

    def __init__(self, channel: grpclib.client.Channel) -> None:
        self.Establish = grpclib.client.UnaryUnaryMethod(
            channel,
            '/umbra.Scenario/Establish',
            umbra_pb2.Workflow,
            umbra_pb2.Status,
        )
        self.Stats = grpclib.client.UnaryUnaryMethod(
            channel,
            '/umbra.Scenario/Stats',
            umbra_pb2.Workflow,
            umbra_pb2.Status,
        )


class MonitorBase(abc.ABC):

    @abc.abstractmethod
    async def Measure(self, stream: 'grpclib.server.Stream[umbra_pb2.Directrix, umbra_pb2.Status]') -> None:
        pass

    def __mapping__(self) -> typing.Dict[str, grpclib.const.Handler]:
        return {
            '/umbra.Monitor/Measure': grpclib.const.Handler(
                self.Measure,
                grpclib.const.Cardinality.UNARY_UNARY,
                umbra_pb2.Directrix,
                umbra_pb2.Status,
            ),
        }


class MonitorStub:

    def __init__(self, channel: grpclib.client.Channel) -> None:
        self.Measure = grpclib.client.UnaryUnaryMethod(
            channel,
            '/umbra.Monitor/Measure',
            umbra_pb2.Directrix,
            umbra_pb2.Status,
        )


class AgentBase(abc.ABC):

    @abc.abstractmethod
    async def Probe(self, stream: 'grpclib.server.Stream[umbra_pb2.Instruction, umbra_pb2.Snapshot]') -> None:
        pass

    def __mapping__(self) -> typing.Dict[str, grpclib.const.Handler]:
        return {
            '/umbra.Agent/Probe': grpclib.const.Handler(
                self.Probe,
                grpclib.const.Cardinality.UNARY_UNARY,
                umbra_pb2.Instruction,
                umbra_pb2.Snapshot,
            ),
        }


class AgentStub:

    def __init__(self, channel: grpclib.client.Channel) -> None:
        self.Probe = grpclib.client.UnaryUnaryMethod(
            channel,
            '/umbra.Agent/Probe',
            umbra_pb2.Instruction,
            umbra_pb2.Snapshot,
        )


class CLIBase(abc.ABC):

    @abc.abstractmethod
    async def Inform(self, stream: 'grpclib.server.Stream[umbra_pb2.State, umbra_pb2.Status]') -> None:
        pass

    def __mapping__(self) -> typing.Dict[str, grpclib.const.Handler]:
        return {
            '/umbra.CLI/Inform': grpclib.const.Handler(
                self.Inform,
                grpclib.const.Cardinality.UNARY_UNARY,
                umbra_pb2.State,
                umbra_pb2.Status,
            ),
        }


class CLIStub:

    def __init__(self, channel: grpclib.client.Channel) -> None:
        self.Inform = grpclib.client.UnaryUnaryMethod(
            channel,
            '/umbra.CLI/Inform',
            umbra_pb2.State,
            umbra_pb2.Status,
        )
# Generated by the Protocol Buffers compiler. DO NOT EDIT! # source: umbra.proto # plugin: grpclib.plugin.main