java.lang.IndexOutOfBoundsException: Index: 99, Size: 0

tip

Thrown to indicate that an index of some sort (such as to an array, to a string, or to a vector) is out of range. Applications can subclass this class to indicate similar exceptions.


rafael

You have a different solution? A short tip here would help you and many other users who saw this issue last week.

  • Check serialization method
    via Stack Overflow by Aslan986
    ,
  • Performing a cross of two dataset of POJOs I have got the exception below. The first time I run the process, there was no problem. When I run it the second time, I have got the exception. My guess is that it could be a race condition related to the reuse of the Kryo serializer object. However, it could also be "a bug where type registrations are not properly forwarded to all Serializers", as suggested by Stephan. ------------------------------------------------------------------------ 2015-10-01 18:18:21 INFO JobClient:161 - 10/01/2015 18:18:21 Cross(Cross at main(FlinkMongoHadoop2LinkPOI2CDA.java:160))(3/4) switched to FAILED com.esotericsoftware.kryo.KryoException: Encountered unregistered class ID: 114 at com.esotericsoftware.kryo.util.DefaultClassResolver.readClass(DefaultClassResolver.java:119) at com.esotericsoftware.kryo.Kryo.readClass(Kryo.java:641) at com.esotericsoftware.kryo.Kryo.readClassAndObject(Kryo.java:752) at org.apache.flink.api.java.typeutils.runtime.kryo.KryoSerializer.deserialize(KryoSerializer.java:210) at org.apache.flink.api.java.typeutils.runtime.TupleSerializer.deserialize(TupleSerializer.java:127) at org.apache.flink.api.java.typeutils.runtime.TupleSerializer.deserialize(TupleSerializer.java:30) at org.apache.flink.runtime.operators.resettable.AbstractBlockResettableIterator.getNextRecord(AbstractBlockResettableIterator.java:180) at org.apache.flink.runtime.operators.resettable.BlockResettableMutableObjectIterator.next(BlockResettableMutableObjectIterator.java:111) at org.apache.flink.runtime.operators.CrossDriver.runBlockedOuterSecond(CrossDriver.java:309) at org.apache.flink.runtime.operators.CrossDriver.run(CrossDriver.java:162) at org.apache.flink.runtime.operators.RegularPactTask.run(RegularPactTask.java:489) at org.apache.flink.runtime.operators.RegularPactTask.invoke(RegularPactTask.java:354) at org.apache.flink.runtime.taskmanager.Task.run(Task.java:581) at java.lang.Thread.run(Thread.java:745)
    via by Stefano Bortoli,
    • java.lang.IndexOutOfBoundsException: Index: 99, Size: 0 at java.util.ArrayList.rangeCheck(ArrayList.java:653)[na:1.8.0_73] at java.util.ArrayList.get(ArrayList.java:429)[na:1.8.0_73] at com.esotericsoftware.kryo.util.MapReferenceResolver.getReadObject(MapReferenceResolver.java:42)[kryo-2.24.0.jar:na] at com.esotericsoftware.kryo.Kryo.readReferenceOrNull(Kryo.java:805)[kryo-2.24.0.jar:na] at com.esotericsoftware.kryo.Kryo.readClassAndObject(Kryo.java:759)[kryo-2.24.0.jar:na] at org.apache.flink.api.java.typeutils.runtime.kryo.KryoSerializer.deserialize(KryoSerializer.java:228)[flink-core-1.0.3.jar:1.0.3] at org.apache.flink.contrib.streaming.DataStreamIterator.readNextFromStream(DataStreamIterator.java:108)[flink-streaming-contrib-0.10.2.jar:0.10.2] at org.apache.flink.contrib.streaming.DataStreamIterator.hasNext(DataStreamIterator.java:78)[flink-streaming-contrib-0.10.2.jar:0.10.2] at com.example.controllers.MiningModelController.viewResults(MiningModelController.java:559)[classes/:na] at com.example.controllers.MiningModelController$$FastClassBySpringCGLIB$$d468bf0d.invoke(<generated>)[classes/:na] at org.springframework.cglib.proxy.MethodProxy.invoke(MethodProxy.java:204)[spring-core-4.2.5.RELEASE.jar:4.2.5.RELEASE] at org.springframework.aop.framework.CglibAopProxy$DynamicAdvisedInterceptor.intercept(CglibAopProxy.java:651)[spring-aop-4.2.5.RELEASE.jar:4.2.5.RELEASE] at com.example.controllers.MiningModelController$$EnhancerBySpringCGLIB$$de7f687c.viewResults(<generated>)[classes/:na] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)[na:1.8.0_73] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)[na:1.8.0_73] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)[na:1.8.0_73] at java.lang.reflect.Method.invoke(Method.java:497)[na:1.8.0_73] at org.springframework.web.method.support.InvocableHandlerMethod.doInvoke(InvocableHandlerMethod.java:221)[spring-web-4.2.5.RELEASE.jar:4.2.5.RELEASE]

    Users with the same issue

    Unknown visitor1 times, last one,
    Pilleo
    Pilleo9 times, last one,
    aidoan
    aidoan2 times, last one,
    nasimk
    nasimk2 times, last one,
    Axelo
    Axelo7 times, last one,
    234 more bugmates