Attached is a simple script-based example of this idea.

Barry Oglesby
GemFire Advanced Customer Engineering (ACE)
For immediate support please contact Pivotal Support at
http://support.pivotal.io/


On Wed, Jan 27, 2016 at 9:50 AM, Barry Oglesby <[email protected]> wrote:

> Yes, this is possible. Normally, the arguments are passed to all nodes
> that execute the function, but the filters are split up and routed to only
> the appropriate nodes. So, you'll need to change your filter to include not
> only the keys but also the arguments. Then, add (or change) a
> PartitionResolver that routes based on just the key part of that
> key-and-argument filter. For example, if your key is a string then you'll
> need to create a KeyWithArguments that includes the string and the
> argument. Then add a PartitionResolver whose getRoutingObject method can
> handle either a string or a KeyWithArguments. If the input key is a string,
> then just return it; if the input key is a KeyWithArguments, then return
> the string field.
>
> Barry Oglesby
> GemFire Advanced Customer Engineering (ACE)
> For immediate support please contact Pivotal Support at
> http://support.pivotal.io/
>
>
> On Wed, Jan 27, 2016 at 4:48 AM, Hovhannes Antonyan <[email protected]>
> wrote:
>
>> Hi,
>>
>>
>>
>> I have a question about partitioning provided arguments to corresponding
>> keys upon onRegion call.
>>
>> Lets say I have 3 keys (from 1 to 3) each hosting on different node and I
>> want to make onRegion call by passing individual argument for each key.
>>
>> I don't want to pass all arguments to all nodes, I want each node to
>> receive arguments only for keys it is hosting.
>>
>> How can I achieve this?
>>
>>
>>
>> Thanks in advance,
>>
>> Hovhannes
>>
>
>

Attachment: key-and-arguments-script-clean_01-27-2016.tgz
Description: GNU Zip compressed data

Reply via email to