-
Language:
English
-
Language:
English
Red Hat Training
A Red Hat training course is available for Red Hat Fuse
6.2. Using the tasks in build files
Adding the JBI tasks to build an Ant file
taskdef
element, as shown in Example 6.5.
Example 6.5. Adding the JBI tasks to an Ant build file
... <property name="fuseesb.install_dir" value="/home/fuse_esb"/> 1 <taskdef file="${fuseesb.install_dir}/ant/servicemix_ant_taskdef.properties"> 2 <classpath id="fuseesb.classpath"> 3 <fileset dir="${fuseesb.install_dir}"> <include name="*.jar"/> </fileset> <fileset dir="${fuseesb.install_dir}/lib"> <include name="*.jar"/> </fileset> </classpath> </taskdef> ...
Installing a component
jbi-install-component
. Its attributes are listed in Table 6.8.
Table 6.8. Attributes for installing a JBI component using an Ant task
Example 6.6. Ant target that installs a JBI component
... <target name="installDrools" description="Installs the drools engine."> <jbi-install-component port="1099" file="servicemix-drools-3.3.0.6-fuse-installer.zip" /> </target> ...
Removing a component
jbi-uninstall-component
. Its attributes are listed in Table 6.9.
Table 6.9. Attributes for removing a JBI component using an Ant task
Example 6.7. Ant target that removes a JBI component
... <target name="removeDrools" description="Removes the drools engine."> <jbi-uninstall-component port="1099" name="servicemix-drools" /> </target> ...
Starting a component
jbi-start-component
. Its attributes are listed in Table 6.10.
Table 6.10. Attributes for starting a JBI component using an Ant task
Example 6.8. Ant target that starts a JBI component
... <target name="startDrools" description="Starts the drools engine."> <jbi-start-component port="1099" name="servicemix-drools" /> </target> ...
Stopping a component
jbi-start-component
. Its attributes are listed in Table 6.11.
Table 6.11. Attributes for stopping a JBI component using an Ant task
Example 6.9. Ant target that stops a JBI component
... <target name="stopDrools" description="Stops the drools engine."> <jbi-stop-component port="1099" name="servicemix-drools" /> </target> ...
Shutting down a component
jbi-shut-down-component
. Its attributes are listed in Table 6.12.
Table 6.12. Attributes for shutting down a JBI component using an Ant task
Example 6.10. Ant target that shuts down a JBI component
... <target name="shutdownDrools" description="Stops the drools engine."> <jbi-shut-down-component port="1099" name="servicemix-drools" /> </target> ...
Installing a shared library
jbi-install-shared-library
. Its attributes are listed in Table 6.13.
Table 6.13. Attributes for installing a shared library using an Ant task
Removing a shared library
jbi-uninstall-shared-library
. Its attributes are listed in Table 6.14.
Table 6.14. Attributes for removing a shared library using an Ant task