Re: [5] Components / optional / compat
Costin Manolache wrote: Proposal: Let's split 5.0 code into several directories ( components - like in commons ). 'catalina' will remain the 'core' interfaces and required features ( i.e. the minimal stuff ). 'naming' for jndi stuff 'compat' for all the interfaces from 4.0 that we deprecate but preserve for backward compat ( Logger ? etc ). 'modules' for optional things. Launchers, specific realms, etc could go here. On a separate issue, there are few things that may be very usefull independent of tomcat, and even if we don't move them to commons we should try to make them independently useable: - naming - users - class loading - catalina has one of the most advanced loaders +1. Good idea. I'll help with the reorg if you can wait for next week. Remy -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
DO NOT REPLY [Bug 11417] - Coyote HTTP connector livelocks (possible DOS vulnerability)
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://nagoya.apache.org/bugzilla/show_bug.cgi?id=11417. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE. http://nagoya.apache.org/bugzilla/show_bug.cgi?id=11417 Coyote HTTP connector livelocks (possible DOS vulnerability) [EMAIL PROTECTED] changed: What|Removed |Added Status|NEW |RESOLVED Resolution||INVALID --- Additional Comments From [EMAIL PROTECTED] 2002-08-04 11:40 --- There's no syncing, so no possibility of a deadlock. The code will wait at that point in the code when doing some keepalive, so everything looks normal. -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
[5.0] Build notes
Hi. Just thought I would share the steps I followed to Build tomcat 5 on a RedHat 7.2 box. The box is net connected via DSL. I had already downloaded JDK1.4 and Ant1.5 $ mkdir tc5 $ cd tc5 $ export JAVA_HOME=/usr/java/j2sdk1.4.0 $ export PATH=$JAVA_HOME/bin:$PATH:/home/bob/tc5/jakarta-ant-1.5/bin $ cvs -d :pserver:[EMAIL PROTECTED]:/home/cvspublic login $ cvs -d :pserver:[EMAIL PROTECTED]:/home/cvspublic checkout jakarta-tomcat-5 jakarta-tomcat-connectors jakarta-tomcat-jasper jakarta-servletapi-5 jakarta-tomcat-catalina $ cd jakarta-tomcat-5 $ sed -e 's/^base.path=\/usr\/local$/base.path=\/home\/test\/tc5\/dependson/' build.properties.default t $ mv t build.properties.default $ mkdir /home/bob/tc5/dependson $ echo /home/bob/tc5/dependson/LICENSE $ ant download $ ant dist $ dist/bin/startup.sh $ tail /home/bob/tc5/jakarta-tomcat-5/dist/logs/catalina.out Cheers, -bob -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
[ANNOUNCEMENT] Tomcat 4.1.8 Beta
Tomcat 4.1.8 Beta has been released. It includes major bugfixes to Jasper over the previous Tomcat 4.1.7 Beta (please refer to the release notes for the complete list). Relese notes: http://jakarta.apache.org/builds/jakarta-tomcat-4.0/release/v4.1.8-beta/RELEASE-NOTES Downloads (source and binaries): http://jakarta.apache.org/builds/jakarta-tomcat-4.0/release/v4.1.8-beta/ Important note: When upgrading from another Tomcat 4.x release, Tomcat's work directory must be cleared. Remy -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: [5.0] Build notes
Bob Herrmann wrote: Hi. Just thought I would share the steps I followed to Build tomcat 5 on a RedHat 7.2 box. The box is net connected via DSL. I had already downloaded JDK1.4 and Ant1.5 $ mkdir tc5 $ cd tc5 $ export JAVA_HOME=/usr/java/j2sdk1.4.0 $ export PATH=$JAVA_HOME/bin:$PATH:/home/bob/tc5/jakarta-ant-1.5/bin $ cvs -d :pserver:[EMAIL PROTECTED]:/home/cvspublic login $ cvs -d :pserver:[EMAIL PROTECTED]:/home/cvspublic checkout jakarta-tomcat-5 jakarta-tomcat-connectors jakarta-tomcat-jasper jakarta-servletapi-5 jakarta-tomcat-catalina $ cd jakarta-tomcat-5 $ sed -e 's/^base.path=\/usr\/local$/base.path=\/home\/test\/tc5\/dependson/' build.properties.default t $ mv t build.properties.default $ mkdir /home/bob/tc5/dependson $ echo /home/bob/tc5/dependson/LICENSE $ ant download $ ant dist $ dist/bin/startup.sh $ tail /home/bob/tc5/jakarta-tomcat-5/dist/logs/catalina.out I'd like to wait a bit before we do some instructions, as the build may not be stable yet (see Costin's recent experimentation to try to make building faster). (it looks simpler than 4.x, though, and that's a good thing) Remy -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: [5.0] Build notes
Bob, Bob Herrmann wrote: $ sed -e 's/^base.path=\/usr\/local$/base.path=\/home\/test\/tc5\/dependson/' build.properties.default t $ mv t build.properties.default You don't want to replace build.properties.default. Instead you want to put your customized file in build.properties. That way, if build.properties.default changes, you will know. Also, using build.properties prevents accidental commits to build.properties.default. Patrick -- Patrick Luby Email: [EMAIL PROTECTED] Sun Microsystems Phone: 408-276-7471 901 San Antonio Road, USCA14-303 Palo Alto, CA 94303-4900 -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
cvs commit: jakarta-tomcat-5 build.xml
costin 2002/08/04 08:45:16 Modified:.build.xml Log: Reverse the order of property loading. ~/build.properties will be loaded first - and can override any other property. Next is ./build.properties, and finally build.properties.default Revision ChangesPath 1.17 +1 -1 jakarta-tomcat-5/build.xml Index: build.xml === RCS file: /home/cvs/jakarta-tomcat-5/build.xml,v retrieving revision 1.16 retrieving revision 1.17 diff -u -r1.16 -r1.17 --- build.xml 1 Aug 2002 21:00:18 - 1.16 +++ build.xml 4 Aug 2002 15:45:16 - 1.17 @@ -5,8 +5,8 @@ !-- See build.properties.sample in the top level directory for all -- !-- property values you must customize for successful building!!!-- - property file=build.properties/ property file=${user.home}/build.properties/ + property file=build.properties/ property file=build.properties.default/ !-- Project Properties -- -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: [5.0] Build notes
On Sun, 4 Aug 2002, Patrick Luby wrote: Bob, Bob Herrmann wrote: $ sed -e 's/^base.path=\/usr\/local$/base.path=\/home\/test\/tc5\/dependson/' build.properties.default t $ mv t build.properties.default You don't want to replace build.properties.default. Instead you want to put your customized file in build.properties. That way, if build.properties.default changes, you will know. Also, using build.properties prevents accidental commits to build.properties.default. Another sugestion ( see my commit ) - just create a ~/build.properties and use it to override base.path. That means: base.path=/. ( and nothing else - unless you have some other overrides to make ). No need to copy the whole file or do any file modifications. Costin -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: cvs commit: jakarta-tomcat-5 build2.xml
On Sat, 03 Aug 2002 21:00:17 -0700, Patrick Luby wrote: Costin, If it helps, you can exclude org/apache/catalina/launcher/** from the build if you are not using commons-launcher. This package is only used by the Launcher's XML files and has no other packages depend on this package. It may be a good idea to move the ant tasks/types that you need from sandbox into oac.launcher. I think they should be in either tomcat or ant ( preferably). Later on, after things stabilise we can propose it for commons proper. Also, I noticed that you are compiling the ${taglibs.home}/standard/src directory. If it helps, you don't need to do this as the expression language classes are already compiled and checked into the jakarta-tomcat-jasper/jasper2/lib/jsp20el.jar. My goal was is have all the source that directly affects tomcat compiled. Not necesarily complete gump-style, but at least 'our' code. Costin Patrick [EMAIL PROTECTED] wrote: costin 2002/08/03 20:48:50 Modified:.build2.xml Log: A more functional build file. It now creates a fully functional tomcat ( there are few problems with jasper tough ). Also added a task that starts tomcat from ant - with 1.4 you need fork=true ( I'll try to make few changes to ant classloader to avoid this ). I'm also trying 'everything in a jar' model - there are cases when you don't need the complex hierarchy. Note that the generated tomcat.jar is 2.8M, out of which 1.6 is tomcat. That's not very bad - if we move backward compat stuff into tomcat-compat and split some 'optional' functionality we can get well bellow 1M. ( that includes tomcat33 code - i.e. 300k, most of it not used at the moment, only some non-duplicated modules will be ported ) Revision ChangesPath 1.3 +120 -3jakarta-tomcat-5/build2.xml Index: build2.xml === RCS file: /home/cvs/jakarta-tomcat-5/build2.xml,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- build2.xml 1 Aug 2002 20:31:15 - 1.2 +++ build2.xml 4 Aug 2002 03:48:50 -1.3 @@ -28,7 +28,7 @@ property name=jtc.home value=${basedir}/../jakarta-tomcat-connectors/ - property name=build.dir value=${basedir}/build/tomcat5/ + property name=build.dir value=${basedir}/build/ property name=log4j.jar value=${base.path}/log4j/log4j.jar/ @@ -44,6 +44,14 @@ pathelement location=${jta.jar}/ pathelement location=${log4j.jar}/ /path + + patternset id=static.res +include name=**/*.properties / +include name=**/*.dtd / +include name=**/*.tld / +include name=**/*.xsd / +include name=**/*.xml / + /patternset path id=jasperjars pathelement location=${jaxen.jar}/ @@ -86,8 +94,25 @@ /src exclude name=org/apache/tomcat/util/net/PureTLS* / exclude name=org/apache/commons/logging/impl/LogKitLogger.java / - exclude name=org/apache/commons/modeler/Modeler.java / + + !-- Fail with GCJ -- + exclude name=org/apache/commons/collections/DoubleOrderedMap.java / + exclude name=org/apache/tomcat/util/log/CommonLogHandler.java / /javac +copy toDir=${build.dir}/classes + fileset dir=${commons.home}/modeler/src/java +patternset refid=static.res / + /fileset + fileset dir=${jtc.home}/util/java +patternset refid=static.res / + /fileset + fileset dir=${commons.home}/digester/src/java + patternset refid=static.res / + /fileset + fileset dir=${commons.home}/logging/src/java + patternset refid=static.res / + /fileset +/copy /target target name=tomcat @@ -111,6 +136,40 @@ exclude name=org/apache/tomcat/ant/Tomcat3Precompiler.java / exclude name=org/apache/catalina/startup/BootstrapService.java / /javac + +copy toDir=${build.dir}/classes + fileset dir=${catalina.home}/catalina/src/share +patternset refid=static.res / + /fileset + fileset dir=${jtc.home}/coyote/src/java + patternset refid=static.res / + /fileset + fileset dir=${jtc.home}/http11/src/java + patternset refid=static.res / + /fileset + fileset dir=${jtc.home}/jk/java + patternset refid=static.res / + /fileset +/copy + +copy toDir=${build.dir}/classes +fileset dir=${api.home}/src/share + include name=**/*.properties/ +/fileset +/copy + +!-- Servlet/JSP resources - work around stupid src layout -- +copy todir=${build.dir}/classes/javax/servlet/resources + fileset dir=${api.home}/src/share/dtd + include name=web-app*.dtd/ +
Re: cvs commit: jakarta-tomcat-5 build2.xml
Costin, Costin Manolache wrote: It may be a good idea to move the ant tasks/types that you need from sandbox into oac.launcher. I think they should be in either tomcat or ant ( preferably). Later on, after things stabilise we can propose it for commons proper. I would like to see the syspropertyset, argset, and jvmargset data types and the conditional sysproperty, arg, and jvmarg elements moved to Ant. Also, I should be able to integrate the launch task attributes into Ant's java task. I just won't be able to do it for a few weeks since my employer has squeezed my spare time down to nothing. But I intend to post patches for this code so that it can go in Ant 1.6. The other half of the Launcher code is merely the bootstrapping of ant.jar (which is where the enhanced data types listed above would be). This code be added to Ant 1.6 very easily as all it does is instantiate a ClassLoader and classload ant.jar. This piece of code deserves more explanation. In the launcher, this bootstrapper is called LauncherBootstrap.class and resides in the same directory as the shell script that users use. Then, in Windows batch scripts, you put %0\..;%PATH% as the classpath when invoking Java. Since Windows sometimes makes %0 meaningless, %PATH% is used as the classpath. Since LauncherBootstrap.class is an unjarred class in %PATH% (since it is in the same directory as the script), it will get included in the classpath. LauncherBootstrap.class then just loads ant.jar since Java can reliably determine which directory LauncherBootstrap.class was loaded from. In essence, the whole bootstrapping process is a hack to get around the %0 problem on Windows 95, 98, ME, and sometimes 2000. So, it might be useful to include this bootstrapper in Ant so that the Ant batch scripts can find its classes. There were a few other things that are in the Launcher which may be useful if ported to Ant: - Catching of uncaught Errors (e.g. OutOfMemoryError) and gracefully exiting - Syncronized starting and stopping of the build process so that other applications (e.g. commons-daemon) can start Ant and kill Ant directly. - Retrieve localized strings so that we can localize BuildExceptions and echo and fail messages. If the Ant committers accept my patches, effectively moving all of the Launcher functionality into Ant 1.6, then I think the commons-launcher portion of commons-daemon can be made obsolete and commons-daemon could just use Ant 1.6 directly. Right now, commons-daemon needs both commons-launcher.jar *and* ant.jar. Let me know what you think of this approach. Thanks, Patrick -- Patrick Luby Email: [EMAIL PROTECTED] Sun Microsystems Phone: 408-276-7471 901 San Antonio Road, USCA14-303 Palo Alto, CA 94303-4900 -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
cvs commit: jakarta-tomcat-catalina/catalina/src/bin catalina.bat catalina.sh cpappend.bat digest.bat digest.sh setclasspath.bat setclasspath.sh shutdown-using-launcher.bat shutdown-using-launcher.sh startup-using-launcher.bat startup-using-launcher.sh tool-wrapper-using-launcher.bat tool-wrapper-using-launcher.sh shutdown.bat shutdown.sh startup.bat startup.sh tool-wrapper.bat tool-wrapper.sh
patrickl2002/08/04 11:19:44 Modified:catalina build.xml catalina/src/bin shutdown.bat shutdown.sh startup.bat startup.sh tool-wrapper.bat tool-wrapper.sh Added: catalina/src/bin catalina.bat catalina.sh cpappend.bat digest.bat digest.sh setclasspath.bat setclasspath.sh shutdown-using-launcher.bat shutdown-using-launcher.sh startup-using-launcher.bat startup-using-launcher.sh tool-wrapper-using-launcher.bat tool-wrapper-using-launcher.sh Log: Make use of commons-launcher optional by restoring the old scripts and renaming the commons-launcher scripts to *-using-launcher.*. The commons-launcher scripts and supporting class and jar files will only be added to the build if commons-launcher.jar is detected by the build. If commons-launcher.jar is not detected by the build, only the old scripts will be included in the build. Revision ChangesPath 1.11 +63 -24jakarta-tomcat-catalina/catalina/build.xml Index: build.xml === RCS file: /home/cvs/jakarta-tomcat-catalina/catalina/build.xml,v retrieving revision 1.10 retrieving revision 1.11 diff -u -r1.10 -r1.11 --- build.xml 1 Aug 2002 21:31:13 - 1.10 +++ build.xml 4 Aug 2002 18:19:43 - 1.11 @@ -157,8 +157,7 @@ classname=org.apache.commons.launcher.Launcher classpath=${commons-daemon-launcher.jar}/ available property=launcher.bootstrap.present - classname=LauncherBootstrap - classpath=${commons-daemon-launcher-bootstrap.class}/ + file=${commons-daemon-launcher-bootstrap.class}/ available property=logging.present classname=org.apache.commons.logging.Log classpath=${commons-logging.jar}/ @@ -231,6 +230,7 @@ classpath=${xercesImpl.jar} / !-- JAR files availability flags -- +available property=daemon.jar.present file=${commons-daemon.jar} / available property=dbcp.jar.present file=${commons-dbcp.jar} / available property=jaas.jar.present file=${jaas.jar} / condition property=javamail.jar.present @@ -247,6 +247,12 @@ available property=jsse.jar.present file=${jsse.jar} / available property=jta.jar.present file=${jta.jar} / available property=junit.jar.present file=${junit.jar} / +condition property=launcher.jars.present + and +equals arg1=${launcher.present} arg2=true/ +equals arg1=${launcher.bootstrap.present} arg2=true/ + /and +/condition available property=ldap.jar.present file=${ldap.jar} / available property=logging.jar.present file=${commons-logging.jar} / available property=modeler.jar.present file=${commons-modeler.jar} / @@ -265,6 +271,12 @@ /condition !-- Conditional compilation flags (determined from the flags above) -- +condition property=compile.daemon + or +equals arg1=${full.dist} arg2=on / +equals arg1=${daemon.present} arg2=true / + /or +/condition condition property=compile.dbcp or equals arg1=${full.dist} arg2=on / @@ -321,6 +333,15 @@ equals arg1=${junit.present} arg2=true / /or /condition +condition property=compile.launcher + or +equals arg1=${full.dist} arg2=on / +and + equals arg1=${launcher.present} arg2=true / + equals arg1=${launcher.bootstrap.present} arg2=true / +/and + /or +/condition condition property=compile.ldap or equals arg1=${full.dist} arg2=on / @@ -338,6 +359,12 @@ !-- Conditional copy flags (determined from the flags above) -- +condition property=copy.daemon.jar + or +equals arg1=${full.dist} arg2=on / +equals arg1=${daemon.jar.present} arg2=true / + /or +/condition condition property=copy.dbcp.jar and not @@ -428,6 +455,12 @@ /or /and /condition +condition property=copy.launcher.jars + or +equals arg1=${full.dist} arg2=on / +equals arg1=${launcher.jars.present} arg2=true / + /or +/condition condition property=copy.ldap.jar and not @@ -531,17 +564,15 @@ echo message=--- Required Libraries --- / echo message=beanutils.present=${beanutils.present} / echo message=collections.present=${collections.present} / -echo message=daemon.present=${daemon.present} / echo message=digester.present=${digester.present} / echo message=jaxp.present=${jaxp.present} / echo message=jndi.present=${jndi.present} / -echo
cvs commit: jakarta-tomcat-jasper/jasper2/src/bin jasper.bat jasper.sh jspc-using-launcher.bat jspc-using-launcher.sh jspc.bat jspc.sh
patrickl2002/08/04 11:21:08 Modified:jasper2 build.xml jasper2/src/bin jspc.bat jspc.sh Added: jasper2/src/bin jasper.bat jasper.sh jspc-using-launcher.bat jspc-using-launcher.sh Log: Make use of commons-launcher optional by restoring the old scripts and renaming the commons-launcher scripts to *-using-launcher.*. The commons-launcher scripts and supporting class and jar files will only be added to the build if commons-launcher.jar is detected by the build. If commons-launcher.jar is not detected by the build, only the old scripts will be included in the build. Revision ChangesPath 1.14 +24 -6 jakarta-tomcat-jasper/jasper2/build.xml Index: build.xml === RCS file: /home/cvs/jakarta-tomcat-jasper/jasper2/build.xml,v retrieving revision 1.13 retrieving revision 1.14 diff -u -r1.13 -r1.14 --- build.xml 1 Aug 2002 17:57:25 - 1.13 +++ build.xml 4 Aug 2002 18:21:08 - 1.14 @@ -56,6 +56,18 @@ target name=build-prepare available classname=junit.framework.TestCase property=junit.present / +available property=launcher.present + classname=org.apache.commons.launcher.Launcher + classpath=${commons-daemon-launcher.jar}/ +available property=launcher.bootstrap.present + file=${commons-daemon-launcher-bootstrap.class}/ + +condition property=copy.launcher.jars + and +equals arg1=${launcher.present} arg2=true / +equals arg1=${launcher.bootstrap.present} arg2=true / + /and +/condition mkdir dir=${jasper.build}/ mkdir dir=${jasper.build}/bin/ @@ -67,21 +79,27 @@ /target - !-- === BUILD: Copy Static Files === -- - target name=build-static depends=build-prepare - -!-- Copy the launcher classes -- + !-- === BUILD: Copy Launcher Files = -- + target name=copy-launcher.jars if=copy.launcher.jars copy todir=${jasper.build}/common/lib file=${ant.jar}/ copy todir=${jasper.build}/bin file=${commons-daemon-launcher.jar}/ copy todir=${jasper.build}/bin file=${commons-daemon-launcher-bootstrap.class}/ +copy todir=${jasper.build}/bin + fileset dir=src/bin includes=*-using-launcher.*,launcher.properties,jasper.xml / +/copy + /target + + + !-- === BUILD: Copy Static Files === -- + target name=build-static depends=build-prepare,copy-launcher.jars !-- Executable Commands -- copy todir=${jasper.build}/bin - fileset dir=src/bin / + fileset dir=src/bin excludes=*-using-launcher.*,launcher.properties,jasper.xml / /copy fixcrlf srcdir=${jasper.build}/bin includes=*.sh eol=lf/ fixcrlf srcdir=${jasper.build}/bin includes=*.bat eol=crlf/ -chmod perm=+x file=${jasper.build}/bin/jspc.sh/ +chmod perm=+x dir=${jasper.build}/bin includes=*.sh/ /target 1.3 +22 -21jakarta-tomcat-jasper/jasper2/src/bin/jspc.bat Index: jspc.bat === RCS file: /home/cvs/jakarta-tomcat-jasper/jasper2/src/bin/jspc.bat,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- jspc.bat 1 Aug 2002 17:55:51 - 1.2 +++ jspc.bat 4 Aug 2002 18:21:08 - 1.3 @@ -1,31 +1,33 @@ @echo off if %OS% == Windows_NT setlocal - rem --- +rem Script to run the Jasper offline JSP compiler rem -rem Script for running JSPC compiler using the Launcher -rem +rem $Id$ rem --- -rem Get standard environment variables -set PRG=%0 -if exist %PRG%\..\setenv.bat goto gotCmdPath -rem %0 must have been found by DOS using the %PATH% so we assume that -rem setenv.bat will also be found in the %PATH% -call setenv.bat -goto doneSetenv -:gotCmdPath -call %PRG%\..\setenv.bat -:doneSetenv - -rem Make sure prerequisite environment variables are set -if not %JAVA_HOME% == goto gotJavaHome -echo The JAVA_HOME environment variable is not defined +rem Guess JASPER_HOME if not defined +if not %JASPER_HOME% == goto gotHome +set JASPER_HOME=. +if exist %JASPER_HOME%\bin\jspc.bat goto okHome +set JASPER_HOME=.. +:gotHome +if exist %JASPER_HOME%\bin\jspc.bat goto okHome +echo The JASPER_HOME environment variable is not defined correctly echo This environment variable is needed to run this program goto end -:gotJavaHome +:okHome + +set EXECUTABLE=%JASPER_HOME%\bin\jasper.bat + +rem Check that target executable exists +if exist %EXECUTABLE% goto okExec +echo Cannot find %EXECUTABLE%
cvs commit: jakarta-tomcat-connectors/coyote/src/java/org/apache/coyote/tomcat5 - New directory
patrickl2002/08/04 11:22:13 jakarta-tomcat-connectors/coyote/src/java/org/apache/coyote/tomcat5 - New directory -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]
Re: cvs commit: jakarta-tomcat-5 build2.xml
On Sun, 4 Aug 2002, Patrick Luby wrote: I would like to see the syspropertyset, argset, and jvmargset data types and the conditional sysproperty, arg, and jvmarg elements moved to Ant. You'll have to submit patches to ant-dev. But you can very well do the same thing with the current ant1.5 types - the syntax may be a bit more complicated, but using multiple sysproperty instead of syspropertyset is not that critical. Same for the conditionals - you can do most of that in the current syntax ( using conditional targets ). Not the cleanest way - but it works. Also, I should be able to integrate the launch task attributes into Ant's java task. I just won't be able to do it for a few weeks since my employer has squeezed my spare time down to nothing. But I intend to post patches for this code so that it can go in Ant 1.6. I have more work than I can handle - probably we're all in the same situation. You can just move launcher into tomcat CVS for now, and use it as a custom tomcat ant task. This piece of code deserves more explanation. In the launcher, this bootstrapper is called LauncherBootstrap.class and resides in the same directory as the shell script that users use. Then, in Windows batch scripts, you put %0\..;%PATH% as the classpath when invoking Java. Since Windows sometimes makes %0 meaningless, %PATH% is used as the classpath. Since LauncherBootstrap.class is an unjarred class in %PATH% (since it is in the same directory as the script), it will get included in the classpath. LauncherBootstrap.class then just loads ant.jar since Java can reliably determine which directory LauncherBootstrap.class was loaded from. Can't you just do 'java -jar ./bootstrap.jar' ? In essence, the whole bootstrapping process is a hack to get around the %0 problem on Windows 95, 98, ME, and sometimes 2000. So, it might be useful to include this bootstrapper in Ant so that the Ant batch scripts can find its classes. Or we can require TOMCAT_HOME/ANT_HOME env to be set. Or a registry key. Or use a small C program. Or we can 'install' a small bootstrap.jar in java's lib/ext. There are many hacks - what's important is to not let the hack affect the design and other platforms. There were a few other things that are in the Launcher which may be useful if ported to Ant: - Catching of uncaught Errors (e.g. OutOfMemoryError) and gracefully exiting - Syncronized starting and stopping of the build process so that other applications (e.g. commons-daemon) can start Ant and kill Ant directly. Not sure what that means. Other application can start and kill ant - there is no need for anything special. I'm trying to enhance the API for embeding ant - including wrapping it as an MBean ( with start/stop lifecycle methods ), it isn't difficult ( except finding time ). And I'll try to wrap the ant tasks/targets using modeler ( after I get the introspection-based code moved from util.mx to modeler ) - so individual tasks can be easier to execute. - Retrieve localized strings so that we can localize BuildExceptions and echo and fail messages. That would require a lot of work in ant, but I think it's a good idea. Costin -- To unsubscribe, e-mail: mailto:[EMAIL PROTECTED] For additional commands, e-mail: mailto:[EMAIL PROTECTED]