'Apache Ignite IgniteCompute grid computation
I am using Apache Ignite v. 2.8.1 to perform parallel computations on the objects loaded in cache ( multiple nodes ).
In my client implementation I got an instance of IgniteCompute and then execute pass IgniteRunnable to perform my calculations:
Ignite ignite = Ignition.start();
IgniteCache cache = ignite.getOrCreateCache("testCache");
/* load data entries */
IgniteCompute compute = ignite.compute();
compute.run(()->{ ... } )
Here is the problem, in my IgniteRunnable implementation I can iterate through the keys and update every entry I need to update, however that's not a concurrent execution that I am interested in.
I can use an invokeAll method of IgniteCache, but as far as I understand it also executes an EntryProcessors sequentially on correspondent entries.
What's the right way to perform concurrent computation on a subset of entries allocated to the multiple nodes in Ignite Cluster?
Solution 1:[1]
You need to look at the affinity compute methods. In short, you send one compute task per partition in a cache.
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | Stephen Darlington |
