diff --git a/integration-tests-jvm/flink/src/main/java/org/apache/camel/quarkus/component/flink/it/FlinkResource.java b/integration-tests-jvm/flink/src/main/java/org/apache/camel/quarkus/component/flink/it/FlinkResource.java index 01fe5346ecb7..6885b4d60c19 100644 --- a/integration-tests-jvm/flink/src/main/java/org/apache/camel/quarkus/component/flink/it/FlinkResource.java +++ b/integration-tests-jvm/flink/src/main/java/org/apache/camel/quarkus/component/flink/it/FlinkResource.java @@ -37,6 +37,7 @@ import org.apache.camel.component.flink.VoidDataStreamCallback; import org.apache.flink.api.java.DataSet; import org.apache.flink.api.java.ExecutionEnvironment; +import org.apache.flink.configuration.Configuration; import org.apache.flink.streaming.api.datastream.DataStream; import org.apache.flink.streaming.api.environment.StreamExecutionEnvironment; import org.jboss.logging.Logger; @@ -66,6 +67,7 @@ public Response dataSetFromTextFile(@PathParam("filePath") String filePath) { if (Files.exists(Paths.get(filePath))) { ExecutionEnvironment env = Flinks.createExecutionEnvironment(); + env.getConfiguration().setString("io.tmp.dirs", "target"); DataSet myDataSet = env.readTextFile(filePath); context.getRegistry().bind("myDataSet", myDataSet); context.getRegistry().bind("countTotal", addDataSetCallback()); @@ -84,7 +86,9 @@ public Response dataSetFromTextFile(@PathParam("filePath") String filePath) { public Response loadStream(@PathParam("filePath") String filePath, String data) throws IOException { java.nio.file.Path path = Paths.get(filePath); if (path != null) { - StreamExecutionEnvironment env = StreamExecutionEnvironment.getExecutionEnvironment(); + Configuration configuration = new Configuration(); + configuration.setString("io.tmp.dirs", "target"); + StreamExecutionEnvironment env = StreamExecutionEnvironment.getExecutionEnvironment(configuration); DataStream datastream = env.fromElements(data); context.getRegistry().bind("myDataStream", datastream); template.sendBodyAndHeader(flinkDataStreamUri, null,