Uploaded image for project: 'Kafka'
  1. Kafka
  2. KAFKA-1364

ReplicaManagerTest hard-codes log dir

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.8.2.0
    • Component/s: core
    • Labels:
      None

      Description

      Saw the following unit test failure. This is probably due to that the hard-coded log.dir conflicts with the default config when running a standalone sack.

      kafka.server.ReplicaManagerTest > testHighwaterMarkDirectoryMapping FAILED
      java.lang.IllegalArgumentException: requirement failed: Corrupt index found, index file (/tmp/kafka-logs/test-topic-1/00000000000000000000.index) has non-zero size but the last offset is 0 and the base offset is 0
      at scala.Predef$.require(Predef.scala:145)
      at kafka.log.OffsetIndex.sanityCheck(OffsetIndex.scala:352)
      at kafka.log.Log$$anonfun$loadSegments$5.apply(Log.scala:159)
      at kafka.log.Log$$anonfun$loadSegments$5.apply(Log.scala:158)
      at scala.collection.Iterator$class.foreach(Iterator.scala:631)
      at scala.collection.JavaConversions$JIteratorWrapper.foreach(JavaConversions.scala:474)
      at scala.collection.IterableLike$class.foreach(IterableLike.scala:79)
      at scala.collection.JavaConversions$JCollectionWrapper.foreach(JavaConversions.scala:495)
      at kafka.log.Log.loadSegments(Log.scala:158)
      at kafka.log.Log.<init>(Log.scala:64)
      at kafka.server.ReplicaManagerTest.testHighwaterMarkDirectoryMapping(ReplicaManagerTest.scala:43)

        Attachments

        1. KAFKA-1364_2014-04-09_10:24:24.patch
          2 kB
          Guozhang Wang
        2. KAFKA-1364.patch
          2 kB
          Guozhang Wang

          Activity

            People

            • Assignee:
              guozhang Guozhang Wang
              Reporter:
              junrao Jun Rao
            • Votes:
              1 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: