avro-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Deepak Nettem <deepaknet...@gmail.com>
Subject Code Generation from avsc files
Date Fri, 30 Mar 2012 13:32:10 GMT
Hi,

I have a .avsc schema file in my maven project, and I am able to use it to
write simple avro apps. However, I am not able to generate source code
(classes) from the avro schema file to be able to use them in Avro
MapReduce code.

My pom.xml plugins section looks like this:

    <plugins>
    <plugin>
            <artifactId>maven-assembly-plugin</artifactId>
            <configuration>
                <archive>
                    <manifest>
                        <mainClass>org.avrotest.App</mainClass>
                    </manifest>
                </archive>
                 <manifestEntries>
          <Class-Path>../target/classes</Class-Path>
        </manifestEntries>
                <descriptorRefs>
                    <descriptorRef>jar-with-dependencies</descriptorRef>
                </descriptorRefs>
            </configuration>
        </plugin>

     <plugin>
        <groupId>org.apache.avro</groupId>
        <artifactId>avro-maven-plugin</artifactId>
        <version>1.6.1</version>
      </plugin>
    </plugins>

I package my jar by running

mvn compile
mvn assembly:single

Best,
Deepak

Mime
View raw message