Re: [lang] StringUtils.sliceFirstRemainder behavior
On Fri, 25 Jul 2003 [EMAIL PROTECTED] wrote: from:Phil Steitz [EMAIL PROTECTED] I agree as well that the subtring names are much better, but what is the policy on changing the names of methods that have been introduced between releases? I would hate to see chomp, slice and substring - named stuff all released with two out of three deprecated. Code inbetween releases doesn't count. If you use CVS HEAD its your lookout. I'll change it tonight. +1. Might be amusing if we get some Struts complaints :) Always surprises me that they run against cvs tag's of our HEAD. Hen - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
cvs commit: jakarta-commons/httpclient/src/java/org/apache/commons/httpclient/methods EntityEnclosingMethod.java MultipartPostMethod.java
olegk 2003/07/25 11:29:32 Modified:httpclient/src/java/org/apache/commons/httpclient ConnectMethod.java HttpMethodBase.java httpclient/src/java/org/apache/commons/httpclient/methods EntityEnclosingMethod.java MultipartPostMethod.java Log: Bug fix #21880 (Content-Length Transfer-Encoding request headers should be handled by entity enclosing methods) Contributed by Oleg Kalnichevski Reviewed by Michael Becke Revision ChangesPath 1.20 +4 -22 jakarta-commons/httpclient/src/java/org/apache/commons/httpclient/ConnectMethod.java Index: ConnectMethod.java === RCS file: /home/cvs/jakarta-commons/httpclient/src/java/org/apache/commons/httpclient/ConnectMethod.java,v retrieving revision 1.19 retrieving revision 1.20 diff -u -r1.19 -r1.20 --- ConnectMethod.java13 Jul 2003 21:29:05 - 1.19 +++ ConnectMethod.java25 Jul 2003 18:29:31 - 1.20 @@ -123,24 +123,6 @@ /** * This method does nothing. ttCONNECT/tt request is not supposed - * to contain ttContent-Length/tt request header. - * - * @param state current state of http requests - * @param conn the connection to use for I/O - * - * @throws IOException when errors occur reading or writing to/from the - * connection - * @throws HttpException when a recoverable error occurs - * - * @see HttpMethodBase#addContentLengthRequestHeader(HttpState, HttpConnection) - */ -protected void addContentLengthRequestHeader(HttpState state, HttpConnection conn) -throws IOException, HttpException { -// Do nothing. Not applicable to CONNECT method -} - -/** - * This method does nothing. ttCONNECT/tt request is not supposed * to contain ttCookie/tt request header. * * @param state current state of http requests 1.173 +6 -70 jakarta-commons/httpclient/src/java/org/apache/commons/httpclient/HttpMethodBase.java Index: HttpMethodBase.java === RCS file: /home/cvs/jakarta-commons/httpclient/src/java/org/apache/commons/httpclient/HttpMethodBase.java,v retrieving revision 1.172 retrieving revision 1.173 diff -u -r1.172 -r1.173 --- HttpMethodBase.java 22 Jul 2003 18:17:48 - 1.172 +++ HttpMethodBase.java 25 Jul 2003 18:29:31 - 1.173 @@ -94,17 +94,6 @@ * /ul * * p - * When a method's request may contain a body, subclasses will typically want - * to override: - * ul - * li[EMAIL PROTECTED] #getRequestContentLength} to indicate the length (in bytes) - * of that body/li - * li[EMAIL PROTECTED] #writeRequestBody writeRequestBody(HttpState,HttpConnection)} - * to write the body/li - * /ul - * /p - * - * p * When a method requires additional request headers, subclasses will typically * want to override: * ul @@ -1328,25 +1317,6 @@ } /** - * Return the length (in bytes) of my request body, suitable for use in a - * ttContent-Length/tt header. - * - * p - * Return tt-1/tt when the content-length is unknown. - * /p - * - * p - * This implementation returns tt0/tt, indicating that the request has - * no body. - * /p - * - * @return tt0/tt, indicating that the request has no body. - */ -protected long getRequestContentLength() { -return 0; -} - -/** * Adds an ttAuthorization/tt request if needed, as long as no * ttAuthorization/tt request header already exists. * @@ -1382,39 +1352,6 @@ } /** - * Adds a ttContent-Length/tt or ttTransfer-Encoding: Chunked/tt - * request header, as long as no ttContent-Length/tt request header - * already exists. - * - * TODO: Revise this method as it is potentially error-prone. - * 'Transfer-encoding: chunked' header should not be set here - * as some sub classes may not support chunk-encoding. - * - * @param state current state of http requests - * @param conn the connection to use for I/O - * - * @throws IOException when errors occur reading or writing to/from the - * connection - * @throws HttpException when a recoverable error occurs - */ -protected void addContentLengthRequestHeader(HttpState state, - HttpConnection conn) -throws IOException, HttpException { -LOG.trace(enter HttpMethodBase.addContentLengthRequestHeader( - + HttpState, HttpConnection)); - -// add content length or chunking -long len =
Re: [JELLY][PATCH] Focus and Key Listeners added
On Wednesday, July 23, 2003, at 05:19 PM, Sean W. Ferguson wrote: This is my first ever attempt at a patch. If I am doing wrong, please advise. The purpose of this patch is to include new functionality in the jelly swing tag library. I added a FocusListenerTag and a KeyListenerTag and modified ComponentTag and SwingTagLibrary. In my zip are these four files plus the patchfile.txt Can you create an issue in our issuetracker, http://jira.codehaus.org/secure/BrowseProject.jspa?id=10012 just to make sure this doesn't get lost in the shuffle? thanks! -pete - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [JELLY][PATCH] Focus and Key Listeners added
Created, thanks! Peter Royal wrote: On Wednesday, July 23, 2003, at 05:19 PM, Sean W. Ferguson wrote: This is my first ever attempt at a patch. If I am doing wrong, please advise. The purpose of this patch is to include new functionality in the jelly swing tag library. I added a FocusListenerTag and a KeyListenerTag and modified ComponentTag and SwingTagLibrary. In my zip are these four files plus the patchfile.txt Can you create an issue in our issuetracker, http://jira.codehaus.org/secure/BrowseProject.jspa?id=10012 just to make sure this doesn't get lost in the shuffle? thanks! -pete - 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]
[jira] Updated: (JELLY-65) Key and Focus Listeners added
The following issue has been updated: Updater: Sean Ferguson (mailto:[EMAIL PROTECTED]) Date: Fri, 25 Jul 2003 3:22 PM Comment: Includes the patch and new classes Changes: Attachment changed to patch.zip - For a full history of the issue, see: http://jira.codehaus.org/secure/ViewIssue.jspa?key=JELLY-65page=history - View the issue: http://jira.codehaus.org/secure/ViewIssue.jspa?key=JELLY-65 Here is an overview of the issue: - Key: JELLY-65 Summary: Key and Focus Listeners added Type: New Feature Status: Unassigned Priority: Major Time Spent: Unknown Remaining: 0 minutes Project: jelly Components: taglib.swing Assignee: Reporter: Sean Ferguson Created: Fri, 25 Jul 2003 3:21 PM Updated: Fri, 25 Jul 2003 3:22 PM Environment: jelly Description: The purpose of this patch is to include new functionality in the jelly swing tag library. I created a FocusListenerTag and a KeyListenerTag and modified ComponentTag and SwingTagLibrary. - JIRA INFORMATION: This message is automatically generated by JIRA. If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa If you want more information on JIRA, or have a bug to report see: http://www.atlassian.com/software/jira - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
cvs commit: jakarta-commons/lang/src/java/org/apache/commons/lang StringUtils.java
scolebourne2003/07/25 15:22:31 Modified:lang/src/test/org/apache/commons/lang StringUtilsTest.java StringUtilsSubstringTest.java lang/src/java/org/apache/commons/lang StringUtils.java Log: Rename slice functions to substringAfter/substringBefore Revision ChangesPath 1.39 +1 -104 jakarta-commons/lang/src/test/org/apache/commons/lang/StringUtilsTest.java Index: StringUtilsTest.java === RCS file: /home/cvs/jakarta-commons/lang/src/test/org/apache/commons/lang/StringUtilsTest.java,v retrieving revision 1.38 retrieving revision 1.39 diff -u -r1.38 -r1.39 --- StringUtilsTest.java 25 Jul 2003 00:50:00 - 1.38 +++ StringUtilsTest.java 25 Jul 2003 22:22:30 - 1.39 @@ -573,109 +573,6 @@ } } -public void testSliceFunctions() { - -String[][] sliceCases = { -{foo\n, foo}, -{foo\nbar, foo}, -{foo\nbar\n, foo\nbar}, -{foo\nbar\nbaz, foo\nbar}, -{null, null}, -{, }, -{\n, }, -{abc \n, abc }, -{abc\r\n, abc\r}, -{foo, foo}, -}; -for (int i = 0; i sliceCases.length; i++) { -String original = sliceCases[i][0]; -String expectedResult = sliceCases[i][1]; -assertEquals(slice(String) failed, -expectedResult, StringUtils.slice(original)); -} -} - -public void testSlice_StringString() { -assertEquals(fooXXbar, StringUtils.slice(fooXXbarXXbaz, XX)); - -assertEquals(null, StringUtils.slice(null, null)); -assertEquals(null, StringUtils.slice(null, )); -assertEquals(null, StringUtils.slice(null, XX)); -assertEquals(, StringUtils.slice(, null)); -assertEquals(, StringUtils.slice(, )); -assertEquals(, StringUtils.slice(, XX)); - -assertEquals(foo, StringUtils.slice(foo, null)); -assertEquals(foo, StringUtils.slice(foo, b)); -assertEquals(fo, StringUtils.slice(foo, o)); -assertEquals(abc\r\n, StringUtils.slice(abc\r\n, d)); -assertEquals(abc, StringUtils.slice(abcdabc, d)); -assertEquals(abcdabc, StringUtils.slice(abcdabcd, d)); -assertEquals(a, StringUtils.slice(abc, b)); -assertEquals(abc , StringUtils.slice(abc \n, \n)); -assertEquals(a, StringUtils.slice(a, null)); -assertEquals(a, StringUtils.slice(a, )); -assertEquals(, StringUtils.slice(a, a)); -} - -public void testSliceRemainder_StringString() { -assertEquals(baz, StringUtils.sliceRemainder(fooXXbarXXbaz, XX)); - -assertEquals(null, StringUtils.sliceRemainder(null, null)); -assertEquals(null, StringUtils.sliceRemainder(null, )); -assertEquals(null, StringUtils.sliceRemainder(null, XX)); -assertEquals(, StringUtils.sliceRemainder(, null)); -assertEquals(, StringUtils.sliceRemainder(, )); -assertEquals(, StringUtils.sliceRemainder(, a)); - -assertEquals(, StringUtils.sliceRemainder(foo, null)); -assertEquals(, StringUtils.sliceRemainder(foo, b)); -assertEquals(t, StringUtils.sliceRemainder(foot, o)); -assertEquals(bc, StringUtils.sliceRemainder(abc, a)); -assertEquals(a, StringUtils.sliceRemainder(abcba, b)); -assertEquals(, StringUtils.sliceRemainder(abc, c)); -assertEquals(, StringUtils.sliceRemainder(, d)); -assertEquals(, StringUtils.sliceRemainder(abc, )); -} - -public void testSliceFirst_StringString() { -assertEquals(foo, StringUtils.sliceFirst(fooXXbarXXbaz, XX)); - -assertEquals(null, StringUtils.sliceFirst(null, null)); -assertEquals(null, StringUtils.sliceFirst(null, )); -assertEquals(null, StringUtils.sliceFirst(null, XX)); -assertEquals(, StringUtils.sliceFirst(, null)); -assertEquals(, StringUtils.sliceFirst(, )); -assertEquals(, StringUtils.sliceFirst(, XX)); - -assertEquals(foo, StringUtils.sliceFirst(foo, null)); -assertEquals(foo, StringUtils.sliceFirst(foo, b)); -assertEquals(f, StringUtils.sliceFirst(foot, o)); -assertEquals(, StringUtils.sliceFirst(abc, a)); -assertEquals(a, StringUtils.sliceFirst(abcba, b)); -assertEquals(ab, StringUtils.sliceFirst(abc, c)); -assertEquals(, StringUtils.sliceFirst(abc, )); -} - -public void testSliceFirstRemainder_StringString() { -assertEquals(barXXbaz, StringUtils.sliceFirstRemainder(fooXXbarXXbaz, XX)); - -assertEquals(null, StringUtils.sliceFirstRemainder(null, null)); -
cvs commit: jakarta-commons/lang/src/test/org/apache/commons/lang ObjectUtilsTest.java
scolebourne2003/07/25 15:37:59 Modified:lang/src/java/org/apache/commons/lang ObjectUtils.java lang/src/test/org/apache/commons/lang ObjectUtilsTest.java Log: Javadoc and tests for ObjectUtils Revision ChangesPath 1.14 +39 -6 jakarta-commons/lang/src/java/org/apache/commons/lang/ObjectUtils.java Index: ObjectUtils.java === RCS file: /home/cvs/jakarta-commons/lang/src/java/org/apache/commons/lang/ObjectUtils.java,v retrieving revision 1.13 retrieving revision 1.14 diff -u -r1.13 -r1.14 --- ObjectUtils.java 20 Jul 2003 15:41:52 - 1.13 +++ ObjectUtils.java 25 Jul 2003 22:37:58 - 1.14 @@ -105,6 +105,14 @@ /** * pReturns a default value if the object passed is * codenull/code./p + * + * pre + * ObjectUtils.defaultIfNull(null, null) = null + * ObjectUtils.defaultIfNull(null, )= + * ObjectUtils.defaultIfNull(null, zz) = zz + * ObjectUtils.defaultIfNull(abc, *)= abc + * ObjectUtils.defaultIfNull(Boolean.TRUE, *) = Boolean.TRUE + * /pre * * @param object the codeObject/code to test, may be codenull/code * @param defaultValue the default value to return, may be codenull/code @@ -118,6 +126,17 @@ * pCompares two objects for equality, where either one or both * objects may be codenull/code./p * + * pre + * ObjectUtils.equals(null, null) = true + * ObjectUtils.equals(null, )= false + * ObjectUtils.equals(, null)= false + * ObjectUtils.equals(, ) = true + * ObjectUtils.equals(Boolean.TRUE, null) = false + * ObjectUtils.equals(Boolean.TRUE, true)= false + * ObjectUtils.equals(Boolean.TRUE, Boolean.TRUE) = true + * ObjectUtils.equals(Boolean.TRUE, Boolean.FALSE) = false + * /pre + * * @param object1 the first object, may be codenull/code * @param object2 the second object, may be codenull/code * @return codetrue/code if the values of both objects are the same @@ -138,6 +157,12 @@ * if a class did not override toString itself. codenull/code * will return codenull/code./p * + * pre + * ObjectUtils.identityToString(null) = null + * ObjectUtils.identityToString() = [EMAIL PROTECTED] + * ObjectUtils.identityToString(Boolean.TRUE) = [EMAIL PROTECTED] + * /pre + * * @param object the object to create a toString for, may be * codenull/code * @return the default toString text, or codenull/code if @@ -147,7 +172,7 @@ if (object == null) { return null; } -return appendIdentityToString(new StringBuffer(), object).toString(); +return appendIdentityToString(null, object).toString(); } /** @@ -155,16 +180,24 @@ * if a class did not override toString itself. codenull/code * will return codenull/code./p * - * @param buffer the buffer to append to, may not be - * codenull/code - * @param object the object to create a toString for, may be - * codenull/code + * pre + * ObjectUtils.appendIdentityToString(*, null)= null + * ObjectUtils.appendIdentityToString(null, ) = [EMAIL PROTECTED] + * ObjectUtils.appendIdentityToString(null, Boolean.TRUE) = [EMAIL PROTECTED] + * ObjectUtils.appendIdentityToString(buf, Boolean.TRUE) = buf.append([EMAIL PROTECTED]) + * /pre + * + * @param buffer the buffer to append to, may be codenull/code + * @param object the object to create a toString for, may be codenull/code * @return the default toString text, or codenull/code if * codenull/code passed in */ public static StringBuffer appendIdentityToString(StringBuffer buffer, Object object) { if (object == null) { return null; +} +if (buffer == null) { +buffer = new StringBuffer(); } return buffer .append(object.getClass().getName()) 1.7 +13 -6 jakarta-commons/lang/src/test/org/apache/commons/lang/ObjectUtilsTest.java Index: ObjectUtilsTest.java === RCS file: /home/cvs/jakarta-commons/lang/src/test/org/apache/commons/lang/ObjectUtilsTest.java,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- ObjectUtilsTest.java 20 Jul 2003 15:41:52 - 1.6 +++ ObjectUtilsTest.java 25 Jul 2003 22:37:59 - 1.7 @@ -111,6 +111,7 @@ } public void testIdentityToString() { +
cvs commit: jakarta-commons/codec/src/java/org/apache/commons/codec/binary Base64.java
ggregory2003/07/25 15:40:36 Modified:codec/src/java/org/apache/commons/codec/binary Base64.java Log: Severity Description ResourceIn Folder Location Creation Time Unnecessary cast to type byte[] for expression of type byte[] Base64.java Apache Jakarta Commons/codec/src/java/org/apache/commons/codec/binary line 275 July 23, 2003 11:22:45 AM Revision ChangesPath 1.5 +4 -4 jakarta-commons/codec/src/java/org/apache/commons/codec/binary/Base64.java Index: Base64.java === RCS file: /home/cvs/jakarta-commons/codec/src/java/org/apache/commons/codec/binary/Base64.java,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- Base64.java 29 May 2003 23:03:28 - 1.4 +++ Base64.java 25 Jul 2003 22:40:36 - 1.5 @@ -272,7 +272,7 @@ */ public byte[] decode(byte[] pArray) throws DecoderException { byte[] result; -result = decodeBase64((byte[]) pArray); +result = decodeBase64(pArray); return (result); } - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
cvs commit: jakarta-commons/codec/src/java/org/apache/commons/codec/net URLCodec.java
ggregory2003/07/25 15:42:46 Modified:codec/src/java/org/apache/commons/codec/net URLCodec.java Log: Severity Description ResourceIn Folder Location Creation Time Unnecessary cast to type int for expression of type char. It is already compatible with the argument type int URLCodec.java Apache Jakarta Commons/codec/src/java/org/apache/commons/codec/net line 165July 23, 2003 11:22:45 AM Unnecessary cast to type int for expression of type char. It is already compatible with the argument type int URLCodec.java Apache Jakarta Commons/codec/src/java/org/apache/commons/codec/net line 166July 23, 2003 11:22:45 AM Revision ChangesPath 1.2 +6 -5 jakarta-commons/codec/src/java/org/apache/commons/codec/net/URLCodec.java Index: URLCodec.java === RCS file: /home/cvs/jakarta-commons/codec/src/java/org/apache/commons/codec/net/URLCodec.java,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- URLCodec.java 11 Jul 2003 16:53:28 - 1.1 +++ URLCodec.java 25 Jul 2003 22:42:46 - 1.2 @@ -87,6 +87,7 @@ * /p * * @author a href=mailto:[EMAIL PROTECTED]Oleg Kalnichevski/a + * @version $Id$ */ public class URLCodec @@ -162,8 +163,8 @@ Character.forDigit((b 4) 0xF, 16)); char hex2 = Character.toUpperCase( Character.forDigit(b 0xF, 16)); -buffer.write((int)hex1); -buffer.write((int)hex2); +buffer.write(hex1); +buffer.write(hex2); } } return buffer.toByteArray(); - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
cvs commit: jakarta-commons/codec/src/java/org/apache/commons/codec/base64 Base64.java
ggregory2003/07/25 15:48:12 Modified:codec/src/java/org/apache/commons/codec EncoderException.java BinaryDecoder.java StringEncoderComparator.java BinaryEncoder.java StringEncoder.java Encoder.java StringDecoder.java DecoderException.java Decoder.java codec/src/java/org/apache/commons/codec/language RefinedSoundex.java Metaphone.java DoubleMetaphone.java Soundex.java codec/src/java/org/apache/commons/codec/binary Base64.java Hex.java codec/src/java/org/apache/commons/codec/base64 Base64.java Log: Consistent use of @version $Id$ as the last tag in a type's Javadoc comment. Revision ChangesPath 1.2 +75 -75 jakarta-commons/codec/src/java/org/apache/commons/codec/EncoderException.java Index: EncoderException.java === RCS file: /home/cvs/jakarta-commons/codec/src/java/org/apache/commons/codec/EncoderException.java,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- EncoderException.java 25 Apr 2003 17:50:56 - 1.1 +++ EncoderException.java 25 Jul 2003 22:48:11 - 1.2 @@ -1,75 +1,75 @@ -/* - * The Apache Software License, Version 1.1 - * - * Copyright (c) 2003 The Apache Software Foundation. All rights - * reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * - * 1. Redistributions of source code must retain the above copyright - *notice, this list of conditions and the following disclaimer. - * - * 2. Redistributions in binary form must reproduce the above copyright - *notice, this list of conditions and the following disclaimer in - *the documentation and/or other materials provided with the - *distribution. - * - * 3. The end-user documentation included with the redistribution, - *if any, must include the following acknowledgment: - * This product includes software developed by the - *Apache Software Foundation (http://www.apache.org/). - *Alternately, this acknowledgment may appear in the software itself, - *if and wherever such third-party acknowledgments normally appear. - * - * 4. The names Apache and Apache Software Foundation and - *Apache Commons must not be used to endorse or promote products - *derived from this software without prior written permission. For - *written permission, please contact [EMAIL PROTECTED] - * - * 5. Products derived from this software may not be called Apache, - *Apache Commons, nor may Apache appear in their name, without - *prior written permission of the Apache Software Foundation. - * - * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED - * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES - * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE - * DISCLAIMED. IN NO EVENT SHALL THE APACHE SOFTWARE FOUNDATION OR - * ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, - * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT - * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF - * USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND - * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, - * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT - * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * - * - * This software consists of voluntary contributions made by many - * individuals on behalf of the Apache Software Foundation. For more - * information on the Apache Software Foundation, please see - * http://www.apache.org/. - */ -package org.apache.commons.codec; - -/** - * An EncoderException is thrown when there is a - * failure condition during the encoding process. - * - * @author a href=[EMAIL PROTECTED]Tim O'Brien/a - * @version $Revision$ $Date$ - */ -public class EncoderException extends Exception { - -/** - * Create a new instance of this exception with - * an informative message. - * - * @param pMessage a human intelligible message - */ -public EncoderException(String pMessage) { -super(pMessage); -} -} - +/* + * The Apache Software License, Version 1.1 + * + * Copyright (c) 2003 The Apache Software Foundation. All rights + * reserved. + *
Re: [lang] StringUtils.sliceFirstRemainder behavior
Change made. Anything else in StringUtils todo? Stephen - Original Message - From: Henri Yandell [EMAIL PROTECTED] To: Jakarta Commons Developers List [EMAIL PROTECTED] Sent: Friday, July 25, 2003 6:39 PM Subject: Re: [lang] StringUtils.sliceFirstRemainder behavior On Fri, 25 Jul 2003 [EMAIL PROTECTED] wrote: from:Phil Steitz [EMAIL PROTECTED] I agree as well that the subtring names are much better, but what is the policy on changing the names of methods that have been introduced between releases? I would hate to see chomp, slice and substring - named stuff all released with two out of three deprecated. Code inbetween releases doesn't count. If you use CVS HEAD its your lookout. I'll change it tonight. +1. Might be amusing if we get some Struts complaints :) Always surprises me that they run against cvs tag's of our HEAD. Hen - 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]
cvs commit: jakarta-commons/codec/src/java/org/apache/commons/codec/language DoubleMetaphone.java
ggregory2003/07/25 15:52:55 Modified:codec/src/java/org/apache/commons/codec/language DoubleMetaphone.java Log: Javadoc. Revision ChangesPath 1.6 +7 -6 jakarta-commons/codec/src/java/org/apache/commons/codec/language/DoubleMetaphone.java Index: DoubleMetaphone.java === RCS file: /home/cvs/jakarta-commons/codec/src/java/org/apache/commons/codec/language/DoubleMetaphone.java,v retrieving revision 1.5 retrieving revision 1.6 diff -u -r1.5 -r1.6 --- DoubleMetaphone.java 25 Jul 2003 22:48:11 - 1.5 +++ DoubleMetaphone.java 25 Jul 2003 22:52:55 - 1.6 @@ -62,12 +62,13 @@ /** * DoubleMetaphone Java Implementation * From the algorithm by Lawrence Philips - * - * Original Article a + * ul + * liOriginal Article: a * href=http://www.cuj.com/documents/s=8038/cuj0006philips/; - * http://www.cuj.com/documents/s=8038/cuj0006philips//a - * Original Source Code: a href=ftp://ftp.cuj.com/pub/2000/1806/philips.zip; - * ftp://ftp.cuj.com/pub/2000/1806/philips.zip/a + * http://www.cuj.com/documents/s=8038/cuj0006philips//a/li + * liOriginal Source Code: a href=ftp://ftp.cuj.com/pub/2000/1806/philips.zip; + * ftp://ftp.cuj.com/pub/2000/1806/philips.zip/a/li + * /ul * * @author a href=mailto:[EMAIL PROTECTED]Benjamin Walstrum/a * @version $Id$ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
cvs commit: jakarta-commons/lang/src/java/org/apache/commons/lang/time FastDateFormat.java
scolebourne2003/07/25 15:53:49 Modified:lang/src/java/org/apache/commons/lang/time FastDateFormat.java Log: Remove unneeded String constructor as found by findBugs Revision ChangesPath 1.12 +2 -2 jakarta-commons/lang/src/java/org/apache/commons/lang/time/FastDateFormat.java Index: FastDateFormat.java === RCS file: /home/cvs/jakarta-commons/lang/src/java/org/apache/commons/lang/time/FastDateFormat.java,v retrieving revision 1.11 retrieving revision 1.12 diff -u -r1.11 -r1.12 --- FastDateFormat.java 22 Jul 2003 00:09:14 - 1.11 +++ FastDateFormat.java 25 Jul 2003 22:53:49 - 1.12 @@ -572,7 +572,7 @@ if (sub.length() == 1) { rule = new CharacterLiteral(sub.charAt(0)); } else { -rule = new StringLiteral(new String(sub)); +rule = new StringLiteral(sub); } break; default: - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
cvs commit: jakarta-commons/codec/src/java/org/apache/commons/codec/language DoubleMetaphone.java
ggregory2003/07/25 15:53:54 Modified:codec/src/java/org/apache/commons/codec/language DoubleMetaphone.java Log: Allow ivar to be accessed from a subclass without warnings: Severity Description ResourceIn Folder Location Creation Time Read access to enclosing field DoubleMetaphone.maxCodeLen is emulated by a synthetic accessor method. Increasing its visibility will improve your performance DoubleMetaphone.javaApache Jakarta Commons/codec/src/java/org/apache/commons/codec/language line 1118 July 25, 2003 3:53:04 PM Read access to enclosing field DoubleMetaphone.maxCodeLen is emulated by a synthetic accessor method. Increasing its visibility will improve your performance DoubleMetaphone.javaApache Jakarta Commons/codec/src/java/org/apache/commons/codec/language line 1119 July 25, 2003 3:53:04 PM Revision ChangesPath 1.7 +2 -2 jakarta-commons/codec/src/java/org/apache/commons/codec/language/DoubleMetaphone.java Index: DoubleMetaphone.java === RCS file: /home/cvs/jakarta-commons/codec/src/java/org/apache/commons/codec/language/DoubleMetaphone.java,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- DoubleMetaphone.java 25 Jul 2003 22:52:55 - 1.6 +++ DoubleMetaphone.java 25 Jul 2003 22:53:53 - 1.7 @@ -95,7 +95,7 @@ /** * Maximum length of an encoding, default is 4 */ -private int maxCodeLen = 4; +protected int maxCodeLen = 4; /** * Creates an instance of this DoubleMetaphone encoder - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
cvs commit: jakarta-commons/codec/src/java/org/apache/commons/codec/binary Hex.java
ggregory2003/07/25 15:56:22 Modified:codec/src/java/org/apache/commons/codec/binary Hex.java Log: Javadoc. Revision ChangesPath 1.5 +2 -2 jakarta-commons/codec/src/java/org/apache/commons/codec/binary/Hex.java Index: Hex.java === RCS file: /home/cvs/jakarta-commons/codec/src/java/org/apache/commons/codec/binary/Hex.java,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- Hex.java 25 Jul 2003 22:48:11 - 1.4 +++ Hex.java 25 Jul 2003 22:56:22 - 1.5 @@ -60,7 +60,7 @@ import org.apache.commons.codec.EncoderException; /** - * Hex encoder/decoder + * Hex encoder/decoder. * * @author a href=mailto:[EMAIL PROTECTED]Christopher O'Brien/a * @author a href=mailto:[EMAIL PROTECTED]Tim O'Brien/a - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
cvs commit: jakarta-commons/codec/src/test/org/apache/commons/codec/binary Base64Test.java
ggregory2003/07/25 15:57:35 Modified:codec/src/test/org/apache/commons/codec/binary Base64Test.java Log: Severity Description ResourceIn Folder Location Creation Time Unnecessary cast to type Object for expression of type byte[] Base64Test.java Apache Jakarta Commons/codec/src/test/org/apache/commons/codec/binary line 370July 23, 2003 11:22:45 AM Unnecessary cast to type Object for expression of type byte[] Base64Test.java Apache Jakarta Commons/codec/src/test/org/apache/commons/codec/binary line 401July 23, 2003 11:22:45 AM Unnecessary cast to type Object for expression of type Object Base64Test.java Apache Jakarta Commons/codec/src/test/org/apache/commons/codec/binary line 373July 23, 2003 11:22:45 AM Revision ChangesPath 1.4 +7 -7 jakarta-commons/codec/src/test/org/apache/commons/codec/binary/Base64Test.java Index: Base64Test.java === RCS file: /home/cvs/jakarta-commons/codec/src/test/org/apache/commons/codec/binary/Base64Test.java,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- Base64Test.java 14 May 2003 02:40:18 - 1.3 +++ Base64Test.java 25 Jul 2003 22:57:35 - 1.4 @@ -367,10 +367,10 @@ String original = Hello World!; byte[] bArray = Base64.encodeBase64( (new String(original)).getBytes() ); -Object o = (Object) bArray; +Object o = bArray; Base64 b64 = new Base64(); -Object oDecoded = (Object) b64.decode( o ); +Object oDecoded = b64.decode( o ); byte[] baDecoded = (byte[]) oDecoded; String dest = new String( baDecoded ); @@ -398,7 +398,7 @@ String original = Hello World!; byte[] origBytes = original.getBytes(); -Object origObj = (Object) origBytes; +Object origObj = origBytes; Base64 b64 = new Base64(); Object oEncoded = b64.encode( origObj ); - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
cvs commit: jakarta-commons/lang/src/java/org/apache/commons/lang/builder HashCodeBuilder.java
ggregory2003/07/25 16:03:31 Modified:lang/src/java/org/apache/commons/lang/builder HashCodeBuilder.java Log: Severity Description ResourceIn Folder Location Creation Time Unnecessary cast to type int for expression of type byte. It is already compatible with the argument type int HashCodeBuilder.javaApache Jakarta Commons/lang/src/java/org/apache/commons/lang/builderline 471July 23, 2003 11:22:36 AM Unnecessary cast to type int for expression of type char. It is already compatible with the argument type int HashCodeBuilder.javaApache Jakarta Commons/lang/src/java/org/apache/commons/lang/builderline 460July 23, 2003 11:22:36 AM Unnecessary cast to type int for expression of type short. It is already compatible with the argument type int HashCodeBuilder.javaApache Jakarta Commons/lang/src/java/org/apache/commons/lang/builderline 449July 23, 2003 11:22:36 AM Revision ChangesPath 1.17 +4 -4 jakarta-commons/lang/src/java/org/apache/commons/lang/builder/HashCodeBuilder.java Index: HashCodeBuilder.java === RCS file: /home/cvs/jakarta-commons/lang/src/java/org/apache/commons/lang/builder/HashCodeBuilder.java,v retrieving revision 1.16 retrieving revision 1.17 diff -u -r1.16 -r1.17 --- HashCodeBuilder.java 21 Jul 2003 23:30:42 - 1.16 +++ HashCodeBuilder.java 25 Jul 2003 23:03:30 - 1.17 @@ -446,7 +446,7 @@ * @return this */ public HashCodeBuilder append(short value) { -iTotal = iTotal * iConstant + (int) value; +iTotal = iTotal * iConstant + value; return this; } @@ -457,7 +457,7 @@ * @return this */ public HashCodeBuilder append(char value) { -iTotal = iTotal * iConstant + (int) value; +iTotal = iTotal * iConstant + value; return this; } @@ -468,7 +468,7 @@ * @return this */ public HashCodeBuilder append(byte value) { -iTotal = iTotal * iConstant + (int) value; +iTotal = iTotal * iConstant + value; return this; } - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
cvs commit: jakarta-commons/lang/src/java/org/apache/commons/lang/builder ToStringStyle.java
ggregory2003/07/25 16:04:24 Modified:lang/src/java/org/apache/commons/lang/builder ToStringStyle.java Log: Severity Description ResourceIn Folder Location Creation Time Unnecessary cast to type Object for expression of type Object ToStringStyle.java Apache Jakarta Commons/lang/src/java/org/apache/commons/lang/builderline 420July 23, 2003 11:22:36 AM Unnecessary cast to type Object for expression of type Object ToStringStyle.java Apache Jakarta Commons/lang/src/java/org/apache/commons/lang/builderline 422July 23, 2003 11:22:36 AM Revision ChangesPath 1.21 +3 -3 jakarta-commons/lang/src/java/org/apache/commons/lang/builder/ToStringStyle.java Index: ToStringStyle.java === RCS file: /home/cvs/jakarta-commons/lang/src/java/org/apache/commons/lang/builder/ToStringStyle.java,v retrieving revision 1.20 retrieving revision 1.21 diff -u -r1.20 -r1.21 --- ToStringStyle.java21 Jul 2003 23:30:42 - 1.20 +++ ToStringStyle.java25 Jul 2003 23:04:24 - 1.21 @@ -417,9 +417,9 @@ } else { if (detail) { -appendDetail(buffer, fieldName, (Object) value); +appendDetail(buffer, fieldName, value); } else { -appendSummary(buffer, fieldName, (Object) value); +appendSummary(buffer, fieldName, value); } } } - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
cvs commit: jakarta-commons/lang/src/java/org/apache/commons/lang/exception NestableDelegate.java
ggregory2003/07/25 16:05:22 Modified:lang/src/java/org/apache/commons/lang/exception NestableDelegate.java Log: Severity Description ResourceIn Folder Location Creation Time Unnecessary cast to type String[] for expression of type Object[]. It is already compatible with the argument type Object NestableDelegate.java Apache Jakarta Commons/lang/src/java/org/apache/commons/lang/exception line 378July 23, 2003 11:22:36 AM Revision ChangesPath 1.16 +2 -2 jakarta-commons/lang/src/java/org/apache/commons/lang/exception/NestableDelegate.java Index: NestableDelegate.java === RCS file: /home/cvs/jakarta-commons/lang/src/java/org/apache/commons/lang/exception/NestableDelegate.java,v retrieving revision 1.15 retrieving revision 1.16 diff -u -r1.15 -r1.16 --- NestableDelegate.java 20 Jul 2003 15:49:58 - 1.15 +++ NestableDelegate.java 25 Jul 2003 23:05:22 - 1.16 @@ -375,7 +375,7 @@ currList.add(\t... +trimmed+ more); stacks.set( i, - (String[])currList.toArray(new String[currList.size()]) + currList.toArray(new String[currList.size()]) ); } } - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
cvs commit: jakarta-commons/lang/src/java/org/apache/commons/lang/exception ExceptionUtils.java
scolebourne2003/07/25 16:06:59 Modified:lang/src/java/org/apache/commons/lang StringEscapeUtils.java BooleanUtils.java lang/src/java/org/apache/commons/lang/math RandomUtils.java lang/src/java/org/apache/commons/lang/exception ExceptionUtils.java Log: Change as recommended by findBugs (static variables private or final, and Boolean constructor optimisation) Revision ChangesPath 1.19 +4 -3 jakarta-commons/lang/src/java/org/apache/commons/lang/StringEscapeUtils.java Index: StringEscapeUtils.java === RCS file: /home/cvs/jakarta-commons/lang/src/java/org/apache/commons/lang/StringEscapeUtils.java,v retrieving revision 1.18 retrieving revision 1.19 diff -u -r1.18 -r1.19 --- StringEscapeUtils.java20 Jul 2003 15:49:58 - 1.18 +++ StringEscapeUtils.java25 Jul 2003 23:06:58 - 1.19 @@ -59,7 +59,8 @@ import org.apache.commons.lang.exception.NestableRuntimeException; /** - * pEscapes and unescapes codeString/codes for Java, Java Script, HTML, XML, and SQL. + * pEscapes and unescapes codeString/codes for + * Java, Java Script, HTML, XML, and SQL./p * * @author Apache Jakarta Turbine * @author GenerationJavaCore library @@ -78,7 +79,7 @@ /** * The entity set to use when escaping and unescaping HTML. */ -protected static Entities DEFAULT_ENTITIES = Entities.HTML40; +private static final Entities DEFAULT_ENTITIES = Entities.HTML40; /** * pcodeStringEscapeUtils/code instances should NOT be constructed in 1.9 +2 -2 jakarta-commons/lang/src/java/org/apache/commons/lang/BooleanUtils.java Index: BooleanUtils.java === RCS file: /home/cvs/jakarta-commons/lang/src/java/org/apache/commons/lang/BooleanUtils.java,v retrieving revision 1.8 retrieving revision 1.9 diff -u -r1.8 -r1.9 --- BooleanUtils.java 19 Jul 2003 20:17:12 - 1.8 +++ BooleanUtils.java 25 Jul 2003 23:06:58 - 1.9 @@ -659,7 +659,7 @@ * @throws IllegalArgumentException if codearray/code is empty. */ public static Boolean xor(Boolean[] array) { -return new Boolean(xor(ArrayUtils.toPrimitive(array))); +return (xor(ArrayUtils.toPrimitive(array)) ? Boolean.TRUE : Boolean.FALSE); } } 1.4 +2 -2 jakarta-commons/lang/src/java/org/apache/commons/lang/math/RandomUtils.java Index: RandomUtils.java === RCS file: /home/cvs/jakarta-commons/lang/src/java/org/apache/commons/lang/math/RandomUtils.java,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- RandomUtils.java 14 Jul 2003 22:25:05 - 1.3 +++ RandomUtils.java 25 Jul 2003 23:06:58 - 1.4 @@ -66,7 +66,7 @@ */ public final class RandomUtils { -public static Random JVM_RANDOM = new JVMRandom(); +public static final Random JVM_RANDOM = new JVMRandom(); // should be possible for JVM_RANDOM? //public static void nextBytes(byte[]) { 1.27 +2 -2 jakarta-commons/lang/src/java/org/apache/commons/lang/exception/ExceptionUtils.java Index: ExceptionUtils.java === RCS file: /home/cvs/jakarta-commons/lang/src/java/org/apache/commons/lang/exception/ExceptionUtils.java,v retrieving revision 1.26 retrieving revision 1.27 diff -u -r1.26 -r1.27 --- ExceptionUtils.java 20 Jul 2003 15:49:58 - 1.26 +++ ExceptionUtils.java 25 Jul 2003 23:06:58 - 1.27 @@ -95,7 +95,7 @@ * pThe names of methods commonly used to access a wrapped * exception./p */ -protected static String[] CAUSE_METHOD_NAMES = { +private static String[] CAUSE_METHOD_NAMES = { getCause, getNextException, getTargetException, - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [lang] Findbugs output for Lang 2.0
I've addressed these as seems sensible. Some static variables went from protected to private Some static variables went from non-final to final Stephen - Original Message - From: Henri Yandell [EMAIL PROTECTED] To: Jakarta Commons Developers List [EMAIL PROTECTED] Sent: Wednesday, July 23, 2003 9:54 PM Subject: [lang] Findbugs output for Lang 2.0 Taking current CVS I get the following as output from the Findbugs project. Lang output: http://www.flamefew.net/~hen/lang-2.0-findbugs-output.html Findbugs:http://www.cs.umd.edu/~pugh/java/bugs/ Just in case anyone's interested :) Hen - 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]
cvs commit: jakarta-commons/lang/src/java/org/apache/commons/lang RandomStringUtils.java
ggregory2003/07/25 17:26:32 Modified:lang/src/java/org/apache/commons/lang RandomStringUtils.java Log: Severity Description ResourceIn Folder Location Creation Time Unnecessary cast to type int for expression of type char RandomStringUtils.java Apache Jakarta Commons/lang/src/java/org/apache/commons/lang line 259July 23, 2003 11:22:36 AM Unnecessary cast to type int for expression of type char. It is already compatible with the argument type int RandomStringUtils.java Apache Jakarta Commons/lang/src/java/org/apache/commons/langline 258July 23, 2003 11:22:36 AM Revision ChangesPath 1.18 +3 -3 jakarta-commons/lang/src/java/org/apache/commons/lang/RandomStringUtils.java Index: RandomStringUtils.java === RCS file: /home/cvs/jakarta-commons/lang/src/java/org/apache/commons/lang/RandomStringUtils.java,v retrieving revision 1.17 retrieving revision 1.18 diff -u -r1.17 -r1.18 --- RandomStringUtils.java19 Jul 2003 20:21:08 - 1.17 +++ RandomStringUtils.java26 Jul 2003 00:26:32 - 1.18 @@ -255,8 +255,8 @@ throw new IllegalArgumentException(Requested random string length + count + is less than 0.); } if( (start == 0) (end == 0) ) { -end = (int)'z' + 1; -start = (int)' '; +end = 'z' + 1; +start = ' '; if(!letters !numbers) { start = 0; end = Integer.MAX_VALUE; - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
cvs commit: jakarta-commons/lang/src/test/org/apache/commons/lang EntitiesTest.java
ggregory2003/07/25 17:31:30 Modified:lang/src/test/org/apache/commons/lang EntitiesTest.java Log: Severity Description ResourceIn Folder Location Creation Time Unnecessary cast to type int for expression of type char. It is already compatible with the argument type int EntitiesTest.java Apache Jakarta Commons/lang/src/test/org/apache/commons/langline 130July 23, 2003 11:22:39 AM Revision ChangesPath 1.7 +3 -2 jakarta-commons/lang/src/test/org/apache/commons/lang/EntitiesTest.java Index: EntitiesTest.java === RCS file: /home/cvs/jakarta-commons/lang/src/test/org/apache/commons/lang/EntitiesTest.java,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- EntitiesTest.java 29 Jun 2003 03:04:33 - 1.6 +++ EntitiesTest.java 26 Jul 2003 00:31:29 - 1.7 @@ -63,6 +63,7 @@ * * @author of original StringUtilsTest.testEscape = ? * @author a href=mailto:[EMAIL PROTECTED]Alexander Day Chaffee/a + * @author a href=mailto:[EMAIL PROTECTED]Gary Gregory/a * @version $Id$ */ public class EntitiesTest extends TestCase @@ -127,7 +128,7 @@ public void testEntitiesXmlObject() throws Exception { assertEquals(gt, Entities.XML.entityName('')); -assertEquals((int) '', Entities.XML.entityValue(gt)); +assertEquals('', Entities.XML.entityValue(gt)); assertEquals(-1, Entities.XML.entityValue(xyzzy)); } - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
cvs commit: jakarta-commons/lang/src/java/org/apache/commons/lang Entities.java
ggregory2003/07/25 17:32:19 Modified:lang/src/java/org/apache/commons/lang Entities.java Log: Severity Description ResourceIn Folder Location Creation Time Unnecessary cast to type int for expression of type charEntities.java Apache Jakarta Commons/lang/src/java/org/apache/commons/langline 643July 23, 2003 11:22:37 AM Unnecessary cast to type int for expression of type char. It is already compatible with the argument type int Entities.java Apache Jakarta Commons/lang/src/java/org/apache/commons/langline 642July 23, 2003 11:22:37 AM Revision ChangesPath 1.11 +3 -3 jakarta-commons/lang/src/java/org/apache/commons/lang/Entities.java Index: Entities.java === RCS file: /home/cvs/jakarta-commons/lang/src/java/org/apache/commons/lang/Entities.java,v retrieving revision 1.10 retrieving revision 1.11 diff -u -r1.10 -r1.11 --- Entities.java 14 Jul 2003 22:21:11 - 1.10 +++ Entities.java 26 Jul 2003 00:32:19 - 1.11 @@ -639,8 +639,8 @@ char ch = str.charAt(i); String entityName = this.entityName(ch); if (entityName == null) { -if (((int) ch) 0x7F) { -int intValue = ((int) ch); +if (ch 0x7F) { +int intValue = ch; buf.append(#); buf.append(intValue); buf.append(';'); - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
cvs commit: jakarta-commons/lang/src/java/org/apache/commons/lang/exception ExceptionUtils.java
ggregory2003/07/25 17:43:08 Modified:lang/src/java/org/apache/commons/lang/exception ExceptionUtils.java Log: Avoid Javadoc warning with Standard Doclet version 1.4.2. Revision ChangesPath 1.28 +3 -2 jakarta-commons/lang/src/java/org/apache/commons/lang/exception/ExceptionUtils.java Index: ExceptionUtils.java === RCS file: /home/cvs/jakarta-commons/lang/src/java/org/apache/commons/lang/exception/ExceptionUtils.java,v retrieving revision 1.27 retrieving revision 1.28 diff -u -r1.27 -r1.28 --- ExceptionUtils.java 25 Jul 2003 23:06:58 - 1.27 +++ ExceptionUtils.java 26 Jul 2003 00:43:08 - 1.28 @@ -378,7 +378,8 @@ } /** - * pEquivalent to codeprintRootCauseStackTrace(t, System.err);/code/p + * pCalls codeprintRootCauseStackTraceprintRootCauseStackTrace/code./p + * Same as: preprintRootCauseStackTrace(t, System.err);/pre * * @see #printRootCauseStackTrace(Throwable,PrintWriter) */ - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
cvs commit: jakarta-commons/lang/src/java/org/apache/commons/lang ObjectUtils.java
ggregory2003/07/25 17:45:27 Modified:lang/src/java/org/apache/commons/lang ObjectUtils.java Log: Avoid Javadoc warning with Standard Doclet version 1.4.2. Revision ChangesPath 1.15 +3 -4 jakarta-commons/lang/src/java/org/apache/commons/lang/ObjectUtils.java Index: ObjectUtils.java === RCS file: /home/cvs/jakarta-commons/lang/src/java/org/apache/commons/lang/ObjectUtils.java,v retrieving revision 1.14 retrieving revision 1.15 diff -u -r1.14 -r1.15 --- ObjectUtils.java 25 Jul 2003 22:37:58 - 1.14 +++ ObjectUtils.java 26 Jul 2003 00:45:27 - 1.15 @@ -208,7 +208,7 @@ //--- /** * pGets the codetoString/code of an codeObject/code returning - * an empty string () if codenull/code input,/p + * an empty string () if codenull/code input./p * * pre * ObjectUtils.toString(null) = @@ -218,7 +218,6 @@ * /pre * * @param obj the Object to codetoString/code, may be null - * @param nullStr the String to return if codenull/code input, may be null * @return the passed in Object's toString, or nullStr if codenull/code input */ public static String toString(Object obj) { @@ -227,7 +226,7 @@ /** * pGets the codetoString/code of an codeObject/code returning - * an empty string () if codenull/code input,/p + * an empty string () if codenull/code input./p * * pre * ObjectUtils.toString(null, null) = null - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[lang] unit tests 1.3.1_08 vs 1.4.2.
I am seing something odd: under Sun 1.4.2, the unit tests run fine but under Sun 1.3.1_08, they do not. Specifically: test.lang: [echo] Running lang package tests ... [java] . [java] . [java] . [java] . [java] . [java] . [java] . [java] .F [java] ... [java] Time: 0.285 [java] There was 1 failure: [java] 1) testIndexOf_StringInt(org.apache.commons.lang.StringUtilsEqualsIndexOfTest)j unit.framework.AssertionFailedError: expected:0 but was:-1 [java] at org.apache.commons.lang.StringUtilsEqualsIndexOfTest.testIndexOf_StringInt(S tringUtilsEqualsIndexOfTest.java:158) [java] FAILURES!!! [java] Tests run: 359, Failures: 1, Errors: 0 and: test.math: [echo] Running math package tests ... [java] . [java] . [java] ..E... [java] .. [java] Time: 9.424 [java] There was 1 error: [java] 1) testCreateBigDecimal(org.apache.commons.lang.math.NumberUtilsTest)java.lang. StringIndexOutOfBoundsException: String index out of range: 0 [java] at java.lang.String.charAt(String.java:582) [java] at java.math.BigDecimal.init(BigDecimal.java:124) [java] at org.apache.commons.lang.math.NumberUtils.createBigDecimal(NumberUtils.java:4 78) [java] at org.apache.commons.lang.math.NumberUtilsTest.testCreateBigDecimal(NumberUtil sTest.java:209) [java] FAILURES!!! [java] Tests run: 149, Failures: 0, Errors: 1 Gary -Original Message- From: Stephen Colebourne [mailto:[EMAIL PROTECTED] Sent: Friday, July 25, 2003 16:12 To: Jakarta Commons Developers List Subject: Re: [lang] Findbugs output for Lang 2.0 I've addressed these as seems sensible. Some static variables went from protected to private Some static variables went from non-final to final Stephen - Original Message - From: Henri Yandell [EMAIL PROTECTED] To: Jakarta Commons Developers List [EMAIL PROTECTED] Sent: Wednesday, July 23, 2003 9:54 PM Subject: [lang] Findbugs output for Lang 2.0 Taking current CVS I get the following as output from the Findbugs project. Lang output: http://www.flamefew.net/~hen/lang-2.0-findbugs-output.html Findbugs:http://www.cs.umd.edu/~pugh/java/bugs/ Just in case anyone's interested :) Hen - 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]
cvs commit: jakarta-commons/lang/src/java/org/apache/commons/lang/math Fraction.java
ggregory2003/07/25 17:57:03 Modified:lang/src/java/org/apache/commons/lang/math Fraction.java Log: Severity Description ResourceIn Folder Location Creation Time Unnecessary cast to type int for expression of type int Fraction.java Apache Jakarta Commons/lang/src/java/org/apache/commons/lang/math line 391July 25, 2003 5:56:34 PM Revision ChangesPath 1.5 +2 -2 jakarta-commons/lang/src/java/org/apache/commons/lang/math/Fraction.java Index: Fraction.java === RCS file: /home/cvs/jakarta-commons/lang/src/java/org/apache/commons/lang/math/Fraction.java,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- Fraction.java 14 Jul 2003 22:25:05 - 1.4 +++ Fraction.java 26 Jul 2003 00:57:02 - 1.5 @@ -388,7 +388,7 @@ * @return the whole number fraction part */ public int intValue() { -return (int) numerator / denominator; +return numerator / denominator; } /** - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
cvs commit: jakarta-commons/dbcp/src/java/org/apache/commons/dbcp/jdbc2pool Jdbc2PoolDataSource.java
jmcnally2003/07/25 18:23:22 Modified:dbcp/src/java/org/apache/commons/dbcp/jdbc2pool Jdbc2PoolDataSource.java Log: code was selecting the maximum as default instead of the desired minumum. use the Math.min method to be more obvious as well as correct. Revision ChangesPath 1.13 +11 -14 jakarta-commons/dbcp/src/java/org/apache/commons/dbcp/jdbc2pool/Jdbc2PoolDataSource.java Index: Jdbc2PoolDataSource.java === RCS file: /home/cvs/jakarta-commons/dbcp/src/java/org/apache/commons/dbcp/jdbc2pool/Jdbc2PoolDataSource.java,v retrieving revision 1.12 retrieving revision 1.13 diff -u -r1.12 -r1.13 --- Jdbc2PoolDataSource.java 29 Jun 2003 12:42:16 - 1.12 +++ Jdbc2PoolDataSource.java 26 Jul 2003 01:23:21 - 1.13 @@ -166,10 +166,8 @@ private boolean defaultAutoCommit = false; private int defaultMaxActive = GenericObjectPool.DEFAULT_MAX_ACTIVE; private int defaultMaxIdle = GenericObjectPool.DEFAULT_MAX_IDLE; -private int defaultMaxWait = -(((long)Integer.MAX_VALUE) GenericObjectPool.DEFAULT_MAX_WAIT) ? -(int)(GenericObjectPool.DEFAULT_MAX_WAIT) : -Integer.MAX_VALUE; +private int defaultMaxWait = (int)Math.min((long)Integer.MAX_VALUE, +GenericObjectPool.DEFAULT_MAX_WAIT); private boolean defaultReadOnly = false; /** Description */ private String description = null; @@ -186,15 +184,14 @@ private Map perUserDefaultReadOnly = null; private boolean _testOnBorrow = GenericObjectPool.DEFAULT_TEST_ON_BORROW; private boolean _testOnReturn = GenericObjectPool.DEFAULT_TEST_ON_RETURN; -private int _timeBetweenEvictionRunsMillis = -(((long)Integer.MAX_VALUE) GenericObjectPool.DEFAULT_TIME_BETWEEN_EVICTION_RUNS_MILLIS) ? -(int)(GenericObjectPool.DEFAULT_TIME_BETWEEN_EVICTION_RUNS_MILLIS) : -Integer.MAX_VALUE;; -private int _numTestsPerEvictionRun = GenericObjectPool.DEFAULT_NUM_TESTS_PER_EVICTION_RUN; -private int _minEvictableIdleTimeMillis = -(((long)Integer.MAX_VALUE) GenericObjectPool.DEFAULT_MIN_EVICTABLE_IDLE_TIME_MILLIS) ? -(int)(GenericObjectPool.DEFAULT_MIN_EVICTABLE_IDLE_TIME_MILLIS) : -Integer.MAX_VALUE;; +private int _timeBetweenEvictionRunsMillis = (int) +Math.min((long)Integer.MAX_VALUE, + GenericObjectPool.DEFAULT_TIME_BETWEEN_EVICTION_RUNS_MILLIS); +private int _numTestsPerEvictionRun = +GenericObjectPool.DEFAULT_NUM_TESTS_PER_EVICTION_RUN; +private int _minEvictableIdleTimeMillis = (int) +Math.min((long)Integer.MAX_VALUE, + GenericObjectPool.DEFAULT_MIN_EVICTABLE_IDLE_TIME_MILLIS); private boolean _testWhileIdle = GenericObjectPool.DEFAULT_TEST_WHILE_IDLE; private String validationQuery = null; private boolean testPositionSet = false; - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
DO NOT REPLY [Bug 21758] - [lang] lang.builder classes javadoc edits (mostly typo fixes)
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://nagoya.apache.org/bugzilla/show_bug.cgi?id=21758. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE. http://nagoya.apache.org/bugzilla/show_bug.cgi?id=21758 [lang] lang.builder classes javadoc edits (mostly typo fixes) [EMAIL PROTECTED] changed: What|Removed |Added Status|NEW |RESOLVED Resolution||FIXED - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
DO NOT REPLY [Bug 21903] New: - Include filename or uri if Digester.parse(File file or String uri throws a SAXException
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://nagoya.apache.org/bugzilla/show_bug.cgi?id=21903. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE. http://nagoya.apache.org/bugzilla/show_bug.cgi?id=21903 Include filename or uri if Digester.parse(File file or String uri throws a SAXException Summary: Include filename or uri if Digester.parse(File file or String uri throws a SAXException Product: Commons Version: unspecified Platform: All OS/Version: All Status: NEW Severity: Enhancement Priority: Other Component: Digester AssignedTo: [EMAIL PROTECTED] ReportedBy: [EMAIL PROTECTED] Would make debugging easier. A try catch SAXException block around the getXMLReader().parse(input); statements in the parse File and parse(String would allow the SAX Exception to be caught, taken apart, an error statement with file or uri added, and thrown. But how to capture the first stack trace? Use NestedExceptions from jakarta-commons-lang? Use org.apache.commons.lang.exception.ExceptionUtils.getStackTrace and and cram the first stack trace in the with new SAXExceptions? Or avoid the new dependecy on lang and do something else? - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
[lang] NumberUtilsNumberUtils.createXXX methods and empty strings [WAS: unit tests 1.3.1_08 vs 1.4.2.]
Hello, The NumberUtils.createXXX methods all have the following pattern: public static XXX createXXX(String str) { if (str == null) { return null; } In the case of BigDecimal, passing in a to new BigDecimal(String) in Sun 1.3.1_08 blows up like this: java.lang.StringIndexOutOfBoundsException: String index out of range: 0 at java.lang.String.charAt(String.java:582) at java.math.BigDecimal.init(BigDecimal.java:124) at org.apache.commons.lang.math.NumberUtils.createBigDecimal(NumberUtils.java:4 78) at org.apache.commons.lang.math.NumberUtilsTest.testCreateBigDecimal(NumberUtil sTest.java:209) Under Sun 1.4.2, you get a NumberFormatException if the length of the string is 0 (no trim()). The unit tests expect a NumberFormatException when you pass in . So... to make this all nice on 1.3, should all of the guard clauses become: (1) if (StringUtil.isEmpty(str)) { return null; } (2) if (StringUtil.isBlank(str)) { return null; } (3) if (str == null) { return null; } if (StringUtil.isEmpty(str)) { return str; } ? I think (2) would be good since it would not blow up on AND but I am not familiar with the various invocation contexts, so, please opine. Thanks, Gary -Original Message- From: Gary Gregory [mailto:[EMAIL PROTECTED] Sent: Friday, July 25, 2003 17:53 To: 'Jakarta Commons Developers List' Subject: [lang] unit tests 1.3.1_08 vs 1.4.2. I am seing something odd: under Sun 1.4.2, the unit tests run fine but under Sun 1.3.1_08, they do not. Specifically: test.lang: [echo] Running lang package tests ... [java] . [java] . [java] . [java] . [java] . [java] . [java] . [java] .F [java] ... [java] Time: 0.285 [java] There was 1 failure: [java] 1) testIndexOf_StringInt(org.apache.commons.lang.StringUtilsEqualsIndexOfTest)j unit.framework.AssertionFailedError: expected:0 but was:-1 [java] at org.apache.commons.lang.StringUtilsEqualsIndexOfTest.testIndexOf_StringInt(S tringUtilsEqualsIndexOfTest.java:158) [java] FAILURES!!! [java] Tests run: 359, Failures: 1, Errors: 0 and: test.math: [echo] Running math package tests ... [java] . [java] . [java] ..E... [java] .. [java] Time: 9.424 [java] There was 1 error: [java] 1) testCreateBigDecimal(org.apache.commons.lang.math.NumberUtilsTest)java.lang. StringIndexOutOfBoundsException: String index out of range: 0 [java] at java.lang.String.charAt(String.java:582) [java] at java.math.BigDecimal.init(BigDecimal.java:124) [java] at org.apache.commons.lang.math.NumberUtils.createBigDecimal(NumberUtils.java:4 78) [java] at org.apache.commons.lang.math.NumberUtilsTest.testCreateBigDecimal(NumberUtil sTest.java:209) [java] FAILURES!!! [java] Tests run: 149, Failures: 0, Errors: 1 Gary -Original Message- From: Stephen Colebourne [mailto:[EMAIL PROTECTED] Sent: Friday, July 25, 2003 16:12 To: Jakarta Commons Developers List Subject: Re: [lang] Findbugs output for Lang 2.0 I've addressed these as seems sensible. Some static variables went from protected to private Some static variables went from non-final to final Stephen - Original Message - From: Henri Yandell [EMAIL PROTECTED] To: Jakarta Commons Developers List [EMAIL PROTECTED] Sent: Wednesday, July 23, 2003 9:54 PM Subject: [lang] Findbugs output for Lang 2.0 Taking current CVS I get the following as output from the Findbugs project. Lang output: http://www.flamefew.net/~hen/lang-2.0-findbugs-output.html Findbugs:http://www.cs.umd.edu/~pugh/java/bugs/ Just in case anyone's interested :) Hen - 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]
cvs commit: jakarta-commons/lang/src/java/org/apache/commons/lang/math NumberUtils.java
ggregory2003/07/25 19:57:37 Modified:lang/src/java/org/apache/commons/lang/math NumberUtils.java Log: In 2 places, removed local var def before return of var, replaced with actual expression. This follows the other methods' code pattern. Revision ChangesPath 1.5 +3 -5 jakarta-commons/lang/src/java/org/apache/commons/lang/math/NumberUtils.java Index: NumberUtils.java === RCS file: /home/cvs/jakarta-commons/lang/src/java/org/apache/commons/lang/math/NumberUtils.java,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- NumberUtils.java 20 Jul 2003 16:03:21 - 1.4 +++ NumberUtils.java 26 Jul 2003 02:57:37 - 1.5 @@ -458,8 +458,7 @@ if (str == null) { return null; } -BigInteger bi = new BigInteger(str); -return bi; +return new BigInteger(str); } /** @@ -475,8 +474,7 @@ if (str == null) { return null; } -BigDecimal bd = new BigDecimal(str); -return bd; +return new BigDecimal(str); } // Min in array - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: [lang] Findbugs output for Lang 2.0
Stephen, I was just going to remark that some *Utils classes are final and some others are not; and propose to clean that up but... this is intentional then? For backwards compatibility I take it. We could javadoc these non-final classes as to be made final in the next release...? IMHO, subclassing a class (like our *Utils) that only contains statics is asking for trouble since there is no static side inheritance like there is in Smalltalk, but... different story. ;-) Gary -Original Message- From: Stephen Colebourne [mailto:[EMAIL PROTECTED] Sent: Friday, July 25, 2003 16:12 To: Jakarta Commons Developers List Subject: Re: [lang] Findbugs output for Lang 2.0 I've addressed these as seems sensible. Some static variables went from protected to private Some static variables went from non-final to final Stephen - Original Message - From: Henri Yandell [EMAIL PROTECTED] To: Jakarta Commons Developers List [EMAIL PROTECTED] Sent: Wednesday, July 23, 2003 9:54 PM Subject: [lang] Findbugs output for Lang 2.0 Taking current CVS I get the following as output from the Findbugs project. Lang output: http://www.flamefew.net/~hen/lang-2.0-findbugs-output.html Findbugs:http://www.cs.umd.edu/~pugh/java/bugs/ Just in case anyone's interested :) Hen - 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]
DO NOT REPLY [Bug 21904] New: - NumberUtils.createBigDecimal() NPE in Sun 1.3.1_08
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://nagoya.apache.org/bugzilla/show_bug.cgi?id=21904. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE. http://nagoya.apache.org/bugzilla/show_bug.cgi?id=21904 NumberUtils.createBigDecimal() NPE in Sun 1.3.1_08 Summary: NumberUtils.createBigDecimal() NPE in Sun 1.3.1_08 Product: Commons Version: Nightly Builds Platform: Other OS/Version: Other Status: NEW Severity: Normal Priority: Other Component: Lang AssignedTo: [EMAIL PROTECTED] ReportedBy: [EMAIL PROTECTED] Hello, The NumberUtils.createXXX methods all have the following pattern: public static XXX createXXX(String str) { if (str == null) { return null; } In the case of BigDecimal, passing in a to new BigDecimal(String) in Sun 1.3.1_08 blows up like this: java.lang.StringIndexOutOfBoundsException: String index out of range: 0 at java.lang.String.charAt(String.java:582) at java.math.BigDecimal.init(BigDecimal.java:124) at org.apache.commons.lang.math.NumberUtils.createBigDecimal(NumberUtils.java:4 78) at org.apache.commons.lang.math.NumberUtilsTest.testCreateBigDecimal(NumberUtil sTest.java:209) Under Sun 1.4.2, you get a NumberFormatException if the length of the string is 0 (no trim()). The unit tests expect a NumberFormatException when you pass in . So... to make this all nice on 1.3, should all of the guard clauses become: (1) if (StringUtil.isEmpty(str)) { return null; } (2) if (StringUtil.isBlank(str)) { return null; } (3) if (str == null) { return null; } if (StringUtil.isEmpty(str)) { return str; } ? I think (2) would be good since it would not blow up on AND but I am not familiar with the various invocation contexts, so, please opine. Thanks, Gary - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: [lang] NumberUtilsNumberUtils.createXXX methods and empty strings [WAS: unit tests 1.3.1_08 vs 1.4.2.]
FYI, tracking here: http://nagoya.apache.org/bugzilla/show_bug.cgi?id=21904 Gary -Original Message- From: Gary Gregory [mailto:[EMAIL PROTECTED] Sent: Friday, July 25, 2003 19:52 To: 'Jakarta Commons Developers List' Subject: [lang] NumberUtilsNumberUtils.createXXX methods and empty strings [WAS: unit tests 1.3.1_08 vs 1.4.2.] Hello, The NumberUtils.createXXX methods all have the following pattern: public static XXX createXXX(String str) { if (str == null) { return null; } In the case of BigDecimal, passing in a to new BigDecimal(String) in Sun 1.3.1_08 blows up like this: java.lang.StringIndexOutOfBoundsException: String index out of range: 0 at java.lang.String.charAt(String.java:582) at java.math.BigDecimal.init(BigDecimal.java:124) at org.apache.commons.lang.math.NumberUtils.createBigDecimal(NumberUtils.java:4 78) at org.apache.commons.lang.math.NumberUtilsTest.testCreateBigDecimal(NumberUtil sTest.java:209) Under Sun 1.4.2, you get a NumberFormatException if the length of the string is 0 (no trim()). The unit tests expect a NumberFormatException when you pass in . So... to make this all nice on 1.3, should all of the guard clauses become: (1) if (StringUtil.isEmpty(str)) { return null; } (2) if (StringUtil.isBlank(str)) { return null; } (3) if (str == null) { return null; } if (StringUtil.isEmpty(str)) { return str; } ? I think (2) would be good since it would not blow up on AND but I am not familiar with the various invocation contexts, so, please opine. Thanks, Gary -Original Message- From: Gary Gregory [mailto:[EMAIL PROTECTED] Sent: Friday, July 25, 2003 17:53 To: 'Jakarta Commons Developers List' Subject: [lang] unit tests 1.3.1_08 vs 1.4.2. I am seing something odd: under Sun 1.4.2, the unit tests run fine but under Sun 1.3.1_08, they do not. Specifically: test.lang: [echo] Running lang package tests ... [java] . [java] . [java] . [java] . [java] . [java] . [java] . [java] .F [java] ... [java] Time: 0.285 [java] There was 1 failure: [java] 1) testIndexOf_StringInt(org.apache.commons.lang.StringUtilsEqualsIndexOfTest)j unit.framework.AssertionFailedError: expected:0 but was:-1 [java] at org.apache.commons.lang.StringUtilsEqualsIndexOfTest.testIndexOf_StringInt(S tringUtilsEqualsIndexOfTest.java:158) [java] FAILURES!!! [java] Tests run: 359, Failures: 1, Errors: 0 and: test.math: [echo] Running math package tests ... [java] . [java] . [java] ..E... [java] .. [java] Time: 9.424 [java] There was 1 error: [java] 1) testCreateBigDecimal(org.apache.commons.lang.math.NumberUtilsTest)java.lang. StringIndexOutOfBoundsException: String index out of range: 0 [java] at java.lang.String.charAt(String.java:582) [java] at java.math.BigDecimal.init(BigDecimal.java:124) [java] at org.apache.commons.lang.math.NumberUtils.createBigDecimal(NumberUtils.java:4 78) [java] at org.apache.commons.lang.math.NumberUtilsTest.testCreateBigDecimal(NumberUtil sTest.java:209) [java] FAILURES!!! [java] Tests run: 149, Failures: 0, Errors: 1 Gary -Original Message- From: Stephen Colebourne [mailto:[EMAIL PROTECTED] Sent: Friday, July 25, 2003 16:12 To: Jakarta Commons Developers List Subject: Re: [lang] Findbugs output for Lang 2.0 I've addressed these as seems sensible. Some static variables went from protected to private Some static variables went from non-final to final Stephen - Original Message - From: Henri Yandell [EMAIL PROTECTED] To: Jakarta Commons Developers List [EMAIL PROTECTED] Sent: Wednesday, July 23, 2003 9:54 PM Subject: [lang] Findbugs output for Lang 2.0 Taking current CVS I get the following as output from the Findbugs project. Lang output: http://www.flamefew.net/~hen/lang-2.0-findbugs-output.html Findbugs:http://www.cs.umd.edu/~pugh/java/bugs/ Just in case anyone's interested :) Hen - 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]
[collections] NotifyingCollections design
This email gives an overview of the design of NotifyingCollections, and addresses all of the points raised by Stephen in earlier emails. The NotifyingCollections code is too large to post to the list, but can be accessed at http://nettool.sourceforge.net/nc/ Design Overview --- NotifyingCollections is a decorator package that provides event-based notification functionality for the collections api. Decorators are provided for Collection, List, Set, SortedSet, Bag, SortedBag, Map and SortedMap. The iterators and sub-views (e.g. List#subList) are also first class decorators (and are fail-fast). All of the decorator classes implement the NotifyingDecorator interface, which provides common functionality for managing listeners (adding, removing, etc.). A collection is decorated using the usual static method pattern, e.g.: NotifyingCollection nc = NotifyingCollectionsUtils.notifyingCollection( c ); There are two types of listeners. A 'post-listener' implements the CollectionListener interface, and it receives a CollectionEvent *after* the actual modification has occurred (as you might expect). public interface CollectionListener extends EventListener { void collectionEventOccurred(CollectionEvent event); } A 'pre-listener' implements the VetoingCollectionListener interface, and it receives the event *before* the modification takes place. This gives the pre-listener a chance to veto the proposed modification before it occurs. public interface VetoingCollectionListener extends EventListener { /** * @throws ModificationVetoException to indicate that the * proposed event should be vetoed. */ void vetoableModificationOccurring( ModifyingEvent event ); } A notifying decorator can be configured to support either or both of these listener mechanisms. The base event type fired by NotifyingCollections is CollectionEvent. This has two subclasses, ModifyingEvent and NonModifyingEvent. NonModifyingEvents are only fired in exceptional circumstances, i.e. when a listener vetoes a modification (ModificationVetoEvent), or when an exception occurs during an operation on the decorated collection (CollectionExceptionEvent). All normal collection operations result in instances of ModifyingEvent being fired. ModifyingEvent provides limited information about the event (actually just the size of the collection before and after the modification). Subclasses of ModifyingEvent (which is an abstract class) can choose to provide as much or as little detail as desired. This capability is provided through the use of a pluggable event package. The author of an event package implements one or many of the event factory interfaces defined by NotifyingCollections (one for each main collection type), and passes an instance of such an event factory to the decorator factory methods in NotifyingCollectionsUtils. NotifyingCollections includes two** event package implementations, 'simple' and 'rich'. SimpleCollectionEvent is fast and light, and does not provide additional functionality above and beyond that specified by ModifyingEvent. RichCollectionEvent is a heavyweight implementation. It has an event hierarchy (i.e. AddEvent, RemoveEvent etc.), and significant additional functionality. In particular, RichCollectionEvent implements the ReplayableEvent interface. This interface defines two operations, #replay and #undo, which permit the event's actions to be replayed (or undone) on the decorated collection, *or* on any arbitrary target collection. In effect, RichCollectionEvent can be used to capture the entire history of a collection, and can be used to roll back a collection to any previous state. This is a very powerful facility. ** The current build includes a third event package 'monolithic', which illustrates some of the limitations of dispensing with an event hierarchy and using a single event class to capture rich mixed-type data. FAQ, comments, and responses How much information about the collection modification can an event capture? Just about everything. For any given method, the fired event can access: - the entire state of the collection before and after the modification, - the signature of the invoked method, - the arguments to the method, - the return value, - any exceptions that occur, - the state of the decorator (i.e. access to the listeners). 2) The event dispatch sometimes assumes too much. For example the List addAll() method validates the index as being in range, but the LazyList implementation expects out of range indices. The modCount in the iterators could face the same problem. This issue didn't occur to me earlier in development as I had not considered the case of contract violators such as LazyList. And in fact the explicit range checks by NotifyingList are superfluous as the decorated list will eventually throw an IndexOutOfBoundsException anyway. The offending code has been removed and LazyList should work fine now (though I have not
[collections] NotifyingCollections update
Latest build and docs for NotifyingCollections available from: http://nettool.sourceforge.net/nc/ The significant update is that NotifyingList no longer performs explicit range checks (and thus should now be suitable for use with LazyList - an informal indicates that it does indeed work). - Neil - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: [collections] NotifyingCollections update
--- Neil O'Toole [EMAIL PROTECTED] wrote: Latest build and docs for NotifyingCollections available from: http://nettool.sourceforge.net/nc/ The significant update is that NotifyingList no longer performs explicit range checks (and thus should now be suitable for use with LazyList - an informal indicates that it does indeed work). Last line should read an informal test indicates that... - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: using httpclient from tomcat
Jo, what version of Tomcat are you using? Recent Tomcats do not come with a security manager in their default configuration. Odi Johannes Huettemeister wrote: Hi, as you might notice I'm not a java professional and also my tomcat knowledge is limited. If I just create GetMethod objekt in the servlet I get a security exception. If you say that this is unusual, I guess I got an error in my tomcat configuration, I will have a close look now to this. btw: its not an applet its a very simple servlet only. cheers johannes. -- _ NOSE applied intelligence ag [www] http://www.nose.ch ortwin glück [email] [EMAIL PROTECTED] hardturmstrasse 171 [pgp key] 0x81CF3416 8005 zurich [office] +41-1-277 57 35 switzerland [fax] +41-1-277 57 12 - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: SocketException : SSL Implementation not available
Hello, from the JavaDocs of javax.net.ssl.SSLSocketFactory.getDefault(): If SSL has not been configured properly for this virtual machine, the factory will be inoperative (reporting instantiation exceptions). In order to create SSL connections, the SSL implementation needs to know the root certificates it is supposed to trust. This must be configured, usually in properties files. Since you are switching manually to a Sun JSSE within an IBM JDK, chances are that there is no configuration of the key store, which is supposed to hold the root certificates. You should verify steps 7 and 8 of the installation instructions: http://java.sun.com/products/jsse/install.html hope that helps, Roland Ramanan nr [EMAIL PROTECTED] 24.07.2003 22:32 Please respond to Commons HttpClient Project To: Commons HttpClient Project [EMAIL PROTECTED], [EMAIL PROTECTED] cc: Subject:RE: SocketException : SSL Implementation not available Hi oleg, My https call. Works fine with Sun JDK 1.4.1 I dont have the provision to move to IBM's Version I am using commons-httpclient 2.0 beta, IBM JDK 1.3.1 (WSAD 4.0.3), Sun JSSE 1.0.3 I downloaded Sun JSSE 1.0.3 added the jar files from that to WSAD JRE (to the ext directory) changed the security file to add the following info: security.provider.1=sun.security.provider.Sun security.provider.2=com.sun.crypto.provider.SunJCE security.provider.3=com.sun.net.ssl.internal.ssl.Provider security.provider.4=com.sun.jsse.JSSEProvider #security.provider.5=com.ibm.crypto.provider.IBMJCE #security.provider.6=com.ibm.jsse.JSSEProvider Also in my code I am doing the following : System.setProperty(java.protocol.handler.pkgs,com.sun.net.ssl.internal.www.protocol); Security.addProvider(new com.sun.net.ssl.internal.ssl.Provider()); Security.insertProviderAt(new com.sun.crypto.provider.SunJCE(),1); I am getting the following exception: java.net.SocketException: SSL implementation not available at javax.net.ssl.DefaultSSLSocketFactory.createSocket(Unknown Source) at org.apache.commons.httpclient.protocol.SSLProtocolSocketFactory.createSocket(SSLProtocolSocketFactory.java:127) at org.apache.commons.httpclient.HttpConnection.tunnelCreated(HttpConnection.java:749) at org.apache.commons.httpclient.ConnectMethod.execute(ConnectMethod.java:204) at org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:638) at org.apache.commons.httpclient.HttpClient.executeMethod(HttpClient.java:500) stacktrace removed Am I missing any thing that needs to be done? thanks NRR
DO NOT REPLY [Bug 21880] New: - Content-Length Transfer-Encoding request headers should be handled by entity enclosing methods
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://nagoya.apache.org/bugzilla/show_bug.cgi?id=21880. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE. http://nagoya.apache.org/bugzilla/show_bug.cgi?id=21880 Content-Length Transfer-Encoding request headers should be handled by entity enclosing methods Summary: Content-Length Transfer-Encoding request headers should be handled by entity enclosing methods Product: Commons Version: 2.0 Beta 2 Platform: Other OS/Version: Other Status: NEW Severity: Enhancement Priority: Other Component: HttpClient AssignedTo: [EMAIL PROTECTED] ReportedBy: [EMAIL PROTECTED] Currently 'Content-Length' 'Transfer-Encoding' request headers are handled by the HttpMethodBase class. This is conceptually wrong and error-prone in my opinion. Entity enclosing methods should control 'Content-Length' 'Transfer- Encoding' request headers instead, as they provide request content and encapsulate the requisite content transfer logic. - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
RE: FW: Commons-HttpClient conflict with WebDAVClient
There should be some documentation on both projects web sites stating their 'connectedness' of lack of it... I bet I am not the only one who ended up with this problem... Regards, Daniel -Original Message- From: Adrian Sutton [mailto:[EMAIL PROTECTED] Sent: Friday, 25 July, 2003 12:50 PM To: Commons HttpClient Project Subject: Re: FW: Commons-HttpClient conflict with WebDAVClient They're two separate projects with little interaction these days. Slide depends on HttpClient and we do try our best not to break their build but I don't think there are any committers on both teams. Regards, Adrian Sutton. On Friday, July 25, 2003, at 02:30 PM, Daniel Joshua wrote: Just curious is there any co-ordination going on between the Commons-HttpClient and the Slide developers? Or are the 2 Jakarta projects developing totally independant of each other? Regards, Daniel -Original Message- From: Adrian Sutton [mailto:[EMAIL PROTECTED] Sent: Thursday, 24 July, 2003 8:33 PM To: Commons HttpClient Project Cc: 'Slide Users Mailing List' Subject: Re: FW: Commons-HttpClient conflict with WebDAVClient There are a few options here: a. Check out the slide sources and build against HttpClient beta 2 instead of HEAD (all the compile errors that I can see are due to the changes on the HEAD branch and won't be in the 2.0 release). b. Update Slide to compile with HttpClient CVS HEAD - Note that slide will then no longer compile with older HttpClient versions. I can do up a patch if the slide developers want to do it this way. c. Release HttpClient 2.0 (planned very soon) and Slide x.x (???) then take option b. d. Something else? I'll open a bug report on this in a moment, Daniel I'd suggest you add yourself to the CC list. Regards, Adrian Sutton. On Thursday, July 24, 2003, at 10:12 PM, Daniel Joshua wrote: Can somebody make a release soon in that case... I really need a WebDAVClient which can be use with either a Commons-HttpClient beta 1 or 2? Regards, Daniel -Original Message- From: Christopher Lenz [mailto:[EMAIL PROTECTED] Sent: Thursday, 24 July, 2003 7:53 PM To: Slide Users Mailing List Subject: Re: FW: Commons-HttpClient conflict with WebDAVClient Martin Holz wrote: Daniel Joshua [EMAIL PROTECTED] writes: We use the latest beta releases of HttpClient with a CVS build of the WebDAV client. Works fine. Fisrt, I have checked http://jakarta.apache.org/site/binindex.cgi and the latest release build for download is Slide 1.0.16. Also, I was looking at the Slide documentation and there is mention of Slide 2.0.0 Where can I download this. Slide 2.0 is not released and there is no such thing as nightly build. You have to build it from CVS. There *are* automated nightly builds: http://cvs.apache.org/builds/jakarta-slide/nightly/ But the builds have been faily for weeks now :-/ http://cvs.apache.org/builds/gump/latest/jakarta-slide.html (Apparently due to an incompatible change in HttpClient) -chris - 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] -- Intencha tomorrow's technology today Ph: 38478913 0422236329 Suite 8/29 Oatland Crescent Holland Park West 4121 Australia QLD www.intencha.com - 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] -- Intencha tomorrow's technology today Ph: 38478913 0422236329 Suite 8/29 Oatland Crescent Holland Park West 4121 Australia QLD www.intencha.com - 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]
DO NOT REPLY [Bug 10791] - HTTP Version configuration and tracking
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://nagoya.apache.org/bugzilla/show_bug.cgi?id=10791. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE. http://nagoya.apache.org/bugzilla/show_bug.cgi?id=10791 HTTP Version configuration and tracking --- Additional Comments From [EMAIL PROTECTED] 2003-07-25 13:33 --- Oleg, Very nice. I think this is a clean solution to the problem. I have a few comments: - HttpVersion.parse() no longer handles the http status of HTTP. Though this is an obviously non-standard value it is something that we intentionally added support for. - HttpVersion should implement hashCode(). - HttpVersion.equals(Object) does the following test: if ((obj != null) (obj instanceof HttpVersion)) Though this is not an error the test for null is not necessary as instanceof already handles this case. Mike - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
DO NOT REPLY [Bug 19868] - Exception handling in HttpClient requires redesign
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://nagoya.apache.org/bugzilla/show_bug.cgi?id=19868. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE. http://nagoya.apache.org/bugzilla/show_bug.cgi?id=19868 Exception handling in HttpClient requires redesign --- Additional Comments From [EMAIL PROTECTED] 2003-07-25 14:00 --- Created an attachment (id=7510) (Hopefully) the final exception handling clean-up (take 1) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
DO NOT REPLY [Bug 19868] - Exception handling in HttpClient requires redesign
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://nagoya.apache.org/bugzilla/show_bug.cgi?id=19868. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE. http://nagoya.apache.org/bugzilla/show_bug.cgi?id=19868 Exception handling in HttpClient requires redesign --- Additional Comments From [EMAIL PROTECTED] 2003-07-25 14:02 --- I cleaned up things somewhat and dealt with the remaining outstanding issues. Please let me know what you think. Oleg - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
DO NOT REPLY [Bug 21880] - Content-Length Transfer-Encoding request headers should be handled by entity enclosing methods
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://nagoya.apache.org/bugzilla/show_bug.cgi?id=21880. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE. http://nagoya.apache.org/bugzilla/show_bug.cgi?id=21880 Content-Length Transfer-Encoding request headers should be handled by entity enclosing methods --- Additional Comments From [EMAIL PROTECTED] 2003-07-25 14:30 --- Created an attachment (id=7512) Patch (take 2) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
DO NOT REPLY [Bug 21880] - Content-Length Transfer-Encoding request headers should be handled by entity enclosing methods
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://nagoya.apache.org/bugzilla/show_bug.cgi?id=21880. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE. http://nagoya.apache.org/bugzilla/show_bug.cgi?id=21880 Content-Length Transfer-Encoding request headers should be handled by entity enclosing methods --- Additional Comments From [EMAIL PROTECTED] 2003-07-25 14:30 --- Javadoc warning corrected. Oleg - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
DO NOT REPLY [Bug 10791] - HTTP Version configuration and tracking
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://nagoya.apache.org/bugzilla/show_bug.cgi?id=10791. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE. http://nagoya.apache.org/bugzilla/show_bug.cgi?id=10791 HTTP Version configuration and tracking --- Additional Comments From [EMAIL PROTECTED] 2003-07-25 15:29 --- Created an attachment (id=7515) HTTP version patch (take 2) - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
DO NOT REPLY [Bug 10791] - HTTP Version configuration and tracking
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://nagoya.apache.org/bugzilla/show_bug.cgi?id=10791. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE. http://nagoya.apache.org/bugzilla/show_bug.cgi?id=10791 HTTP Version configuration and tracking --- Additional Comments From [EMAIL PROTECTED] 2003-07-25 16:05 --- I don't know of a good reason to hash HttpVersions either. I think it is just good practice to override equals() and hashCode() together. Mike - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: DNS // NIO
Clemens, Please see my comments below On Fri, 2003-07-25 at 19:24, Clemens Marschner wrote: Hi, there are two issues I would like to bring up that were mentioned in this list during the last months but were never resolved: 1. Java DNS handling as done by java.net.Socket is very inefficient for snip This could be avoided by issueing only the IP address to java.net.Socket and thus to HTTPClient. However, it is necessary to pass the host name to HTTPClient in order to resolve multiple host names per IP address within the HTTP request. Do you have any plans to plug in an external DNS resolver and create a Socket only with the IP address? The issue of custom DNS resolver has been discussed on several occasions. The consensus was (if my memory does not fail me) that domain name resolution was clearly out of HttpClient's scope. Instead we have provided a way to plug in a custom DN resolution mechanism by supporting virtual host names in the target host's configuration. HostConfiguration hostconfig = new HostConfiguration(); hostconfig.setHost(127.0.0.1, www.whatever.com, 80, Protocol.getProtocol(http)); HttpClient agent = new HttpClient(); agent.setHostConfiguration(hostconfig); 2. Are there any people working on a NIO based version of HTTPClient? I saw some notes on this on a weblog, but haven't seen any results. Our goal is to provide Java 1.2 compatibility as long as the project reliant on HttpClient require it. That puts NIO support pretty much out of question for a considerable period of time to come. This said, however, we are planning to provide a means of plugging in a custom HttpConnection implementation in 3.x release, which would allow NIO based implementation to be used instead of official Java 1.2 compatible one. More good stuff will be coming in the 3.x release. It can well make bearing with us worthwhile. cheers Oleg - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: DNS // NIO
The issue of custom DNS resolver has been discussed on several occasions. The consensus was (if my memory does not fail me) that domain name resolution was clearly out of HttpClient's scope. Instead we have provided a way to plug in a custom DN resolution mechanism by supporting virtual host names in the target host's configuration. HostConfiguration hostconfig = new HostConfiguration(); hostconfig.setHost(127.0.0.1, www.whatever.com, 80, Protocol.getProtocol(http)); HttpClient agent = new HttpClient(); agent.setHostConfiguration(hostconfig); This can also be done on individual methods using HttpMethod.getHostConfiguration().setHost(...). Mike - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
DO NOT REPLY [Bug 21880] - Content-Length Transfer-Encoding request headers should be handled by entity enclosing methods
DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT http://nagoya.apache.org/bugzilla/show_bug.cgi?id=21880. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE. http://nagoya.apache.org/bugzilla/show_bug.cgi?id=21880 Content-Length Transfer-Encoding request headers should be handled by entity enclosing methods [EMAIL PROTECTED] changed: What|Removed |Added Status|NEW |RESOLVED Resolution||FIXED --- Additional Comments From [EMAIL PROTECTED] 2003-07-25 18:33 --- Patch committed. Oleg - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Performance Issue
Hi, After upgrading from 2.0-alpha3 to 2.0-beta2, instead of roughly 10 requests per second, I am averaging only 3 requests per second. I was hoping someone could take a look at the attached code and show me the 'error of my ways.' My test is multithreaded, and all requests are sent to the same host. I am setting MaxConnectionsPerHost equivalent to the number of sending threads. The auth-method required by the server is BASIC. Thanks for your help. Todd - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]