Github user tdas commented on a diff in the pull request:

    https://github.com/apache/spark/pull/20710#discussion_r171993066
  
    --- Diff: 
sql/core/src/main/java/org/apache/spark/sql/sources/v2/writer/DataWriterFactory.java
 ---
    @@ -48,6 +48,9 @@
        *                      same task id but different attempt number, which 
means there are multiple
        *                      tasks with the same task id running at the same 
time. Implementations can
        *                      use this attempt number to distinguish writers 
of different task attempts.
    +   * @param epochId A monotonically increasing id for streaming queries 
that are split in to
    +   *                discrete periods of execution. For queries that 
execute as a single batch, this
    +   *                id will always be zero.
        */
    -  DataWriter<T> createDataWriter(int partitionId, int attemptNumber);
    +  DataWriter<T> createDataWriter(int partitionId, int attemptNumber, long 
epochId);
    --- End diff --
    
    Add clear lifecycle semantics.


---

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to