[ 
https://issues.apache.org/jira/browse/FLINK-10977?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16718852#comment-16718852
 ] 

ASF GitHub Bot commented on FLINK-10977:
----------------------------------------

dianfu commented on a change in pull request #7209: [FLINK-10977][table] Add 
UnBounded FlatAggregate operator to streaming Table API
URL: https://github.com/apache/flink/pull/7209#discussion_r240930180
 
 

 ##########
 File path: 
flink-libraries/flink-table-common/src/main/java/org/apache/flink/table/utils/RetractableCollector.java
 ##########
 @@ -16,21 +16,29 @@
  * limitations under the License.
  */
 
-package org.apache.flink.table.sinks
+package org.apache.flink.table.utils;
 
-import org.apache.flink.streaming.api.datastream.DataStream
-import org.apache.flink.table.api.Table
+import org.apache.flink.annotation.Internal;
+import org.apache.flink.util.Collector;
 
 /**
-  * Defines an external [[TableSink]] to emit streaming [[Table]] with only 
insert changes.
-  *
-  * If the [[Table]] is also modified by update or delete changes, a
-  * [[org.apache.flink.table.api.TableException]] will be thrown.
-  *
-  * @tparam T Type of [[DataStream]] that this [[TableSink]] expects and 
supports.
-  */
-trait AppendStreamTableSink[T] extends StreamTableSink[T] {
+ * Collects a record and forwards it. The collector can output retract 
messages with retract method.
+ * Currently, RetractableCollector is used in TableAggregateFunction.
+ */
+@Internal
+public abstract class RetractableCollector<T> implements Collector<T> {
 
 Review comment:
   RetractableCollector can be declared as an interface

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


> Add FlatAggregate operator to unbounded streaming Table API
> -----------------------------------------------------------
>
>                 Key: FLINK-10977
>                 URL: https://issues.apache.org/jira/browse/FLINK-10977
>             Project: Flink
>          Issue Type: Sub-task
>          Components: Table API &amp; SQL
>            Reporter: sunjincheng
>            Assignee: Hequn Cheng
>            Priority: Major
>              Labels: pull-request-available
>             Fix For: 1.8.0
>
>
> Add FlatAggregate operator to streaming Table API as described in [Google 
> doc|https://docs.google.com/document/d/1tnpxg31EQz2-MEzSotwFzqatsB4rNLz0I-l_vPa5H4Q/edit#heading=h.q23rny2iglsr].
> The usage:
> {code:java}
> val res = tab
> .groupBy('a) // leave out groupBy-clause to define global table aggregates
> .flatAgg(fun: TableAggregateFunction) // output has columns 'a, 'b, 'c
> .select('a, 'c){code}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to