afedulov commented on code in PR #20757:
URL: https://github.com/apache/flink/pull/20757#discussion_r963522637


##########
flink-core/src/main/java/org/apache/flink/api/connector/source/SourceReaderContext.java:
##########
@@ -63,4 +63,11 @@ public interface SourceReaderContext {
      * @see UserCodeClassLoader
      */
     UserCodeClassLoader getUserCodeClassLoader();
+
+    /**
+     * Get the current parallelism of this Source.
+     *
+     * @return the parallelism of the Source.
+     */
+    int currentParallelism();

Review Comment:
   Discussed with Becket [on the 
ML](https://lists.apache.org/thread/73t5mzsjyhtho9827k0pkqxmocp236xz).
   Justified/described in the FLIP 
[here](https://cwiki.apache.org/confluence/display/FLINK/FLIP-238%3A+Introduce+FLIP-27-based+Data+Generator+Source#:~:text=In%20order%20to,the%20currentParallelism()%20method%3A).
   Do you think adding the default method is the right way?
   
   



-- 
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.

To unsubscribe, e-mail: issues-unsubscr...@flink.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to