Thanks Nick. Can you file a Jira issue? Thanks!
Regards,
Alan
On Jan 20, 2009, at 1:37 PM, Nicholas White wrote:
> There is a bug in the SLP Server code that causes a problem...
>
> TO REPRODUCE (using the standard directory server, and the client and
> servers here:
http://livetribe.codehaus.org/SLP-Examples-JMX>
> (1) Start the directory server, client and server. They should all
> find each other
> (2) Kill the directory server and the client
> (3) Start the directory server, then the client
> ** the client will not find the server**
>
> WHY
>
> When the directory server restarts, it sends advertising messages.
> However, the server doesn't respond as it thinks it has already
> registered with that server. In the meantime, it advertises itself via
> multicast. When the client is restarted, it finds the directory server
> and interrogates it, so doesn't read the server's multicast messages.
>
> CODE
>
> In DirectoryAgentInfoCache, the following method is called when a
> server receives a directory server advertisement:
>
> public void handle(DirectoryAgentInfo directoryAgent)
> {
> if (directoryAgent.isShuttingDown())
> {
> DirectoryAgentInfo removed =
> remove(directoryAgent.getKey());
> if (removed != null)
> notifyDirectoryAgentDied(directoryAgent);
> }
> else
> {
> DirectoryAgentInfo existing = add(directoryAgent);
> if (existing == null)
> notifyDirectoryAgentBorn(directoryAgent); //*******REMOVE if(existing
> == null)*******
> }
> }
>
> In the above situation, existing is not null when the restarted
> directory agent sends its advertisements, so the server never
> responds. To fix this, remove 'if (existing == null)' so the server
> always tells the directory agent what services it has.
>
> Please let me know if you need any more clarification,
>
> Thanks,
>
> Nick
>
> ---------------------------------------------------------------------
> To unsubscribe from this list, please visit:
>
>
http://xircles.codehaus.org/manage_email>
>
>
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email