The producer performance class is not included in the binary release.
You can build it from the source release (as you attempted) - although
you need to use gradle. Just run "./gradlew jar" - you can see the
README.md file for more information.

Joel

On Fri, May 23, 2014 at 02:17:21PM -0500, Chris Neal wrote:
> Hi everyone.
> 
> Looking for some help running the Kafka performance testing shell script.
> First got the NoClassDefFound error, and then built from src from these
> instructions:
> 
> wget http://archive.apache.org/dist/kafka/0.8.1.1/kafka-0.8.1.1-src.tgz
> tar -xvf kafka-0.8.1.1-src.tgz
> cd kafka-0.8.1.1-src
> sbt update
> sbt package
> sbt assembly-package-dependency
> 
> The 'sbt assembly-package-dependency' gave this error:
> 
> cneal@chriss-mbp[574]:~/workspace/kafka-0.8.1.1-src> sbt
> assembly-package-dependency
> [info] Set current project to kafka-0-8-1-1-src (in build
> file:/Users/cneal/workspace/kafka-0.8.1.1-src/)
> [error] Not a valid command: assembly-package-dependency
> [error] Not a valid project ID: assembly-package-dependency
> [error] Expected ':' (if selecting a configuration)
> [error] Not a valid key: assembly-package-dependency (similar:
> sbt-dependency)
> [error] assembly-package-dependency
> [error]
> 
> I tried running the suggested 'sbt-dependency' and got this:
> 
> cneal@chriss-mbp[579]:~/workspace/kafka-0.8.1.1-src> sbt sbt-dependency
> [info] Set current project to kafka-0-8-1-1-src (in build
> file:/Users/cneal/workspace/kafka-0.8.1.1-src/)
> [info] org.scala-sbt:sbt:0.13.2
> 
> ...which sure didn't seem like it did anything.  I'm running sbt-0.13.2 on
> a Mac.
> 
> But I still found this JAR file that seemed to have the classes required:
> 
> /workspace/kafka-0.8.1.1-src/system_test/migration_tool_testsuite/0.7/lib>
> ls -l
> total 2800
> -rw-r--r--@ 1 cneal  staff  1306797 Apr 22 18:37 kafka-0.7.0.jar
> *-rw-r--r--@ 1 cneal  staff    55427 Apr 22 18:37 kafka-perf-0.7.0.jar*
> -rw-r--r--@ 1 cneal  staff    62913 Apr 22 18:37 zkclient-0.1.jar
> 
> But then when I run the .sh scripts as follows, I get yet another exception:
> 
> root@ip-10-0-0-42[397]:/opt/kafka/kafka>
>    bin/kafka-producer-perf-test.sh --brokerinfo zk.connect=$ZOOKEEPER
> --topic test_input  --async --threads 2 --messages 100000
> 
> start.time, end.time, compression, message.size, batch.size,
> total.data.sent.in.MB, MB.sec, total.data.sent.in.nMsg, nMsg.sec
> Exception in thread "main" java.lang.NoSuchMethodError:
> scala.Predef$.intWrapper(I)Lscala/runtime/RichInt;
> at kafka.perf.ProducerPerformance$.main(ProducerPerformance.scala:57)
> at kafka.perf.ProducerPerformance.main(ProducerPerformance.scala)
> 
> Can someone please shed some light on how to get this to run?
> 
> Most appreciated,
> 
> Chris

Reply via email to