You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ignite.apache.org by Raymond Wilson <ra...@trimble.com> on 2019/03/07 20:19:34 UTC

Affinity aware version of ICompute.Apply() in Ignite C# client

I have a current workflow where I use ICompute.Apply() and
ICompute.BroadCast to execute a compute function with an argument and
return a response. In the former I want any one of a number of nodes in the
projection to execute the compute func, in the latter I want all the nodes
to execute the compute func.

I have a new workflow where I want to execute a compute func with an
argument on a node based on an affinity key.

ICompute defines AffinityCall() which takes a cache name, an affinity key
relevant to the cache, and a compute func, then returns a result. However,
unlike Apply and Broadcast it does not accept an argument parameter.

Looking through the ICompute interface it seems that there is no similar
method available that does take an argument.

Two questions:

- Is this a capability defined in the Java client but not yet available in
the C# client?
- If not, is the standard practice to include the argument into the compute
func state that is sent to the node to execute it?

Thanks,
Raymond.

Re: Affinity aware version of ICompute.Apply() in Ignite C# client

Posted by Raymond Wilson <ra...@trimble.com>.
Thanks Pavel :)

Sent from my iPhone

On 8/03/2019, at 9:47 PM, Pavel Tupitsyn <pt...@apache.org> wrote:

>  - Is this a capability defined in the Java client but not yet available
in the C# client?
There is no such API in Java AFAIK

>  - If not, is the standard practice to include the argument into the
compute func state that is sent to the node to execute it?
Yes


Thanks,
Pavel



On Thu, Mar 7, 2019 at 11:19 PM Raymond Wilson <ra...@trimble.com>
wrote:

> I have a current workflow where I use ICompute.Apply() and
> ICompute.BroadCast to execute a compute function with an argument and
> return a response. In the former I want any one of a number of nodes in the
> projection to execute the compute func, in the latter I want all the nodes
> to execute the compute func.
>
> I have a new workflow where I want to execute a compute func with an
> argument on a node based on an affinity key.
>
> ICompute defines AffinityCall() which takes a cache name, an affinity key
> relevant to the cache, and a compute func, then returns a result. However,
> unlike Apply and Broadcast it does not accept an argument parameter.
>
> Looking through the ICompute interface it seems that there is no similar
> method available that does take an argument.
>
> Two questions:
>
> - Is this a capability defined in the Java client but not yet available in
> the C# client?
> - If not, is the standard practice to include the argument into the
> compute func state that is sent to the node to execute it?
>
> Thanks,
> Raymond.
>
>
>

Re: Affinity aware version of ICompute.Apply() in Ignite C# client

Posted by Pavel Tupitsyn <pt...@apache.org>.
>  - Is this a capability defined in the Java client but not yet available
in the C# client?
There is no such API in Java AFAIK

>  - If not, is the standard practice to include the argument into the
compute func state that is sent to the node to execute it?
Yes


Thanks,
Pavel



On Thu, Mar 7, 2019 at 11:19 PM Raymond Wilson <ra...@trimble.com>
wrote:

> I have a current workflow where I use ICompute.Apply() and
> ICompute.BroadCast to execute a compute function with an argument and
> return a response. In the former I want any one of a number of nodes in the
> projection to execute the compute func, in the latter I want all the nodes
> to execute the compute func.
>
> I have a new workflow where I want to execute a compute func with an
> argument on a node based on an affinity key.
>
> ICompute defines AffinityCall() which takes a cache name, an affinity key
> relevant to the cache, and a compute func, then returns a result. However,
> unlike Apply and Broadcast it does not accept an argument parameter.
>
> Looking through the ICompute interface it seems that there is no similar
> method available that does take an argument.
>
> Two questions:
>
> - Is this a capability defined in the Java client but not yet available in
> the C# client?
> - If not, is the standard practice to include the argument into the
> compute func state that is sent to the node to execute it?
>
> Thanks,
> Raymond.
>
>
>