tillrohrmann commented on a change in pull request #10550: [FLINK-15194]
Support registering directory as cache file in Yarn per-job mode
URL: https://github.com/apache/flink/pull/10550#discussion_r357711107
##########
File path:
flink-yarn-tests/src/test/java/org/apache/flink/yarn/testjob/YarnTestCacheJob.java
##########
@@ -44,11 +44,16 @@
public class YarnTestCacheJob {
private static final List<String> LIST = ImmutableList.of("test1",
"test2");
- public static JobGraph getDistributedCacheJobGraph() {
+ public static JobGraph getDistributedCacheJobGraph() throws IOException
{
final StreamExecutionEnvironment env =
StreamExecutionEnvironment.getExecutionEnvironment();
- String cacheFilePath =
Thread.currentThread().getContextClassLoader().getResource("cache.properties").getFile();
-
+ final String cacheFilePath =
Thread.currentThread().getContextClassLoader()
+ .getResource("cache.properties").getFile();
+ final File testDirectory =
File.createTempFile("test_directory", "");
Review comment:
Would it make sense use instead a `TemporaryFolder` rule in
`YarnDistributedCacheITCase` and pass in the test directory to the
`getDistributedCacheJobGraph(File testDirectory)`?
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services