Hi! Window aggregations will only output results when the watermark rises above the end of window. Let's say the end of window is at 00:01, only when recvdTime is larger or equal than 00:06 will this window emit (because there is a 5 minutes out of orderness).
If it is not the case then it indeed seems wired. You can also check the web UI of the job and see if any failures happen. Ravi Sankar Reddy Sangana <ra...@radware.com> 于2021年7月26日周一 下午7:51写道: > Hi Team, > > I am trying to upgrade from 1.7 to 1.13 > > Code in 1.7 > > Schema schema = new Schema(); > schema.rowtime(new Rowtime() > .timestampsFromField("eventTime") > .watermarksPeriodicBounded(3000) > ); > > > Code in 1.13 > > tableEnv.executeSql("CREATE TABLE ORDERS ( " + > "`sid` BIGINT, " + > "`isBot` BOOLEAN, " + > "`botcode` STRING, " + > "`_zpsbd8` INT, " + > "`recvdTime` TIMESTAMP(3), " + > "WATERMARK FOR recvdTime AS recvdTime - INTERVAL '5' MINUTES) " + > "WITH ( " + > "'connector' = 'kafka', " + > "'topic' = 'badbotstream', " + > "'properties.bootstrap.servers' = localhost:9092', " + > "'properties.group.id' = 'testGroup', " + > "'format' = 'json', " + > "'json.fail-on-missing-field' = 'false',\n" + > "'json.ignore-parse-errors' = 'true'" + > " ) "); > > Table result = tableEnv.sqlQuery("SELECT sid, botcode, COUNT(*) as > total_hits, TUMBLE_START(recvdTime, INTERVAL '1' MINUTE) AS fseen from > ORDERS GROUP BY sid, botcode, TUMBLE(recvdTime, INTERVAL '1' MINUTE)"); > DataStream<Row> resultStream = tableEnv.toDataStream(result); > resultStream.writeAsText("/home/ravisankar/test_file.txt"); > > > But no records are getting written into file. Is the both codes are same?? > What else I need to do to group by 1 minute data with 5 minutes out of > orderness? > > > Thanks in Advance > > > Regards, > Ravi Sankar >