curator-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jordan Zimmerman <>
Subject Re: Static/Permanent service type
Date Tue, 11 Feb 2014 14:14:54 GMT
Hmm - that’s a good point. I wonder if PERMANENT should be excluded. The idea here is that
the instance is going down so any services that it registered should go down too. But, I can
see an argument that PERMANENT should not. However, this implementation has been released
for a long time so I’d be concerned about breaking existing code. Maybe a method could be
added to designate which service types are unregistered when the ServiceDiscovery instance
is closed.


From: Huang, Ying-Yi Huang, Ying-Yi
Reply: Huang, Ying-Yi
Date: February 10, 2014 at 7:43:59 PM
To: Jordan Zimmerman
Subject:  Re: Static/Permanent service type  
Services registered with service discovery would get unregistered when close() is called.
This will remove all services including static and permanent. Is this the designed behavior?

public class ServiceDiscoveryImpl<T> implements ServiceDiscovery<T>  
public void close() throws IOException  
for ( ServiceCache<T> cache : Lists.newArrayList(caches) )  
for ( ServiceProvider<T> provider : Lists.newArrayList(providers) )  

for ( ServiceInstance<T> service : services.values() )  
catch ( Exception e )  
log.error("Could not unregister instance: " + service.getName(), e);  


On Feb 7, 2014, at 6:24 PM, Jordan Zimmerman <<>>

ServiceType.DYNAMIC is not supported. It makes sense because there is no session for the REST


From: Huang, Ying-Yi Huang, Ying-Yi<>  
Reply: Huang, Ying-Yi<>  
Date: February 7, 2014 at 1:29:12 PM  
To: Jordan Zimmerman<> 

Subject: Re: Static/Permanent service type  
A general question is that are all three types of services supported in Java API and RESTFul

View raw message