cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "gabriele renzi (JIRA)" <>
Subject [jira] Created: (CASSANDRA-933) OutOfBoundException in StorageService.getAllRanges
Date Tue, 30 Mar 2010 19:08:27 GMT
OutOfBoundException in StorageService.getAllRanges 

                 Key: CASSANDRA-933
             Project: Cassandra
          Issue Type: Bug
    Affects Versions: 0.6
            Reporter: gabriele renzi
            Priority: Minor

this was seen on 0.6-beta3 but it appears to be in trunk too, given the same code for getAllRanges.
The problem appeared while accessing a bootstraping node via nodetool, giving the following

Exception in thread "main" java.lang.ArrayIndexOutOfBoundsException: -1
        at java.util.ArrayList.get(
        at java.util.Collections$UnmodifiableList.get(
        at org.apache.cassandra.service.StorageService.getAllRanges(
        at org.apache.cassandra.service.StorageService.getRangeToAddressMap(
        at org.apache.cassandra.service.StorageService.getRangeToEndPointMap(
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
        at sun.reflect.NativeMethodAccessorImpl.invoke(
        at sun.reflect.DelegatingMethodAccessorImpl.invoke(
        at java.lang.reflect.Method.invoke(
        at com.sun.jmx.mbeanserver.StandardMBeanIntrospector.invokeM2(
        at com.sun.jmx.mbeanserver.StandardMBeanIntrospector.invokeM2(
        at com.sun.jmx.mbeanserver.MBeanIntrospector.invokeM(
        at com.sun.jmx.mbeanserver.PerInterface.invoke(
        at com.sun.jmx.mbeanserver.MBeanSupport.invoke(
        at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(
        at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(

Basically, no test is performed for non-emptyness of the input token list. If such list should
never be empty, I guess this should be explicit in the interface/javadoc, otherwise I'm attaching
a patch & testcase (pretty silly code, but the test passes :) ) 

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message