Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 352 lines (313 sloc) 12.842 kb
fbd0f95 @jkreps Initial import
jkreps authored
1 <?xml version="1.0"?>
2
3 <project name="voldemort" basedir="." default="all">
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
4 <property file="build.properties" />
5
6 <property name="name" value="voldemort" />
7 <property name="display.name" value="Voldemort" />
8 <property name="author" value="Jay Kreps" />
9 <property environment="env" />
10
11 <path id="main-classpath">
12 <fileset dir="${lib.dir}">
13 <include name="*.jar" />
14 </fileset>
15 <pathelement path="${classes.dir}" />
16 </path>
17
762e6f8 @jkreps Add a compatibility test for json data.
jkreps authored
18 <!-- set the build number based on environment variable, otherwise blank -->
2addb2d @bbansal Addded build-XX in Hudson Artificat names
bbansal authored
19 <property environment="env" description="System environment variables (including those set by Hudson)"/>
218f057 @bbansal Fixed unresolved ${curr.release} tags in artifacts.
bbansal authored
20 <condition property="curr.release.snapshot" value="${curr.release}-snapshot-${env.BUILD_NUMBER}" else="${curr.release}">
a49144e @bbansal Fixed snapshot naming issue if BUILD_NUMBER set to "".
bbansal authored
21 <and>
22 <isset property="env.BUILD_NUMBER" />
23 <not>
24 <equals arg1="" arg2="${env.BUILD_NUMBER}" trim="yes"/>
25 </not>
26 </and>
2addb2d @bbansal Addded build-XX in Hudson Artificat names
bbansal authored
27 </condition>
28
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
29 <path id="contrib-classpath">
30 <fileset dir="${dist.dir}">
31 <include name="${name}-${curr.release}.jar" />
32 </fileset>
33 <fileset dir="${contrib.root.dir}">
34 <include name="**/*.jar" />
35 </fileset>
36 <path refid="test-classpath" />
37 </path>
38
39 <path id="test-classpath">
40 <pathelement path="${env.VOLD_TEST_JARS}" />
41 <path refid="main-classpath" />
42 <pathelement path="${testclasses.dir}" />
43 </path>
44
45 <path id="contrib-test-classpath">
46 <path refid="main-classpath" />
47 <path refid="contrib-classpath" />
48 <fileset dir="${dist.dir}">
49 <include name="${name}-contrib-${curr.release}.jar" />
50 </fileset>
51 </path>
52
53 <macrodef name="replace-dir">
54 <attribute name="dir" />
55 <sequential>
56 <delete dir="@{dir}" />
57 <mkdir dir="@{dir}" />
58 </sequential>
59 </macrodef>
60
2cb9de1 @jkreps Add target to build release artifacts.
jkreps authored
61 <target name="all" depends="clean, jar, test, contrib-jar, srcjar" description="Build all artifacts." />
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
62
63 <target name="clean" description="Delete generated files.">
64 <delete dir="${dist.dir}" />
65 <replace-dir dir="${javadoc.dir}" />
66 </target>
1b78867 @bbansal ReadOnly store batch data indexer package as contrib.
bbansal authored
67
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
68 <target name="build" description="Compile main source tree java files">
69 <replace-dir dir="${classes.dir}" />
70 <!-- copy non-java files to classes dir to load from classpath -->
71 <copy todir="${classes.dir}">
72 <fileset dir="${java.dir}">
73 <exclude name="**/*.java" />
74 <exclude name="**/*.html" />
d628362 @jkreps Merge in changes from li-918 branch.
jkreps authored
75 <exclude name="**/log4j.properties" />
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
76 </fileset>
77 </copy>
2d1b21b @jkreps Add log4j.properties to classpath for shell scripts.
jkreps authored
78 <!-- place to put log4j.properties -->
79 <replace-dir dir="${resources.dir}"/>
80 <copy file="${java.dir}/log4j.properties" todir="${resources.dir}"/>
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
81 <javac destdir="${classes.dir}" target="1.5" debug="true" deprecation="true" failonerror="true">
82 <src path="${java.dir}" />
83 <classpath refid="main-classpath" />
84 </javac>
85 </target>
1b78867 @bbansal ReadOnly store batch data indexer package as contrib.
bbansal authored
86
189a43d @jkreps Test ant target must copy in configs.
jkreps authored
87 <target name="buildtest" description="Compile test classes">
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
88 <replace-dir dir="${testclasses.dir}" />
189a43d @jkreps Test ant target must copy in configs.
jkreps authored
89 <copy todir="${testclasses.dir}">
90 <fileset dir="${commontestsrc.dir}">
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
91 <exclude name="**/*.java" />
92 <exclude name="**/*.html" />
189a43d @jkreps Test ant target must copy in configs.
jkreps authored
93 </fileset>
94 </copy>
762e6f8 @jkreps Add a compatibility test for json data.
jkreps authored
95 <copy todir="${testclasses.dir}">
96 <fileset dir="${unittestsrc.dir}">
97 <exclude name="**/*.java" />
98 <exclude name="**/*.html" />
99 </fileset>
100 </copy>
189a43d @jkreps Test ant target must copy in configs.
jkreps authored
101 <javac destdir="${testclasses.dir}" target="1.5" debug="true" deprecation="true" failonerror="true">
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
102 <src path="${unittestsrc.dir}" />
103 <src path="${inttestsrc.dir}" />
104 <src path="${commontestsrc.dir}" />
105 <classpath refid="main-classpath" />
189a43d @jkreps Test ant target must copy in configs.
jkreps authored
106 </javac>
107 </target>
1b78867 @bbansal ReadOnly store batch data indexer package as contrib.
bbansal authored
108
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
109 <target name="test" depends="build, buildtest" description="Build test jar file">
110 <jar destfile="${dist.dir}/${name}-test-${curr.release}.jar">
111 <fileset dir="${testclasses.dir}" />
112 </jar>
113 </target>
c49df1b @jkreps Add support for protocol buffers based network format. Add new client co...
jkreps authored
114
115 <target name="protobuff" description="Generate source files from .proto files">
71acbce Initial import of the protocol buffers based admin protocol.
Alex Feinberg authored
116 <pathconvert property="proto.sources" pathsep=" ">
117 <path id="proto-files">
118 <fileset dir="${protobuff.dir}" />
119 </path>
120 </pathconvert>
121
c49df1b @jkreps Add support for protocol buffers based network format. Add new client co...
jkreps authored
122 <property name="proto.path" location="${protobuff.dir}"/>
123 <property name="javaout.path" location="${java.dir}"/>
3dba9b7 First pass at python client. Still incomplete.
Jay Kreps authored
124 <property name="pythonout.path" location="${python.dir}"/>
c49df1b @jkreps Add support for protocol buffers based network format. Add new client co...
jkreps authored
125 <exec executable="protoc" failonerror="true">
126 <arg value="--proto_path=${proto.path}"/>
127 <arg value="--java_out=${javaout.path}"/>
3dba9b7 First pass at python client. Still incomplete.
Jay Kreps authored
128 <arg value="--python_out=${pythonout.path}"/>
71acbce Initial import of the protocol buffers based admin protocol.
Alex Feinberg authored
129 <arg line="${proto.sources}"/>
c49df1b @jkreps Add support for protocol buffers based network format. Add new client co...
jkreps authored
130 </exec>
131 </target>
1b78867 @bbansal ReadOnly store batch data indexer package as contrib.
bbansal authored
132
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
133 <target name="jar" depends="build" description="Build server jar file">
134 <jar destfile="${dist.dir}/${name}-${curr.release}.jar">
135 <fileset dir="${classes.dir}">
136 <include name="**/*.*" />
137 </fileset>
138 <!-- include xsds -->
139 <fileset dir="${java.dir}">
140 <include name="**/*.xsd" />
141 </fileset>
142 </jar>
143 </target>
1b78867 @bbansal ReadOnly store batch data indexer package as contrib.
bbansal authored
144
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
145 <target name="srcjar" description="Build source jar file">
146 <mkdir dir="${dist.dir}" />
147 <jar destfile="${dist.dir}/${name}-${curr.release}-src.jar">
148 <fileset dir="${java.dir}">
149 <include name="**/*.java" />
150 </fileset>
151 </jar>
152 </target>
c49df1b @jkreps Add support for protocol buffers based network format. Add new client co...
jkreps authored
153
d2274da @jkreps Misc. read-only store improvements. Some cleanup in hadoop contrib.
jkreps authored
154 <target name="alljar" depends="build, contrib-build" description="Build a jar file that includes all contrib code.">
155 <jar destfile="${dist.dir}/${name}-${curr.release}-all.jar">
156 <fileset dir="${classes.dir}">
157 <include name="**/*.*" />
158 </fileset>
159 <fileset dir="${contrib.classes.dir}">
160 <include name="**/*.*" />
161 </fileset>
162 <!-- include xsds -->
163 <fileset dir="${java.dir}">
164 <include name="**/*.xsd" />
165 </fileset>
166 </jar>
167 </target>
168
c49df1b @jkreps Add support for protocol buffers based network format. Add new client co...
jkreps authored
169 <target name="war" depends="build" description="Build server war file">
170 <war destfile="${dist.dir}/${name}.war" webxml="web.xml" basedir="${classes.dir}">
171 <classes dir="${classes.dir}"/>
172 <lib dir="${lib.dir}">
9bdc948 @ijuma Issue 113: Upgrade various dependencies
ijuma authored
173 <exclude name="${lib.dir}/servlet-api*.jar"/>
c49df1b @jkreps Add support for protocol buffers based network format. Add new client co...
jkreps authored
174 <exclude name="${lib.dir}/src/**"/>
175 </lib>
176 </war>
177 </target>
1b78867 @bbansal ReadOnly store batch data indexer package as contrib.
bbansal authored
178
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
179 <target name="contrib-build" depends="build, buildtest" description="Compile contrib packages (java and test) ">
180 <replace-dir dir="${contrib.classes.dir}" />
181 <javac destdir="${contrib.classes.dir}" target="1.5" debug="true" deprecation="true" failonerror="true">
182 <src path="${contrib.root.dir}" />
183 <src path="${contrib.root.dir}" />
184 <classpath refid="main-classpath" />
185 <classpath refid="contrib-classpath" />
186 </javac>
52cc393 @kirktrue Fixed build problem.
kirktrue authored
187 <copy todir="${contrib.classes.dir}">
188 <fileset dir="${contrib.root.dir}/ec2-testing/resources" />
189 </copy>
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
190 </target>
1b78867 @bbansal ReadOnly store batch data indexer package as contrib.
bbansal authored
191
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
192 <target name="contrib-jar" depends="contrib-build" description="Build contrib jar file">
193 <jar destfile="${dist.dir}/${name}-contrib-${curr.release}.jar">
194 <fileset dir="${contrib.classes.dir}">
195 <include name="**/*.*" />
196 </fileset>
197 </jar>
198 </target>
1b78867 @bbansal ReadOnly store batch data indexer package as contrib.
bbansal authored
199
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
200 <target name="contrib-srcjar" description="Build contrib source jar file">
201 <mkdir dir="${dist.dir}" />
202 <jar destfile="${dist.dir}/${name}-contrib-${curr.release}-src.jar">
203 <fileset dir="${contrib.root.dir}/**/java">
204 <include name="**/*.java" />
205 </fileset>
206 </jar>
207 </target>
1b78867 @bbansal ReadOnly store batch data indexer package as contrib.
bbansal authored
208
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
209 <target name="contrib-junit" depends="contrib-jar" description="Run contrib junit tests.">
210 <replace-dir dir="${contribtestreport.dir}" />
211 <replace-dir dir="${contribtesthtml.dir}" />
212 <junit printsummary="yes" maxmemory="1024m" showoutput="true" failureProperty="test.failure">
213 <classpath refid="contrib-test-classpath" />
214 <formatter type="xml" />
215 <batchtest fork="yes" todir="${contribtestreport.dir}">
216 <fileset dir="${contrib.classes.dir}">
217 <include name="**/*Test.class" />
218 <exclude name="**/*PerformanceTest.class" />
219 </fileset>
220 </batchtest>
221 </junit>
222 <junitreport todir="${contribtesthtml.dir}">
223 <fileset dir="${contribtestreport.dir}">
224 <include name="TEST-*.xml" />
225 </fileset>
226 <report todir="${contribtesthtml.dir}" format="frames" />
227 </junitreport>
228 </target>
2cb9de1 @jkreps Add target to build release artifacts.
jkreps authored
229
5a07888 @bbansal Modified Ant target 'release' and added new target 'snapshot'.
bbansal authored
230
231 <macrodef name="create-release-artifacts">
232 <attribute name="version" />
233 <sequential>
234 <antcall target="all"/>
218f057 @bbansal Fixed unresolved ${curr.release} tags in artifacts.
bbansal authored
235 <zip destfile="${dist.dir}/${name}-@{version}.zip">
236 <zipfileset dir="." prefix="voldemort-@{version}" filemode="755" includes="bin/*"/>
237 <zipfileset dir="." prefix="voldemort-@{version}" includes="**">
2cb9de1 @jkreps Add target to build release artifacts.
jkreps authored
238 <exclude name="${dist.dir}/*classes"/>
239 <exclude name="bin/*"/>
3c3b935 @afeinberg Modified build.xml to exclude the .git directory from the tarball.
afeinberg authored
240 <exclude name=".git*/**"/>
2cb9de1 @jkreps Add target to build release artifacts.
jkreps authored
241 </zipfileset>
242 </zip>
218f057 @bbansal Fixed unresolved ${curr.release} tags in artifacts.
bbansal authored
243 <tar destfile="${dist.dir}/${name}-@{version}.tar.gz" compression="gzip" longfile="gnu">
244 <tarfileset dir="." prefix="voldemort-@{version}" filemode="755" includes="bin/*"/>
245 <tarfileset dir="." prefix="voldemort-@{version}" includes="**">
2cb9de1 @jkreps Add target to build release artifacts.
jkreps authored
246 <exclude name="${dist.dir}/*classes"/>
247 <exclude name="${dist.dir}/*.zip"/>
248 <exclude name="bin/*"/>
3c3b935 @afeinberg Modified build.xml to exclude the .git directory from the tarball.
afeinberg authored
249 <exclude name=".git*/**"/>
2cb9de1 @jkreps Add target to build release artifacts.
jkreps authored
250 </tarfileset>
251 </tar>
5a07888 @bbansal Modified Ant target 'release' and added new target 'snapshot'.
bbansal authored
252 </sequential>
253 </macrodef>
254
255 <target name="snapshot" description="Create a release-snapshot zip file with everything pre-built.">
256 <create-release-artifacts version="${curr.release.snapshot}" />
257 </target>
258
259 <target name="release" description="Create a release zip file with everything pre-built.">
218f057 @bbansal Fixed unresolved ${curr.release} tags in artifacts.
bbansal authored
260 <create-release-artifacts version="${curr.release}" />
2cb9de1 @jkreps Add target to build release artifacts.
jkreps authored
261 </target>
f77aff6 @jkreps Read-only store improvements: (1) Break store into chunks so that multip...
jkreps authored
262
2a99b18 @jkreps Better docs and some cleanup for hadoop store builder.
jkreps authored
263 <target name="hadoop-benchmark-jar" depends="build, contrib-build"
264 description="Build a jar file that includes all contrib code plus the necessary jars for running the hadoop benchmark.">
265 <jar destfile="${dist.dir}/hadoop-benchmark.jar">
f77aff6 @jkreps Read-only store improvements: (1) Break store into chunks so that multip...
jkreps authored
266 <fileset dir="${classes.dir}">
267 <include name="**/*.*" />
268 </fileset>
269 <fileset dir="${contrib.classes.dir}">
270 <include name="**/*.*" />
271 </fileset>
272 <!-- include xsds -->
273 <fileset dir="${java.dir}">
274 <include name="**/*.xsd" />
275 </fileset>
276 <fileset dir="">
9bdc948 @ijuma Issue 113: Upgrade various dependencies
ijuma authored
277 <include name="lib/jdom*.jar"/>
f77aff6 @jkreps Read-only store improvements: (1) Break store into chunks so that multip...
jkreps authored
278 <include name="lib/google-collect*.jar"/>
279 <include name="lib/commons-lang*.jar"/>
280 </fileset>
281 </jar>
282 </target>
1b78867 @bbansal ReadOnly store batch data indexer package as contrib.
bbansal authored
283
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
284 <target name="junit" depends="build, buildtest" description="Run junit tests.">
285 <replace-dir dir="${testreport.dir}" />
286 <replace-dir dir="${testhtml.dir}" />
ce3d234 @bbansal unit test fixes.
bbansal authored
287 <junit printsummary="yes" showoutput="true" maxmemory="1024m">
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
288 <classpath refid="test-classpath" />
289 <formatter type="xml" />
290 <batchtest fork="yes" todir="${testreport.dir}">
291 <fileset dir="${unittestsrc.dir}">
292 <include name="**/*Test.java" />
293 <exclude name="**/Abstract*.java" />
294 </fileset>
295 </batchtest>
296 </junit>
297 <junitreport todir="${testhtml.dir}">
298 <fileset dir="${testreport.dir}">
299 <include name="TEST-*.xml" />
300 </fileset>
301 <report todir="${testhtml.dir}" format="frames" />
302 </junitreport>
303 </target>
8afb67c @bbansal Fixing failing contrib tests.
bbansal authored
304
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
305 <target name="junit-all" depends="junit, contrib-junit" description="Run All junit tests including contrib.">
306 </target>
1b78867 @bbansal ReadOnly store batch data indexer package as contrib.
bbansal authored
307
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
308 <macrodef name="make-javadocs">
309 <attribute name="dir" />
310 <attribute name="packagenames" />
c285d2e @jkreps Fix javadoc problems.
jkreps authored
311 <attribute name="javadir" />
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
312 <sequential>
313 <replace-dir dir="@{dir}" />
c285d2e @jkreps Fix javadoc problems.
jkreps authored
314 <javadoc sourcepath="@{javadir}" destdir="@{dir}" windowtitle="${display.name}" source="1.5" author="true" version="true" use="true" packagenames="@{packagenames}">
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
315 <doctitle>${display.name}</doctitle>
316 <bottom>${author}</bottom>
317 <classpath refid="main-classpath" />
318 </javadoc>
319 </sequential>
320 </macrodef>
321
322 <target name="docs" description="Create complete Javadoc documentation">
c285d2e @jkreps Fix javadoc problems.
jkreps authored
323 <make-javadocs dir="${javadoc.dir}/all" packagenames="*" javadir="${java.dir}"/>
324 <make-javadocs dir="${javadoc.dir}/client" packagenames="voldemort.versioning.*, voldemort.client.*,voldemort.serialization.*" javadir="${java.dir}"/>
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
325 </target>
1b78867 @bbansal ReadOnly store batch data indexer package as contrib.
bbansal authored
326
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
327 <target name="redeploy" depends="war, deploy">
328 </target>
1b78867 @bbansal ReadOnly store batch data indexer package as contrib.
bbansal authored
329
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
330 <taskdef file="tomcat-tasks.properties">
331 <classpath>
332 <path location="${lib.dir}/catalina-ant.jar" />
333 </classpath>
334 </taskdef>
1b78867 @bbansal ReadOnly store batch data indexer package as contrib.
bbansal authored
335
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
336 <target name="list" description="List Tomcat applications">
337 <list url="${tomcat.manager.url}" username="${tomcat.manager.username}" password="${tomcat.manager.password}" />
338 </target>
fbd0f95 @jkreps Initial import
jkreps authored
339
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
340 <target name="deploy" description="Deploy application" depends="war">
341 <deploy url="${tomcat.manager.url}" username="${tomcat.manager.username}" password="${tomcat.manager.password}" path="${tomcat.context}" update="true" war="file:${dist.dir}/${name}.war" />
342 </target>
fbd0f95 @jkreps Initial import
jkreps authored
343
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
344 <target name="undeploy" description="Undeploy application">
345 <undeploy url="${tomcat.manager.url}"
fbd0f95 @jkreps Initial import
jkreps authored
346 username="${tomcat.manager.username}"
347 password="${tomcat.manager.password}"
348 path="${tomcat.context}"/>
11ecbeb @jkreps Add plugin mechanism for storage engines plus MongoDB plugin.
jkreps authored
349 </target>
fbd0f95 @jkreps Initial import
jkreps authored
350
351 </project>
Something went wrong with that request. Please try again.