Return-Path: Delivered-To: apmail-lucene-solr-dev-archive@locus.apache.org Received: (qmail 62069 invoked from network); 14 Dec 2008 18:04:05 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 14 Dec 2008 18:04:05 -0000 Received: (qmail 81611 invoked by uid 500); 14 Dec 2008 18:04:17 -0000 Delivered-To: apmail-lucene-solr-dev-archive@lucene.apache.org Received: (qmail 81583 invoked by uid 500); 14 Dec 2008 18:04:17 -0000 Mailing-List: contact solr-dev-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: solr-dev@lucene.apache.org Delivered-To: mailing list solr-dev@lucene.apache.org Received: (qmail 81572 invoked by uid 99); 14 Dec 2008 18:04:17 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 14 Dec 2008 10:04:17 -0800 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.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 14 Dec 2008 18:04:04 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 39351234C3C7 for ; Sun, 14 Dec 2008 10:03:44 -0800 (PST) Message-ID: <1092400039.1229277824233.JavaMail.jira@brutus> Date: Sun, 14 Dec 2008 10:03:44 -0800 (PST) From: "Shalin Shekhar Mangar (JIRA)" To: solr-dev@lucene.apache.org Subject: [jira] Resolved: (SOLR-913) org/apache/solr/handler/SnapPuller.java - Expensive Pattern object made static In-Reply-To: <1769750203.1229274944200.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/SOLR-913?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Shalin Shekhar Mangar resolved SOLR-913. ---------------------------------------- Resolution: Won't Fix Marking as won't fix because the readInterval method is called only on core startup and it is better to create and throw away Pattern object rather then keep it in static. Thanks for going through the code Kay, please keep the suggestions coming :) > org/apache/solr/handler/SnapPuller.java - Expensive Pattern object made static > -------------------------------------------------------------------------------- > > Key: SOLR-913 > URL: https://issues.apache.org/jira/browse/SOLR-913 > Project: Solr > Issue Type: Improvement > Components: clients - java > Environment: Tomcat 6, JRE 6 > Reporter: Kay Kay > Fix For: 1.4 > > Attachments: SOLR-913.patch > > Original Estimate: 2h > Remaining Estimate: 2h > > In the class - org.apache.solr.handler.SnapPuller - there seems to be an expensive Pattern object created locally in the method > static Integer readInterval(String interval) ; > Pattern instances are better created as static objects and reused. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.