ignite-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Eduard Shangareev <eduard.shangar...@gmail.com>
Subject Issues with forceServerMode on clients and unclear contract of isClient/isClientMode methods
Date Thu, 31 May 2018 14:10:57 GMT
Hi, guys!

I just have found that we widely
misuse org.apache.ignite.cluster.ClusterNode#isClient method.

Now it returns how a node is connected to cluster (as part of the ring or
not).

So, it's not the same as IgniteConfiguration#isClientMode!

But! Actually, we treat as the same thing. At ignite-core we have 57 usages
of ClusterNode#isClient.
And nowhere we care about connection mode.

Well, there is only one case when these methods would return different
values, when forceClientMode=true and clientMode=true.

To fix this I propose next:
1. Deprecate usage of forceClientMode.
2. Create a ticket to remove it in 3.0.
3. Make ClusterNode#isClient what everyone expects.
4. Reconcile other isClient* methods. We should care about way hot client
is connected only in discovery SPI. Otherwise, it should return the same
value as IgniteConfiguration#isClientMode.


Any objections?

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message