You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by GitBox <gi...@apache.org> on 2020/10/26 12:40:48 UTC

[GitHub] [flink] SteNicholas commented on a change in pull request #13637: [FLINK-19494][DataStream API] Adjust StreamExecutionEnvironment.generateSequence() to new API Sources

SteNicholas commented on a change in pull request #13637:
URL: https://github.com/apache/flink/pull/13637#discussion_r511929028



##########
File path: flink-streaming-java/src/main/java/org/apache/flink/streaming/api/environment/StreamExecutionEnvironment.java
##########
@@ -832,14 +833,42 @@ private StateBackend loadStateBackend(ReadableConfig configuration, ClassLoader
 	 * @param to
 	 * 		The number to stop at (inclusive)
 	 * @return A data stream, containing all number in the [from, to] interval
+	 * @deprecated Use {@link #fromSequence(long, long)} instead to create a new data stream
+	 * that contains {@link org.apache.flink.api.connector.source.lib.NumberSequenceSource}.
 	 */
+	@Deprecated
 	public DataStreamSource<Long> generateSequence(long from, long to) {
 		if (from > to) {
 			throw new IllegalArgumentException("Start of sequence must not be greater than the end");
 		}
 		return addSource(new StatefulSequenceSource(from, to), "Sequence Source");
 	}
 
+	/**
+	 * Creates a new data stream that contains {@link org.apache.flink.api.connector.source.lib.NumberSequenceSource}

Review comment:
       @StephanEwen Does this need to mention that implementation detail? I thought this need be mentioned here.




----------------------------------------------------------------
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:
users@infra.apache.org