Search code examples
javajarexecutable-jaravro

Run Apache Avro on command line


I followed this tutorial to use Avro on command-line. I downloaded avro jar from here. Then, I followed the tutorial run command:

java -jar ~/avro-tools-1.7.5.jar

I expected to see the "Available tools" as output like the tutorial shows, but I got error message:

no main manifest attribute, in avro-1.7.5.jar

I also tried command java jar t avro-1.7.5.jar , but I got error message:

Error: Could not find or load main class jar

Is the tutorial wrong or did I do something wrong?


Solution

  • It seems you downloaded the main avro jar (avro-1.7.5.jar) and not the tools jar (avro-tools-1.7.5.jar). You should be good once you download the right jar file.