java.lang.StringIndexOutOfBoundsException: String index out of range: 1

GitHub | GoogleCodeExporter | 2 years ago
  1. 0

    Install orcsites within Eclipse

    Google Groups | 6 years ago | Nguyen Kim Son
    java.lang.StringIndexOutOfBoundsException: String index out of range: 1
  2. 0

    Hi, We recently had a kafka node go down suddenly. When it came back up, it apparently had a corrupt recovery file, and refused to startup: {code} 2014-11-06 08:17:19,299 WARN [main] server.KafkaServer - Error starting up KafkaServer java.lang.NumberFormatException: For input string: "^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@ ^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@" at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65) at java.lang.Integer.parseInt(Integer.java:481) at java.lang.Integer.parseInt(Integer.java:527) at scala.collection.immutable.StringLike$class.toInt(StringLike.scala:229) at scala.collection.immutable.StringOps.toInt(StringOps.scala:31) at kafka.server.OffsetCheckpoint.read(OffsetCheckpoint.scala:76) at kafka.log.LogManager$$anonfun$loadLogs$1.apply(LogManager.scala:106) at kafka.log.LogManager$$anonfun$loadLogs$1.apply(LogManager.scala:105) at scala.collection.IndexedSeqOptimized$class.foreach(IndexedSeqOptimized.scala:33) at scala.collection.mutable.WrappedArray.foreach(WrappedArray.scala:34) at kafka.log.LogManager.loadLogs(LogManager.scala:105) at kafka.log.LogManager.<init>(LogManager.scala:57) at kafka.server.KafkaServer.createLogManager(KafkaServer.scala:275) at kafka.server.KafkaServer.startup(KafkaServer.scala:72) {code} And the app is under a monitor (so it was repeatedly restarting and failing with this error for several minutes before we got to it)… We moved the ‘recovery-point-offset-checkpoint’ file out of the way, and it then restarted cleanly (but of course re-synced all it’s data from replicas, so we had no data loss). Anyway, I’m wondering if that’s the expected behavior? Or should it not declare it corrupt and then proceed automatically to an unclean restart? Should this NumberFormatException be handled a bit more gracefully? We saved the corrupt file if it’s worth inspecting (although I doubt it will be useful!)…. The corrupt files appeared to be all zeroes.

    Apache's JIRA Issue Tracker | 2 years ago | Jason Rosenberg
    java.lang.NumberFormatException: For input string: "^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@ ^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@"
  3. Speed up your debug routine!

    Automated exception search integrated into your IDE

  4. 0

    StringIndexOutOfBoundsException on both tree and graph

    GitHub | 4 years ago | hedefalk
    java.lang.StringIndexOutOfBoundsException: String index out of range: 168
  5. 0

    GitHub comment 348#265054459

    GitHub | 1 month ago | dsblr
    java.lang.RuntimeException: [1.11] failure: end of input job_admin. ^

  1. tyson925 1 times, last 2 days ago
  2. Torasque 1 times, last 4 weeks ago
  3. Hronom 32257 times, last 1 month ago
  4. filpgame 6 times, last 1 month ago
  5. harshg 2 times, last 4 months ago
10 more registered users
18 unregistered visitors
Not finding the right solution?
Take a tour to get the most out of Samebug.

Tired of useless tips?

Automated exception search integrated into your IDE

