alex-plekhanov commented on code in PR #11039:
URL: https://github.com/apache/ignite/pull/11039#discussion_r1403532997
##########
modules/core/src/main/java/org/apache/ignite/internal/processors/platform/client/cache/ClientCachePartitionAwarenessGroup.java:
##########
@@ -42,7 +42,7 @@ class ClientCachePartitionAwarenessGroup {
private final boolean dfltAffinity;
/** Descriptor of the associated caches. */
- private final Map<Integer, CacheConfiguration<?, ?>> cacheCfgs = new
HashMap<>();
Review Comment:
Redundant change
##########
modules/core/src/test/java/org/apache/ignite/internal/client/thin/ThinClientAbstractPartitionAwarenessTest.java:
##########
@@ -389,4 +399,14 @@ public boolean isClosed() {
return cfg.getAddresses().toString();
}
}
+
+ /**
+ * Excludes node if its consistent id ends with 'Test1'.
+ */
+ protected static final class ConsistentIdNodeFilter implements
IgnitePredicate<ClusterNode> {
Review Comment:
There are three almost identical classes. Can we use just and and pass
consistent id suffix as constructor parameter?
##########
modules/core/src/test/java/org/apache/ignite/internal/client/thin/ThinClientPartitionAwarenessStableTopologyTest.java:
##########
@@ -409,14 +600,29 @@ private void testNotApplicableCache(String cacheName) {
* @param keyFactory Key factory function.
*/
private void testApplicableCache(String cacheName, Function<Integer,
Object> keyFactory) throws Exception {
+ testApplicableCache(cacheName, keyFactory, true);
+ }
+
+ /**
+ * @param cacheName Cache name.
+ * @param keyFactory Key factory function.
+ * @param partitionsRequestExpected If {@code true}, awaits {@link
ClientOperation#CACHE_PARTITIONS} first.
+ */
+ private void testApplicableCache(
+ String cacheName,
+ Function<Integer, Object> keyFactory,
+ boolean partitionsRequestExpected
+ ) throws Exception {
ClientCache<Object, Object> clientCache = client.cache(cacheName);
IgniteInternalCache<Object, Object> igniteCache =
grid(0).context().cache().cache(cacheName);
clientCache.put(keyFactory.apply(0), 0);
- TestTcpClientChannel opCh = affinityChannel(keyFactory.apply(0),
igniteCache);
+ TestTcpClientChannel opCh = affinityChannel(0, igniteCache);
Review Comment:
`keyFactory.apply(0)` - correct implementation, why it was changed?
--
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]