This is an automated email from the ASF dual-hosted git repository.

zstan pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/ignite.git


The following commit(s) were added to refs/heads/master by this push:
     new e8f16e03d6f IGNITE-28277 CacheInterceptor need to take into account 
cache keepBinary mode (#12911)
e8f16e03d6f is described below

commit e8f16e03d6fafaa37f607afc5c44d8642bc85b2e
Author: Evgeniy Stanilovskiy <[email protected]>
AuthorDate: Mon Apr 6 14:52:45 2026 +0300

    IGNITE-28277 CacheInterceptor need to take into account cache keepBinary 
mode (#12911)
    
    I make a fix only for calcite related part, honestly - i afraid to make
    an equal changes on h2 related part and prefer to store it - as is. If
    approach is ok - i fill follow up issue for related documentation
    change.
---
 .../jmh/sql/JmhCacheWithInterceptorBenchmark.java  |  82 +++++++
 .../query/calcite/exec/ExecutionServiceImpl.java   |  13 +-
 .../query/calcite/exec/rel/HashJoinNode.java       |   2 +-
 .../query/calcite/exec/rel/ModifyNode.java         |  15 +-
 .../query/calcite/message/QueryStartRequest.java   |  13 +-
 .../processors/query/calcite/CancelTest.java       |   2 +-
 .../CacheWithInterceptorIntegrationTest.java       | 251 +++++++++++++++++++++
 .../tx/TxWithExceptionalInterceptorTest.java       |   9 +-
 .../ignite/testsuites/IntegrationTestSuite.java    |   4 +-
 .../managers/discovery/GridDiscoveryManager.java   |   2 +-
 .../processors/cache/CacheOperationContext.java    |  19 ++
 .../processors/cache/GridCacheAdapter.java         |  22 ++
 .../processors/cache/GridCacheProxyImpl.java       |   4 +-
 .../processors/cache/IgniteInternalCache.java      |   3 +
 .../distributed/dht/atomic/GridDhtAtomicCache.java |   2 +-
 .../CacheContinuousQueryPartitionRecovery.java     |   2 +-
 .../internal/processors/job/GridJobWorker.java     |   2 +-
 .../ignite/internal/util/BasicRateLimiter.java     |   2 +-
 .../org.apache.ignite.plugin.PluginProvider        |   2 +-
 .../binary/CacheKeepBinaryWithInterceptorTest.java |  49 ++--
 .../standbycluster/IgniteStandByClusterTest.java   |   8 +-
 .../processors/cache/SqlFieldsQuerySelfTest.java   |   3 -
 .../processors/query/SqlSystemViewsSelfTest.java   |   2 +-
 .../query/stat/PSUStatisticsTypesTest.java         |   2 +-
 24 files changed, 462 insertions(+), 53 deletions(-)

diff --git 
a/modules/benchmarks/src/main/java/org/apache/ignite/internal/benchmarks/jmh/sql/JmhCacheWithInterceptorBenchmark.java
 
b/modules/benchmarks/src/main/java/org/apache/ignite/internal/benchmarks/jmh/sql/JmhCacheWithInterceptorBenchmark.java
new file mode 100644
index 00000000000..e2cb09afd99
--- /dev/null
+++ 
b/modules/benchmarks/src/main/java/org/apache/ignite/internal/benchmarks/jmh/sql/JmhCacheWithInterceptorBenchmark.java
@@ -0,0 +1,82 @@
+/*
+ * 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.benchmarks.jmh.sql;
+
+import java.util.concurrent.ThreadLocalRandom;
+import java.util.concurrent.TimeUnit;
+import org.apache.ignite.cache.CacheInterceptorAdapter;
+import org.apache.ignite.configuration.CacheConfiguration;
+import org.openjdk.jmh.annotations.Benchmark;
+import org.openjdk.jmh.annotations.BenchmarkMode;
+import org.openjdk.jmh.annotations.Fork;
+import org.openjdk.jmh.annotations.Measurement;
+import org.openjdk.jmh.annotations.Mode;
+import org.openjdk.jmh.annotations.OutputTimeUnit;
+import org.openjdk.jmh.annotations.Param;
+import org.openjdk.jmh.annotations.Scope;
+import org.openjdk.jmh.annotations.State;
+import org.openjdk.jmh.annotations.Warmup;
+import org.openjdk.jmh.runner.Runner;
+import org.openjdk.jmh.runner.options.Options;
+import org.openjdk.jmh.runner.options.OptionsBuilder;
+
+/**
+ * Benchmark cache with interceptor queries.
+ */
+@Fork(1)
+@BenchmarkMode(Mode.Throughput)
+@OutputTimeUnit(TimeUnit.SECONDS)
+@Warmup(iterations = 5, time = 5)
+@Measurement(iterations = 10, time = 5)
+@State(Scope.Benchmark)
+public class JmhCacheWithInterceptorBenchmark extends JmhSqlAbstractBenchmark {
+    /** Query engine. */
+    @Param({"CALCITE"})
+    protected String engine;
+
+    /** Keep binary mode. */
+    @Param({"true", "false"})
+    protected boolean keepBinary;
+
+    /** {@inheritDoc} */
+    @Override protected CacheConfiguration<Integer, Item> cacheConfiguration() 
{
+        return super.cacheConfiguration().setInterceptor(new 
CacheInterceptorAdapter<>());
+    }
+
+    /** Test update operation. */
+    @Benchmark
+    public void update() {
+        int key = ThreadLocalRandom.current().nextInt(KEYS_CNT);
+
+        executeSql("UPDATE CACHE.Item SET fld = fld + 1 WHERE fldIdx=?", key);
+    }
+
+    /**
+     * Run benchmarks.
+     *
+     * @param args Args.
+     * @throws Exception Exception.
+     */
+    public static void main(String[] args) throws Exception {
+        final Options options = new OptionsBuilder()
+            .include(JmhCacheWithInterceptorBenchmark.class.getSimpleName())
+            .build();
+
+        new Runner(options).run();
+    }
+}
diff --git 
a/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/exec/ExecutionServiceImpl.java
 
b/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/exec/ExecutionServiceImpl.java
index 1ff16124e46..497520f96ef 100644
--- 
a/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/exec/ExecutionServiceImpl.java
+++ 
b/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/exec/ExecutionServiceImpl.java
@@ -672,6 +672,9 @@ public class ExecutionServiceImpl<Row> extends 
AbstractService implements Execut
                     try {
                         SessionContextImpl sesCtx = 
qry.context().unwrap(SessionContextImpl.class);
 
+                        QueryProperties props = 
qry.context().unwrap(QueryProperties.class);
+                        boolean keepBinaryMode = props == null || 
props.keepBinary();
+
                         QueryStartRequest req = new QueryStartRequest(
                             qry.id(),
                             qry.localQueryId(),
@@ -684,7 +687,8 @@ public class ExecutionServiceImpl<Row> extends 
AbstractService implements Execut
                             parametersMarshalled,
                             timeout,
                             ectx.getQryTxEntries(),
-                            sesCtx == null ? null : sesCtx.attributes()
+                            sesCtx == null ? null : sesCtx.attributes(),
+                            keepBinaryMode
                         );
 
                         messageService().send(nodeId, req);
@@ -881,8 +885,13 @@ public class ExecutionServiceImpl<Row> extends 
AbstractService implements Execut
                 )
             );
 
+            boolean keepBinaryMode = msg.keepBinaryMode();
+            QueryProperties qryProps = new QueryProperties(null, 
keepBinaryMode, false);
+
             final BaseQueryContext qctx = createQueryContext(
-                msg.applicationAttributes() == null ? Contexts.empty() : 
Contexts.of(new SessionContextImpl(msg.applicationAttributes())),
+                msg.applicationAttributes() == null ?
+                    Contexts.of(qryProps) :
+                    Contexts.of(new 
SessionContextImpl(msg.applicationAttributes()), qryProps),
                 msg.schema());
 
             FragmentPlan fragmentPlan = 
fragmentPlanCache.computeIfAbsent(msg.root(), k -> prepareFragment(qctx, k));
diff --git 
a/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/exec/rel/HashJoinNode.java
 
b/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/exec/rel/HashJoinNode.java
index c3731b26037..0158abb25b0 100644
--- 
a/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/exec/rel/HashJoinNode.java
+++ 
b/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/exec/rel/HashJoinNode.java
@@ -394,7 +394,7 @@ public abstract class HashJoinNode<Row> extends 
AbstractRightMaterializedJoinNod
         private void downstreamPush(Row left, Row right) throws Exception {
             requested--;
 
-            downstream().push(outRowFactory.apply(left, right));;
+            downstream().push(outRowFactory.apply(left, right));
         }
 
         /** {@inheritDoc} */
diff --git 
a/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/exec/rel/ModifyNode.java
 
b/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/exec/rel/ModifyNode.java
index 650a775514d..76220c84251 100644
--- 
a/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/exec/rel/ModifyNode.java
+++ 
b/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/exec/rel/ModifyNode.java
@@ -31,9 +31,10 @@ import org.apache.calcite.rel.type.RelDataType;
 import org.apache.ignite.IgniteCheckedException;
 import org.apache.ignite.internal.cache.context.SessionContextImpl;
 import org.apache.ignite.internal.processors.cache.GridCacheContext;
-import org.apache.ignite.internal.processors.cache.GridCacheProxyImpl;
+import org.apache.ignite.internal.processors.cache.IgniteInternalCache;
 import 
org.apache.ignite.internal.processors.cache.distributed.near.GridNearTxLocal;
 import org.apache.ignite.internal.processors.query.IgniteSQLException;
+import org.apache.ignite.internal.processors.query.QueryProperties;
 import 
org.apache.ignite.internal.processors.query.calcite.exec.ExecutionContext;
 import 
org.apache.ignite.internal.processors.query.calcite.schema.CacheTableDescriptor;
 import org.apache.ignite.internal.processors.query.calcite.schema.ModifyTuple;
@@ -200,9 +201,15 @@ public class ModifyNode<Row> extends AbstractNode<Row> 
implements SingleNode<Row
         this.tuples = new ArrayList<>(MODIFY_BATCH_SIZE);
 
         GridCacheContext<Object, Object> cctx = desc.cacheContext();
-        GridCacheProxyImpl<Object, Object> cache = cctx.cache().keepBinary();
+        IgniteInternalCache<Object, Object> cache = cctx.cache();
         GridNearTxLocal tx = Commons.queryTransaction(context(), 
cctx.shared());
 
+        QueryProperties props = context().unwrap(QueryProperties.class);
+        boolean keepBinaryMode = props == null || props.keepBinary();
+
+        if (keepBinaryMode)
+            cache = cache.keepBinary();
+
         if (tx == null)
             invokeOutsideTransaction(tuples, cache);
         else
@@ -217,7 +224,7 @@ public class ModifyNode<Row> extends AbstractNode<Row> 
implements SingleNode<Row
      */
     private void invokeOutsideTransaction(
         List<ModifyTuple> tuples,
-        GridCacheProxyImpl<Object, Object> cache
+        IgniteInternalCache<Object, Object> cache
     ) throws IgniteCheckedException {
         SessionContextImpl sesCtx = context().unwrap(SessionContextImpl.class);
         Map<String, String> sesAttrs = sesCtx == null ? null : 
sesCtx.attributes();
@@ -251,7 +258,7 @@ public class ModifyNode<Row> extends AbstractNode<Row> 
implements SingleNode<Row
      */
     private void invokeInsideTransaction(
         List<ModifyTuple> tuples,
-        GridCacheProxyImpl<Object, Object> cache,
+        IgniteInternalCache<Object, Object> cache,
         GridNearTxLocal userTx
     ) throws IgniteCheckedException {
         userTx.resume();
diff --git 
a/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/message/QueryStartRequest.java
 
b/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/message/QueryStartRequest.java
index fe45e12a1c8..bc0817f2473 100644
--- 
a/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/message/QueryStartRequest.java
+++ 
b/modules/calcite/src/main/java/org/apache/ignite/internal/processors/query/calcite/message/QueryStartRequest.java
@@ -79,6 +79,10 @@ public class QueryStartRequest implements 
CalciteMarshalableMessage, ExecutionCo
     @Order(10)
     @Nullable Map<String, String> appAttrs;
 
+    /** */
+    @Order(11)
+    boolean keepBinaryMode;
+
     /** */
     @SuppressWarnings("AssignmentOrReturnOfFieldWithMutableType")
     public QueryStartRequest(
@@ -93,7 +97,8 @@ public class QueryStartRequest implements 
CalciteMarshalableMessage, ExecutionCo
         @Nullable byte[] paramsBytes,
         long timeout,
         @Nullable Collection<QueryTxEntry> qryTxEntries,
-        @Nullable Map<String, String> appAttrs
+        @Nullable Map<String, String> appAttrs,
+        boolean keepBinaryMode
     ) {
         this.qryId = qryId;
         this.originatingQryId = originatingQryId;
@@ -107,6 +112,7 @@ public class QueryStartRequest implements 
CalciteMarshalableMessage, ExecutionCo
         this.timeout = timeout;
         this.qryTxEntries = qryTxEntries;
         this.appAttrs = appAttrs;
+        this.keepBinaryMode = keepBinaryMode;
     }
 
     /** */
@@ -199,6 +205,11 @@ public class QueryStartRequest implements 
CalciteMarshalableMessage, ExecutionCo
         return appAttrs;
     }
 
+    /** */
+    public boolean keepBinaryMode() {
+        return keepBinaryMode;
+    }
+
     /** {@inheritDoc} */
     @Override public void prepareMarshal(GridCacheSharedContext<?, ?> ctx) 
throws IgniteCheckedException {
         if (paramsBytes == null && params != null)
diff --git 
a/modules/calcite/src/test/java/org/apache/ignite/internal/processors/query/calcite/CancelTest.java
 
b/modules/calcite/src/test/java/org/apache/ignite/internal/processors/query/calcite/CancelTest.java
index 77e8dc5f0fd..4e78cbe40fd 100644
--- 
a/modules/calcite/src/test/java/org/apache/ignite/internal/processors/query/calcite/CancelTest.java
+++ 
b/modules/calcite/src/test/java/org/apache/ignite/internal/processors/query/calcite/CancelTest.java
@@ -72,7 +72,7 @@ public class CancelTest extends GridCommonAbstractTest {
             .setKeyFieldName("id")
             .setValueFieldName("val")
             .addQueryField("id", Integer.class.getName(), null)
-            .addQueryField("val", String.class.getName(), null);;
+            .addQueryField("val", String.class.getName(), null);
 
         return super.getConfiguration(igniteInstanceName)
             .setCacheConfiguration(
diff --git 
a/modules/calcite/src/test/java/org/apache/ignite/internal/processors/query/calcite/integration/CacheWithInterceptorIntegrationTest.java
 
b/modules/calcite/src/test/java/org/apache/ignite/internal/processors/query/calcite/integration/CacheWithInterceptorIntegrationTest.java
new file mode 100644
index 00000000000..94342b8d588
--- /dev/null
+++ 
b/modules/calcite/src/test/java/org/apache/ignite/internal/processors/query/calcite/integration/CacheWithInterceptorIntegrationTest.java
@@ -0,0 +1,251 @@
+/*
+ * 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.calcite.integration;
+
+import java.util.Collection;
+import java.util.List;
+import javax.cache.Cache;
+import org.apache.ignite.IgniteCache;
+import org.apache.ignite.binary.BinaryObject;
+import org.apache.ignite.cache.CacheInterceptorAdapter;
+import org.apache.ignite.cache.QueryEntity;
+import org.apache.ignite.cache.query.SqlFieldsQuery;
+import org.apache.ignite.cache.query.annotations.QuerySqlField;
+import org.apache.ignite.calcite.CalciteQueryEngineConfiguration;
+import org.apache.ignite.configuration.CacheConfiguration;
+import org.apache.ignite.configuration.IgniteConfiguration;
+import org.apache.ignite.configuration.SqlConfiguration;
+import org.apache.ignite.configuration.TransactionConfiguration;
+import org.apache.ignite.internal.IgniteEx;
+import org.apache.ignite.lang.IgniteBiTuple;
+import org.apache.ignite.testframework.junits.common.GridCommonAbstractTest;
+import org.apache.ignite.transactions.Transaction;
+import org.jetbrains.annotations.Nullable;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.junit.runners.Parameterized;
+
+import static org.apache.ignite.cache.CacheAtomicityMode.ATOMIC;
+import static org.apache.ignite.cache.CacheAtomicityMode.TRANSACTIONAL;
+import static 
org.apache.ignite.transactions.TransactionConcurrency.PESSIMISTIC;
+import static 
org.apache.ignite.transactions.TransactionIsolation.READ_COMMITTED;
+
+/** Cache interceptor related tests. */
+@RunWith(Parameterized.class)
+public class CacheWithInterceptorIntegrationTest extends 
GridCommonAbstractTest {
+    /** Keep binary mode. */
+    @Parameterized.Parameter(0)
+    public boolean keepBinary;
+
+    /** */
+    @Parameterized.Parameters(name = "keepBinary={0}")
+    public static Collection<?> parameters() {
+        return List.of(true, false);
+    }
+
+    /** {@inheritDoc} */
+    @Override protected void afterTest() throws Exception {
+        super.afterTest();
+
+        stopAllGrids(true);
+    }
+
+    /** {@inheritDoc} */
+    @Override protected IgniteConfiguration getConfiguration(String 
igniteInstanceName) throws Exception {
+        var entity0 = new QueryEntity()
+            .setTableName("Pure")
+            .setKeyType(Integer.class.getName())
+            .setValueType(String.class.getName())
+            .addQueryField("id", Integer.class.getName(), null)
+            .addQueryField("name", String.class.getName(), null)
+            .setKeyFieldName("id")
+            .setValueFieldName("name");
+
+        var entity1 = new QueryEntity()
+            .setTableName("Complex")
+            .setKeyType(Integer.class.getName())
+            .setValueType("ComplexKey")
+            .addQueryField("id", Integer.class.getName(), null)
+            .addQueryField("name", String.class.getName(), null)
+            .addQueryField("val", Integer.class.getName(), null)
+            .setKeyFieldName("id");
+
+        var personCfg = new CacheConfiguration<Integer, Object>("person")
+            .setAtomicityMode(TRANSACTIONAL)
+            .setSqlSchema("PUBLIC")
+            .setInterceptor(new TestCacheInterceptor(keepBinary))
+            .setQueryEntities(List.of(new QueryEntity(Integer.class, 
Person.class)
+                .setTableName("PERSON")
+                .addQueryField("ID", Integer.class.getName(), null)
+                .addQueryField("CITYID", Integer.class.getName(), "city_id")
+                .setKeyFieldName("ID")
+            ));
+
+        var personAtomicCfg = new CacheConfiguration<Integer, 
Object>("personAtomic")
+            .setAtomicityMode(ATOMIC)
+            .setSqlSchema("PUBLIC")
+            .setInterceptor(new TestCacheInterceptor(keepBinary))
+            .setQueryEntities(List.of(new QueryEntity(Integer.class, 
Person.class)
+                .setTableName("PERSON_ATOMIC")
+                .addQueryField("ID", Integer.class.getName(), null)
+                .addQueryField("CITYID", Integer.class.getName(), "city_id")
+                .setKeyFieldName("ID")
+            ));
+
+        var cityCfg = new CacheConfiguration<Integer, Object>("city")
+            .setAtomicityMode(TRANSACTIONAL)
+            .setSqlSchema("PUBLIC")
+            .setInterceptor(new TestCacheInterceptor(keepBinary))
+            .setQueryEntities(List.of(new QueryEntity(Integer.class, 
City.class)
+                .setTableName("CITY")
+                .addQueryField("ID", Integer.class.getName(), null)
+                .setKeyFieldName("ID")
+            ));
+
+        var pureCacheCfg = new CacheConfiguration<Integer, Object>("pure")
+            .setAtomicityMode(TRANSACTIONAL)
+            .setSqlSchema("PUBLIC")
+            .setInterceptor(new TestCacheInterceptor(false))
+            .setQueryEntities(List.of(entity0));
+
+        var complexCacheCfg = new CacheConfiguration<Integer, 
Object>("complex")
+            .setAtomicityMode(TRANSACTIONAL)
+            .setSqlSchema("PUBLIC")
+            .setQueryEntities(List.of(entity1));
+
+        var calciteQryEngineCfg = new 
CalciteQueryEngineConfiguration().setDefault(true);
+
+        return super.getConfiguration(igniteInstanceName)
+            .setSqlConfiguration(new 
SqlConfiguration().setQueryEnginesConfiguration(calciteQryEngineCfg))
+            .setTransactionConfiguration(new 
TransactionConfiguration().setTxAwareQueriesEnabled(true))
+            .setCacheConfiguration(pureCacheCfg, cityCfg, personCfg, 
personAtomicCfg, complexCacheCfg);
+    }
+
+    /** Test object unwrapped on interceptor side if applicable. */
+    @Test
+    public void testInterceptorUnwrapValIfNeeded() throws Exception {
+        startGrid(0);
+        IgniteEx client = startClientGrid("client");
+
+        IgniteCache<Object, Object> cache = client.getOrCreateCache(new 
CacheConfiguration<>(DEFAULT_CACHE_NAME)
+            .setAtomicityMode(TRANSACTIONAL));
+
+        if (keepBinary)
+            cache = cache.withKeepBinary();
+
+        try (Transaction tx = client.transactions().txStart(PESSIMISTIC, 
READ_COMMITTED)) {
+            cache.query(new SqlFieldsQuery("INSERT INTO PURE(id, name) VALUES 
(1, 'val')")).getAll();
+            cache.query(new SqlFieldsQuery("UPDATE PURE SET name = '' WHERE id 
= 1")).getAll();
+            cache.query(new SqlFieldsQuery("DELETE FROM PURE WHERE id = 
1")).getAll();
+
+            cache.query(new SqlFieldsQuery("INSERT INTO COMPLEX(id, name) 
VALUES (1, 'val')")).getAll();
+            cache.query(new SqlFieldsQuery("UPDATE COMPLEX SET name = '' WHERE 
id = 1")).getAll();
+            cache.query(new SqlFieldsQuery("DELETE FROM COMPLEX WHERE id = 
1")).getAll();
+
+            cache.query(new SqlFieldsQuery("INSERT INTO CITY(id, name) VALUES 
(1, 'val')")).getAll();
+            cache.query(new SqlFieldsQuery("UPDATE CITY SET name = '' WHERE id 
= 1")).getAll();
+            cache.query(new SqlFieldsQuery("DELETE FROM CITY WHERE id = 
1")).getAll();
+
+            cache.query(new SqlFieldsQuery("INSERT INTO PERSON(id, name, 
city_id) VALUES (1, 'val', 1)")).getAll();
+            cache.query(new SqlFieldsQuery("UPDATE PERSON SET name = '' WHERE 
id = 1")).getAll();
+            cache.query(new SqlFieldsQuery("DELETE FROM PERSON WHERE id = 
1")).getAll();
+
+            tx.commit();
+        }
+
+        cache.query(new SqlFieldsQuery("INSERT INTO PURE(id, name) VALUES (1, 
'val')")).getAll();
+        cache.query(new SqlFieldsQuery("UPDATE PURE SET name = '' WHERE id = 
1")).getAll();
+        cache.query(new SqlFieldsQuery("DELETE FROM PURE WHERE id = 
1")).getAll();
+
+        cache.query(new SqlFieldsQuery("INSERT INTO COMPLEX(id, name) VALUES 
(1, 'val')")).getAll();
+        cache.query(new SqlFieldsQuery("UPDATE COMPLEX SET name = '' WHERE id 
= 1")).getAll();
+        cache.query(new SqlFieldsQuery("DELETE FROM COMPLEX WHERE id = 
1")).getAll();
+
+        cache.query(new SqlFieldsQuery("INSERT INTO CITY(id, name) VALUES (1, 
'val')")).getAll();
+        cache.query(new SqlFieldsQuery("UPDATE CITY SET name = '' WHERE id = 
1")).getAll();
+        cache.query(new SqlFieldsQuery("DELETE FROM CITY WHERE id = 
1")).getAll();
+
+        cache.query(new SqlFieldsQuery("INSERT INTO PERSON(id, name, city_id) 
VALUES (1, 'val', 1)")).getAll();
+        cache.query(new SqlFieldsQuery("UPDATE PERSON SET name = 'a' WHERE id 
= 1")).getAll();
+        cache.query(new SqlFieldsQuery("DELETE FROM PERSON WHERE id = 
1")).getAll();
+
+        cache.query(new SqlFieldsQuery("INSERT INTO PERSON_ATOMIC(id, name, 
city_id) VALUES (1, 'val', 1)")).getAll();
+        cache.query(new SqlFieldsQuery("UPDATE PERSON_ATOMIC SET name = '' 
WHERE id = 1")).getAll();
+        cache.query(new SqlFieldsQuery("DELETE FROM PERSON_ATOMIC WHERE id = 
1")).getAll();
+    }
+
+    /** */
+    private static class City {
+        /** */
+        @QuerySqlField
+        String name;
+
+        /** */
+        City(String name) {
+            this.name = name;
+        }
+    }
+
+    /** */
+    private static class Person {
+        /** */
+        @QuerySqlField
+        String name;
+
+        /** */
+        @QuerySqlField
+        int cityId;
+
+        /** */
+        Person(String name, int cityId) {
+            this.name = name;
+            this.cityId = cityId;
+        }
+    }
+
+    /** */
+    private static class TestCacheInterceptor extends 
CacheInterceptorAdapter<Integer, Object> {
+        /** */
+        private final boolean keepBinary;
+
+        /**
+         * @param keepBinary Keep binary defines flag.
+         */
+        TestCacheInterceptor(boolean keepBinary) {
+            this.keepBinary = keepBinary;
+        }
+
+        /** {@inheritDoc} */
+        @Override public @Nullable Object onBeforePut(Cache.Entry<Integer, 
Object> entry, Object newVal) {
+            assertEquals(keepBinary, newVal instanceof BinaryObject);
+
+            return newVal;
+        }
+
+        /** {@inheritDoc} */
+        @Nullable @Override public IgniteBiTuple<Boolean, Object> 
onBeforeRemove(Cache.Entry<Integer, Object> entry) {
+            Object val = entry.getValue();
+
+            if (val != null) {
+                assertEquals(keepBinary, entry.getValue() instanceof 
BinaryObject);
+            }
+
+            return new IgniteBiTuple<>(false, val);
+        }
+    }
+}
diff --git 
a/modules/calcite/src/test/java/org/apache/ignite/internal/processors/tx/TxWithExceptionalInterceptorTest.java
 
b/modules/calcite/src/test/java/org/apache/ignite/internal/processors/tx/TxWithExceptionalInterceptorTest.java
index b3aa281a82b..2c824f64fa9 100644
--- 
a/modules/calcite/src/test/java/org/apache/ignite/internal/processors/tx/TxWithExceptionalInterceptorTest.java
+++ 
b/modules/calcite/src/test/java/org/apache/ignite/internal/processors/tx/TxWithExceptionalInterceptorTest.java
@@ -107,8 +107,6 @@ public class TxWithExceptionalInterceptorTest extends 
GridCommonAbstractTest {
     @Override protected void beforeTest() throws Exception {
         super.beforeTest();
 
-        stopAllGrids();
-
         if (persistence)
             cleanPersistenceDir();
 
@@ -117,6 +115,13 @@ public class TxWithExceptionalInterceptorTest extends 
GridCommonAbstractTest {
         exceptionRaised.set(0);
     }
 
+    /** {@inheritDoc} */
+    @Override protected void afterTest() throws Exception {
+        super.afterTest();
+
+        stopAllGrids(true);
+    }
+
     /** */
     private static class FilterDefinedNode implements 
IgnitePredicate<ClusterNode> {
         /** */
diff --git 
a/modules/calcite/src/test/java/org/apache/ignite/testsuites/IntegrationTestSuite.java
 
b/modules/calcite/src/test/java/org/apache/ignite/testsuites/IntegrationTestSuite.java
index 9326c647854..ccba0615464 100644
--- 
a/modules/calcite/src/test/java/org/apache/ignite/testsuites/IntegrationTestSuite.java
+++ 
b/modules/calcite/src/test/java/org/apache/ignite/testsuites/IntegrationTestSuite.java
@@ -28,6 +28,7 @@ import 
org.apache.ignite.internal.processors.query.calcite.SqlFieldsQueryUsageTe
 import 
org.apache.ignite.internal.processors.query.calcite.integration.AggregatesIntegrationTest;
 import 
org.apache.ignite.internal.processors.query.calcite.integration.AuthorizationIntegrationTest;
 import 
org.apache.ignite.internal.processors.query.calcite.integration.CacheStoreTest;
+import 
org.apache.ignite.internal.processors.query.calcite.integration.CacheWithInterceptorIntegrationTest;
 import 
org.apache.ignite.internal.processors.query.calcite.integration.CalciteBasicSecondaryIndexIntegrationTest;
 import 
org.apache.ignite.internal.processors.query.calcite.integration.CalciteErrorHandlilngIntegrationTest;
 import 
org.apache.ignite.internal.processors.query.calcite.integration.CalcitePlanningDumpTest;
@@ -174,7 +175,8 @@ import org.junit.runners.Suite;
     QueryEntityValueColumnAliasTest.class,
     CacheStoreTest.class,
     MultiDcQueryMappingTest.class,
-    TxWithExceptionalInterceptorTest.class
+    TxWithExceptionalInterceptorTest.class,
+    CacheWithInterceptorIntegrationTest.class,
 })
 public class IntegrationTestSuite {
 }
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/managers/discovery/GridDiscoveryManager.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/managers/discovery/GridDiscoveryManager.java
index 91825fd876a..119d53d7847 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/managers/discovery/GridDiscoveryManager.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/managers/discovery/GridDiscoveryManager.java
@@ -3062,7 +3062,7 @@ public class GridDiscoveryManager extends 
GridManagerAdapter<DiscoverySpi> {
                     evt.message("Client node reconnected");
 
                 else
-                    assert false : "Unexpected discovery message type: " + 
type;;
+                    assert false : "Unexpected discovery message type: " + 
type;
 
                 ctx.event().record(evt, discoCache);
             }
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheOperationContext.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheOperationContext.java
index e701ae5a93f..b6470c60edc 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheOperationContext.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/CacheOperationContext.java
@@ -18,6 +18,7 @@
 package org.apache.ignite.internal.processors.cache;
 
 import java.io.Serializable;
+import java.util.Collections;
 import java.util.HashMap;
 import java.util.Map;
 import javax.cache.expiry.ExpiryPolicy;
@@ -181,6 +182,24 @@ public class CacheOperationContext implements Serializable 
{
         return skipReadThrough;
     }
 
+    /**
+     * See {@link IgniteInternalCache#withApplicationAttributes(Map)}.
+     *
+     * @return New instance of CacheOperationContext with new application 
attributes.
+     */
+    public CacheOperationContext withApplicationAttributes(Map<String, String> 
attrs) {
+        return new CacheOperationContext(
+            skipStore,
+            skipReadThrough,
+            keepBinary,
+            expiryPlc,
+            noRetries,
+            dataCenterId,
+            recovery,
+            readRepairStrategy,
+            Collections.unmodifiableMap(attrs));
+    }
+
     /**
      * See {@link IgniteInternalCache#withSkipReadThrough()}.
      *
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
index b13161079eb..5c91859b1dc 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheAdapter.java
@@ -504,6 +504,28 @@ public abstract class GridCacheAdapter<K, V> implements 
IgniteInternalCache<K, V
         return new GridCacheProxyImpl<>(this.ctx, this, opCtx);
     }
 
+    /** @return New internal cache instance based on this one, but with 
application attributes. */
+    @Override public GridCacheProxyImpl<K, V> 
withApplicationAttributes(Map<String, String> attrs) {
+        CacheOperationContext opCtx = ctx.operationContextPerCall();
+
+        if (opCtx == null) {
+            opCtx = new CacheOperationContext(
+                false,
+                false,
+                false,
+                null,
+                false,
+                null,
+                false,
+                null,
+                new HashMap<>(attrs));
+        }
+        else
+            opCtx = opCtx.withApplicationAttributes(attrs);
+
+        return new GridCacheProxyImpl<>(ctx, this, opCtx);
+    }
+
     /** {@inheritDoc} */
     @Override public final <K1, V1> GridCacheProxyImpl<K1, V1> keepBinary() {
         CacheOperationContext opCtx = new CacheOperationContext(
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProxyImpl.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProxyImpl.java
index 4c51863f393..d06f64e039a 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProxyImpl.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/GridCacheProxyImpl.java
@@ -303,7 +303,7 @@ public class GridCacheProxyImpl<K, V> implements 
IgniteInternalCache<K, V>, Exte
     }
 
     /** @return New internal cache instance based on this one, but with 
application attributes. */
-    public GridCacheProxyImpl<K, V> withApplicationAttributes(Map<String, 
String> attrs) {
+    @Override public GridCacheProxyImpl<K, V> 
withApplicationAttributes(Map<String, String> attrs) {
         CacheOperationContext prev = gate.enter(opCtx);
 
         try {
@@ -311,7 +311,7 @@ public class GridCacheProxyImpl<K, V> implements 
IgniteInternalCache<K, V>, Exte
                 opCtx != null ? opCtx.setApplicationAttributes(attrs) :
                     new CacheOperationContext(
                         false,
-                        true,
+                        false,
                         false,
                         null,
                         false,
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/IgniteInternalCache.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/IgniteInternalCache.java
index f5b50d8f035..50bdf4efe97 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/IgniteInternalCache.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/IgniteInternalCache.java
@@ -230,6 +230,9 @@ public interface IgniteInternalCache<K, V> extends 
Iterable<Cache.Entry<K, V>> {
     /** @return New internal cache instance based on this one, but with skip 
read-through cache store flag enabled. */
     public IgniteInternalCache<K, V> withSkipReadThrough();
 
+    /** @return New internal cache instance based on this one, but with 
application attributes. */
+    public IgniteInternalCache<K, V> withApplicationAttributes(Map<String, 
String> attrs);
+
     /**
      * Creates projection that will operate with binary objects.
      * <p>
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/atomic/GridDhtAtomicCache.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/atomic/GridDhtAtomicCache.java
index 919199ec48c..0a4ace04892 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/atomic/GridDhtAtomicCache.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/distributed/dht/atomic/GridDhtAtomicCache.java
@@ -1805,7 +1805,7 @@ public class GridDhtAtomicCache<K, V> extends 
GridDhtCacheAdapter<K, V> {
 
             // If batch store update is enabled, we need to lock all entries.
             // First, need to acquire locks on cache entries, then check 
filter.
-            List<GridDhtCacheEntry> locked = lockEntries(req, 
req.topologyVersion());;
+            List<GridDhtCacheEntry> locked = lockEntries(req, 
req.topologyVersion());
 
             Collection<IgniteBiTuple<GridDhtCacheEntry, GridCacheVersion>> 
deleted = null;
 
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/continuous/CacheContinuousQueryPartitionRecovery.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/continuous/CacheContinuousQueryPartitionRecovery.java
index 0b43c82188d..a2b68210980 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/continuous/CacheContinuousQueryPartitionRecovery.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/cache/query/continuous/CacheContinuousQueryPartitionRecovery.java
@@ -227,7 +227,7 @@ class CacheContinuousQueryPartitionRecovery {
 
                     long filtered = pending.filteredCount();
 
-                    boolean fire = e.getKey() == lastFiredEvt + 1;;
+                    boolean fire = e.getKey() == lastFiredEvt + 1;
 
                     if (!fire && filtered > 0)
                         fire = e.getKey() - filtered <= lastFiredEvt + 1;
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/job/GridJobWorker.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/job/GridJobWorker.java
index b59fd5b15da..1ab5b7f1e4f 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/processors/job/GridJobWorker.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/processors/job/GridJobWorker.java
@@ -543,7 +543,7 @@ public class GridJobWorker extends GridWorker implements 
GridTimeoutObject {
                     IgniteException ex = new IgniteException("Failed to lock 
partitions " +
                         "[jobId=" + ses.getJobId() + ", ses=" + ses + ']', e);
 
-                    U.error(log, "Failed to lock partitions [jobId=" + 
ses.getJobId() + ", ses=" + ses + ']', e);;
+                    U.error(log, "Failed to lock partitions [jobId=" + 
ses.getJobId() + ", ses=" + ses + ']', e);
 
                     finishJob(null, ex, true);
 
diff --git 
a/modules/core/src/main/java/org/apache/ignite/internal/util/BasicRateLimiter.java
 
b/modules/core/src/main/java/org/apache/ignite/internal/util/BasicRateLimiter.java
index 861c72a27e0..d70c2846bf2 100644
--- 
a/modules/core/src/main/java/org/apache/ignite/internal/util/BasicRateLimiter.java
+++ 
b/modules/core/src/main/java/org/apache/ignite/internal/util/BasicRateLimiter.java
@@ -171,7 +171,7 @@ public class BasicRateLimiter {
             long idleTime = passed - nextFreeTicketNanos;
 
             // This is the number of permits we can give for free because 
we've been inactive longer than expected.
-            storedPermits = idleTime > MAX_IDLE_TIMEOUT ? 0 : min(getRate(), 
storedPermits + (idleTime / stableIntervalNanos));;
+            storedPermits = idleTime > MAX_IDLE_TIMEOUT ? 0 : min(getRate(), 
storedPermits + (idleTime / stableIntervalNanos));
 
             nextFreeTicketNanos = passed;
         }
diff --git 
a/modules/core/src/test/java/META-INF/services/org.apache.ignite.plugin.PluginProvider
 
b/modules/core/src/test/java/META-INF/services/org.apache.ignite.plugin.PluginProvider
index 7704c0b7490..b243818255b 100644
--- 
a/modules/core/src/test/java/META-INF/services/org.apache.ignite.plugin.PluginProvider
+++ 
b/modules/core/src/test/java/META-INF/services/org.apache.ignite.plugin.PluginProvider
@@ -1,4 +1,4 @@
-org.apache.ignite.internal.processors.cache.persistence.standbycluster.IgniteStandByClusterTest$StanByClusterTestProvider
+org.apache.ignite.internal.processors.cache.persistence.standbycluster.IgniteStandByClusterTest$StandByClusterTestProvider
 
org.apache.ignite.internal.processors.cache.persistence.wal.memtracker.PageMemoryTrackerPluginProvider
 
org.apache.ignite.internal.processors.configuration.distributed.TestDistibutedConfigurationPlugin
 org.apache.ignite.plugin.NodeValidationPluginProvider
diff --git 
a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/binary/CacheKeepBinaryWithInterceptorTest.java
 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/binary/CacheKeepBinaryWithInterceptorTest.java
index 4a7b4ac9bd2..d2385432768 100644
--- 
a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/binary/CacheKeepBinaryWithInterceptorTest.java
+++ 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/binary/CacheKeepBinaryWithInterceptorTest.java
@@ -73,11 +73,11 @@ public class CacheKeepBinaryWithInterceptorTest extends 
GridCommonAbstractTest {
         ignite(0).createCache(ccfg);
 
         try {
-            TestInterceptor1.onAfterRmv = 0;
-            TestInterceptor1.onBeforeRmv = 0;
-            TestInterceptor1.onAfterPut = 0;
-            TestInterceptor1.onBeforePut = 0;
-            TestInterceptor1.onGet = 0;
+            TestBOInterceptor.onAfterRmv = 0;
+            TestBOInterceptor.onBeforeRmv = 0;
+            TestBOInterceptor.onAfterPut = 0;
+            TestBOInterceptor.onBeforePut = 0;
+            TestBOInterceptor.onGet = 0;
 
             IgniteCache cache = 
ignite(0).cache(DEFAULT_CACHE_NAME).withKeepBinary();
 
@@ -106,11 +106,11 @@ public class CacheKeepBinaryWithInterceptorTest extends 
GridCommonAbstractTest {
 
             assertTrue(cache.remove(new TestKey(1)));
 
-            assertTrue(TestInterceptor1.onAfterRmv > 0);
-            assertTrue(TestInterceptor1.onBeforeRmv > 0);
-            assertTrue(TestInterceptor1.onAfterPut > 0);
-            assertTrue(TestInterceptor1.onBeforePut > 0);
-            assertTrue(TestInterceptor1.onGet > 0);
+            assertTrue(TestBOInterceptor.onAfterRmv > 0);
+            assertTrue(TestBOInterceptor.onBeforeRmv > 0);
+            assertTrue(TestBOInterceptor.onAfterPut > 0);
+            assertTrue(TestBOInterceptor.onBeforePut > 0);
+            assertTrue(TestBOInterceptor.onGet > 0);
         }
         finally {
             ignite(0).destroyCache(ccfg.getName());
@@ -124,11 +124,11 @@ public class CacheKeepBinaryWithInterceptorTest extends 
GridCommonAbstractTest {
         ignite(0).createCache(ccfg);
 
         try {
-            TestInterceptor2.onAfterRmv = 0;
-            TestInterceptor2.onBeforeRmv = 0;
-            TestInterceptor2.onAfterPut = 0;
-            TestInterceptor2.onBeforePut = 0;
-            TestInterceptor2.onGet = 0;
+            TestTypeSpecifiedInterceptor.onAfterRmv = 0;
+            TestTypeSpecifiedInterceptor.onBeforeRmv = 0;
+            TestTypeSpecifiedInterceptor.onAfterPut = 0;
+            TestTypeSpecifiedInterceptor.onBeforePut = 0;
+            TestTypeSpecifiedInterceptor.onGet = 0;
 
             IgniteCache cache = 
ignite(0).cache(DEFAULT_CACHE_NAME).withKeepBinary();
 
@@ -157,11 +157,11 @@ public class CacheKeepBinaryWithInterceptorTest extends 
GridCommonAbstractTest {
 
             assertTrue(cache.remove(1));
 
-            assertTrue(TestInterceptor2.onAfterRmv > 0);
-            assertTrue(TestInterceptor2.onBeforeRmv > 0);
-            assertTrue(TestInterceptor2.onAfterPut > 0);
-            assertTrue(TestInterceptor2.onBeforePut > 0);
-            assertTrue(TestInterceptor2.onGet > 0);
+            assertTrue(TestTypeSpecifiedInterceptor.onAfterRmv > 0);
+            assertTrue(TestTypeSpecifiedInterceptor.onBeforeRmv > 0);
+            assertTrue(TestTypeSpecifiedInterceptor.onAfterPut > 0);
+            assertTrue(TestTypeSpecifiedInterceptor.onBeforePut > 0);
+            assertTrue(TestTypeSpecifiedInterceptor.onGet > 0);
         }
         finally {
             ignite(0).destroyCache(ccfg.getName());
@@ -177,7 +177,7 @@ public class CacheKeepBinaryWithInterceptorTest extends 
GridCommonAbstractTest {
         CacheConfiguration ccfg = new CacheConfiguration(DEFAULT_CACHE_NAME);
 
         ccfg.setAtomicityMode(atomicityMode);
-        ccfg.setInterceptor(testPrimitives ? new TestInterceptor2() : new 
TestInterceptor1());
+        ccfg.setInterceptor(testPrimitives ? new 
TestTypeSpecifiedInterceptor() : new TestBOInterceptor());
         ccfg.setWriteSynchronizationMode(FULL_SYNC);
         ccfg.setBackups(1);
 
@@ -187,7 +187,7 @@ public class CacheKeepBinaryWithInterceptorTest extends 
GridCommonAbstractTest {
     /**
      *
      */
-    static class TestInterceptor1 implements CacheInterceptor<BinaryObject, 
BinaryObject> {
+    static class TestBOInterceptor implements CacheInterceptor<BinaryObject, 
BinaryObject> {
         /** */
         static int onGet;
 
@@ -266,7 +266,7 @@ public class CacheKeepBinaryWithInterceptorTest extends 
GridCommonAbstractTest {
     /**
      *
      */
-    static class TestInterceptor2 implements CacheInterceptor<Integer, 
Integer> {
+    static class TestTypeSpecifiedInterceptor implements 
CacheInterceptor<Integer, Integer> {
         /** */
         static int onGet;
 
@@ -379,7 +379,8 @@ public class CacheKeepBinaryWithInterceptorTest extends 
GridCommonAbstractTest {
      */
     static class TestValue {
         /** */
-        private int val;
+        @SuppressWarnings("unused")
+        private final int val;
 
         /**
          * @param val Value.
diff --git 
a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/standbycluster/IgniteStandByClusterTest.java
 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/standbycluster/IgniteStandByClusterTest.java
index 22daaa90412..acc93e7dd4e 100644
--- 
a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/standbycluster/IgniteStandByClusterTest.java
+++ 
b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/persistence/standbycluster/IgniteStandByClusterTest.java
@@ -300,11 +300,11 @@ public class IgniteStandByClusterTest extends 
GridCommonAbstractTest {
      * @param deAct Expected deActivation counter.
      */
     private void checkPlugin(Ignite ig, int act, int deAct) {
-        IgnitePlugin pl = ig.plugin(StanByClusterTestProvider.NAME);
+        IgnitePlugin pl = ig.plugin(StandByClusterTestProvider.NAME);
 
         assertNotNull(pl);
 
-        StanByClusterTestProvider plugin = (StanByClusterTestProvider)pl;
+        StandByClusterTestProvider plugin = (StandByClusterTestProvider)pl;
 
         assertEquals(act, plugin.actCnt.get());
         assertEquals(deAct, plugin.deActCnt.get());
@@ -333,10 +333,10 @@ public class IgniteStandByClusterTest extends 
GridCommonAbstractTest {
     /**
      *
      */
-    public static class StanByClusterTestProvider extends 
AbstractTestPluginProvider implements IgnitePlugin,
+    public static class StandByClusterTestProvider extends 
AbstractTestPluginProvider implements IgnitePlugin,
         IgniteChangeGlobalStateSupport {
         /** */
-        static final String NAME = "StanByClusterTestProvider";
+        static final String NAME = "StandByClusterTestProvider";
 
         /** */
         final AtomicInteger actCnt = new AtomicInteger();
diff --git 
a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/SqlFieldsQuerySelfTest.java
 
b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/SqlFieldsQuerySelfTest.java
index 28b482eff11..5a58be6e2b8 100644
--- 
a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/SqlFieldsQuerySelfTest.java
+++ 
b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/cache/SqlFieldsQuerySelfTest.java
@@ -32,9 +32,6 @@ import org.junit.Test;
  *
  */
 public class SqlFieldsQuerySelfTest extends GridCommonAbstractTest {
-    /** INSERT statement. */
-    private static final String INSERT = "insert into Person(_key, name) 
values (5, 'x')";
-
     /** {@inheritDoc} */
     @Override protected void afterTest() throws Exception {
         stopAllGrids();
diff --git 
a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/SqlSystemViewsSelfTest.java
 
b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/SqlSystemViewsSelfTest.java
index 593e6b4a2ee..8defdf0b3d6 100644
--- 
a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/SqlSystemViewsSelfTest.java
+++ 
b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/SqlSystemViewsSelfTest.java
@@ -1725,7 +1725,7 @@ public class SqlSystemViewsSelfTest extends 
AbstractIndexingCommonTest {
 
         ClusterMetricsImpl original = getField(node, "metrics");
 
-        setField(node, "metrics", new MockedClusterMetrics(original));;
+        setField(node, "metrics", new MockedClusterMetrics(original));
 
         List<?> durationMetrics = execSql(ign,
             "SELECT " +
diff --git 
a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/stat/PSUStatisticsTypesTest.java
 
b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/stat/PSUStatisticsTypesTest.java
index e3408a2a66d..c9705544ecb 100644
--- 
a/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/stat/PSUStatisticsTypesTest.java
+++ 
b/modules/indexing/src/test/java/org/apache/ignite/internal/processors/query/stat/PSUStatisticsTypesTest.java
@@ -40,7 +40,7 @@ public class PSUStatisticsTypesTest extends 
StatisticsTypesAbstractTest {
         String[][] wrongHints = new String[1][];
         wrongHints[0] = new String[]{"DTYPES_COL_INDEX"};
 
-        String isNullSql = String.format("select * from dtypes i1 where col_%s 
is null", name);;
+        String isNullSql = String.format("select * from dtypes i1 where col_%s 
is null", name);
 
         checkOptimalPlanChosenForDifferentIndexes(grid(0), new 
String[]{"DTYPES_" + name}, isNullSql, noHints);
 

Reply via email to