svn commit: r156023 - jakarta/commons/proper/httpclient/trunk/xdocs/tutorial.xml
Author: oglueck Date: Thu Mar 3 00:44:53 2005 New Revision: 156023 URL: http://svn.apache.org/viewcvs?view=revrev=156023 Log: Fixed: dependencies and JDK version PR: 33815 Modified: jakarta/commons/proper/httpclient/trunk/xdocs/tutorial.xml Modified: jakarta/commons/proper/httpclient/trunk/xdocs/tutorial.xml URL: http://svn.apache.org/viewcvs/jakarta/commons/proper/httpclient/trunk/xdocs/tutorial.xml?view=diffr1=156022r2=156023 == --- jakarta/commons/proper/httpclient/trunk/xdocs/tutorial.xml (original) +++ jakarta/commons/proper/httpclient/trunk/xdocs/tutorial.xml Thu Mar 3 00:44:53 2005 @@ -21,12 +21,10 @@ section name=Getting Ready pThe first thing you need to do is get a copy of emHttpClient/em and it's - dependencies. Currently the only required dependency is - a href=/commons/logging/commons-logging/a. This tutorial was - written for emHttpClient/em 2.0 and at a minimum requires 2.0 Alpha - 2. You will also need JDK 1.2.2 or above./p + a href=dependencies.htmldependencies/a. This tutorial was + written for emHttpClient/em 3.0. You will also need JDK 1.3 or above./p -pOnce you've downloaded emHttpClient/em and commons-logging you'll need to +pOnce you've downloaded emHttpClient/em and dependencies you will need to put them on your classpath. There is also an optional dependency on JSSE which is required for HTTPS connections; this is not required for this tutorial./p - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
svn commit: r156025 - jakarta/commons/sandbox/vfs/trunk/src/java/org/apache/commons/vfs/Resources.properties
Author: imario Date: Thu Mar 3 01:21:30 2005 New Revision: 156025 URL: http://svn.apache.org/viewcvs?view=revrev=156025 Log: missing message Modified: jakarta/commons/sandbox/vfs/trunk/src/java/org/apache/commons/vfs/Resources.properties Modified: jakarta/commons/sandbox/vfs/trunk/src/java/org/apache/commons/vfs/Resources.properties URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/vfs/trunk/src/java/org/apache/commons/vfs/Resources.properties?view=diffr1=156024r2=156025 == --- jakarta/commons/sandbox/vfs/trunk/src/java/org/apache/commons/vfs/Resources.properties (original) +++ jakarta/commons/sandbox/vfs/trunk/src/java/org/apache/commons/vfs/Resources.properties Thu Mar 3 01:21:30 2005 @@ -27,6 +27,7 @@ vfs.provider/create-folder-mismatched-type.error=Could not create folder {0} because it already exists and is a file. vfs.provider/create-folder-read-only.error=Could not create folder {0} because its parent folder is read-only. vfs.provider/create-folder.error=Could not create folder {0}. +vfs.provider/create-file.error=Could not create file {0}. vfs.provider/write-read-only.error=Could not write to {0} because it is read-only. vfs.provider/write-not-file.error=Could not write to {0} because it is not a file. vfs.provider/write.error=Could not write to {0}. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[GUMP@brutus]: Project commons-jelly-tags-xml (in module commons-jelly) failed
To whom it may engage... This is an automated request, but not an unsolicited one. For more information please visit http://gump.apache.org/nagged.html, and/or contact the folk at [EMAIL PROTECTED] Project commons-jelly-tags-xml has an issue affecting its community integration. This issue affects 12 projects, and has been outstanding for 7 runs. The current state of this project is 'Failed', with reason 'Build Failed'. For reference only, the following projects are affected by this: - commons-jelly-tags-define : Commons Jelly - commons-jelly-tags-html : Commons Jelly - commons-jelly-tags-http : Commons Jelly - commons-jelly-tags-jaxme : Commons Jelly - commons-jelly-tags-jetty : Commons Jelly - commons-jelly-tags-jface : Commons Jelly - commons-jelly-tags-jsl : Commons Jelly - commons-jelly-tags-swing : Commons Jelly - commons-jelly-tags-xml : Commons Jelly - commons-jelly-tags-xmlunit : Commons Jelly - maven : Project Management Tools - maven-bootstrap : Project Management Tools Full details are available at: http://brutus.apache.org/gump/public/commons-jelly/commons-jelly-tags-xml/index.html That said, some information snippets are provided here. The following annotations (debug/informational/warning/error messages) were provided: -DEBUG- Sole output [commons-jelly-tags-xml-03032005.jar] identifier set to project name -DEBUG- Dependency on xml-xerces exists, no need to add for property maven.jar.xerces. -DEBUG- (Gump generated) Maven Properties in: /usr/local/gump/public/workspace/commons-jelly/jelly-tags/xml/build.properties -INFO- Failed with reason build failed -DEBUG- Maven POM in: /usr/local/gump/public/workspace/commons-jelly/jelly-tags/xml/project.xml -DEBUG- Maven project properties in: /usr/local/gump/public/workspace/commons-jelly/jelly-tags/xml/project.properties -INFO- Project Reports in: /usr/local/gump/public/workspace/commons-jelly/jelly-tags/xml/target/test-reports -DEBUG- Extracted fallback artifacts from Gump Repository The following work was performed: http://brutus.apache.org/gump/public/commons-jelly/commons-jelly-tags-xml/gump_work/build_commons-jelly_commons-jelly-tags-xml.html Work Name: build_commons-jelly_commons-jelly-tags-xml (Type: Build) Work ended in a state of : Failed Elapsed: 13 secs Command Line: maven --offline jar [Working Directory: /usr/local/gump/public/workspace/commons-jelly/jelly-tags/xml] CLASSPATH: /opt/jdk1.4/lib/tools.jar:/usr/local/gump/public/workspace/jakarta-commons/beanutils/dist/commons-beanutils-core.jar:/usr/local/gump/public/workspace/ant/dist/lib/ant-jmf.jar:/usr/local/gump/public/workspace/ant/dist/lib/ant-swing.jar:/usr/local/gump/public/workspace/ant/dist/lib/ant-apache-resolver.jar:/usr/local/gump/public/workspace/ant/dist/lib/ant-trax.jar:/usr/local/gump/public/workspace/ant/dist/lib/ant-junit.jar:/usr/local/gump/public/workspace/ant/dist/lib/ant-launcher.jar:/usr/local/gump/public/workspace/ant/dist/lib/ant-nodeps.jar:/usr/local/gump/public/workspace/ant/dist/lib/ant.jar:/usr/local/gump/public/workspace/dist/junit/junit.jar:/usr/local/gump/public/workspace/xml-commons/java/build/resolver.jar:/usr/local/gump/public/workspace/ant/bootstrap/lib/ant-launcher.jar:/usr/local/gump/public/workspace/ant/bootstrap/lib/ant.jar:/usr/local/gump/public/workspace/jakarta-commons/collections/build/commons-collections-03032005.jar:/usr/local/gump/public/workspace/commons-jelly/target/commons-jelly-03032005.jar:/usr/local/gump/public/workspace/commons-jelly/jelly-tags/junit/target/commons-jelly-tags-junit-03032005.jar:/usr/local/gump/public/workspace/jakarta-commons/jexl/dist/commons-jexl-03032005.jar:/usr/local/gump/public/workspace/jakarta-commons/logging/dist/commons-logging.jar:/usr/local/gump/public/workspace/jakarta-commons/logging/dist/commons-logging-api.jar:/usr/local/gump/public/workspace/dom4j/build/dom4j.jar:/usr/local/gump/public/workspace/jaxen/target/jaxen-03032005.jar - [mkdir] Created dir: /home/gump/workspaces2/public/workspace/commons-jelly/jelly-tags/xml/target/classes java:compile: [echo] Compiling to /home/gump/workspaces2/public/workspace/commons-jelly/jelly-tags/xml/target/classes [echo] == NOTE: Targetting JVM 1.4, classes will not run on earlier JVMs == [javac] Compiling 16 source files to /home/gump/workspaces2/public/workspace/commons-jelly/jelly-tags/xml/target/classes java:jar-resources: test:prepare-filesystem: [mkdir] Created dir: /home/gump/workspaces2/public/workspace/commons-jelly/jelly-tags/xml/target/test-classes [mkdir] Created dir: /home/gump/workspaces2/public/workspace/commons-jelly/jelly-tags/xml/target/test-reports test:test-resources: Copying 36 files to
[GUMP@brutus]: Project commons-jelly-tags-fmt (in module commons-jelly) failed
To whom it may engage... This is an automated request, but not an unsolicited one. For more information please visit http://gump.apache.org/nagged.html, and/or contact the folk at [EMAIL PROTECTED] Project commons-jelly-tags-fmt has an issue affecting its community integration. This issue affects 1 projects. The current state of this project is 'Failed', with reason 'Build Failed'. For reference only, the following projects are affected by this: - commons-jelly-tags-fmt : Commons Jelly Full details are available at: http://brutus.apache.org/gump/public/commons-jelly/commons-jelly-tags-fmt/index.html That said, some information snippets are provided here. The following annotations (debug/informational/warning/error messages) were provided: -DEBUG- Sole output [commons-jelly-tags-fmt-03032005.jar] identifier set to project name -DEBUG- Dependency on xml-xerces exists, no need to add for property maven.jar.xerces. -DEBUG- (Gump generated) Maven Properties in: /usr/local/gump/public/workspace/commons-jelly/jelly-tags/fmt/build.properties -INFO- Failed with reason build failed -DEBUG- Maven POM in: /usr/local/gump/public/workspace/commons-jelly/jelly-tags/fmt/project.xml -DEBUG- Maven project properties in: /usr/local/gump/public/workspace/commons-jelly/jelly-tags/fmt/project.properties -INFO- Project Reports in: /usr/local/gump/public/workspace/commons-jelly/jelly-tags/fmt/target/test-reports -WARNING- No directory [/usr/local/gump/public/workspace/commons-jelly/jelly-tags/fmt/target/test-reports] -INFO- Failed to extract fallback artifacts from Gump Repository The following work was performed: http://brutus.apache.org/gump/public/commons-jelly/commons-jelly-tags-fmt/gump_work/build_commons-jelly_commons-jelly-tags-fmt.html Work Name: build_commons-jelly_commons-jelly-tags-fmt (Type: Build) Work ended in a state of : Failed Elapsed: 9 secs Command Line: maven --offline jar [Working Directory: /usr/local/gump/public/workspace/commons-jelly/jelly-tags/fmt] CLASSPATH: /opt/jdk1.4/lib/tools.jar:/usr/local/gump/public/workspace/ant/dist/lib/ant-jmf.jar:/usr/local/gump/public/workspace/ant/dist/lib/ant-swing.jar:/usr/local/gump/public/workspace/ant/dist/lib/ant-apache-resolver.jar:/usr/local/gump/public/workspace/ant/dist/lib/ant-trax.jar:/usr/local/gump/public/workspace/ant/dist/lib/ant-junit.jar:/usr/local/gump/public/workspace/ant/dist/lib/ant-launcher.jar:/usr/local/gump/public/workspace/ant/dist/lib/ant-nodeps.jar:/usr/local/gump/public/workspace/ant/dist/lib/ant.jar:/usr/local/gump/public/workspace/beanshell/dist/bsh-classpath-03032005.jar:/usr/local/gump/public/workspace/beanshell/dist/bsh-commands-03032005.jar:/usr/local/gump/public/workspace/beanshell/dist/bsh-util-03032005.jar:/usr/local/gump/public/workspace/beanshell/dist/bsh-bsf-03032005.jar:/usr/local/gump/public/workspace/beanshell/dist/bsh-03032005.jar:/usr/local/gump/public/workspace/beanshell/dist/bsh-core-03032005.jar:/usr/local/gump/public/workspace/beanshell/dist/bsh-reflect-03032005.jar:/usr/local/gump/public/workspace/dist/junit/junit.jar:/usr/local/gump/public/workspace/xml-commons/java/build/resolver.jar:/usr/local/gump/public/workspace/ant/bootstrap/lib/ant-launcher.jar:/usr/local/gump/public/workspace/ant/bootstrap/lib/ant.jar:/usr/local/gump/public/workspace/jakarta-commons/beanutils/dist/commons-beanutils-core.jar:/usr/local/gump/public/workspace/jakarta-commons/collections/build/commons-collections-03032005.jar:/usr/local/gump/public/workspace/commons-jelly/target/commons-jelly-03032005.jar:/usr/local/gump/public/workspace/commons-jelly/jelly-tags/ant/target/commons-jelly-tags-ant-03032005.jar:/usr/local/gump/public/workspace/commons-jelly/jelly-tags/beanshell/target/commons-jelly-tags-beanshell-03032005.jar:/usr/local/gump/public/workspace/commons-jelly/jelly-tags/junit/target/commons-jelly-tags-junit-03032005.jar:/usr/local/gump/public/workspace/jakarta-commons/jexl/dist/commons-jexl-03032005.jar:/usr/local/gump/public/workspace/jakarta-commons/logging/dist/commons-logging.jar:/usr/local/gump/public/workspace/jakarta-commons/logging/dist/commons-logging-api.jar:/usr/local/gump/public/workspace/dom4j/build/dom4j.jar:/usr/local/gump/public/workspace/jaxen/target/jaxen-03032005.jar - __ __ | \/ |__ _Apache__ ___ | |\/| / _` \ V / -_) ' \ ~ intelligent projects ~ |_| |_\__,_|\_/\___|_||_| v. 1.0.2 You are working offline so the build will continue, but commons-jelly-SNAPSHOT.jar may be out of date! The build cannot continue because of the following unsatisfied dependency: commons-grant-1.0-beta-4.jar Total time: 9 seconds Finished at: Thu Mar 03 03:07:54 PST 2005 - To subscribe to this information via syndicated feeds: - RSS: http://brutus.apache.org/gump/public/commons-jelly/commons-jelly-tags-fmt/rss.xml - Atom:
DO NOT REPLY [Bug 18942] - [beanutils] Add t/f to BooleanConverter
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG· RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://issues.apache.org/bugzilla/show_bug.cgi?id=18942. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND· INSERTED IN THE BUG DATABASE. http://issues.apache.org/bugzilla/show_bug.cgi?id=18942 --- Additional Comments From [EMAIL PROTECTED] 2005-03-03 13:14 --- Ok, I've had a closer look at the code. A number of slightly tricky issues have popped to mind. I'm sure they could all be resolved, but I am seriously wondering whether it might instead be better to just improve the documentation on how people can write register their own custom converters to override the default behaviours. BeanUtils *does* currently make it possible for users to do language-specific boolean mappings (by writing custom Converters), though it certainly isn't as easy or as well documented as it could be! Have a look at the issues listed below and let me know what you think. Please don't think that because the comments are long and complex that I don't like your patch. I think the issue is reasonable, and worth spending time on : 3 people (Bruno/Mattias/Eric) have requested this feature. But it's just not quite as simple as it first appears. And of course I'm not a regular BeanUtils maintainer so I'm trying to be extra careful not to stuff anything up :-) I'm also wondering whether code that currently uses BeanUtils (eg Struts) has already dealt with this issue...it might be worth asking on the Struts list whether they use BeanUtils to process input from non-english languages. === How do end users actually use this new functionality? Were you thinking of something like this? BooleanConverter bc = (BooleanConverter) ConvertUtils.lookup(Boolean.class); bc.addTrueString(oui); bc.addFalseString(non); or like this? BooleanConverter bc = new BooleanConverter(); bc.addTrueString(oui); bc.addFalseString(non); ConvertUtils.register(bc, Boolean.class); If the latter, then it seems *almost* as easy for the user to just write a custom Converter class of their own that implements their desired mapping than for BeanUtils to provide a configurable BooleanConverter... In either case, *just* the conversion of String-Boolean is affected. String-boolean and String-Boolean[] conversions have not been modified (see below) === BooleanArrayConverter Perhaps BooleanArrayConverter should contain a reference to a BooleanConverter, with the ConvertUtilsBean.deregister() method ensuring that the BooleanArrayConverter constructor is passed the just-created BooleanConverter object? That way, any changes to the BooleanConverter will automatically affect the BooleanArrayConverter too. ie in ConvertUtilsBean.deregister(), do something like this: register(booleanArray.getClass(), new BooleanArrayConverter(bc, booleanArray)); where bc is the same BooleanConverter object that was registered for the Boolean.class type. That way, changing the true/false values for the Boolean.class converter will also change the mappings for the BooleanArrayConverter. Or the documentation for the BooleanConverter can just explain that any calls to addTrueString/addFalseString won't affect String-Boolean[] conversions. Any such change, however, would have to be carefully done to avoid backwards-compatibility issues. For example, the old constructors must remain in place. === String-boolean Currently, the ConvertUtilsBean.deregister() method creates separate instances of BooleanConverter to handle String-Boolean.class (ie String to Boolean) and String-Boolean.type (ie String to boolean). Perhaps it would be best to change the ConvertBeanUtils.deregister() method from register(Boolean.TYPE, new BooleanConverter(defaultBoolean)); register(Boolean.class, new BooleanConverter(defaultBoolean)); to BooleanConverter bc = new BooleanConverter(defaultBoolean); register(Boolean.TYPE, bc); register(Boolean.class, bc); === Thread-safety I can't see anything in the beanutils javadoc regarding the issue of threadsafety, but it would appear to me that a Converter is really required to be thread-safe, as it could be possible for ConvertUtils functionality to be invoked from multiple threads concurrently, resulting in the same Converter instance being run concurrently. I see your patch uses Hashtable rather than HashMap, and Hashtable *is* threadsafe, though at the price of extra synchronization. The old code was of course thread-safe because it didn't use any collections to store this data. [NB: it would be nice to add a comment re *why* you used Hashtable instead of HashMap']. Here the approach of having users just create a custom Converter class of their own with whatever true/false strings they want hard-wired in can make life easier than the proposed patch. However it *does* fail for apps that want to detect the language at run-time and load constants from a resource bundle or
svn commit: r156049 - jakarta/commons/proper/email/trunk/xdocs/index.xml
Author: epugh Date: Thu Mar 3 07:19:58 2005 New Revision: 156049 URL: http://svn.apache.org/viewcvs?view=revrev=156049 Log: Lets not link to SCM from two places, it gets out of date! Modified: jakarta/commons/proper/email/trunk/xdocs/index.xml Modified: jakarta/commons/proper/email/trunk/xdocs/index.xml URL: http://svn.apache.org/viewcvs/jakarta/commons/proper/email/trunk/xdocs/index.xml?view=diffr1=156048r2=156049 == --- jakarta/commons/proper/email/trunk/xdocs/index.xml (original) +++ jakarta/commons/proper/email/trunk/xdocs/index.xml Thu Mar 3 07:19:58 2005 @@ -59,10 +59,8 @@ subsection name=Status p ul - liThis code has been recently promoted from commons isandbox/i/li - liThe code is unreleased/li - liMethods and classes can and will appear and disappear without warning/li - liIf you like the code and want to push it towards a release, join the mailing list!/li + liAfter a very long time in the commons isandbox/li, this code is ready for the 1.0 release./li + liIf you like the code and need new features, join the commons-dev mailing list!/li /ul /p /subsection @@ -73,7 +71,7 @@ p ul liThe a href=apidocs/index.htmlJavadoc/a of the latest CVS/li - liThe a href=http://cvs.apache.org/viewcvs/jakarta-commons/email/;CVS repository/a can be browsed./li + liThe a href=cvs-usage.htmlCVS repository/a can be browsed./li /ul /p /section - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
svn commit: r156055 - jakarta/commons/proper/jelly/trunk/jelly-tags/fmt/project.xml
Author: brett Date: Thu Mar 3 07:31:22 2005 New Revision: 156055 URL: http://svn.apache.org/viewcvs?view=revrev=156055 Log: new version, update to newer ant taglib Modified: jakarta/commons/proper/jelly/trunk/jelly-tags/fmt/project.xml Modified: jakarta/commons/proper/jelly/trunk/jelly-tags/fmt/project.xml URL: http://svn.apache.org/viewcvs/jakarta/commons/proper/jelly/trunk/jelly-tags/fmt/project.xml?view=diffr1=156054r2=156055 == --- jakarta/commons/proper/jelly/trunk/jelly-tags/fmt/project.xml (original) +++ jakarta/commons/proper/jelly/trunk/jelly-tags/fmt/project.xml Thu Mar 3 07:31:22 2005 @@ -1,6 +1,6 @@ ?xml version=1.0 encoding=UTF-8? !-- - Copyright 2002,2004 The Apache Software Foundation. + Copyright 2002,2005 The Apache Software Foundation. Licensed under the Apache License, Version 2.0 (the License); you may not use this file except in compliance with the License. @@ -19,7 +19,7 @@ idcommons-jelly-tags-fmt/id groupIdcommons-jelly/groupId namecommons-jelly-tags-fmt/name - currentVersion1.0/currentVersion + currentVersion1.1-SNAPSHOT/currentVersion packageorg.apache.commons.jelly.tags.fmt/package @@ -42,17 +42,12 @@ dependency groupIdcommons-jelly/groupId artifactIdcommons-jelly-tags-ant/artifactId - version1.0/version + version1.1-SNAPSHOT/version /dependency dependency idant/id - version1.5.1/version -/dependency - -dependency - idcommons-grant/id - version1.0-beta-4/version + version1.6.2/version /dependency dependency - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: [VOTE] Release commons email 1.0
Okay.. I'll take care of those changes. The build.xml could definitly be out of date.. It has been patched a couple times by hand, and then we have had those patches get wiped out by the Maven build. Recently some patches were added to the Maven Ant plugin, it may be that the hand tweaking is no longer required. Did you get this error: no protocol: ${javamail-1.3.2.url}? I am going to regenerate the Maven one and commit it. I have tweaked the docs, I'll try and tackle the other little changes today. Eric Pugh -Original Message- From: Phil Steitz [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 02, 2005 3:49 PM To: Jakarta Commons Developers List Subject: Re: [VOTE] Release commons email 1.0 +1 modulo the following nits: * Binary distro includes NOTICE.txt in the jar (top level, should probably be with LICENSE.txt in META-INF) but not in the top level directory of the distribution. * Source distro does not include NOTICE.txt * Ant build.xml in source distro fails with MalformedURLException in get deps. When I regenerated the build.xml using maven ant, the regenerated build.xml worked. Could be build.xml is out of date? * Make sure to update the repo link on the web site to point to svn. Phil robert burrell donkin wrote: On Tue, 2005-03-01 at 06:58, Eric Pugh wrote: [X] +1 Lets release commons-email, it's been too long! [ ] 0 Commons-what? Not ready for release [ ] -1 Don't release. I can't get dumbster (replace with your reason) to work. BTW i've checked the sums and signatures - robert - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: [VOTE] Release commons email 1.0
Okay.. I'll take care of those changes. The build.xml could definitly be out of date.. It has been patched a couple times by hand, and then we have had those patches get wiped out by the Maven build. Recently some patches were added to the Maven Ant plugin, it may be that the hand tweaking is no longer required. Did you get this error: no protocol: ${javamail-1.3.2.url}? I am going to regenerate the Maven one and commit it. I have tweaked the docs, I'll try and tackle the other little changes today. Eric Pugh -Original Message- From: Phil Steitz [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 02, 2005 3:49 PM To: Jakarta Commons Developers List Subject: Re: [VOTE] Release commons email 1.0 +1 modulo the following nits: * Binary distro includes NOTICE.txt in the jar (top level, should probably be with LICENSE.txt in META-INF) but not in the top level directory of the distribution. * Source distro does not include NOTICE.txt * Ant build.xml in source distro fails with MalformedURLException in get deps. When I regenerated the build.xml using maven ant, the regenerated build.xml worked. Could be build.xml is out of date? * Make sure to update the repo link on the web site to point to svn. Phil robert burrell donkin wrote: On Tue, 2005-03-01 at 06:58, Eric Pugh wrote: [X] +1 Lets release commons-email, it's been too long! [ ] 0 Commons-what? Not ready for release [ ] -1 Don't release. I can't get dumbster (replace with your reason) to work. BTW i've checked the sums and signatures - robert - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: [VOTE] Release commons email 1.0
Do you use the ant plugin 1.8.1 for maven or the 1.9-SNAPSHOT ? Arnaud -Message d'origine- De : Eric Pugh [mailto:[EMAIL PROTECTED] Envoyé : jeudi 3 mars 2005 16:48 À : 'Jakarta Commons Developers List' Objet : RE: [VOTE] Release commons email 1.0 Okay.. I'll take care of those changes. The build.xml could definitly be out of date.. It has been patched a couple times by hand, and then we have had those patches get wiped out by the Maven build. Recently some patches were added to the Maven Ant plugin, it may be that the hand tweaking is no longer required. Did you get this error: no protocol: ${javamail-1.3.2.url}? I am going to regenerate the Maven one and commit it. I have tweaked the docs, I'll try and tackle the other little changes today. Eric Pugh -Original Message- From: Phil Steitz [mailto:[EMAIL PROTECTED] Sent: Wednesday, March 02, 2005 3:49 PM To: Jakarta Commons Developers List Subject: Re: [VOTE] Release commons email 1.0 +1 modulo the following nits: * Binary distro includes NOTICE.txt in the jar (top level, should probably be with LICENSE.txt in META-INF) but not in the top level directory of the distribution. * Source distro does not include NOTICE.txt * Ant build.xml in source distro fails with MalformedURLException in get deps. When I regenerated the build.xml using maven ant, the regenerated build.xml worked. Could be build.xml is out of date? * Make sure to update the repo link on the web site to point to svn. Phil robert burrell donkin wrote: On Tue, 2005-03-01 at 06:58, Eric Pugh wrote: [X] +1 Lets release commons-email, it's been too long! [ ] 0 Commons-what? Not ready for release [ ] -1 Don't release. I can't get dumbster (replace with your reason) to work. BTW i've checked the sums and signatures - robert - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [logging] discovery error handling
Brian, Thank you for your analysis which is very much appreciated. I think it deserves further investigation. Unfortunately, I can't spare the time to study it right away, but promise to do so as soon as my schedule clears up. On 2005-03-03 5:34:50, Brian Stansberry wrote: What I've found is documented at http://xnet.wanconcepts.com/jcl/furtherAnalysis.html. -- Ceki Gülcü The complete log4j manual: http://www.qos.ch/log4j/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
DO NOT REPLY [Bug 18942] - [beanutils] Add t/f to BooleanConverter
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG· RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://issues.apache.org/bugzilla/show_bug.cgi?id=18942. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND· INSERTED IN THE BUG DATABASE. http://issues.apache.org/bugzilla/show_bug.cgi?id=18942 --- Additional Comments From [EMAIL PROTECTED] 2005-03-03 19:45 --- Thanks, Simon, for taking a look. I'll address each of your points with individual comments. [Simon] === How do end users actually use this new functionality? Were you thinking of something like this? BooleanConverter bc = (BooleanConverter) ConvertUtils.lookup(Boolean.class); bc.addTrueString(oui); bc.addFalseString(non); or like this? BooleanConverter bc = new BooleanConverter(); bc.addTrueString(oui); bc.addFalseString(non); ConvertUtils.register(bc, Boolean.class); If the latter, then it seems *almost* as easy for the user to just write a custom Converter class of their own that implements their desired mapping than for BeanUtils to provide a configurable BooleanConverter... In either case, *just* the conversion of String-Boolean is affected. String-boolean and String-Boolean[] conversions have not been modified (see below) [Eric response] I disagree that using this configurable converter is not significantly easier than writing your own. BeanUtils is a framework and as such should be as configurable as is reasonably possible. Writing a new implementation just to handle T/F is overkill, IMO. Also, the current ConvertUtils by default registers two separate (but identical) converters for Boolean and boolean, which I think is a mistake. I would amend my patch to use the same converter for both types. It doesn't matter if the user chooses form A or form B that you describe above - they amount to the same thing. -- Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email --- You are receiving this mail because: --- You are the assignee for the bug, or are watching the assignee. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
DO NOT REPLY [Bug 18942] - [beanutils] Add t/f to BooleanConverter
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG· RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://issues.apache.org/bugzilla/show_bug.cgi?id=18942. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND· INSERTED IN THE BUG DATABASE. http://issues.apache.org/bugzilla/show_bug.cgi?id=18942 --- Additional Comments From [EMAIL PROTECTED] 2005-03-03 19:52 --- [Simon] === BooleanArrayConverter Perhaps BooleanArrayConverter should contain a reference to a BooleanConverter, with the ConvertUtilsBean.deregister() method ensuring that the BooleanArrayConverter constructor is passed the just-created BooleanConverter object? That way, any changes to the BooleanConverter will automatically affect the BooleanArrayConverter too. ie in ConvertUtilsBean.deregister(), do something like this: register(booleanArray.getClass(), new BooleanArrayConverter(bc, booleanArray)); where bc is the same BooleanConverter object that was registered for the Boolean.class type. That way, changing the true/false values for the Boolean.class converter will also change the mappings for the BooleanArrayConverter. Or the documentation for the BooleanConverter can just explain that any calls to addTrueString/addFalseString won't affect String-Boolean[] conversions. Any such change, however, would have to be carefully done to avoid backwards-compatibility issues. For example, the old constructors must remain in place. [Eric response] I agree that BooleanArrayConverter is poorly written in that it ignores BooleanConverter. I, too, think it should be rewritten to use BooleanConverter. However, to me that is a seperate (though related) request from this one. This one could be accepted/implemented without affecting BooleanArrayConverter (I agree that at least a comment addition to explicitly state that seperation would be appropriate). Heck, I might even volunteer to fix BooleanArrayConverter, too, if my work on BooleanConverter were accepted. -- Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email --- You are receiving this mail because: --- You are the assignee for the bug, or are watching the assignee. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
DO NOT REPLY [Bug 18942] - [beanutils] Add t/f to BooleanConverter
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG· RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://issues.apache.org/bugzilla/show_bug.cgi?id=18942. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND· INSERTED IN THE BUG DATABASE. http://issues.apache.org/bugzilla/show_bug.cgi?id=18942 --- Additional Comments From [EMAIL PROTECTED] 2005-03-03 20:15 --- [Simon] === Thread-safety [Eric response] I'm reasonably sure that the patch I provided is thread-safe, although I did not put a lot of analysis into making it so beyond the choice of Hashtable. I would think it prudent to add some unit tests to verify that. In considering thread safety, it is important to note frequency of reads vs. frequency of writes, as well as the potential cost of a read happening in the middle of a write. The only writes happening here are upon first call to getKnownStrings() - that method can be synchronized if we can write a test that shows it to be a problem. The performance of synchronization is not nearly as big a factor as it was in earlier JVMs, so I'm skeptical of any concern over its usage. Not that I want to promote unwarranted synchronization; I just would not sacrafice design and/or API simplicity or flexibility for the sake of avoiding synchronization. If it was demonstrated to be a peroformance problem, then I'd look at alternative designs to avoid it, but not until then. -- Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email --- You are receiving this mail because: --- You are the assignee for the bug, or are watching the assignee. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
DO NOT REPLY [Bug 18942] - [beanutils] Add t/f to BooleanConverter
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG· RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://issues.apache.org/bugzilla/show_bug.cgi?id=18942. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND· INSERTED IN THE BUG DATABASE. http://issues.apache.org/bugzilla/show_bug.cgi?id=18942 --- Additional Comments From [EMAIL PROTECTED] 2005-03-03 20:29 --- [Simon] === avoid calling addTrueString/addFalseString from getKnownStrings This is just a minor code issue. The addTrueString/addFalseString methods call getKnownStrings, so it would seem better in getKnownString to just do: knownStrings = new Hashtable(); knownStrings.put(true, Boolean.TRUE); [Eric response] Any particular reason why you prefer that way? -- Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email --- You are receiving this mail because: --- You are the assignee for the bug, or are watching the assignee. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
DO NOT REPLY [Bug 18942] - [beanutils] Add t/f to BooleanConverter
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG· RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://issues.apache.org/bugzilla/show_bug.cgi?id=18942. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND· INSERTED IN THE BUG DATABASE. http://issues.apache.org/bugzilla/show_bug.cgi?id=18942 --- Additional Comments From [EMAIL PROTECTED] 2005-03-03 20:33 --- [Simon] I think there definitely needs to be a way to remove the built-in mappings for BooleanConverter. For example, interpreting t as a true value may not be appropriate in all cases. I originally considered including a removeTrueString()/removeFalseString(), but I was thinking in terms of ones the user had added and didn't think it was worth the effort. But in the context of wanting to remove a default string, I agree it would be very useful. A couple of these suggestions involve realtively straightforward modifications, so I'll work on them when I get a spare hour or two. The others (where I've counter-pointed or asked for clarification/explanation) I'll hold off until I get more feedback. -- Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email --- You are receiving this mail because: --- You are the assignee for the bug, or are watching the assignee. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
svn commit: r156068 - jakarta/commons/proper/dbcp/tags/pre_5_15_bm
Author: burton Date: Thu Mar 3 11:53:43 2005 New Revision: 156068 URL: http://svn.apache.org/viewcvs?view=revrev=156068 Log: branched Added: jakarta/commons/proper/dbcp/tags/pre_5_15_bm/ - copied from r156067, jakarta/commons/proper/dbcp/trunk/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
svn commit: r156070 - jakarta/commons/sandbox/benchmark/tags
Author: burton Date: Thu Mar 3 11:58:05 2005 New Revision: 156070 URL: http://svn.apache.org/viewcvs?view=revrev=156070 Log: mkdir Added: jakarta/commons/sandbox/benchmark/tags/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
svn commit: r156071 - jakarta/commons/sandbox/benchmark/tags/pre_5_15_bm
Author: burton Date: Thu Mar 3 11:58:36 2005 New Revision: 156071 URL: http://svn.apache.org/viewcvs?view=revrev=156071 Log: tagged for 5 and 15 min refactor Added: jakarta/commons/sandbox/benchmark/tags/pre_5_15_bm/ - copied from r156070, jakarta/commons/sandbox/benchmark/trunk/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
svn commit: r156072 - jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java
Author: burton Date: Thu Mar 3 12:01:10 2005 New Revision: 156072 URL: http://svn.apache.org/viewcvs?view=revrev=156072 Log: javadoc update Modified: jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java Modified: jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java?view=diffr1=156071r2=156072 == --- jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java (original) +++ jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java Thu Mar 3 12:01:10 2005 @@ -74,6 +74,16 @@ public static long INTERVAL = 60 * 1000; /** + * The 5 minute benchmark interval. + */ +public static long INTERVAL_5 = 5 * 60 * 1000; + +/** + * The 15 minute benchmark interval. + */ +public static long INTERVAL_15 = 15 * 60 * 1000; + +/** * Disable all logging of benchmarks. This essentially makes the * performance overhead zero. */ @@ -84,8 +94,14 @@ */ public static HashMap benchmarks = new HashMap(); +/** + * Mutext used to prevent threads from corrupting start/complete cycles. + */ private Object MUTEX = new Object(); +/** + * The current name of this benchmark. + */ private String name = null; /** @@ -94,25 +110,39 @@ public long timestamp = -1; /** - * The current number of started benchmarks + * The current number of started benchmarks. This can be analyzed at + * runtime but its recommended that you use totalCompleted, totalStarted */ public long started = 0; /** - * The current number of completed benchmarks + * The current number of completed benchmarks. This can be analyzed at + * runtime but its recommended that you use totalCompleted, totalStarted */ public long completed = 0; +/** + * Value getTotalStarted + */ public long totalStarted = 0; +/** + * Value getTotalCompleted + */ public long totalCompleted = 0; // metadata about this benchmark *** +/** + * The total number of start()ed benchmarks since in the last rollover. + */ public long getTotalStarted() { return totalStarted; } +/** + * The total number of complete()ed benchmarks since in the last rollover. + */ public long getTotalCompleted() { return totalCompleted; } @@ -130,7 +160,6 @@ /** * Reset stats if necessary. * - * @author a href=mailto:[EMAIL PROTECTED]Kevin A. Burton/a */ private void doReset() { @@ -186,7 +215,7 @@ /** * Return a child benchmark of the current method. This can be used to * return a benchmark for a specific method based on a benchmark for a - * class. + * class. * * @author a href=mailto:[EMAIL PROTECTED]Kevin A. Burton/a */ @@ -198,6 +227,12 @@ // static code * +/** + * Factory method for obtaining a benchmark. This method uses the callers + * classname by performing a quick stack analysis. Note that this is slow + * and you should cache your benchmarks in a static variable. + * + */ public static Benchmark getBenchmark() { Exception e = new Exception(); @@ -206,10 +241,18 @@ } +/** + * Factory method for obtaining a benchmark by classname + * + */ public static Benchmark getBenchmark( Class clazz ) { return getBenchmark( clazz.getName() ); } +/** + * Factory method for obtaining a benchmark by name + * + */ public static Benchmark getBenchmark( String name ) { synchronized( benchmarks ) { @@ -229,6 +272,9 @@ // test code *** +/** + * Quick benchmark code testing. + */ public static void main( String[] args ) throws Exception { //FIXME: we should also support benchmarking of code regions and whether - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
svn commit: r156076 - jakarta/commons/proper/feedparser/trunk/src/java/org/apache/commons/feedparser/test/TestProbeLocator.java
Author: burton Date: Thu Mar 3 12:20:59 2005 New Revision: 156076 URL: http://svn.apache.org/viewcvs?view=revrev=156076 Log: unit tests pass Modified: jakarta/commons/proper/feedparser/trunk/src/java/org/apache/commons/feedparser/test/TestProbeLocator.java Modified: jakarta/commons/proper/feedparser/trunk/src/java/org/apache/commons/feedparser/test/TestProbeLocator.java URL: http://svn.apache.org/viewcvs/jakarta/commons/proper/feedparser/trunk/src/java/org/apache/commons/feedparser/test/TestProbeLocator.java?view=diffr1=156075r2=156076 == --- jakarta/commons/proper/feedparser/trunk/src/java/org/apache/commons/feedparser/test/TestProbeLocator.java (original) +++ jakarta/commons/proper/feedparser/trunk/src/java/org/apache/commons/feedparser/test/TestProbeLocator.java Thu Mar 3 12:20:59 2005 @@ -425,12 +425,13 @@ // The FeedParser gets a different location for the XML file then // through the aggresive prober for this feed -testSite(http://www.pipetree.com/qmacro/;, - new Blosxom(), 1, - new String[] { FeedReference.RSS_MEDIA_TYPE }, - new String[] { http://www.pipetree.com/qmacro/index.rss; }, - NO_ATOM_FEED, null, - HAS_RSS_FEED, http://www.pipetree.com/qmacro/xml;); + +// testSite(http://www.pipetree.com/qmacro/;, +// new Blosxom(), 1, +// new String[] { FeedReference.RSS_MEDIA_TYPE }, +// new String[] { http://www.pipetree.com/qmacro/index.rss; }, +// NO_ATOM_FEED, null, +// HAS_RSS_FEED, http://www.pipetree.com/qmacro/xml;); testSite(http://www.bitbucketheaven.com/cgi-bin/blosxom.cgi;, new Blosxom(), 1, - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
svn commit: r156079 - in jakarta/commons/sandbox/benchmark/trunk: project.xml src/java/org/apache/commons/benchmark/Benchmark.java src/java/org/apache/commons/benchmark/BenchmarkTracker.java
Author: burton Date: Thu Mar 3 12:32:12 2005 New Revision: 156079 URL: http://svn.apache.org/viewcvs?view=revrev=156079 Log: refactored benchmark tracking and rollover into dedicated class Added: jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java Modified: jakarta/commons/sandbox/benchmark/trunk/project.xml jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java Modified: jakarta/commons/sandbox/benchmark/trunk/project.xml URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/benchmark/trunk/project.xml?view=diffr1=156078r2=156079 == --- jakarta/commons/sandbox/benchmark/trunk/project.xml (original) +++ jakarta/commons/sandbox/benchmark/trunk/project.xml Thu Mar 3 12:32:12 2005 @@ -17,7 +17,7 @@ descriptionJakarta Benchmark/description -currentVersion0.0.1/currentVersion +currentVersion0.0.2/currentVersion packageorg.apache.commons.benchmark/package Modified: jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java?view=diffr1=156078r2=156079 == --- jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java (original) +++ jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java Thu Mar 3 12:32:12 2005 @@ -95,56 +95,26 @@ public static HashMap benchmarks = new HashMap(); /** - * Mutext used to prevent threads from corrupting start/complete cycles. - */ -private Object MUTEX = new Object(); - -/** * The current name of this benchmark. */ private String name = null; - -/** - * The time the current benchmark was started. -1 for never started. - */ -public long timestamp = -1; - -/** - * The current number of started benchmarks. This can be analyzed at - * runtime but its recommended that you use totalCompleted, totalStarted - */ -public long started = 0; - -/** - * The current number of completed benchmarks. This can be analyzed at - * runtime but its recommended that you use totalCompleted, totalStarted - */ -public long completed = 0; - -/** - * Value getTotalStarted - */ -public long totalStarted = 0; - -/** - * Value getTotalCompleted - */ -public long totalCompleted = 0; +private BenchmarkTracker tracker = null; + // metadata about this benchmark *** /** * The total number of start()ed benchmarks since in the last rollover. */ public long getTotalStarted() { -return totalStarted; +return tracker.totalStarted; } /** * The total number of complete()ed benchmarks since in the last rollover. */ public long getTotalCompleted() { -return totalCompleted; +return tracker.totalCompleted; } public String getName() { @@ -155,47 +125,16 @@ public Benchmark( String name ) { this.name = name; -} - -/** - * Reset stats if necessary. - * - */ -private void doReset() { - -long now = System.currentTimeMillis(); - -if ( now - timestamp INTERVAL ) { - -//need to perform a swap and save the current benchmark. -totalStarted = started; -totalCompleted = completed; - -//reset the benchmark -timestamp = now; -started = 0; -completed = 0; - -} - +tracker = new BenchmarkTracker( INTERVAL, this ); + } public void start() { if ( DISABLED ) return; - -//we need to synchronize on this individual metadata unit because if we -//didn't then another thread could come in, and corrupt our metadata -//about this benchmark. Since benchmarks are often performed within -//threads this is important. -synchronized( MUTEX ) { -doReset(); -++started; - -} - +tracker.start(); } public void complete() { @@ -203,12 +142,7 @@ if ( DISABLED ) return; -synchronized( MUTEX ) { - -doReset(); -++completed; - -} +tracker.complete(); } Added: jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java?view=autorev=156079
DO NOT REPLY [Bug 33834] New: - WordUtils capitalizeFully() throws a null pointer exception
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG· RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://issues.apache.org/bugzilla/show_bug.cgi?id=33834. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND· INSERTED IN THE BUG DATABASE. http://issues.apache.org/bugzilla/show_bug.cgi?id=33834 Summary: WordUtils capitalizeFully() throws a null pointer exception Product: Commons Version: 2.0 Final Platform: PC OS/Version: Windows XP Status: NEW Severity: normal Priority: P2 Component: Lang AssignedTo: commons-dev@jakarta.apache.org ReportedBy: [EMAIL PROTECTED] When submitting a null value I get a null pointer exception, it would be preferable for a function such as this to simply return the null value instead of blow up. Otherwise I have to add unnecessary logic in front of what should be a simple function call. -- Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email --- You are receiving this mail because: --- You are the assignee for the bug, or are watching the assignee. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [chain] questions about various servlet/*Mapper classes
To answer your second question, the current release of ChainServlet actually sets the catalog object as a ServletContext (not chain context) attribute or a request attribute depending if CONFIG_ATTR is set or not. I guess the original idea may be that the chain context (i,e ServletWebContext) will encapsulate how catalog is stored so a command doesn't need to know where it's stored in order to retrieve a catalog.(The ServeltPathMapper is a command that needs to get a catalog to further dispatch commands.) But it seems this is broken (may be there is a problem in the ServletWebContext.) To fix this, let's first consider how a catalog can be retrieved. Suppose a command retrieves a catalog from the CatalogFactory (either the default one or a named one and this is the case when CONFIG_ATTR is not set), now the problem becomes how it knows the catalog name. One way is to hard code the catalog name in the command. Another way is to retrieve the name from the chain context. I think the later one is more flexible (especially for a generic command like ServletPathMapper command), even though it incurs one more step. (This command has a setCatalogKey method, but I'm not sure how this method can be called. Since you can't call this method from the containing servlet because the servlet only knows about the generic command interface.) The code will look like this (in ServletPathMapper) Catalog catalog = null; String catalog_name = (String) context.get(getCatalogKey()); if (catalog_name != null) { catalog = CatalogFactory.getInstance().getCatalog(catalog_name); } else { catalog = CatalogFactory.getInstance().getCatalog(); } In order for this scheme to work, the ChainProcessor needs to set the name in the context, like this (in ChainProcessor): if (attribute == null) { // save catalog in CATALOG_DEFAULT, // no need to save theCatalog, which can be retrieved by catalogFactory //request.setAttribute(CATALOG_DEFAULT, theCatalog); context.put(CATALOG_DEFAULT, catalog); } Let's see if this will work when CONFIG_ATTR is set (compatibility issue). Basically the command needs to know if CONFIG_ATTR is set. If it's set, it will retrieve the catalog from ServletContext (Or ServletWebContext, which is a chain context. We may need to fix it to hide where catalog is stored.) Here is the final code in ServletPathMapper: Catalog catalog = null; String catalog_name = (String) context.get(getCatalogKey()); String attr = (String) context.get(ChainProcessor.CONFIG_ATTR); if (attr != null) // find catalog through ServletContext { catalog = (Catalog) swcontext.getContext().getAttribute(attr); } else if (catalog_name != null) //find catalog through catalog name { catalog = CatalogFactory.getInstance().getCatalog(catalog_name); } else { catalog = CatalogFactory.getInstance().getCatalog(); } (If both CONFIG_ATTR and CATALOG are set, we need to decide which one take precedence.) The relevent change in ChainProcessor: if (attribute != null) { context.put(CONFIG_ATTR, attribute); } else { context.put(CATALOG_DEFAULT, catalog); } This approach bypassed fixing the chain context. But it's working. Thanks, Howard On Wed, 2 Mar 2005 19:02:05 -0600, Joe Germuska [EMAIL PROTECTED] wrote: At 5:02 PM -0500 3/2/05, Howard Lin wrote: Thanks, I'll file a bug in the Bugzilla. It seems the problem is that in ChainProcessor, there is no need to save the catalog as a request attribute since CatalogFactory already had it, it only needs to save the catalog name in the context so the next command can retrieve the catalog name and use that to retrieve the catalog. If CONFIG_ATTR is set, ChainProcessor should put that value in the context too so the next command can retrieve value of CONFIG_ATTR and get the catalog through the ServletContext. If this seems the right way to fix it, I can submit patches. Again, I haven't used the ChainServlet or its siblings. I was going to argue that, for backwards compatibility, the Catalog itself should be put in the request and the context, but then, it seems that no one would have ever been able to use it as released, so I'm not sure how much we should be worried about compatibility! Still, I'm not sure I think it's bad to pass the Catalog object instead of its name in those places. I'm not sure I can think of any particular reason to decide either way, although I guess it is one less step to retrieve a usable Catalog object than to get its name and look it up. If CONFIG_ATTR is set, ChainProcessor should put that value in the context too so the next command can retrieve value of CONFIG_ATTR and get the catalog through the
svn commit: r156081 - jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java
Author: burton Date: Thu Mar 3 12:48:20 2005 New Revision: 156081 URL: http://svn.apache.org/viewcvs?view=revrev=156081 Log: better dox... Modified: jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java Modified: jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java?view=diffr1=156080r2=156081 == --- jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java (original) +++ jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java Thu Mar 3 12:48:20 2005 @@ -189,6 +189,8 @@ */ public static Benchmark getBenchmark( String name ) { +//we have to synchronize on this hashmap I'm afraid. I could use a +//ConcurrentHashMap but I'm not sure of the performance advantage here. synchronized( benchmarks ) { Benchmark benchmark = (Benchmark)benchmarks.get( name ); @@ -221,7 +223,7 @@ //simple testing framework - INTERVAL = 10 * 1000; +INTERVAL = 10 * 1000; Benchmark benchmark = getBenchmark( Benchmark.class ); benchmark = benchmark.child( main ); Modified: jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java?view=diffr1=156080r2=156081 == --- jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java (original) +++ jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java Thu Mar 3 12:48:20 2005 @@ -37,6 +37,9 @@ */ private Benchmark parent = null; +/** + * Interval (in millis) that we rollover this tracked benchmark. + */ private long interval = 0; /** - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
svn commit: r156083 - jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java
Author: burton Date: Thu Mar 3 13:01:49 2005 New Revision: 156083 URL: http://svn.apache.org/viewcvs?view=revrev=156083 Log: getTracker now supports exporting trackers based on interval. The metadata for the tracker is also exported including total completed and started, etc. Modified: jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java Modified: jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java?view=diffr1=156082r2=156083 == --- jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java (original) +++ jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java Thu Mar 3 13:01:49 2005 @@ -71,7 +71,7 @@ /** * How often should we maintain/reset the benchmark. */ -public static long INTERVAL = 60 * 1000; +public static long INTERVAL_1 = 60 * 1000; /** * The 5 minute benchmark interval. @@ -99,50 +99,102 @@ */ private String name = null; -private BenchmarkTracker tracker = null; - +/** + * The current benchmark. + */ +private BenchmarkTracker tracker1 = null; +private BenchmarkTracker tracker5 = null; +private BenchmarkTracker tracker15 = null; + +/** + * Create a new benchmark with a given name. + */ +private Benchmark( String name ) { + +this.name = name; + +tracker1 = new BenchmarkTracker( INTERVAL_1, this ); +tracker5 = new BenchmarkTracker( INTERVAL_5, this ); +tracker15 = new BenchmarkTracker( INTERVAL_15, this ); + +} + // metadata about this benchmark *** /** * The total number of start()ed benchmarks since in the last rollover. */ public long getTotalStarted() { -return tracker.totalStarted; +return tracker1.totalStarted; } /** * The total number of complete()ed benchmarks since in the last rollover. */ public long getTotalCompleted() { -return tracker.totalCompleted; +return tracker1.totalCompleted; } +/** + * Get the tracker for this benchmark which includes all metadata related to + * this benchmark including total completed/started and current values. + * + */ +public BenchmarkTracker getTracker() { +return tracker1; +} + +public BenchmarkTracker getTracker( long interval ) { + +if ( interval == INTERVAL_1 ) { +return tracker1; +} else if ( interval == INTERVAL_5 ) { +return tracker5; +} else if ( interval == INTERVAL_15 ) { +return tracker15; +} + +return null; + +} + +/** + * Get the name of this benchmark. Usually the classname or method name of + * the caller. + */ public String getName() { return name; } // implementation code for start/complete ** - -public Benchmark( String name ) { -this.name = name; -tracker = new BenchmarkTracker( INTERVAL, this ); - -} +/** + * Tell the benchmark that its has been started for this interval. + * + */ public void start() { if ( DISABLED ) return; -tracker.start(); +tracker1.start(); +tracker5.start(); +tracker15.start(); + } +/** + * Tell the benchmark that its has been completed for this interval. + * + */ public void complete() { if ( DISABLED ) return; -tracker.complete(); +tracker1.complete(); +tracker5.complete(); +tracker15.complete(); } @@ -223,7 +275,7 @@ //simple testing framework -INTERVAL = 10 * 1000; +INTERVAL_1 = 10 * 1000; Benchmark benchmark = getBenchmark( Benchmark.class ); benchmark = benchmark.child( main ); @@ -235,7 +287,7 @@ benchmark.start(); //do something slow... -Thread.sleep( INTERVAL + 10 ); +Thread.sleep( INTERVAL_1 + 10 ); benchmark.complete(); Modified: jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java?view=diffr1=156082r2=156083 == ---
svn commit: r156084 - jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java
Author: burton Date: Thu Mar 3 13:05:06 2005 New Revision: 156084 URL: http://svn.apache.org/viewcvs?view=revrev=156084 Log: ability to specify in terms of minutes not just millis. Nice compromise Modified: jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java Modified: jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java?view=diffr1=156083r2=156084 == --- jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java (original) +++ jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java Thu Mar 3 13:05:06 2005 @@ -144,7 +144,24 @@ return tracker1; } +/** + * Get a tracker with a given interval. When the tracker with an interval + * isn't registered we return null. Note that we're very flexible with the + * interval here. When the value is less than 1000 we assume the user is + * specifying minutes and we do the conversion. This way your code can + * simply call getInterval( 15 ) which is much easier to read instead of + * calling getInterval( 90 ) (which is 15 minutes in millis). + * + * @author a href=mailto:[EMAIL PROTECTED]Kevin A. Burton/a + */ public BenchmarkTracker getTracker( long interval ) { + +if ( interval 1000 ) { +//the user is trying to specify the interval in minutes not in millis. + +interval = interval * 60 * 1000; + +} if ( interval == INTERVAL_1 ) { return tracker1; - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
svn commit: r156087 - jakarta/commons/sandbox/benchmark/trunk/project.xml
Author: burton Date: Thu Mar 3 13:15:20 2005 New Revision: 156087 URL: http://svn.apache.org/viewcvs?view=revrev=156087 Log: init of unit tests... Modified: jakarta/commons/sandbox/benchmark/trunk/project.xml Modified: jakarta/commons/sandbox/benchmark/trunk/project.xml URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/benchmark/trunk/project.xml?view=diffr1=156086r2=156087 == --- jakarta/commons/sandbox/benchmark/trunk/project.xml (original) +++ jakarta/commons/sandbox/benchmark/trunk/project.xml Thu Mar 3 13:15:20 2005 @@ -53,8 +53,17 @@ /dependencies build + nagEmailAddress[EMAIL PROTECTED]/nagEmailAddress sourceDirectorysrc/java/sourceDirectory +unitTestSourceDirectorysrc/test/unitTestSourceDirectory + +unitTest +includes +include**/Test*.java/include +/includes +/unitTest + /build reports - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
svn commit: r156088 - in jakarta/commons/sandbox/benchmark/trunk/src/test: ./ org/ org/apache/ org/apache/commons/ org/apache/commons/benchmark/ org/apache/commons/benchmark/Test1.java
Author: burton Date: Thu Mar 3 13:15:47 2005 New Revision: 156088 URL: http://svn.apache.org/viewcvs?view=revrev=156088 Log: init of tests... Added: jakarta/commons/sandbox/benchmark/trunk/src/test/ jakarta/commons/sandbox/benchmark/trunk/src/test/org/ jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/ jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/ jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/ jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java Added: jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java?view=autorev=156088 == --- jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java (added) +++ jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java Thu Mar 3 13:15:47 2005 @@ -0,0 +1,37 @@ +/* +/* + * Copyright 1999,2004 The Apache Software Foundation. + * + * Licensed under the Apache License, Version 2.0 (the License); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an AS IS BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +package org.apache.commons.benchmark; + +import junit.framework.*; + +/** + */ +public class Test1 extends TestCase { + +public Test1(String testName) { +super(testName); +} + +public void test1() { +System.out.println( This is a test... ); +} + +public static void main(String args[]) { +} + +} - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
svn commit: r156092 - jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java
Author: burton Date: Thu Mar 3 13:46:42 2005 New Revision: 156092 URL: http://svn.apache.org/viewcvs?view=revrev=156092 Log: no need for intervals to be longs.. .using ints. saving 4 bytes... Modified: jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java Modified: jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java?view=diffr1=156091r2=156092 == --- jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java (original) +++ jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java Thu Mar 3 13:46:42 2005 @@ -71,17 +71,17 @@ /** * How often should we maintain/reset the benchmark. */ -public static long INTERVAL_1 = 60 * 1000; +public static int INTERVAL_1 = 60 * 1000; /** * The 5 minute benchmark interval. */ -public static long INTERVAL_5 = 5 * 60 * 1000; +public static int INTERVAL_5 = 5 * 60 * 1000; /** * The 15 minute benchmark interval. */ -public static long INTERVAL_15 = 15 * 60 * 1000; +public static int INTERVAL_15 = 15 * 60 * 1000; /** * Disable all logging of benchmarks. This essentially makes the @@ -154,7 +154,7 @@ * * @author a href=mailto:[EMAIL PROTECTED]Kevin A. Burton/a */ -public BenchmarkTracker getTracker( long interval ) { +public BenchmarkTracker getTracker( int interval ) { if ( interval 1000 ) { //the user is trying to specify the interval in minutes not in millis. Modified: jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java?view=diffr1=156091r2=156092 == --- jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java (original) +++ jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java Thu Mar 3 13:46:42 2005 @@ -40,7 +40,7 @@ /** * Interval (in millis) that we rollover this tracked benchmark. */ -private long interval = 0; +private int interval = 0; /** * The time the current benchmark was started. -1 for never started. @@ -73,7 +73,7 @@ * * Create a new codeBenchmarkTracker/code instance. */ -public BenchmarkTracker( long interval, Benchmark parent ) { +public BenchmarkTracker( int interval, Benchmark parent ) { this.interval = interval; this.parent = parent; } - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[RESULT][VOTE] [logging] promote RC1 to alpha status
i count (binding) 3 +1's only. (unless i hear any objections from the pmc) i will therefore proceed to promote the candidate to an alpha release. thanks to those who voted :) - robert - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [VOTE] Release commons email 1.0
I'm +1! On Wed, 2 Mar 2005 09:27:28 -0800, Eric Pugh [EMAIL PROTECTED] wrote: The only open bug/enhancement is 32900: http://issues.apache.org/bugzilla/show_bug.cgi?id=32900. It is quite clearly an enhancement that is post 1.0, and there is some discussion on the bug list of whether it fits into the commons-email charter. Eric Pugh -Original Message- From: Dion Gillard [mailto:[EMAIL PROTECTED] Sent: Tuesday, March 01, 2005 3:24 PM To: Jakarta Commons Developers List Subject: Re: [VOTE] Release commons email 1.0 Are there any open bugs/enhancements? On Tue, 1 Mar 2005 09:01:03 -0800, Eric Pugh [EMAIL PROTECTED] wrote: My +1 of course! [X] +1 Lets release commons-email, it's been too long! [ ] 0 Commons-what? Not ready for release [ ] -1 Don't release. I can't get dumbster (replace with your reason) to work. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- http://www.multitask.com.au/people/dion/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] -- http://www.multitask.com.au/people/dion/ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
DO NOT REPLY [Bug 33780] - [betwixt] SAX Attribute Problem: qName differ from localName
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG· RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://issues.apache.org/bugzilla/show_bug.cgi?id=33780. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND· INSERTED IN THE BUG DATABASE. http://issues.apache.org/bugzilla/show_bug.cgi?id=33780 --- Additional Comments From [EMAIL PROTECTED] 2005-03-03 23:28 --- Thanks for the comments :) This was indeed a bug (and a one liner at that) I've committed a fix which satisfies the test cases. Many thanks for contributing those. Robert -- Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email --- You are receiving this mail because: --- You are the assignee for the bug, or are watching the assignee. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
svn commit: r156094 - in jakarta/commons/proper/betwixt/trunk/src: java/org/apache/commons/betwixt/digester/AttributeRule.java test/org/apache/commons/betwixt/SimpleClass.betwixt test/org/apache/commons/betwixt/SimpleClass.java test/org/apache/commons/betwixt/TestAttributeQNameProblem.java
Author: rdonkin Date: Thu Mar 3 14:27:12 2005 New Revision: 156094 URL: http://svn.apache.org/viewcvs?view=revrev=156094 Log: Fixed bug in local names when using dot bwetwixt files. Issue 14377. Test cases contributed by Christoph Gaffga. Added: jakarta/commons/proper/betwixt/trunk/src/test/org/apache/commons/betwixt/SimpleClass.betwixt jakarta/commons/proper/betwixt/trunk/src/test/org/apache/commons/betwixt/SimpleClass.java jakarta/commons/proper/betwixt/trunk/src/test/org/apache/commons/betwixt/TestAttributeQNameProblem.java Modified: jakarta/commons/proper/betwixt/trunk/src/java/org/apache/commons/betwixt/digester/AttributeRule.java Modified: jakarta/commons/proper/betwixt/trunk/src/java/org/apache/commons/betwixt/digester/AttributeRule.java URL: http://svn.apache.org/viewcvs/jakarta/commons/proper/betwixt/trunk/src/java/org/apache/commons/betwixt/digester/AttributeRule.java?view=diffr1=156093r2=156094 == --- jakarta/commons/proper/betwixt/trunk/src/java/org/apache/commons/betwixt/digester/AttributeRule.java (original) +++ jakarta/commons/proper/betwixt/trunk/src/java/org/apache/commons/betwixt/digester/AttributeRule.java Thu Mar 3 14:27:12 2005 @@ -198,7 +198,7 @@ attributeDescriptor.setUpdater( new MethodUpdater( writeMethod ) ); } -attributeDescriptor.setLocalName( propertyDescriptor.getName() ); +attributeDescriptor.setPropertyName( propertyDescriptor.getName() ); attributeDescriptor.setPropertyType( type ); // XXX: associate more bean information with the descriptor? Added: jakarta/commons/proper/betwixt/trunk/src/test/org/apache/commons/betwixt/SimpleClass.betwixt URL: http://svn.apache.org/viewcvs/jakarta/commons/proper/betwixt/trunk/src/test/org/apache/commons/betwixt/SimpleClass.betwixt?view=autorev=156094 == --- jakarta/commons/proper/betwixt/trunk/src/test/org/apache/commons/betwixt/SimpleClass.betwixt (added) +++ jakarta/commons/proper/betwixt/trunk/src/test/org/apache/commons/betwixt/SimpleClass.betwixt Thu Mar 3 14:27:12 2005 @@ -0,0 +1,22 @@ +?xml version=1.0 encoding=ISO-8859-1? +!-- + Copyright 2001-2004 The Apache Software Foundation. + + Licensed under the Apache License, Version 2.0 (the License); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an AS IS BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. +-- +info primitiveTypes=element +element name=test-class +attribute name=test-prop-1 property=testPropertyOne/ +attribute name=test-prop-2 property=testPropertyTwo/ +/element +/info \ No newline at end of file Added: jakarta/commons/proper/betwixt/trunk/src/test/org/apache/commons/betwixt/SimpleClass.java URL: http://svn.apache.org/viewcvs/jakarta/commons/proper/betwixt/trunk/src/test/org/apache/commons/betwixt/SimpleClass.java?view=autorev=156094 == --- jakarta/commons/proper/betwixt/trunk/src/test/org/apache/commons/betwixt/SimpleClass.java (added) +++ jakarta/commons/proper/betwixt/trunk/src/test/org/apache/commons/betwixt/SimpleClass.java Thu Mar 3 14:27:12 2005 @@ -0,0 +1,39 @@ +/* + * Copyright 2005 The Apache Software Foundation. + * + * Licensed under the Apache License, Version 2.0 (the License); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an AS IS BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.commons.betwixt; + +public class SimpleClass { + +private String testPropertyOne = abc; + +private Integer testPropertyTwo = new Integer(12); + +public String getTestPropertyOne() { +return this.testPropertyOne; +} + +public void setTestPropertyOne(String testPropertyOne) { +this.testPropertyOne = testPropertyOne; +} + +public Integer getTestPropertyTwo() { +return this.testPropertyTwo; +} + +public void setTestPropertyTwo(Integer testPropertyTwo) { +this.testPropertyTwo = testPropertyTwo; +} +} \ No newline at end of file Added:
DO NOT REPLY [Bug 33780] - [betwixt] SAX Attribute Problem: qName differ from localName
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG· RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://issues.apache.org/bugzilla/show_bug.cgi?id=33780. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND· INSERTED IN THE BUG DATABASE. http://issues.apache.org/bugzilla/show_bug.cgi?id=33780 [EMAIL PROTECTED] changed: What|Removed |Added Status|NEW |RESOLVED Resolution||FIXED --- Additional Comments From [EMAIL PROTECTED] 2005-03-03 23:28 --- Opps Mouse slipped Should have marked it fixed Robert -- Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email --- You are receiving this mail because: --- You are the assignee for the bug, or are watching the assignee. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
svn commit: r156096 - jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java
Author: burton Date: Thu Mar 3 14:38:25 2005 New Revision: 156096 URL: http://svn.apache.org/viewcvs?view=revrev=156096 Log: support for assertions around the started/compleded stuff Modified: jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java Modified: jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java?view=diffr1=156095r2=156096 == --- jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java (original) +++ jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java Thu Mar 3 14:38:25 2005 @@ -32,6 +32,35 @@ } public static void main(String args[]) { + +Benchmark benchmark = Benchmark.getBenchmark( Test1.class ); +benchmark = benchmark.child( main ); + +assertEquals( benchmark.getName(), org.apache.commons.benchmark.main ); + +int total = 60; + +for ( int i = 0; i total; ++i ) { + +benchmark.start(); + +assertEquals( benchmark.getTracker().getStarted(), i+1 ); + +benchmark.complete(); + +assertEquals( benchmark.getTracker().getCompleted(), i+1 ); + +} + +//now call the tracker to force a reset +benchmark.getTracker().reset( System.currentTimeMillis() ); + +assertEquals( benchmark.getTracker().getTotalStarted(), total ); +assertEquals( benchmark.getTracker().getTotalCompleted(), total ); + +assertEquals( benchmark.getTracker().getStarted(), 0 ); +assertEquals( benchmark.getTracker().getCompleted(), 0 ); + } } - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
svn commit: r156097 - jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java
Author: burton Date: Thu Mar 3 14:39:15 2005 New Revision: 156097 URL: http://svn.apache.org/viewcvs?view=revrev=156097 Log: support for assertions around the started/compleded stuff Modified: jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java Modified: jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java?view=diffr1=156096r2=156097 == --- jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java (original) +++ jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java Thu Mar 3 14:39:15 2005 @@ -28,10 +28,6 @@ } public void test1() { -System.out.println( This is a test... ); -} - -public static void main(String args[]) { Benchmark benchmark = Benchmark.getBenchmark( Test1.class ); benchmark = benchmark.child( main ); @@ -60,6 +56,10 @@ assertEquals( benchmark.getTracker().getStarted(), 0 ); assertEquals( benchmark.getTracker().getCompleted(), 0 ); + +} + +public static void main(String args[]) { } - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
svn commit: r156106 - in jakarta/commons/sandbox/benchmark/trunk/src: java/org/apache/commons/benchmark/Benchmark.java java/org/apache/commons/benchmark/BenchmarkTracker.java test/org/apache/commons/benchmark/Test1.java
Author: burton Date: Thu Mar 3 16:14:19 2005 New Revision: 156106 URL: http://svn.apache.org/viewcvs?view=revrev=156106 Log: Fixed a reset bug when viewing benchmark values Modified: jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java Modified: jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java?view=diffr1=156105r2=156106 == --- jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java (original) +++ jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java Thu Mar 3 16:14:19 2005 @@ -113,12 +113,23 @@ this.name = name; +reset(); + +} + +/** + * Reset this benchmark. Used primarily with unit tests. + * + * @author a href=mailto:[EMAIL PROTECTED]Kevin A. Burton/a + */ +void reset() { + tracker1 = new BenchmarkTracker( INTERVAL_1, this ); tracker5 = new BenchmarkTracker( INTERVAL_5, this ); tracker15 = new BenchmarkTracker( INTERVAL_15, this ); - -} +} + // metadata about this benchmark *** /** @@ -141,7 +152,7 @@ * */ public BenchmarkTracker getTracker() { -return tracker1; +return getTracker( INTERVAL_1 ); } /** @@ -153,7 +164,7 @@ * calling getInterval( 90 ) (which is 15 minutes in millis). * * @author a href=mailto:[EMAIL PROTECTED]Kevin A. Burton/a - */ + ' */ public BenchmarkTracker getTracker( int interval ) { if ( interval 1000 ) { @@ -164,11 +175,11 @@ } if ( interval == INTERVAL_1 ) { -return tracker1; +return tracker1.resetWhenNecessary(); } else if ( interval == INTERVAL_5 ) { -return tracker5; +return tracker5.resetWhenNecessary(); } else if ( interval == INTERVAL_15 ) { -return tracker15; +return tracker15.resetWhenNecessary(); } return null; Modified: jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java?view=diffr1=156105r2=156106 == --- jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java (original) +++ jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java Thu Mar 3 16:14:19 2005 @@ -78,7 +78,7 @@ this.parent = parent; } -void reset( long now ) { +BenchmarkTracker reset( long now ) { //need to perform a swap and save the current benchmark. totalStarted = started; @@ -89,12 +89,14 @@ started = 0; completed = 0; +return this; + } /** * Reset stats if necessary. */ -void resetWhenNecessary() { +BenchmarkTracker resetWhenNecessary() { long now = System.currentTimeMillis(); @@ -104,6 +106,8 @@ } +return this; + } void start() { Modified: jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java?view=diffr1=156105r2=156106 == --- jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java (original) +++ jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java Thu Mar 3 16:14:19 2005 @@ -1,5 +1,4 @@ /* -/* * Copyright 1999,2004 The Apache Software Foundation. * * Licensed under the Apache License, Version 2.0 (the License); @@ -27,12 +26,43 @@ super(testName); } -public void test1() { +//FIXME: test with using really short intervals but with diff values. + +public void testIntervalReset() throws Exception { + +Benchmark.INTERVAL_1 = 1000; +Benchmark.INTERVAL_5 = 5000; +Benchmark.INTERVAL_15 = 15000; + +Benchmark benchmark = Benchmark.getBenchmark( Test1.class ); +benchmark = benchmark.child( main ); + +benchmark.start(); +
svn commit: r156108 - jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java
Author: burton Date: Thu Mar 3 16:17:18 2005 New Revision: 156108 URL: http://svn.apache.org/viewcvs?view=revrev=156108 Log: interval reset code... reading should be consistent Modified: jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java Modified: jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java?view=diffr1=156107r2=156108 == --- jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java (original) +++ jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java Thu Mar 3 16:17:18 2005 @@ -50,6 +50,9 @@ assertEquals( 0, benchmark.getTracker( Benchmark.INTERVAL_1 ).getStarted() ); +Thread.sleep( 5000 ); +assertEquals( 0, benchmark.getTracker( Benchmark.INTERVAL_5 ).getStarted() ); + //reset all the trackers benchmark.reset(); - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
svn commit: r156110 - jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java
Author: burton Date: Thu Mar 3 16:20:57 2005 New Revision: 156110 URL: http://svn.apache.org/viewcvs?view=revrev=156110 Log: interval reset code... reading should be consistent Modified: jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java Modified: jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java?view=diffr1=156109r2=156110 == --- jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java (original) +++ jakarta/commons/sandbox/benchmark/trunk/src/test/org/apache/commons/benchmark/Test1.java Thu Mar 3 16:20:57 2005 @@ -30,6 +30,8 @@ public void testIntervalReset() throws Exception { +//this is cheating a bit. We set the intervals smaller so that we can +//get through the tests quickly Benchmark.INTERVAL_1 = 1000; Benchmark.INTERVAL_5 = 5000; Benchmark.INTERVAL_15 = 15000; - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
DO NOT REPLY [Bug 18942] - [beanutils] Add t/f to BooleanConverter
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG· RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://issues.apache.org/bugzilla/show_bug.cgi?id=18942. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND· INSERTED IN THE BUG DATABASE. http://issues.apache.org/bugzilla/show_bug.cgi?id=18942 --- Additional Comments From [EMAIL PROTECTED] 2005-03-04 03:21 --- (In reply to comment #7) [Eric response] I disagree that using this configurable converter is not significantly easier than writing your own. BeanUtils is a framework and as such should be as configurable as is reasonably possible. Writing a new implementation just to handle T/F is overkill, IMO. Here's a complete implementation for a french boolean converter: Converter bc = new Converter() { public Object convert(Class type, Object value) { String s = value.toString(); if (s.equalsIgnoreCase(o) || s.equalsIgnoreCase(oui)) return Boolean.TRUE; else if (s.equalsIgnoreCase(n) || s.equalsIgnoreCase(non)) return Boolean.FALSE; else throw new ConversionException(s); } } ConvertUtils.register(bc, Boolean.class); ConvertUtils.register(bc, Boolean.TYPE); This really isn't a whole lot more complicated for the user of BeanUtils than configuring a configurable BooleanConverter class. Note that I generally favour something like your original patch (a configurable BooleanConverter); I'm just pointing out that the current alternative isn't too bad. Also, the current ConvertUtils by default registers two separate (but identical) converters for Boolean and boolean, which I think is a mistake. I would amend my patch to use the same converter for both types. It doesn't matter if the user chooses form A or form B that you describe above - they amount to the same thing. Not quite. If BooleanArrayConverter is modified so it has a reference to the default BooleanConverter, then form A will also change the BooleanArrayConverter's behavior while form B will not. -- Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email --- You are receiving this mail because: --- You are the assignee for the bug, or are watching the assignee. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
DO NOT REPLY [Bug 18942] - [beanutils] Add t/f to BooleanConverter
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG· RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://issues.apache.org/bugzilla/show_bug.cgi?id=18942. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND· INSERTED IN THE BUG DATABASE. http://issues.apache.org/bugzilla/show_bug.cgi?id=18942 --- Additional Comments From [EMAIL PROTECTED] 2005-03-04 03:24 --- (In reply to comment #8) === BooleanArrayConverter [Eric response] I agree that BooleanArrayConverter is poorly written in that it ignores BooleanConverter. I, too, think it should be rewritten to use BooleanConverter. However, to me that is a seperate (though related) request from this one. This one could be accepted/implemented without affecting BooleanArrayConverter (I agree that at least a comment addition to explicitly state that seperation would be appropriate). Heck, I might even volunteer to fix BooleanArrayConverter, too, if my work on BooleanConverter were accepted. I'm just a little reluctant to deliberately create a situation in BeanUtils where BooleanConverter is configurable but BooleanArrayConverter is not. -- Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email --- You are receiving this mail because: --- You are the assignee for the bug, or are watching the assignee. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
DO NOT REPLY [Bug 18942] - [beanutils] Add t/f to BooleanConverter
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG· RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://issues.apache.org/bugzilla/show_bug.cgi?id=18942. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND· INSERTED IN THE BUG DATABASE. http://issues.apache.org/bugzilla/show_bug.cgi?id=18942 --- Additional Comments From [EMAIL PROTECTED] 2005-03-04 03:28 --- (In reply to comment #10) [Simon] knownStrings = new Hashtable(); knownStrings.put(true, Boolean.TRUE); [Eric response] Any particular reason why you prefer that way? Currently, getKnownStrings calls addTrueString, which calls back into getKnownStrings, which returns a reference to a partially-initialised map which is then updated before control returns to getKnownStrings. I think this does work as expected, but it seems a rather complex flow of calls. -- Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email --- You are receiving this mail because: --- You are the assignee for the bug, or are watching the assignee. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
DO NOT REPLY [Bug 18942] - [beanutils] Add t/f to BooleanConverter
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG· RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://issues.apache.org/bugzilla/show_bug.cgi?id=18942. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND· INSERTED IN THE BUG DATABASE. http://issues.apache.org/bugzilla/show_bug.cgi?id=18942 --- Additional Comments From [EMAIL PROTECTED] 2005-03-04 03:55 --- (In reply to comment #14) I agree with Simon that it seems more complex than it needs be. Surely the true/false values just need initializing when the converter is created. Why not just have a constructor that takes a pair of String arrrays - one for true values and the other for false values. Then all a user would have to do is.. ConvertUtils.register(new BooleanConverter({true, t}, {false, f}), Boolean.class); -- Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email --- You are receiving this mail because: --- You are the assignee for the bug, or are watching the assignee. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
DO NOT REPLY [Bug 18942] - [beanutils] Add t/f to BooleanConverter
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG· RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://issues.apache.org/bugzilla/show_bug.cgi?id=18942. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND· INSERTED IN THE BUG DATABASE. http://issues.apache.org/bugzilla/show_bug.cgi?id=18942 --- Additional Comments From [EMAIL PROTECTED] 2005-03-04 05:27 --- Created an attachment (id=14399) -- (http://issues.apache.org/bugzilla/attachment.cgi?id=14399action=view) Alternative implementation Here's an alternative patch for consideration. It doesn't have the flexibility of the original, but is much simpler and is very obviously thread-safe. -- Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email --- You are receiving this mail because: --- You are the assignee for the bug, or are watching the assignee. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
DO NOT REPLY [Bug 18942] - [beanutils] Add t/f to BooleanConverter
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG· RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://issues.apache.org/bugzilla/show_bug.cgi?id=18942. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND· INSERTED IN THE BUG DATABASE. http://issues.apache.org/bugzilla/show_bug.cgi?id=18942 --- Additional Comments From [EMAIL PROTECTED] 2005-03-04 06:11 --- (In reply to comment #16) Looks good to me. The only comment I have is that if someone initializes it with values in the true/false arrays that are upper case then they won't be matched. -- Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email --- You are receiving this mail because: --- You are the assignee for the bug, or are watching the assignee. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
svn commit: r156135 - in jakarta/commons/sandbox/benchmark/trunk: src/java/org/apache/commons/benchmark/Benchmark.java src/java/org/apache/commons/benchmark/BenchmarkTracker.java xdocs/ xdocs/index.xml xdocs/navigation.xml
Author: burton Date: Thu Mar 3 22:04:17 2005 New Revision: 156135 URL: http://svn.apache.org/viewcvs?view=revrev=156135 Log: benchmark xdocs Added: jakarta/commons/sandbox/benchmark/trunk/xdocs/ jakarta/commons/sandbox/benchmark/trunk/xdocs/index.xml jakarta/commons/sandbox/benchmark/trunk/xdocs/navigation.xml Modified: jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java Modified: jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java?view=diffr1=156134r2=156135 == --- jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java (original) +++ jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/Benchmark.java Thu Mar 3 22:04:17 2005 @@ -134,16 +134,18 @@ /** * The total number of start()ed benchmarks since in the last rollover. + * @deprecated */ public long getTotalStarted() { -return tracker1.totalStarted; +return tracker1.lastStarted; } /** * The total number of complete()ed benchmarks since in the last rollover. + * @deprecated */ public long getTotalCompleted() { -return tracker1.totalCompleted; +return tracker1.lastCompleted; } /** @@ -153,6 +155,18 @@ */ public BenchmarkTracker getTracker() { return getTracker( INTERVAL_1 ); +} + +public BenchmarkTracker getTracker1() { +return tracker1.resetWhenNecessary(); +} + +public BenchmarkTracker getTracker5() { +return tracker5.resetWhenNecessary(); +} + +public BenchmarkTracker getTracker15() { +return tracker15.resetWhenNecessary(); } /** Modified: jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java?view=diffr1=156134r2=156135 == --- jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java (original) +++ jakarta/commons/sandbox/benchmark/trunk/src/java/org/apache/commons/benchmark/BenchmarkTracker.java Thu Mar 3 22:04:17 2005 @@ -19,8 +19,11 @@ import java.util.*; /** - * p - * Handles physically tracking each benchmark and handling rollover. + * p Handles physically tracking each benchmark and handling rollover. Note + * that this class is MUTABLE so if you're working with it and additional + * threads are calling start/complete the values will change. This is normally + * fine but if you're trying to perform some type of benchmark analsis then you + * shouldn't hold on to the tracker long. * * @author a href=mailto:[EMAIL PROTECTED]Kevin Burton/a * @version $Id: Benchmark.java,v 1.3 2005/02/16 02:28:09 burton Exp $ @@ -49,25 +52,25 @@ /** * The current number of started benchmarks. This can be analyzed at - * runtime but its recommended that you use totalCompleted, totalStarted + * runtime but its recommended that you use lastCompleted, lastStarted */ public long started = 0; /** * The current number of completed benchmarks. This can be analyzed at - * runtime but its recommended that you use totalCompleted, totalStarted + * runtime but its recommended that you use lastCompleted, lastStarted */ public long completed = 0; /** * Value getTotalStarted */ -public long totalStarted = 0; +public long lastStarted = 0; /** * Value getTotalCompleted */ -public long totalCompleted = 0; +public long lastCompleted = 0; /** * @@ -81,8 +84,8 @@ BenchmarkTracker reset( long now ) { //need to perform a swap and save the current benchmark. -totalStarted = started; -totalCompleted = completed; +lastStarted = started; +lastCompleted = completed; //reset the benchmark timestamp = now; @@ -146,16 +149,26 @@ /** * The total number of start()ed benchmarks since in the last rollover. + * @deprecated */ public long getTotalStarted() { -return totalStarted; +return lastStarted; } /** * The total number of complete()ed benchmarks since in the last rollover. + * @deprecated */ public long getTotalCompleted() { -return totalCompleted; +return lastCompleted; +} + +public long getLastCompleted() { +
svn commit: r156138 - in jakarta/commons/sandbox/benchmark/trunk: project.xml xdocs/index.xml
Author: burton Date: Thu Mar 3 22:44:31 2005 New Revision: 156138 URL: http://svn.apache.org/viewcvs?view=revrev=156138 Log: more dox Modified: jakarta/commons/sandbox/benchmark/trunk/project.xml jakarta/commons/sandbox/benchmark/trunk/xdocs/index.xml Modified: jakarta/commons/sandbox/benchmark/trunk/project.xml URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/benchmark/trunk/project.xml?view=diffr1=156137r2=156138 == --- jakarta/commons/sandbox/benchmark/trunk/project.xml (original) +++ jakarta/commons/sandbox/benchmark/trunk/project.xml Thu Mar 3 22:44:31 2005 @@ -1,8 +1,6 @@ ?xml version=1.0? project -extend../commons-build/sandbox-project.xml/extend - nameCommons Benchmark/name idcommons-benchmark/id @@ -20,7 +18,19 @@ currentVersion0.0.2/currentVersion packageorg.apache.commons.benchmark/package - + +organization +nameApache Software Foundation/name +urlhttp://jakarta.apache.org//url +logohttp://jakarta.apache.org/images/jakarta-logo.gif/logo +/organization + +siteAddressjakarta.apache.org/siteAddress + siteDirectory/www/jakarta.apache.org/commons/sandbox/benchmark/siteDirectory +distributionDirectory +/www/jakarta.apache.org/builds/jakarta-commons/sandbox/benchmark +/distributionDirectory + versions /versions Modified: jakarta/commons/sandbox/benchmark/trunk/xdocs/index.xml URL: http://svn.apache.org/viewcvs/jakarta/commons/sandbox/benchmark/trunk/xdocs/index.xml?view=diffr1=156137r2=156138 == --- jakarta/commons/sandbox/benchmark/trunk/xdocs/index.xml (original) +++ jakarta/commons/sandbox/benchmark/trunk/xdocs/index.xml Thu Mar 3 22:44:31 2005 @@ -48,22 +48,47 @@ try { -benchmark.start(); +benchmark.start(); -//do something expensive +//do something expensive } finally { -benchmark.complete(); +benchmark.complete(); } - + /source p -The method overhead is very light. One a modern machine you can -perform about 1M benchmarks per second. For code thats only -called a few thousand times you won't notice any performance -overhead. + The method overhead is very light. One a modern machine you can + perform about 1M benchmarks per second. For code thats only + called a few thousand times you won't notice any performance + overhead. /p + +/section + +section name=Goals + + p +Java (and UNIX) has for a long time lacked the equivalent (for +the most part) of Windows perfmon. While perfmon was by no +means perfect the goals were admirable. Developers could export +simple statistics from their application and perfmon could +introspect the values and graph them. + /p + + p +With commons benchmark we can provide similar functionality by +allowing developers to export statistics and then tool +developers can write frontends to monitor application +performance. + /p + + p +Infrasturre code such as rrdtool, ganglia, and jrobin, provide +the foundation to view the data and commons benchmarks provides +a way to get at the data. + /p /section - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
DO NOT REPLY [Bug 18942] - [beanutils] Add t/f to BooleanConverter
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG· RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://issues.apache.org/bugzilla/show_bug.cgi?id=18942. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND· INSERTED IN THE BUG DATABASE. http://issues.apache.org/bugzilla/show_bug.cgi?id=18942 --- Additional Comments From [EMAIL PROTECTED] 2005-03-04 08:31 --- A thought on thread-safety and synchronization: I don't know how costly synchronization is in newer JVMs, but I know there is a cost. Considering how extremely frequent a BooleanConverter (or any Converter) might be used in an enterprise application, I'd say synchronization should be avoided as far as possible. IMHO this would be a great place to use the Commons Collection FastHashMap. (Is that depencency already present?) -- Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email --- You are receiving this mail because: --- You are the assignee for the bug, or are watching the assignee. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
DO NOT REPLY [Bug 18942] - [beanutils] Add t/f to BooleanConverter
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG· RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://issues.apache.org/bugzilla/show_bug.cgi?id=18942. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND· INSERTED IN THE BUG DATABASE. http://issues.apache.org/bugzilla/show_bug.cgi?id=18942 --- Additional Comments From [EMAIL PROTECTED] 2005-03-04 08:34 --- Simon writes: Here's a complete implementation for a french boolean converter: ... ... ... Assume I want the currently supported values (true/yes/y/1/on) PLUS t. That would multiply the effort of a complete implementation. -- Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email --- You are receiving this mail because: --- You are the assignee for the bug, or are watching the assignee. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]