"""
@generated by mypy-protobuf.  Do not edit manually!
isort:skip_file
"""
import builtins
import collections.abc
import google.protobuf.descriptor
import google.protobuf.duration_pb2
import google.protobuf.internal.containers
import google.protobuf.message
import prodvana.proto.prodvana.common_config.notification_pb2
import prodvana.proto.prodvana.common_config.program_pb2
import prodvana.proto.prodvana.common_config.retry_pb2
import sys

if sys.version_info >= (3, 8):
    import typing as typing_extensions
else:
    import typing_extensions

DESCRIPTOR: google.protobuf.descriptor.FileDescriptor

class PushTask(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    SERVICE_ID_FIELD_NUMBER: builtins.int
    SERVICE_FIELD_NUMBER: builtins.int
    RELEASE_CHANNEL_ID_FIELD_NUMBER: builtins.int
    RELEASE_CHANNEL_FIELD_NUMBER: builtins.int
    ROLLBACK_FIELD_NUMBER: builtins.int
    APPLICATION_ID_FIELD_NUMBER: builtins.int
    APPLICATION_FIELD_NUMBER: builtins.int
    service_id: builtins.str
    """when passing as input, only specify one of service or service_id, not both"""
    service: builtins.str
    release_channel_id: builtins.str
    """when passing as input, only specify one of release_channel or release_channel_id, not both"""
    release_channel: builtins.str
    rollback: builtins.bool
    """deprecated, set at pipeline level instead of task level"""
    application_id: builtins.str
    application: builtins.str
    def __init__(
        self,
        *,
        service_id: builtins.str = ...,
        service: builtins.str = ...,
        release_channel_id: builtins.str = ...,
        release_channel: builtins.str = ...,
        rollback: builtins.bool = ...,
        application_id: builtins.str = ...,
        application: builtins.str = ...,
    ) -> None: ...
    def ClearField(self, field_name: typing_extensions.Literal["application", b"application", "application_id", b"application_id", "release_channel", b"release_channel", "release_channel_id", b"release_channel_id", "rollback", b"rollback", "service", b"service", "service_id", b"service_id"]) -> None: ...

global___PushTask = PushTask

class WaitTask(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    DURATION_FIELD_NUMBER: builtins.int
    @property
    def duration(self) -> google.protobuf.duration_pb2.Duration: ...
    def __init__(
        self,
        *,
        duration: google.protobuf.duration_pb2.Duration | None = ...,
    ) -> None: ...
    def HasField(self, field_name: typing_extensions.Literal["duration", b"duration"]) -> builtins.bool: ...
    def ClearField(self, field_name: typing_extensions.Literal["duration", b"duration"]) -> None: ...

global___WaitTask = WaitTask

class ParallelTask(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    class TaskTrack(google.protobuf.message.Message):
        DESCRIPTOR: google.protobuf.descriptor.Descriptor

        TASKS_FIELD_NUMBER: builtins.int
        @property
        def tasks(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___Task]: ...
        def __init__(
            self,
            *,
            tasks: collections.abc.Iterable[global___Task] | None = ...,
        ) -> None: ...
        def ClearField(self, field_name: typing_extensions.Literal["tasks", b"tasks"]) -> None: ...

    TRACKS_FIELD_NUMBER: builtins.int
    @property
    def tracks(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___ParallelTask.TaskTrack]: ...
    def __init__(
        self,
        *,
        tracks: collections.abc.Iterable[global___ParallelTask.TaskTrack] | None = ...,
    ) -> None: ...
    def ClearField(self, field_name: typing_extensions.Literal["tracks", b"tracks"]) -> None: ...

global___ParallelTask = ParallelTask

class ManualApprovalTask(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    def __init__(
        self,
    ) -> None: ...

global___ManualApprovalTask = ManualApprovalTask

class CustomTask(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    DESCRIPTION_FIELD_NUMBER: builtins.int
    PROGRAM_FIELD_NUMBER: builtins.int
    RETRY_CONFIG_FIELD_NUMBER: builtins.int
    APPLICATION_FIELD_NUMBER: builtins.int
    APPLICATION_ID_FIELD_NUMBER: builtins.int
    RELEASE_CHANNEL_FIELD_NUMBER: builtins.int
    RELEASE_CHANNEL_ID_FIELD_NUMBER: builtins.int
    FINAL_COMPILED_PROGRAM_FIELD_NUMBER: builtins.int
    description: builtins.str
    """description used for displaying this task"""
    @property
    def program(self) -> prodvana.proto.prodvana.common_config.program_pb2.ProgramConfig: ...
    @property
    def retry_config(self) -> prodvana.proto.prodvana.common_config.retry_pb2.RetryConfig:
        """if not set, the custom task will not be retried once it starts executing once."""
    application: builtins.str
    """TODO(naphat) is this the best interface, or do we just take runtime + namespace?"""
    application_id: builtins.str
    release_channel: builtins.str
    release_channel_id: builtins.str
    final_compiled_program: builtins.bool
    """if set, treat the program as the final program, avoid any internal Prodvana compilation (e.g. setting default env from app config)"""
    def __init__(
        self,
        *,
        description: builtins.str = ...,
        program: prodvana.proto.prodvana.common_config.program_pb2.ProgramConfig | None = ...,
        retry_config: prodvana.proto.prodvana.common_config.retry_pb2.RetryConfig | None = ...,
        application: builtins.str = ...,
        application_id: builtins.str = ...,
        release_channel: builtins.str = ...,
        release_channel_id: builtins.str = ...,
        final_compiled_program: builtins.bool = ...,
    ) -> None: ...
    def HasField(self, field_name: typing_extensions.Literal["program", b"program", "retry_config", b"retry_config"]) -> builtins.bool: ...
    def ClearField(self, field_name: typing_extensions.Literal["application", b"application", "application_id", b"application_id", "description", b"description", "final_compiled_program", b"final_compiled_program", "program", b"program", "release_channel", b"release_channel", "release_channel_id", b"release_channel_id", "retry_config", b"retry_config"]) -> None: ...

global___CustomTask = CustomTask

class Task(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    class Metadata(google.protobuf.message.Message):
        """Metadata contains information generic to all task types.
        Compilation of a task can be done entirely with its metadata and specific task-type config.
        """

        DESCRIPTOR: google.protobuf.descriptor.Descriptor

        ID_FIELD_NUMBER: builtins.int
        id: builtins.int
        def __init__(
            self,
            *,
            id: builtins.int = ...,
        ) -> None: ...
        def ClearField(self, field_name: typing_extensions.Literal["id", b"id"]) -> None: ...

    METADATA_FIELD_NUMBER: builtins.int
    PUSH_TASK_FIELD_NUMBER: builtins.int
    WAIT_TASK_FIELD_NUMBER: builtins.int
    PARALLEL_TASK_FIELD_NUMBER: builtins.int
    MANUAL_APPROVAL_TASK_FIELD_NUMBER: builtins.int
    CUSTOM_TASK_FIELD_NUMBER: builtins.int
    @property
    def metadata(self) -> global___Task.Metadata: ...
    @property
    def push_task(self) -> global___PushTask: ...
    @property
    def wait_task(self) -> global___WaitTask: ...
    @property
    def parallel_task(self) -> global___ParallelTask: ...
    @property
    def manual_approval_task(self) -> global___ManualApprovalTask: ...
    @property
    def custom_task(self) -> global___CustomTask: ...
    def __init__(
        self,
        *,
        metadata: global___Task.Metadata | None = ...,
        push_task: global___PushTask | None = ...,
        wait_task: global___WaitTask | None = ...,
        parallel_task: global___ParallelTask | None = ...,
        manual_approval_task: global___ManualApprovalTask | None = ...,
        custom_task: global___CustomTask | None = ...,
    ) -> None: ...
    def HasField(self, field_name: typing_extensions.Literal["custom_task", b"custom_task", "manual_approval_task", b"manual_approval_task", "metadata", b"metadata", "parallel_task", b"parallel_task", "push_task", b"push_task", "task_oneof", b"task_oneof", "wait_task", b"wait_task"]) -> builtins.bool: ...
    def ClearField(self, field_name: typing_extensions.Literal["custom_task", b"custom_task", "manual_approval_task", b"manual_approval_task", "metadata", b"metadata", "parallel_task", b"parallel_task", "push_task", b"push_task", "task_oneof", b"task_oneof", "wait_task", b"wait_task"]) -> None: ...
    def WhichOneof(self, oneof_group: typing_extensions.Literal["task_oneof", b"task_oneof"]) -> typing_extensions.Literal["push_task", "wait_task", "parallel_task", "manual_approval_task", "custom_task"] | None: ...

global___Task = Task

class PipelineConfig(google.protobuf.message.Message):
    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    NAME_FIELD_NUMBER: builtins.int
    TASKS_FIELD_NUMBER: builtins.int
    ROLLBACK_FIELD_NUMBER: builtins.int
    NOTIFICATIONS_FIELD_NUMBER: builtins.int
    name: builtins.str
    @property
    def tasks(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___Task]: ...
    rollback: builtins.bool
    @property
    def notifications(self) -> prodvana.proto.prodvana.common_config.notification_pb2.NotificationConfig: ...
    def __init__(
        self,
        *,
        name: builtins.str = ...,
        tasks: collections.abc.Iterable[global___Task] | None = ...,
        rollback: builtins.bool = ...,
        notifications: prodvana.proto.prodvana.common_config.notification_pb2.NotificationConfig | None = ...,
    ) -> None: ...
    def HasField(self, field_name: typing_extensions.Literal["notifications", b"notifications"]) -> builtins.bool: ...
    def ClearField(self, field_name: typing_extensions.Literal["name", b"name", "notifications", b"notifications", "rollback", b"rollback", "tasks", b"tasks"]) -> None: ...

global___PipelineConfig = PipelineConfig

class PipelineTemplate(google.protobuf.message.Message):
    """Similar to pipeline, but the task IDs and service fields are expected to not be filled out."""

    DESCRIPTOR: google.protobuf.descriptor.Descriptor

    NAME_SUFFIX_FIELD_NUMBER: builtins.int
    TASKS_FIELD_NUMBER: builtins.int
    ROLLBACK_FIELD_NUMBER: builtins.int
    NOTIFICATIONS_FIELD_NUMBER: builtins.int
    name_suffix: builtins.str
    @property
    def tasks(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[global___Task]: ...
    rollback: builtins.bool
    @property
    def notifications(self) -> prodvana.proto.prodvana.common_config.notification_pb2.NotificationConfig:
        """optional, will default to application's notification config"""
    def __init__(
        self,
        *,
        name_suffix: builtins.str = ...,
        tasks: collections.abc.Iterable[global___Task] | None = ...,
        rollback: builtins.bool = ...,
        notifications: prodvana.proto.prodvana.common_config.notification_pb2.NotificationConfig | None = ...,
    ) -> None: ...
    def HasField(self, field_name: typing_extensions.Literal["notifications", b"notifications"]) -> builtins.bool: ...
    def ClearField(self, field_name: typing_extensions.Literal["name_suffix", b"name_suffix", "notifications", b"notifications", "rollback", b"rollback", "tasks", b"tasks"]) -> None: ...

global___PipelineTemplate = PipelineTemplate
