Return-Path: Delivered-To: apmail-lucene-dev-archive@www.apache.org Received: (qmail 28215 invoked from network); 22 Dec 2010 09:14:23 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 22 Dec 2010 09:14:23 -0000 Received: (qmail 36867 invoked by uid 500); 22 Dec 2010 09:14:22 -0000 Delivered-To: apmail-lucene-dev-archive@lucene.apache.org Received: (qmail 36508 invoked by uid 500); 22 Dec 2010 09:14:22 -0000 Mailing-List: contact dev-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@lucene.apache.org Delivered-To: mailing list dev@lucene.apache.org Received: (qmail 36501 invoked by uid 99); 22 Dec 2010 09:14:21 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 22 Dec 2010 09:14:21 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.22] (HELO thor.apache.org) (140.211.11.22) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 22 Dec 2010 09:14:21 +0000 Received: from thor (localhost [127.0.0.1]) by thor.apache.org (8.13.8+Sun/8.13.8) with ESMTP id oBM9E0tv009743 for ; Wed, 22 Dec 2010 09:14:00 GMT Message-ID: <1109217.262761293009240711.JavaMail.jira@thor> Date: Wed, 22 Dec 2010 04:14:00 -0500 (EST) From: "Shai Erera (JIRA)" To: dev@lucene.apache.org Subject: [jira] Updated: (LUCENE-2830) Use StringBuilder instead of StringBuffer in benchmark In-Reply-To: <212871.262681293008640692.JavaMail.jira@thor> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/LUCENE-2830?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Shai Erera updated LUCENE-2830: ------------------------------- Attachment: LUCENE-2830.patch Patch replaces StringBuffer with StringBuilder. I did not yet remove the parse() method from HtmlParser - if people are ok with it, I'll remove it. For now, I changed the parameter to String. All tests pass. > Use StringBuilder instead of StringBuffer in benchmark > ------------------------------------------------------ > > Key: LUCENE-2830 > URL: https://issues.apache.org/jira/browse/LUCENE-2830 > Project: Lucene - Java > Issue Type: Improvement > Components: contrib/benchmark > Reporter: Shai Erera > Assignee: Shai Erera > Priority: Minor > Fix For: 3.1, 4.0 > > Attachments: LUCENE-2830.patch > > > Minor change - use StringBuilder instead of StringBuffer in benchmark's code. We don't need the synchronization of StringBuffer in all the places that I've checked. > The only place where it _could_ be a problem is in HtmlParser's API - one method accepts a StringBuffer and it's an interface. But I think it's ok to change benchmark's API, back-compat wise and so I'd like to either change it to accept a String, or remove the method altogether -- no code in benchmark uses it, and if anyone needs it, he can pass StringReader to the other method. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org For additional commands, e-mail: dev-help@lucene.apache.org