[
https://issues.apache.org/jira/browse/FLINK-2622?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14740454#comment-14740454
]
ASF GitHub Bot commented on FLINK-2622:
---------------------------------------
Github user fhueske commented on a diff in the pull request:
https://github.com/apache/flink/pull/1098#discussion_r39253553
--- Diff:
flink-staging/flink-streaming/flink-streaming-scala/src/test/java/org/apache/flink/streaming/scala/api/CsvOutputFormatITCase.java
---
@@ -36,6 +37,10 @@ protected void preSubmit() throws Exception {
@Override
protected void testProgram() throws Exception {
OutputFormatTestPrograms.wordCountToCsv(WordCountData.TEXT,
resultPath);
+ OutputFormatTestPrograms.wordCountToCsv(WordCountData.TEXT,
resultPath, 1);
--- End diff --
It is expected that the test fails if you set the overwrite mode to
`NO_OVERWRITE` because you start multiple programs that all write to the same
location.
I debugged the issue and found that the `ForkableFlinkMiniCluster` sets the
overwrite mode to OVERWRITE. That explains the behavior. However, this also
means that you cannot test the correctness of your methods by setting the
overwrite mode to OVERWRITE because this is the default behavior.
I would change the `CsvOuputFormatITCase` to extend
`StreamingMultipleProgramsTestBase` and run each program in a dedicated test
method.
> Scala DataStream API does not have writeAsText method which supports WriteMode
> ------------------------------------------------------------------------------
>
> Key: FLINK-2622
> URL: https://issues.apache.org/jira/browse/FLINK-2622
> Project: Flink
> Issue Type: Bug
> Components: Scala API, Streaming
> Reporter: Till Rohrmann
>
> The Scala DataStream API, unlike the Java DataStream API, does not support a
> {{writeAsText}} method which takes the {{WriteMode}} as a parameter. In order
> to make the two APIs consistent, it should be added to the Scala DataStream
> API.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)