Root Cause Analysis

  1. java.lang.StringIndexOutOfBoundsException

    String index out of range: 1

    at java.lang.String.charAt()
  2. Java RT
    String.charAt
    1. java.lang.String.charAt(Unknown Source)
    1 frame
  3. Scala
    StringOps.apply
    1. scala.collection.immutable.StringLike$class.apply(StringLike.scala:54)
    2. scala.collection.immutable.StringOps.apply(StringOps.scala:31)
    2 frames
  4. orc.compile.parse
    OrcInputContext$$anonfun$resolve$1.apply
    1. orc.compile.parse.OrcInputContext$class.looksLikeFilename$1(Input.scala:118)
    2. orc.compile.parse.OrcInputContext$class.nameToURI$1(Input.scala:120)
    3. orc.compile.parse.OrcInputContext$$anonfun$resolve$1.apply(Input.scala:121)
    4. orc.compile.parse.OrcInputContext$$anonfun$resolve$1.apply(Input.scala:121)
    4 frames
  5. Scala
    WrappedArray.foldLeft
    1. scala.collection.IndexedSeqOptimized$class.foldl(IndexedSeqOptimized.scala:64)
    2. scala.collection.IndexedSeqOptimized$class.foldLeft(IndexedSeqOptimized.scala:73)
    3. scala.collection.mutable.WrappedArray.foldLeft(WrappedArray.scala:32)
    3 frames
  6. orc.compile.parse
    OrcInputContext$class.resolve
    1. orc.compile.parse.OrcInputContext$class.resolve(Input.scala:121)
    1 frame
  7. orc.compile
    StandardOrcCompiler$OrcNullInputContext$.resolve
    1. orc.compile.StandardOrcCompiler$OrcNullInputContext$.resolve(OrcCompiler.scala:295)
    1 frame
  8. orc.compile.parse
    OrcInputContext$class.newInputFromPath
    1. orc.compile.parse.OrcInputContext$class.newInputFromPath(Input.scala:125)
    1 frame
  9. orc.compile
    StandardOrcCompiler$$anonfun$openInclude$2.apply
    1. orc.compile.StandardOrcCompiler$OrcNullInputContext$.newInputFromPath(OrcCompiler.scala:295)
    2. orc.compile.StandardOrcCompiler$$anonfun$openInclude$2.apply(OrcCompiler.scala:315)
    3. orc.compile.StandardOrcCompiler$$anonfun$openInclude$2.apply(OrcCompiler.scala:308)
    3 frames
  10. Scala
    JavaConversions$JCollectionWrapper.foreach
    1. scala.collection.Iterator$class.foreach(Iterator.scala:631)
    2. scala.collection.JavaConversions$JIteratorWrapper.foreach(JavaConversions.scala:474)
    3. scala.collection.IterableLike$class.foreach(IterableLike.scala:79)
    4. scala.collection.JavaConversions$JCollectionWrapper.foreach(JavaConversions.scala:495)
    4 frames
  11. orc.compile
    CoreOrcCompiler$$anon$4$$anonfun$apply$6$$anonfun$1.apply
    1. orc.compile.StandardOrcCompiler.openInclude(OrcCompiler.scala:308)
    2. orc.compile.CoreOrcCompiler$$anon$4$$anonfun$apply$6$$anonfun$1.apply(OrcCompiler.scala:113)
    3. orc.compile.CoreOrcCompiler$$anon$4$$anonfun$apply$6$$anonfun$1.apply(OrcCompiler.scala:112)
    3 frames
  12. Scala
    JavaConversions$JListWrapper.map
    1. scala.collection.TraversableLike$$anonfun$map$1.apply(TraversableLike.scala:206)
    2. scala.collection.TraversableLike$$anonfun$map$1.apply(TraversableLike.scala:206)
    3. scala.collection.Iterator$class.foreach(Iterator.scala:631)
    4. scala.collection.JavaConversions$JIteratorWrapper.foreach(JavaConversions.scala:474)
    5. scala.collection.IterableLike$class.foreach(IterableLike.scala:79)
    6. scala.collection.JavaConversions$JListWrapper.foreach(JavaConversions.scala:521)
    7. scala.collection.TraversableLike$class.map(TraversableLike.scala:206)
    8. scala.collection.JavaConversions$JListWrapper.map(JavaConversions.scala:521)
    8 frames
  13. orc.compile
    StandardOrcCompiler.apply
    1. orc.compile.CoreOrcCompiler$$anon$4$$anonfun$apply$6.apply(OrcCompiler.scala:112)
    2. orc.compile.CoreOrcCompiler$$anon$4$$anonfun$apply$6.apply(OrcCompiler.scala:105)
    3. orc.compile.CompilerPhase$$anon$2$$anonfun$apply$2.apply(OrcCompiler.scala:70)
    4. orc.compile.CompilerPhase$$anon$1$$anonfun$apply$1.apply(OrcCompiler.scala:59)
    5. orc.compile.CompilerPhase$$anon$1$$anonfun$apply$1.apply(OrcCompiler.scala:59)
    6. orc.compile.CompilerPhase$$anon$1$$anonfun$apply$1.apply(OrcCompiler.scala:59)
    7. orc.compile.CompilerPhase$$anon$1$$anonfun$apply$1.apply(OrcCompiler.scala:59)
    8. orc.compile.CompilerPhase$$anon$1$$anonfun$apply$1.apply(OrcCompiler.scala:59)
    9. orc.compile.CompilerPhase$$anon$1$$anonfun$apply$1.apply(OrcCompiler.scala:59)
    10. orc.compile.CompilerPhase$$anon$1$$anonfun$apply$1.apply(OrcCompiler.scala:59)
    11. orc.compile.CompilerPhase$$anon$1$$anonfun$apply$1.apply(OrcCompiler.scala:59)
    12. orc.compile.CompilerPhase$$anon$1$$anonfun$apply$1.apply(OrcCompiler.scala:59)
    13. orc.compile.CoreOrcCompiler.apply(OrcCompiler.scala:256)
    14. orc.compile.StandardOrcCompiler.apply(OrcCompiler.scala:280)
    15. orc.compile.StandardOrcCompiler.apply(OrcCompiler.scala:292)
    15 frames
  14. orc.script
    OrcScriptEngine.compile
    1. orc.script.OrcScriptEngine.compile(OrcScriptEngine.java:204)
    1 frame
  15. orc
    Main.main
    1. orc.Main$.main(Main.scala:60)
    2. orc.Main.main(Main.scala)
    2 frames