Search in sources :

Example 41 with NettyShuffleEnvironmentBuilder

use of org.apache.flink.runtime.io.network.NettyShuffleEnvironmentBuilder in project flink by apache.

the class RecordWriterTest method createResultPartition.

public static ResultPartition createResultPartition(int bufferSize, int numSubpartitions) throws IOException {
    NettyShuffleEnvironment env = new NettyShuffleEnvironmentBuilder().setBufferSize(bufferSize).build();
    ResultPartition partition = createPartition(env, ResultPartitionType.PIPELINED, numSubpartitions);
    partition.setup();
    return partition;
}
Also used : NettyShuffleEnvironmentBuilder(org.apache.flink.runtime.io.network.NettyShuffleEnvironmentBuilder) NettyShuffleEnvironment(org.apache.flink.runtime.io.network.NettyShuffleEnvironment) ResultPartition(org.apache.flink.runtime.io.network.partition.ResultPartition)

Example 42 with NettyShuffleEnvironmentBuilder

use of org.apache.flink.runtime.io.network.NettyShuffleEnvironmentBuilder in project flink by apache.

the class PipelinedApproximateSubpartitionTest method createResultPartition.

private static BufferWritingResultPartition createResultPartition() throws IOException {
    NettyShuffleEnvironment network = new NettyShuffleEnvironmentBuilder().setNumNetworkBuffers(10).setBufferSize(BUFFER_SIZE).build();
    ResultPartition resultPartition = createPartition(network, NoOpFileChannelManager.INSTANCE, ResultPartitionType.PIPELINED_APPROXIMATE, 2);
    resultPartition.setup();
    return (BufferWritingResultPartition) resultPartition;
}
Also used : NettyShuffleEnvironmentBuilder(org.apache.flink.runtime.io.network.NettyShuffleEnvironmentBuilder) NettyShuffleEnvironment(org.apache.flink.runtime.io.network.NettyShuffleEnvironment)

Aggregations

NettyShuffleEnvironmentBuilder (org.apache.flink.runtime.io.network.NettyShuffleEnvironmentBuilder)42 NettyShuffleEnvironment (org.apache.flink.runtime.io.network.NettyShuffleEnvironment)28 Test (org.junit.Test)24 Configuration (org.apache.flink.configuration.Configuration)16 Task (org.apache.flink.runtime.taskmanager.Task)16 StreamConfig (org.apache.flink.streaming.api.graph.StreamConfig)12 OperatorID (org.apache.flink.runtime.jobgraph.OperatorID)11 JobID (org.apache.flink.api.common.JobID)10 ExecutionConfig (org.apache.flink.api.common.ExecutionConfig)7 ExecutionAttemptID (org.apache.flink.runtime.executiongraph.ExecutionAttemptID)7 CompletableFuture (java.util.concurrent.CompletableFuture)6 OneShotLatch (org.apache.flink.core.testutils.OneShotLatch)6 PartitionProducerStateChecker (org.apache.flink.runtime.taskexecutor.PartitionProducerStateChecker)6 TaskManagerActions (org.apache.flink.runtime.taskmanager.TaskManagerActions)6 BroadcastVariableManager (org.apache.flink.runtime.broadcast.BroadcastVariableManager)5 AllocationID (org.apache.flink.runtime.clusterframework.types.AllocationID)5 JobInformation (org.apache.flink.runtime.executiongraph.JobInformation)5 TaskInformation (org.apache.flink.runtime.executiongraph.TaskInformation)5 FileCache (org.apache.flink.runtime.filecache.FileCache)5 TaskEventDispatcher (org.apache.flink.runtime.io.network.TaskEventDispatcher)5