HDFS-2511. Add dev script to generate HDFS protobufs. (tucu)

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/trunk@1212609 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Alejandro Abdelnur 2011-12-09 20:21:19 +00:00
parent 38a19bc293
commit e7682e1496
18 changed files with 26 additions and 113620 deletions

View File

@ -93,6 +93,8 @@ Trunk (unreleased changes)
HDFS-2597 ClientNameNodeProtocol in Protocol Buffers (sanjay)
HDFS-2511. Add dev script to generate HDFS protobufs. (tucu)
OPTIMIZATIONS
HDFS-2477. Optimize computing the diff between a block report and the
namenode state. (Tomasz Nykiel via hairong)

View File

@ -205,6 +205,7 @@
</goals>
<configuration>
<sources>
<source>${project.build.directory}/generated-sources/java</source>
<source>${project.build.directory}/generated-src/main/jsp</source>
</sources>
</configuration>
@ -215,6 +216,29 @@
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<id>compile-proto</id>
<phase>generate-sources</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<target>
<echo file="${project.build.directory}/compile-proto.sh">
PROTO_DIR=${basedir}/src/main/proto
ls $PROTO_DIR &amp;> /dev/null
if [ $? = 0 ]; then
JAVA_DIR=${project.build.directory}/generated-sources/java
mkdir -p $JAVA_DIR
ls $PROTO_DIR/*.proto | xargs -n 1 protoc -I$PROTO_DIR --java_out=$JAVA_DIR
fi
</echo>
<exec executable="sh" dir="${project.build.directory}" failonerror="true">
<arg line="./compile-proto.sh"/>
</exec>
</target>
</configuration>
</execution>
<execution>
<id>create-web-xmls</id>
<phase>compile</phase>