Github user eminency commented on a diff in the pull request:
https://github.com/apache/tajo/pull/944#discussion_r56449510
--- Diff:
tajo-catalog/tajo-catalog-server/src/main/java/org/apache/tajo/catalog/store/XMLCatalogSchemaManager.java
---
@@ -675,40 +654,38 @@ protected void validateSQLObject(List<SQLObject>
queries, SQLObject testQuery) {
}
protected void mergeExistQueries(List<SQLObject> queries) {
- for (SQLObject query: queries) {
+ queries.forEach(query -> {
validateSQLObject(queries, query);
-
+
targetStore.addExistQuery(query);
- }
+ });
}
protected void mergeDropStatements(List<SQLObject> queries) {
- for (SQLObject query: queries) {
+ queries.forEach(query -> {
validateSQLObject(queries, query);
-
+
targetStore.addDropStatement(query);
- }
+ });
}
--- End diff --
I think these two methods can be removed and merged as lambda itself unless
it is called from many places.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---