flink-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] fhueske commented on a change in pull request #6621: [FLINK-8686] [sql-client] Limit result size for prototyping modes
Date Mon, 27 Aug 2018 15:38:31 GMT
fhueske commented on a change in pull request #6621:  [FLINK-8686] [sql-client] Limit result
size for prototyping modes
URL: https://github.com/apache/flink/pull/6621#discussion_r213012121
 
 

 ##########
 File path: flink-libraries/flink-sql-client/src/main/java/org/apache/flink/table/client/cli/CliChangelogResultView.java
 ##########
 @@ -133,6 +134,13 @@ protected void refresh() {
 					}
 
 					// update results
+
+					// formatting and printing of rows is expensive in the current implementation,
+					// therefore we limit the maximum number of lines shown in changelog mode to
+					// keep the CLI responsive
+					if (results.size() >= DEFAULT_MAX_ROW_COUNT) {
+						results.remove(0);
 
 Review comment:
   Alternatively, we could delete all entries at once with `ArrayList.removeRange()`

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


With regards,
Apache Git Services

Mime
View raw message