You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ignite.apache.org by GitBox <gi...@apache.org> on 2020/10/23 08:50:52 UTC

[GitHub] [ignite] xtern commented on a change in pull request #8317: IGNITE-13520 Skip generating encryption keys on the client node.

xtern commented on a change in pull request #8317:
URL: https://github.com/apache/ignite/pull/8317#discussion_r510734137



##########
File path: modules/core/src/test/java/org/apache/ignite/internal/encryption/EncryptedCacheNodeJoinTest.java
##########
@@ -204,6 +221,106 @@ public void testClientNodeJoin() throws Exception {
         createEncryptedCache(client, grid0, cacheName(), null);
     }
 
+    /** */
+    @Test
+    public void testClientNodeJoinActiveClusterWithNewStaticCacheConfig() throws Exception {
+        checkNodeJoinWithStaticCacheConfig(true, true, true);
+    }
+
+    /** */
+    @Test
+    public void testClientNodeJoinActiveClusterWithExistingStaticCacheConfig() throws Exception {
+        checkNodeJoinWithStaticCacheConfig(true, true, false);
+    }
+
+    /** */
+    @Test
+    public void testClientNodeJoinInactiveClusterWithNewStaticCacheConfig() throws Exception {
+        checkNodeJoinWithStaticCacheConfig(true, false, true);
+    }
+
+    /** */
+    @Test
+    public void testClientNodeJoinInactiveClusterWithExistingStaticCacheConfig() throws Exception {
+        checkNodeJoinWithStaticCacheConfig(true, false, false);
+    }
+
+    /** */
+    @Test
+    public void testServerNodeJoinActiveClusterWithNewStaticCacheConfig() throws Exception {
+        checkNodeJoinWithStaticCacheConfig(false, true, true);
+    }
+
+    /** */
+    @Test
+    public void testServerNodeJoinInactiveClusterWithNewStaticCacheConfig() throws Exception {
+        checkNodeJoinWithStaticCacheConfig(false, false, true);
+    }
+
+    /**
+     * @param client {@code True} to test client node join, {@code False} to test server node join.
+     * @param activateBeforeJoin {@code True} to activate the server before joining the client node.
+     * @param newCfg {@code True} to configure cache on the last joined node. {@code False} to configure on all nodes.
+     */
+    public void checkNodeJoinWithStaticCacheConfig(
+        boolean client,
+        boolean activateBeforeJoin,
+        boolean newCfg
+    ) throws Exception {
+        if (!newCfg)
+            configureCache = true;
+
+        startGrid(GRID_0);
+        startGrid(GRID_6);
+
+        IgniteEx client1 = startClientGrid("client1");
+
+        if (newCfg)
+            configureCache = true;
+
+        if (activateBeforeJoin)
+            grid(GRID_0).cluster().state(ClusterState.ACTIVE);
+
+        if (client && newCfg) {
+

Review comment:
       Done, thanks




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

For queries about this service, please contact Infrastructure at:
users@infra.apache.org