Informs the lookup discovery service of the existence of an unavailable lookup service and requests that the lookup discovery service discard the unavailable lookup service.
When the lookup discovery service removes an already-discovered lookup service from a registration's managed set of lookup services and makes the lookup service eligible for re-discovery, the lookup service is considered to be "discarded". There are a number of situations where the lookup discovery service will discard a lookup service.
The lookup discovery service will discard a lookup service in response to a discard request resulting from an invocation of this method.
The lookup discovery service will discard a lookup service when the lookup service - previously discovered through locator discovery - is removed from a registration's managed set of locators in response to an invocation of either the setLocators method or the removeLocators method.
The lookup discovery service will discard a lookup service when the multicast announcements from an already-discovered lookup service are no longer being received.
Whenever the lookup discovery service discards a lookup service previously discovered for this registration, it will send an event to this registration's listener indicating that the lookup service has been discarded.
Note that if a lookup service crashes or is unavailable for some reason, there will be no automatic notification of the occurrence of such an event. This means that for each of a registration's targeted lookup services, after a lookup service is initially discovered, the lookup discovery service will not attempt to discover that lookup service again (for that registration) until that lookup service is discarded.
Thus, when a client determines that lookup service discovered for a registration is no longer available, it is the responsibility of the client to inform the lookup discovery service - through the invocation of this method - that the previously discovered lookup service is no longer available, and that attempts should be made to re-discover that lookup service for the registration. Typically, a client determines that a lookup service is unavailable when the client attempts to use the lookup service but receives a non-fatal exception or error (for example, a RemoteException) as a result of the attempt.
@param registrar a reference to the lookup service that the lookupdiscovery service is being asked to discard.
If this parameter equals none of the lookup services contained in the managed set of lookup services for this registration, no action will be taken.
@throws java.lang.NullPointerException this exception occurs whennull is input to the registrar parameter.
@throws java.rmi.RemoteException typically, this exception occurs whenthere is a communication failure between the client and the lookup discovery service. When this exception does occur, the lookup service may or may not have been successfully discarded.