alex-plekhanov commented on code in PR #10175:
URL: https://github.com/apache/ignite/pull/10175#discussion_r949887674


##########
modules/core/src/main/java/org/apache/ignite/internal/processors/query/schema/AbstractSchemaChangeListener.java:
##########
@@ -0,0 +1,119 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.ignite.internal.processors.query.schema;
+
+import java.lang.reflect.Method;
+import java.util.List;
+import org.apache.ignite.internal.cache.query.index.Index;
+import org.apache.ignite.internal.processors.cache.GridCacheContextInfo;
+import org.apache.ignite.internal.processors.query.GridQueryIndexDescriptor;
+import org.apache.ignite.internal.processors.query.GridQueryTypeDescriptor;
+import org.apache.ignite.internal.processors.query.QueryField;
+import org.apache.ignite.spi.systemview.view.SystemView;
+
+/**
+ * Abstract schema change listener with no-op implementation for all calbacks.
+ */
+public abstract class AbstractSchemaChangeListener implements 
SchemaChangeListener {
+    /** {@inheritDoc} */
+    @Override public void onSchemaCreated(String schemaName) {
+        // No-op.
+    }
+
+    /** {@inheritDoc} */
+    @Override public void onSchemaDropped(String schemaName) {
+        // No-op.
+    }
+
+    /** {@inheritDoc} */
+    @Override public void onIndexCreated(
+        String schemaName,
+        String tblName,
+        String idxName,
+        GridQueryIndexDescriptor idxDesc,
+        Index idx
+    ) {
+        // No-op.
+    }
+
+    /** {@inheritDoc} */
+    @Override public void onIndexDropped(String schemaName, String tblName, 
String idxName) {
+        // No-op.
+    }
+
+    /** {@inheritDoc} */
+    @Override public void onIndexRebuildStarted(String schemaName, String 
tblName) {
+        // No-op.
+    }
+
+    /** {@inheritDoc} */
+    @Override public void onIndexRebuildFinished(String schemaName, String 
tblName) {
+        // No-op.
+    }
+
+    /** {@inheritDoc} */
+    @Override public void onSqlTypeCreated(
+        String schemaName,
+        GridQueryTypeDescriptor typeDesc,
+        GridCacheContextInfo<?, ?> cacheInfo
+    ) {
+        // No-op.
+    }
+
+    /** {@inheritDoc} */
+    @Override public void onColumnsAdded(
+        String schemaName,
+        GridQueryTypeDescriptor typeDesc,
+        GridCacheContextInfo<?, ?> cacheInfo,
+        List<QueryField> cols,
+        boolean ifColNotExists
+    ) {
+        // No-op.
+    }
+
+    /** {@inheritDoc} */
+    @Override public void onColumnsDropped(
+        String schemaName,
+        GridQueryTypeDescriptor typeDesc,
+        GridCacheContextInfo<?, ?> cacheInfo,
+        List<String> cols,
+        boolean ifColExists
+    ){
+        // No-op.
+    }
+
+    /** {@inheritDoc} */
+    @Override public void onSqlTypeDropped(
+        String schemaName,
+        GridQueryTypeDescriptor typeDescriptor,
+        boolean destroy,
+        boolean clearIdx

Review Comment:
   clearIdx is redundant



##########
modules/core/src/main/java/org/apache/ignite/internal/processors/query/schema/SchemaChangeListener.java:
##########
@@ -50,26 +52,57 @@ public interface SchemaChangeListener {
      * @param typeDesc Type descriptor.
      * @param cacheInfo Cache info.
      */
-    public void onSqlTypeCreated(String schemaName, GridQueryTypeDescriptor 
typeDesc,
-        GridCacheContextInfo<?, ?> cacheInfo);
+    public void onSqlTypeCreated(
+        String schemaName,
+        GridQueryTypeDescriptor typeDesc,
+        GridCacheContextInfo<?, ?> cacheInfo
+    );
 
     /**
-     * Callback method.
+     * Callback on columns added.
+     *
+     * @param schemaName Schema name.
+     * @param typeDesc Type descriptor.
+     * @param cacheInfo Cache info.
+     * @param cols Added columns' names.
+     */
+    public void onColumnsAdded(
+        String schemaName,
+        GridQueryTypeDescriptor typeDesc,
+        GridCacheContextInfo<?, ?> cacheInfo,
+        List<QueryField> cols
+    );
+
+    /**
+     * Callback on columns dropped.
      *
      * @param schemaName Schema name.
      * @param typeDesc Type descriptor.
      * @param cacheInfo Cache info.
+     * @param cols Dropped columns' names.
      */
-    public void onSqlTypeUpdated(String schemaName, GridQueryTypeDescriptor 
typeDesc,
-        GridCacheContextInfo<?, ?> cacheInfo);
+    public void onColumnsDropped(
+        String schemaName,
+        GridQueryTypeDescriptor typeDesc,
+        GridCacheContextInfo<?, ?> cacheInfo,
+        List<String> cols
+    );
 
     /**
      * Callback method.
      *
      * @param schemaName Schema name.
      * @param typeDesc Type descriptor.
      */
-    public void onSqlTypeDropped(String schemaName, GridQueryTypeDescriptor 
typeDesc);
+    /**
+     * Callback method.

Review Comment:
   Double javadoc



##########
modules/indexing/src/main/java/org/apache/ignite/internal/processors/query/h2/ConnectionManager.java:
##########
@@ -342,4 +343,11 @@ void setH2Serializer(JavaObjectSerializer serializer) {
     public JdbcConnection jdbcConnection() {
         return (JdbcConnection)sysConn;
     }
+
+    /**
+     * @return Current compare mode.
+     */
+    public CompareMode compareMode() {

Review Comment:
   Redundant now



##########
modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/stat/StatisticsViewsTest.java:
##########
@@ -56,21 +52,13 @@ public abstract class StatisticsViewsTest extends 
StatisticsAbstractTest {
      */
     @Test
     public void testConfigurationView() throws Exception {

Review Comment:
   NL is not removed



-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to