Re: Ignite Services and Data Collocation

2016-04-14 Thread Kamal C
Thanks for your quick response Val!

I'll test throughly and update here.

--Kamal

On Thu, Apr 14, 2016 at 11:57 PM, vkulichenko  wrote:

> Kamal,
>
> I'm not sure I understood what you're trying to achieve. When you use cache
> API, all affinity mappings are done automatically, so you don't need to
> worry about this.
> In your particular case, the client is not aware of affinity and
> essentially
> sends a request to a random node, so the cache update can require one more
> network hop. But I don't see any way to change this without starting a
> client Ignite node.
>
> Can you provide more details? What is the sequence of events happening when
> you do a request and what you would like to change?
>
> -Val
>
>
>
> --
> View this message in context:
> http://apache-ignite-users.70518.x6.nabble.com/Ignite-Services-and-Data-Collocation-tp4178p4192.html
> Sent from the Apache Ignite Users mailing list archive at Nabble.com.
>


Re: Ignite Services and Data Collocation

2016-04-14 Thread vkulichenko
Kamal,

I'm not sure I understood what you're trying to achieve. When you use cache
API, all affinity mappings are done automatically, so you don't need to
worry about this.
In your particular case, the client is not aware of affinity and essentially
sends a request to a random node, so the cache update can require one more
network hop. But I don't see any way to change this without starting a
client Ignite node.

Can you provide more details? What is the sequence of events happening when
you do a request and what you would like to change?

-Val



--
View this message in context: 
http://apache-ignite-users.70518.x6.nabble.com/Ignite-Services-and-Data-Collocation-tp4178p4192.html
Sent from the Apache Ignite Users mailing list archive at Nabble.com.


Ignite Services and Data Collocation

2016-04-14 Thread Kamal C
Hi all,

I've a cluster of 2 ignite server nodes + 1 client node (non-ignite).
I've collocated the data resides in ignite cache based on affinity key.

e.g.
Server 1 - contains all the data related to the affinity key (A, C, E)
Server 2 - contains all the data related to the affinity key (B, D, F)

I've deployed a service using node singleton approach and the same also
provided in RMI for backward compatibility.

Client can add, update and remove the data using API services. I would like
to end up the call called by the client to the node / server where it's
data is located to minimize data serialization within the network.

With Ignite client, I can able to do it by passing a predicate while
getting the service. But, my client works only with RMI. Once I received a
call, what approaches should i take to re-direct the computation to the
node where data is located ?

--Kamal