Re: JMX access sample by jython (Was: How to invoke getNaturalEndpoints with jconsole?)

2011-05-15 Thread aaron morton
Nice, Thanks - Aaron Morton Freelance Cassandra Developer @aaronmorton http://www.thelastpickle.com On 15 May 2011, at 01:12, Maki Watanabe wrote: > Just FYI for beginners like me: I've also write it with jython. > Getting attributes are more easier than invoke Operations. I fee

JMX access sample by jython (Was: How to invoke getNaturalEndpoints with jconsole?)

2011-05-14 Thread Maki Watanabe
Just FYI for beginners like me: I've also write it with jython. Getting attributes are more easier than invoke Operations. I feel jython will be a good option to create custom monitoring/management tools. #!/usr/bin/jython # # *** This is JYTHON script. You can't run it on CPython. *** import sys

Re: How to invoke getNaturalEndpoints with jconsole?

2011-05-13 Thread Maki Watanabe
I did not drop the keyspace, but your comment lead me to resolution. I found cassandra-cli is not case sensitive on keyspace. I used keyspace name FooBar on cassandra-cli, but it was Foobar in correct. cassandra-cli didn't complain on my mistake, but the JMX interface is less tolerance. If I use co

Re: How to invoke getNaturalEndpoints with jconsole?

2011-05-13 Thread Jonathan Ellis
sounds like https://issues.apache.org/jira/browse/CASSANDRA-2353 On Fri, May 13, 2011 at 10:08 AM, Maki Watanabe wrote: > I wrote a small JMX client to invoke getNaturalEndpoints. > It works fine at my test environment, but throws NPE for keyspace we > will use for our application (both 0.7.5). >

Re: How to invoke getNaturalEndpoints with jconsole?

2011-05-13 Thread Alex Araujo
On 5/13/11 10:08 AM, Maki Watanabe wrote: I wrote a small JMX client to invoke getNaturalEndpoints. It works fine at my test environment, but throws NPE for keyspace we will use for our application (both 0.7.5). Does anyone know quick resolution of that before I setting up cassandra on eclipse to

Re: How to invoke getNaturalEndpoints with jconsole?

2011-05-13 Thread Maki Watanabe
I wrote a small JMX client to invoke getNaturalEndpoints. It works fine at my test environment, but throws NPE for keyspace we will use for our application (both 0.7.5). Does anyone know quick resolution of that before I setting up cassandra on eclipse to inspect what happens :) thanks Exception

Re: How to invoke getNaturalEndpoints with jconsole?

2011-05-11 Thread Jonathan Ellis
Thanks! On Wed, May 11, 2011 at 10:20 AM, Maki Watanabe wrote: > Add a new faq: > http://wiki.apache.org/cassandra/FAQ#jconsole_array_arg > > 2011/5/11 Nick Bailey : >> Yes. >> >> On Wed, May 11, 2011 at 8:25 AM, Maki Watanabe >> wrote: >>> Thanks, >>> >>> So my options are: >>> 1. Write a thri

Re: How to invoke getNaturalEndpoints with jconsole?

2011-05-11 Thread Maki Watanabe
Add a new faq: http://wiki.apache.org/cassandra/FAQ#jconsole_array_arg 2011/5/11 Nick Bailey : > Yes. > > On Wed, May 11, 2011 at 8:25 AM, Maki Watanabe > wrote: >> Thanks, >> >> So my options are: >> 1. Write a thrift client code to call describe_ring with hashed key >> or >> 2. Write a JMX cli

Re: How to invoke getNaturalEndpoints with jconsole?

2011-05-11 Thread Nick Bailey
Yes. On Wed, May 11, 2011 at 8:25 AM, Maki Watanabe wrote: > Thanks, > > So my options are: > 1. Write a thrift client code to call describe_ring with hashed key > or > 2. Write a JMX client code to call getNaturalEndpoints > > right? > > 2011/5/11 Nick Bailey : >> As far as I know you can not ca

Re: How to invoke getNaturalEndpoints with jconsole?

2011-05-11 Thread Maki Watanabe
Thanks, So my options are: 1. Write a thrift client code to call describe_ring with hashed key or 2. Write a JMX client code to call getNaturalEndpoints right? 2011/5/11 Nick Bailey : > As far as I know you can not call getNaturalEndpoints from jconsole > because it takes a byte array as a param

Re: How to invoke getNaturalEndpoints with jconsole?

2011-05-11 Thread Nick Bailey
As far as I know you can not call getNaturalEndpoints from jconsole because it takes a byte array as a parameter and jconsole doesn't provide a way for inputting a byte array. You might be able to use the thrift call 'describe_ring' to do what you want though. You will have to manually hash your ke

How to invoke getNaturalEndpoints with jconsole?

2011-05-11 Thread Maki Watanabe
Hello, It's a question on jconsole rather than cassandra, how can I invoke getNaturalEndpoints with jconsole? org.apache.cassandra.service.StorageService.Operations.getNaturalEndpoints I want to run this method to find nodes which are responsible to store data for specific row key. I can find thi