curator-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Steve Loughran (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CURATOR-101) ServiceDiscoveryImpl.close() fails if the service was never started
Date Thu, 10 Apr 2014 13:35:53 GMT

    [ https://issues.apache.org/jira/browse/CURATOR-101?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13965352#comment-13965352
] 

Steve Loughran commented on CURATOR-101:
----------------------------------------

stack. 
{code}
java.lang.IllegalStateException: instance must be started before calling this method
	at com.google.common.base.Preconditions.checkState(Preconditions.java:145)
	at org.apache.curator.framework.imps.CuratorFrameworkImpl.delete(CuratorFrameworkImpl.java:327)
	at org.apache.curator.x.discovery.details.ServiceDiscoveryImpl.unregisterService(ServiceDiscoveryImpl.java:198)
	at org.apache.curator.x.discovery.details.ServiceDiscoveryImpl.close(ServiceDiscoveryImpl.java:129)
	at org.apache.hadoop.io.IOUtils.cleanup(IOUtils.java:237)
	at org.apache.hadoop.io.IOUtils.closeStream(IOUtils.java:254)
	at org.apache.slider.server.services.curator.RegistryBinderService.serviceStop(RegistryBinderService.java:81)
	at org.apache.hadoop.service.AbstractService.stop(AbstractService.java:221)
	at org.apache.hadoop.service.ServiceOperations.stop(ServiceOperations.java:52)
	at org.apache.hadoop.service.ServiceOperations.stopQuietly(ServiceOperations.java:80)
	at org.apache.hadoop.service.CompositeService.stop(CompositeService.java:158)
	at org.apache.hadoop.service.CompositeService.serviceStop(CompositeService.java:131)
	at org.apache.hadoop.service.AbstractService.stop(AbstractService.java:221)
	at org.apache.hadoop.yarn.service.launcher.ServiceShutdownHook.run(ServiceShutdownHook.java:70)
	at org.apache.hadoop.util.ShutdownHookManager$1.run(ShutdownHookManager.java:54)
{code}

> ServiceDiscoveryImpl.close() fails if the service was never started
> -------------------------------------------------------------------
>
>                 Key: CURATOR-101
>                 URL: https://issues.apache.org/jira/browse/CURATOR-101
>             Project: Apache Curator
>          Issue Type: Bug
>    Affects Versions: 2.4.1
>            Reporter: Steve Loughran
>            Assignee: Jordan Zimmerman
>            Priority: Minor
>
> the {{close()}} operator of ServiceDiscoveryImpl raises an {{IllegalStateException}}
if you attempt to call it -this is a runtime exception and somewhat drastic on an operation
that should be robust against odd states.



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Mime
View raw message