Hi all,

We are getting closer and closer to releasing log4j 1.3 (and yes, we
will get there).  In the mean time if anyone is slightly curious about
the new Chainsaw v2 that will be a part of this release, I have written
an Ant-based 'installer' that takes a lot of the effort required to get
everything that is needed for it.  (see the attached file)  

Chainsaw v2 is stable and very useful right now, with a number of people
using it everyday for production use (monitoring sites using log4j
1.2.7+).  We are just adding more features to make it more enterprise
ready.

To run this installer, you need installed:

* Ant
* CVS

This script just checks out the latest jakarta-log4j cvs module to your
local machine, downloads some other required bits and pieces, and sets
up some configs.

You can run the installer by saving the attached xml file to a directory
where you would like Chainsaw installed, and typing:

ant -f install-chainsaw.xml

and follow the prompts.  After the installation, you can cd into the
jakarta-log4j directory and 'ant chainsaw' to run Chainsaw v2.

This script can be run at any time to update what has been downloaded so
you can toy with the latest version whenever you wish.

Feel free to ask questions on this list if you have any problems or
thoughts.

cheers, 

Paul Smith
<project name="install-chainsaw" default="install" basedir="." >

	<property name="module.dir" location="${basedir}"/>
  <property name="oro.file.name" value="jakarta-oro-2.0.7.zip" />
	<property name="oro.location" location="${module.dir}/${oro.file.name}" />
	<property name="oro.unzip.location" location="${module.dir}/" />

	<target name="install" depends="confirm,cvs,get-oro,create-build-properties, success-msg"/>

	<target name="confirm" depends="">
		<echo>
============================================================
CHAINSAW v2 installer
============================================================
This Ant build script will perform the following:
   * Download the jakarta-log4j module from the Apache CVS
   * Dowload the latest binary version of the Jakarta ORO project from www.ibiblio.org

It will create the following artifacts in the current directory (whereever this Ant script is)
   * a jarkarta-log4j directory, containing the log4j source tree
   * a jakarta-oro-2.0.7.zip file
   * a jakarta-oro-2.0.7 directory containing the unpacked ORO jar from the aforementioned zip file
    </echo>
    <input
      message="Are you OK with all of this?"
      validargs="y,n"
      addproperty="confirm"
    />
    <condition property="do.abort">
      <equals arg1="n" arg2="${confirm}"/>
    </condition>
    <fail if="do.abort">Installation aborted by user.</fail>
  </target>

  <target name="cvs" depends="">
    <cvs cvsRoot=":pserver:[EMAIL PROTECTED]:/home/cvspublic"
        package="jakarta-log4j"
        dest="${module.dir}"
        quiet="true"
    />
  </target>

	<target name="get-oro" depends="">
    <!-- <echo>${oro.location}</echo> -->
		  <get src="http://www.ibiblio.org/pub/mirrors/apache/jakarta/oro/${oro.file.name}";
    dest="${oro.location}"
    verbose="true"
    usetimestamp="true"/>

    <unzip src="${oro.location}"
          dest="${oro.unzip.location}">
        <patternset>
            <include name="jakarta-oro-2.0.7/jakarta-oro-2.0.7.jar"/>
        </patternset>
    </unzip>
  </target>


	<target name="create-build-properties" depends="">
    <copy file="${module.dir}/jakarta-log4j/build.properties.sample" tofile="${module.dir}/jakarta-log4j/build.properties">
    </copy>
    <replace file="${module.dir}/jakarta-log4j/build.properties">
      <replacetoken><![CDATA[#regexp.oro.jar=../oro/jakarta-oro-2.0.6.jar]]></replacetoken>
      <replacevalue><![CDATA[regexp.oro.jar=../jakarta-oro-2.0.7/jakarta-oro-2.0.7.jar]]>
</replacevalue>
    </replace>
  </target>

	<!--<target name="clean" depends="">

  </target>-->

  <target name="success-msg" depends="">
		<echo>
Installation completed successfully.

You should now be able to do the following to run Chainsaw v2:

  cd jakarta-log4j
  ant chainsaw

GOOD LUCK!
    </echo>
  </target>
</project>

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to