|
@@ -307,6 +307,7 @@
|
|
|
Later on one can run 'ant jar-fault-inject' to create
|
|
|
Hadoop jar file with instrumented classes
|
|
|
-->
|
|
|
+ <property name="compile-inject.output" value="${build-fi.dir}/compile-fi.log"/>
|
|
|
<target name="compile-fault-inject" depends="compile-core, compile-hdfs-test">
|
|
|
<!-- AspectJ task definition -->
|
|
|
<taskdef
|
|
@@ -327,11 +328,26 @@
|
|
|
deprecation="${javac.deprecation}">
|
|
|
<classpath refid="test.classpath"/>
|
|
|
</iajc>
|
|
|
+ <loadfile property="injection.failure" srcfile="${compile-inject.output}">
|
|
|
+ <filterchain>
|
|
|
+ <linecontainsregexp>
|
|
|
+ <regexp pattern='iajc.*warning'/>
|
|
|
+ </linecontainsregexp>
|
|
|
+ </filterchain>
|
|
|
+ </loadfile>
|
|
|
+ <fail if="injection.failure">
|
|
|
+ Broken binding of advises: ${line.separator}${injection.failure}
|
|
|
+ </fail>
|
|
|
<echo message="Weaving of aspects is finished"/>
|
|
|
</target>
|
|
|
|
|
|
- <target name="injectfaults" description="Instrument HDFS classes with faults and other AOP advices">
|
|
|
- <subant buildpath="${basedir}" target="compile-fault-inject">
|
|
|
+ <target name="injectfaults"
|
|
|
+ description="Instrument HDFS classes with faults and other AOP advices">
|
|
|
+ <!--mkdir to prevent <subant> failure in case the folder has been removed-->
|
|
|
+ <mkdir dir="${build-fi.dir}"/>
|
|
|
+ <delete file="${compile-inject.output}"/>
|
|
|
+ <subant buildpath="${basedir}" target="compile-fault-inject"
|
|
|
+ output="${compile-inject.output}">
|
|
|
<property name="build.dir" value="${build-fi.dir}"/>
|
|
|
</subant>
|
|
|
</target>
|