shutdown

15 views
Skip to first unread message

Damien Lepage

unread,
Mar 29, 2011, 1:05:05 PM3/29/11
to hector...@googlegroups.com
Hi,

Unless I missed something, it seems fine to reuse the same Keyspace operator again and again with Hector.
If I do that in a JVM which is always up and running, can I run into some sort of problem such as a memory leak?
If not, is it really important to call shutdown when I stop my JVM? What could go wrong otherwise? Any resources locked on the server side?

Thanks a lot,

Damien

Nate McCall

unread,
Mar 29, 2011, 1:09:12 PM3/29/11
to hector...@googlegroups.com, Damien Lepage
Nope. Keyspace is fine to re-use. It has a setConsistencyLevelPolicy
method that makes it non-reentrant if used (this will go away in the
first 0.8 release). As long as you stay away from that, you will be
fine.

If you are concerned about cleaning up, you can call
HFactory#shutdownCluster to clean everything up in an orderly fashion.

Reply all
Reply to author
Forward
0 new messages