Skip to content

Conversation

@wirtsleg
Copy link

https://issues.apache.org/jira/browse/IGNITE-13288

Marked the following events as internal:

  • EVT_CLUSTER_ACTIVATED
  • EVT_CLUSTER_DEACTIVATED
  • EVT_BASELINE_CHANGED
  • EVT_CLUSTER_STATE_CHANGED

There are discovery events that are listened to by all nodes.
It will be useful to include these events to listen on all nodes by default too.
All of them are rare, system and cluster-wide.

@dmekhanikov
Copy link
Contributor

I think we can make testClusterActivationEventsOnOtherNode more strict.
Something like this:

Ignite ignite_1 = startGrid(0);
Ignite ignite_2 = startGrid(1);

CountDownLatch deactivatedLatch = addDisposableLocalListener(ignite_2, EVT_CLUSTER_DEACTIVATED);
CountDownLatch stateChangedLatch1 = addDisposableLocalListener(ignite_2, EVT_CLUSTER_STATE_CHANGED);

ignite_1.cluster().state(ClusterState.INACTIVE);

assertTrue(deactivatedLatch.await(2, TimeUnit.SECONDS));
assertTrue(stateChangedLatch1.await(2, TimeUnit.SECONDS));

CountDownLatch activatedLatch = addDisposableLocalListener(ignite_2, EVT_CLUSTER_ACTIVATED);
CountDownLatch stateChangedLatch2 = addDisposableLocalListener(ignite_2, EVT_CLUSTER_STATE_CHANGED);

ignite_1.cluster().state(ClusterState.ACTIVE);

assertTrue(activatedLatch.await(2, TimeUnit.SECONDS));
assertTrue(stateChangedLatch2.await(2, TimeUnit.SECONDS));

Otherwise the fix looks good.

@asfgit asfgit closed this in 398681a Aug 3, 2020
kartiksomani pushed a commit to kartiksomani/ignite that referenced this pull request Sep 15, 2020
Date:   Mon Aug 3 17:35:27 2020 +0300

IGNITE-13288 Activation/deactiovation and cluster state change events were made system. - Fixes apache#8077.

Signed-off-by: Sergey Chugunov <sergey.chugunov@gmail.com>
ymolochkov pushed a commit to ymolochkov/ignite that referenced this pull request Nov 19, 2020
Date:   Mon Aug 3 17:35:27 2020 +0300

IGNITE-13288 Activation/deactiovation and cluster state change events were made system. - Fixes apache#8077.

Signed-off-by: Sergey Chugunov <sergey.chugunov@gmail.com>

(cherry picked from commit 398681a)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants