"""
@generated by mypy-protobuf.  Do not edit manually!
isort:skip_file
"""
import builtins
import flyteidl.core.literals_pb2
import flyteidl.core.tasks_pb2
import flyteidl.core.workflow_pb2
import google.protobuf.descriptor
import google.protobuf.internal.containers
import google.protobuf.message
import typing
import typing_extensions

DESCRIPTOR: google.protobuf.descriptor.FileDescriptor = ...

class DynamicJobSpec(google.protobuf.message.Message):
    """Describes a set of tasks to execute and how the final outputs are produced."""
    DESCRIPTOR: google.protobuf.descriptor.Descriptor = ...
    NODES_FIELD_NUMBER: builtins.int
    MIN_SUCCESSES_FIELD_NUMBER: builtins.int
    OUTPUTS_FIELD_NUMBER: builtins.int
    TASKS_FIELD_NUMBER: builtins.int
    SUBWORKFLOWS_FIELD_NUMBER: builtins.int
    @property
    def nodes(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[flyteidl.core.workflow_pb2.Node]:
        """A collection of nodes to execute."""
        pass
    min_successes: builtins.int = ...
    """An absolute number of successful completions of nodes required to mark this job as succeeded. As soon as this
    criteria is met, the dynamic job will be marked as successful and outputs will be computed. If this number
    becomes impossible to reach (e.g. number of currently running tasks + number of already succeeded tasks <
    min_successes) the task will be aborted immediately and marked as failed. The default value of this field, if not
    specified, is the count of nodes repeated field.
    """

    @property
    def outputs(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[flyteidl.core.literals_pb2.Binding]:
        """Describes how to bind the final output of the dynamic job from the outputs of executed nodes. The referenced ids
        in bindings should have the generated id for the subtask.
        """
        pass
    @property
    def tasks(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[flyteidl.core.tasks_pb2.TaskTemplate]:
        """[Optional] A complete list of task specs referenced in nodes."""
        pass
    @property
    def subworkflows(self) -> google.protobuf.internal.containers.RepeatedCompositeFieldContainer[flyteidl.core.workflow_pb2.WorkflowTemplate]:
        """[Optional] A complete list of task specs referenced in nodes."""
        pass
    def __init__(self,
        *,
        nodes : typing.Optional[typing.Iterable[flyteidl.core.workflow_pb2.Node]] = ...,
        min_successes : builtins.int = ...,
        outputs : typing.Optional[typing.Iterable[flyteidl.core.literals_pb2.Binding]] = ...,
        tasks : typing.Optional[typing.Iterable[flyteidl.core.tasks_pb2.TaskTemplate]] = ...,
        subworkflows : typing.Optional[typing.Iterable[flyteidl.core.workflow_pb2.WorkflowTemplate]] = ...,
        ) -> None: ...
    def ClearField(self, field_name: typing_extensions.Literal[u"min_successes",b"min_successes",u"nodes",b"nodes",u"outputs",b"outputs",u"subworkflows",b"subworkflows",u"tasks",b"tasks"]) -> None: ...
global___DynamicJobSpec = DynamicJobSpec
