You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@curator.apache.org by "Jordan Zimmerman (JIRA)" <ji...@apache.org> on 2013/10/08 21:18:43 UTC

[jira] [Commented] (CURATOR-63) ServiceCacheImpl doesn't check if service name is null

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

Jordan Zimmerman commented on CURATOR-63:
-----------------------------------------

Might as well check not-null for the discovery arg too

> ServiceCacheImpl doesn't check if service name is null
> ------------------------------------------------------
>
>                 Key: CURATOR-63
>                 URL: https://issues.apache.org/jira/browse/CURATOR-63
>             Project: Apache Curator
>          Issue Type: Bug
>          Components: Recipes
>    Affects Versions: 2.2.0-incubating
>            Reporter: Nandor Kracser
>            Assignee: Jordan Zimmerman
>            Priority: Trivial
>             Fix For: TBD
>
>         Attachments: CURATOR-63.patch
>
>
> If not giving a service name with ServiceCacheBuilder.name() the ServiceCache throws a weird Exception later on, because it wants to fetch data from the service group node instead of the service instance node:
> Exception in thread "main" java.io.EOFException: No content to map to Object due to end of input
> 	at org.codehaus.jackson.map.ObjectMapper._initForReading(ObjectMapper.java:2766)
> 	at org.codehaus.jackson.map.ObjectMapper._readMapAndClose(ObjectMapper.java:2709)
> 	at org.codehaus.jackson.map.ObjectMapper.readValue(ObjectMapper.java:1964)
> 	at org.apache.curator.x.discovery.details.JsonInstanceSerializer.deserialize(JsonInstanceSerializer.java:50)
> 	at org.apache.curator.x.discovery.details.ServiceCacheImpl.addInstance(ServiceCacheImpl.java:178)
> 	at org.apache.curator.x.discovery.details.ServiceCacheImpl.start(ServiceCacheImpl.java:81)



--
This message was sent by Atlassian JIRA
(v6.1#6144)