Return-Path: X-Original-To: apmail-commons-issues-archive@minotaur.apache.org Delivered-To: apmail-commons-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 53507C7E2 for ; Wed, 13 Mar 2013 20:00:15 +0000 (UTC) Received: (qmail 3133 invoked by uid 500); 13 Mar 2013 20:00:14 -0000 Delivered-To: apmail-commons-issues-archive@commons.apache.org Received: (qmail 3023 invoked by uid 500); 13 Mar 2013 20:00:14 -0000 Mailing-List: contact issues-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: issues@commons.apache.org Delivered-To: mailing list issues@commons.apache.org Received: (qmail 2946 invoked by uid 99); 13 Mar 2013 20:00:14 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 13 Mar 2013 20:00:14 +0000 Date: Wed, 13 Mar 2013 20:00:14 +0000 (UTC) From: "Thomas Neidhart (JIRA)" To: issues@commons.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (COLLECTIONS-325) Improve thread-safety of ExtendedProperties 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/COLLECTIONS-325?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13601562#comment-13601562 ] Thomas Neidhart commented on COLLECTIONS-325: --------------------------------------------- The class javadoc already states that it would probably a better idea to use commons-configuration. So I wonder if we should not take the opportunity (release 4.0) and remove the class completely. Any objections? > Improve thread-safety of ExtendedProperties > ------------------------------------------- > > Key: COLLECTIONS-325 > URL: https://issues.apache.org/jira/browse/COLLECTIONS-325 > Project: Commons Collections > Issue Type: Improvement > Reporter: Sebb > > It looks as though ExtendedProperties is intended to be thread-safe, otherwise why bother synchronizing load() and save()? > If so, then ExtendedProperties field "isInitialized" should be made volatile to ensure the variable is correctly published. > Likewise, the field "includePropertyName" needs to be volatile or synchronised. > Also, the following protected variables could be made final to improve thread-safety: > defaults > file > basePath > fileSeparator - this could perhaps be static too? > keysAsListed > Regardless of thread-safety issues, does it make sense for these variables to be changed once initialised? -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira