这个是可以直接控制内部连边的方式,可以参考一下这个的Java doc。不过这个是一个内部接口,还是建议使用
env.setRuntimeMode(RuntimeExecutionMode.BATCH),这个可以参考一下这个文档:
https://nightlies.apache.org/flink/flink-docs-release-1.14/docs/dev/datastream/execution_mode/

public enum GlobalStreamExchangeMode {
    /** Set all job edges to be {@link ResultPartitionType#BLOCKING}. */
    ALL_EDGES_BLOCKING,

    /**
     * Set job edges with {@link ForwardPartitioner} to be {@link
     * ResultPartitionType#PIPELINED_BOUNDED} and other edges to be {@link
     * ResultPartitionType#BLOCKING}.
     */
    FORWARD_EDGES_PIPELINED,

    /**
     * Set job edges with {@link ForwardPartitioner} or {@link
RescalePartitioner} to be {@link
     * ResultPartitionType#PIPELINED_BOUNDED} and other edges to be {@link
     * ResultPartitionType#BLOCKING}.
     */
    POINTWISE_EDGES_PIPELINED,

    /** Set all job edges {@link ResultPartitionType#PIPELINED_BOUNDED}. */
    ALL_EDGES_PIPELINED,

    /** Set all job edges {@link ResultPartitionType#PIPELINED_APPROXIMATE}. */
    ALL_EDGES_PIPELINED_APPROXIMATE
}


casel.chen <casel_c...@126.com> 于2021年12月2日周四 上午8:26写道:

> GlobalStreamExchangeMode 这几种交换模式的不同和使用场景是什么?哪些适合流式作业,哪些适合批式作业?
> Flink Remote Shuffle Service的推出是不是意味着可以在生产环境使用Flink处理批式作业?谢谢!
>
>
> package org.apache.flink.streaming.api.graph;
>
>
>
>
> import org.apache.flink.annotation.Internal;
>
>
>
>
> @Internal
>
> public enum GlobalStreamExchangeMode {
>
>     ALL_EDGES_BLOCKING,
>
>     FORWARD_EDGES_PIPELINED,
>
>     POINTWISE_EDGES_PIPELINED,
>
>     ALL_EDGES_PIPELINED,
>
>     ALL_EDGES_PIPELINED_APPROXIMATE;
>
>
>
>
>     private GlobalStreamExchangeMode() {
>
>     }
>
> }
>
>
>

回复