Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NPE when getting list of instances #478

Closed
satai opened this issue May 13, 2013 · 2 comments

Comments

Projects
None yet
3 participants
@satai
Copy link

commented May 13, 2013

When I call getInstances on HazelcastInstance (aquired via HazelcastClient.newHazelcastClient(clientConfig)), I get collection with them. After some time I call the same method and get an exception:

java.lang.NullPointerException

java.util.concurrent.ConcurrentHashMap.hash(ConcurrentHashMap.java:333),
java.util.concurrent.ConcurrentHashMap.get(ConcurrentHashMap.java:988), 
com.hazelcast.client.HazelcastClient.getClientProxy(HazelcastClient.java:167), 
com.hazelcast.client.ClusterClientProxy.getInstances(ClusterClientProxy.java:47), 
com.hazelcast.client.HazelcastClient.getInstances(HazelcastClient.java:260)
...some my groovy code...

This behaviour is not deterministic - there seems to be no reason to appear - doesn't appear after load, after exact time etc. When I get the NPE for the first time, I get it all the next calls until I restart the cluster.
This cluster usually has about 4 members, 2 clients and no lite members.

Environment:
Groovy version: 1.8.8
JVM version: 1.7.0_19
Hazelcast version: 2.5.1

@pveentjer

This comment has been minimized.

Copy link
Member

commented Jul 16, 2013

Sorry for the long delay. I'm looking at this bug now.

So if I understand you correctly, the cluster is stable; there are no members joining or leaving the cluster (I'm trying to narrow scope of the cause).

I'm trying to reproduce the error so we can create a fix for it.

@mdogan mdogan closed this in 98b249a Jul 16, 2013

@mdogan

This comment has been minimized.

Copy link
Member

commented Jul 16, 2013

@satai

The only way we are able to reproduce this issue is to call getInstances() after creating a lock with a null key. Please try with building from source or after 2.6.1 release and reopen this issue if problem still occurs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.