sorry,i find igniteClient.compute() has no affinityCallAsync method ,does 
igniteClient can call affinityCallAsync



wkhapy...@gmail.com
 
From: Stephen Darlington
Date: 2022-08-24 20:27
To: user
Subject: Re: count cache key number
There are a number of ways to tackle this. 

If your cache split the key into distinct fields rather that a concatenated 
string, you could SQL-enable your cache and get your count as a simple SELECT 
statement.

Alternatively, there’s an affinity compute task that takes a partition 
(affinityCallAsync). If you use that and a ScanQuery that fetches records from 
a specific partition (ScanQuery), you’ll get something like a map-reduce. (You 
could also use the map-reduce API, but an affinity call is probably easier.)

On 24 Aug 2022, at 11:59, wkhapy...@gmail.com wrote:

hi
do I pass cache in distribute compute than use cache scan ,that faster than I 
use a cache scan in client api.

---Original---
From: "wkhapy...@gmail.com"<wkhapy...@gmail.com>
Date: Wed, Aug 24, 2022 17:06 PM
To: "user"<user@ignite.apache.org>;
Subject: count cache key number

Hi,
    I have a cache ,it's key like 
   "mobile:140000"
   "mobile:140001",
    "address:test1",
    "address:test2",
    "address:test3"。
   I want to count mobile number and address number。
   address number is 3 and mobile number is 2。I see Ignite doc has mapreduce 
job,but it seem not example iterator cache key。 is there any method to iterator 
key in mapreduce job。Thank you very much



wkhapy...@gmail.com

Reply via email to