On 10 Mar 2010, at 18:21, Galder Zamarreno wrote:

On Wed, 10 Mar 2010 14:08:23 +0100, Mircea Markus  
<mircea.markus@jboss.com> wrote:

Hi Galder,

Here are some thoughts I have about how the hotrod client performs  
initial connection to the HR servers:
A list of servers is statically configured so that the client can  
connect to any of them
            1. client will ping each configured server until it finds  
one that is up and running
            2. at this point it will stop(i.e. not query other  
statically configured servers) and query this server for the cluster  
topology

The idea was that rather than querying for the cluster topology, the  
client would register for notification it's interested in. From the wiki:

"Before any the server can send any notifications, clients need to  
register and indicate which events they're interested in. To do that, they  
have to send a request like this:

[request header][events]"

So, if a client was interested in topology change notifications, it would  
tell the server accordingly.
Isn't the event handling optional? if so, some clients (ones that do not implement event handling) would not be able to get the view?

            3. a a response to this query, the server informs the  
client about hotrod cluster topology (which might be different than  
infinispan cluster, right?)

Although not specified in the wiki, I would assume that once you register  
with the server, the server would push the current topology, no need for  
further requests from client.

            4. based on this information client builds a pool of  
connections to the servers
            5. client register itself as cluster formation listener,  
and update the list of active servers whenever the topology changes
(cluster formation might not be the best name for this listener as it  
only refers to the time when cluster is formed, what about cluster  
topology listener?)

You'd still need a listener like the one you mention based on the  
information received from the server(s).

How does this sound to you?
</snip>

Cheers,
Mircea
_______________________________________________
infinispan-dev mailing list
infinispan-dev@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/infinispan-dev


--
Galder Zamarreņo
Sr. Software Engineer
Infinispan, JBoss Cache

_______________________________________________
infinispan-dev mailing list
infinispan-dev@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/infinispan-dev