1u0 commented on a change in pull request #9383: [FLINK-13248] [runtime] Adding
processing of downstream messages in AsyncWaitOperator's wait loops
URL: https://github.com/apache/flink/pull/9383#discussion_r319038740
##########
File path:
flink-streaming-java/src/main/java/org/apache/flink/streaming/api/datastream/DataStream.java
##########
@@ -1172,21 +1175,53 @@ public ExecutionConfig getExecutionConfig() {
* @param <R>
* type of the return stream
* @return the data stream constructed
+ * @see #transform(String, TypeInformation,
OneInputStreamOperatorFactory)
*/
@PublicEvolving
- public <R> SingleOutputStreamOperator<R> transform(String operatorName,
TypeInformation<R> outTypeInfo, OneInputStreamOperator<T, R> operator) {
+ public <R> SingleOutputStreamOperator<R> transform(
+ String operatorName,
+ TypeInformation<R> outTypeInfo,
+ OneInputStreamOperator<T, R> operator) {
+
+ return transformImpl(operatorName, outTypeInfo,
SimpleOperatorFactory.of(operator));
+ }
+
+ /**
+ * Method for passing user defined operators created by the given
factory along with the type information that will
+ * transform the DataStream.
+ *
+ * <p>This method uses the rather new operator factories and should
only be used when custom factories are needed.
+ *
+ * @param operatorName name of the operator, for logging purposes
+ * @param outTypeInfo the output type of the operator
+ * @param operatorFactory the factory for the operator.
+ * @param <R> type of the return stream
+ * @return the data stream constructed.
+ */
+ @PublicEvolving
+ public <R> SingleOutputStreamOperator<R> transform(
+ String operatorName,
+ TypeInformation<R> outTypeInfo,
+ OneInputStreamOperatorFactory<T, R> operatorFactory) {
+ return transformImpl(operatorName, outTypeInfo,
operatorFactory);
+ }
+
+ private <R> SingleOutputStreamOperator<R> transformImpl(
Review comment:
Suggestion for as an alternative name: `doTransform`.
----------------------------------------------------------------
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