Class StreamGraph

    • Method Detail

      • clear

        public void clear()
        Remove all registered nodes etc.
      • addJar

        public void addJar​(Path jar)
        Adds the path of a JAR file required to run the job on a task manager.
        Parameters:
        jar - path of the JAR file required to run the job on a task manager
      • getUserJars

        public List<Path> getUserJars()
        Gets the list of assigned user jar paths.
        Specified by:
        getUserJars in interface ExecutionPlan
        Returns:
        The list of assigned user jar paths
      • createJobCheckpointingSettings

        public void createJobCheckpointingSettings()
      • getJobName

        public String getJobName()
      • setJobName

        public void setJobName​(String jobName)
      • setLineageGraph

        public void setLineageGraph​(LineageGraph lineageGraph)
      • setStateBackend

        public void setStateBackend​(StateBackend backend)
      • setCheckpointStorage

        public void setCheckpointStorage​(CheckpointStorage checkpointStorage)
      • setGlobalStreamExchangeMode

        public void setGlobalStreamExchangeMode​(GlobalStreamExchangeMode globalExchangeMode)
      • setSlotSharingGroupResource

        public void setSlotSharingGroupResource​(Map<String,​ResourceProfile> slotSharingGroupResources)
      • hasFineGrainedResource

        public boolean hasFineGrainedResource()
      • setAllVerticesInSameSlotSharingGroupByDefault

        public void setAllVerticesInSameSlotSharingGroupByDefault​(boolean allVerticesInSameSlotSharingGroupByDefault)
        Set whether to put all vertices into the same slot sharing group by default.
        Parameters:
        allVerticesInSameSlotSharingGroupByDefault - indicates whether to put all vertices into the same slot sharing group by default.
      • isAllVerticesInSameSlotSharingGroupByDefault

        public boolean isAllVerticesInSameSlotSharingGroupByDefault()
        Gets whether to put all vertices into the same slot sharing group by default.
        Returns:
        whether to put all vertices into the same slot sharing group by default.
      • isEnableCheckpointsAfterTasksFinish

        public boolean isEnableCheckpointsAfterTasksFinish()
      • setEnableCheckpointsAfterTasksFinish

        public void setEnableCheckpointsAfterTasksFinish​(boolean enableCheckpointsAfterTasksFinish)
      • isChainingEnabled

        public boolean isChainingEnabled()
      • isChainingOfOperatorsWithDifferentMaxParallelismEnabled

        public boolean isChainingOfOperatorsWithDifferentMaxParallelismEnabled()
      • isIterative

        public boolean isIterative()
      • addVirtualSideOutputNode

        public void addVirtualSideOutputNode​(Integer originalId,
                                             Integer virtualId,
                                             OutputTag outputTag)
        Adds a new virtual node that is used to connect a downstream vertex to only the outputs with the selected side-output OutputTag.
        Parameters:
        originalId - ID of the node that should be connected to.
        virtualId - ID of the virtual node.
        outputTag - The selected side-output OutputTag.
      • addVirtualPartitionNode

        public void addVirtualPartitionNode​(Integer originalId,
                                            Integer virtualId,
                                            StreamPartitioner<?> partitioner,
                                            StreamExchangeMode exchangeMode)
        Adds a new virtual node that is used to connect a downstream vertex to an input with a certain partitioning.

        When adding an edge from the virtual node to a downstream node the connection will be made to the original node, but with the partitioning given here.

        Parameters:
        originalId - ID of the node that should be connected to.
        virtualId - ID of the virtual node.
        partitioner - The partitioner
      • getSlotSharingGroup

        public String getSlotSharingGroup​(Integer id)
        Determines the slot sharing group of an operation across virtual nodes.
      • addEdge

        public void addEdge​(Integer upStreamVertexID,
                            Integer downStreamVertexID,
                            int typeNumber)
      • setParallelism

        public void setParallelism​(Integer vertexID,
                                   int parallelism)
      • isDynamic

        public boolean isDynamic()
        Description copied from interface: ExecutionPlan
        Checks if the execution plan is dynamic.
        Specified by:
        isDynamic in interface ExecutionPlan
        Returns:
        true if the execution plan is dynamic; false otherwise
      • isEmpty

        public boolean isEmpty()
        Description copied from interface: ExecutionPlan
        Checks if the execution plan is empty.
        Specified by:
        isEmpty in interface ExecutionPlan
        Returns:
        true if the plan is empty; false otherwise
      • setParallelism

        public void setParallelism​(Integer vertexId,
                                   int parallelism,
                                   boolean parallelismConfigured)
      • setDynamic

        public void setDynamic​(boolean dynamic)
      • setMaxParallelism

        public void setMaxParallelism​(int vertexID,
                                      int maxParallelism)
      • setResources

        public void setResources​(int vertexID,
                                 ResourceSpec minResources,
                                 ResourceSpec preferredResources)
      • setBufferTimeout

        public void setBufferTimeout​(Integer vertexID,
                                     long bufferTimeout)
      • setInputFormat

        public void setInputFormat​(Integer vertexID,
                                   InputFormat<?,​?> inputFormat)
      • setOutputFormat

        public void setOutputFormat​(Integer vertexID,
                                    OutputFormat<?> outputFormat)
      • setTransformationUID

        public void setTransformationUID​(Integer nodeId,
                                         String transformationId)
      • getLoopTimeout

        public long getLoopTimeout​(Integer vertexID)
      • getStreamingPlanAsJSON

        public String getStreamingPlanAsJSON()
      • setJobType

        public void setJobType​(JobType jobType)
      • isAutoParallelismEnabled

        public boolean isAutoParallelismEnabled()
      • setAutoParallelismEnabled

        public void setAutoParallelismEnabled​(boolean autoParallelismEnabled)
      • setVertexNameIncludeIndexPrefix

        public void setVertexNameIncludeIndexPrefix​(boolean includePrefix)
      • isVertexNameIncludeIndexPrefix

        public boolean isVertexNameIncludeIndexPrefix()
      • registerJobStatusHook

        public void registerJobStatusHook​(JobStatusHook hook)
        Registers the JobStatusHook.
      • setSupportsConcurrentExecutionAttempts

        public void setSupportsConcurrentExecutionAttempts​(Integer vertexId,
                                                           boolean supportsConcurrentExecutionAttempts)
      • setAttribute

        public void setAttribute​(Integer vertexId,
                                 Attribute attribute)
      • setJobId

        public void setJobId​(JobID jobId)
      • getJobID

        public JobID getJobID()
        Description copied from interface: ExecutionPlan
        Gets the unique identifier of the job.
        Specified by:
        getJobID in interface ExecutionPlan
        Returns:
        the job id
      • setClasspath

        public void setClasspath​(List<URL> paths)
        Sets the classpath required to run the job on a task manager.
        Parameters:
        paths - paths of the directories/JAR files required to run the job on a task manager
      • getClasspath

        public List<URL> getClasspath()
      • getUserJarBlobKeys

        public List<PermanentBlobKey> getUserJarBlobKeys()
        Returns a list of BLOB keys referring to the JAR files required to run this job.
        Specified by:
        getUserJarBlobKeys in interface ExecutionPlan
        Returns:
        list of BLOB keys referring to the JAR files required to run this job
      • getClasspaths

        public List<URL> getClasspaths()
        Description copied from interface: ExecutionPlan
        Gets the classpath required for the job.
        Specified by:
        getClasspaths in interface ExecutionPlan
        Returns:
        a list of classpath URLs
      • setUserArtifactBlobKey

        public void setUserArtifactBlobKey​(String entryName,
                                           PermanentBlobKey blobKey)
                                    throws IOException
        Description copied from interface: ExecutionPlan
        Sets a user artifact blob key for a specified user artifact.
        Specified by:
        setUserArtifactBlobKey in interface ExecutionPlan
        Parameters:
        entryName - the name of the user artifact
        blobKey - the blob key corresponding to the user artifact
        Throws:
        IOException - if an error occurs during the operation
      • getMaximumParallelism

        public int getMaximumParallelism()
        Description copied from interface: ExecutionPlan
        Gets the maximum parallelism level for the job.
        Specified by:
        getMaximumParallelism in interface ExecutionPlan
        Returns:
        the maximum parallelism
      • setInitialClientHeartbeatTimeout

        public void setInitialClientHeartbeatTimeout​(long initialClientHeartbeatTimeout)
      • getInitialClientHeartbeatTimeout

        public long getInitialClientHeartbeatTimeout()
        Description copied from interface: ExecutionPlan
        Gets the initial client heartbeat timeout.
        Specified by:
        getInitialClientHeartbeatTimeout in interface ExecutionPlan
        Returns:
        the timeout duration in milliseconds
      • isPartialResourceConfigured

        public boolean isPartialResourceConfigured()
        Description copied from interface: ExecutionPlan
        Checks if partial resource configuration is specified.
        Specified by:
        isPartialResourceConfigured in interface ExecutionPlan
        Returns:
        true if partial resource configuration is set; false otherwise
      • serializeUserDefinedInstances

        public void serializeUserDefinedInstances()
                                           throws IOException
        Throws:
        IOException