Return-Path: X-Original-To: apmail-accumulo-notifications-archive@minotaur.apache.org Delivered-To: apmail-accumulo-notifications-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 68DA111E83 for ; Thu, 24 Jul 2014 00:08:44 +0000 (UTC) Received: (qmail 29457 invoked by uid 500); 24 Jul 2014 00:08:44 -0000 Delivered-To: apmail-accumulo-notifications-archive@accumulo.apache.org Received: (qmail 29410 invoked by uid 500); 24 Jul 2014 00:08:44 -0000 Mailing-List: contact notifications-help@accumulo.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: jira@apache.org Delivered-To: mailing list notifications@accumulo.apache.org Received: (qmail 29392 invoked by uid 99); 24 Jul 2014 00:08:44 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 24 Jul 2014 00:08:44 +0000 Date: Thu, 24 Jul 2014 00:08:44 +0000 (UTC) From: "Bill Havanki (JIRA)" To: notifications@accumulo.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Created] (ACCUMULO-3012) Simplify DefaultConfiguration MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 Bill Havanki created ACCUMULO-3012: -------------------------------------- Summary: Simplify DefaultConfiguration Key: ACCUMULO-3012 URL: https://issues.apache.org/jira/browse/ACCUMULO-3012 Project: Accumulo Issue Type: Sub-task Reporter: Bill Havanki Assignee: Bill Havanki Priority: Minor Fix For: 1.6.1, 1.7.0 The current implementation of {{DefaultConfiguration}} has some downsides: * Its internal map of configuration defaults is built on-demand in its singleton instance, which drives the need to synchronize access to the singleton. The map could be built statically. * That same map could be made immutable as well. * Even though it uses a singleton, {{new DefaultConfiguration()}} is still permitted since the no-arg constructor isn't defined as private. * Calls to {{DefaultConfiguration.getInstance()}} cannot be easily mocked. * Its main method no longer has anything to do with it, and instead belongs in {{ConfigurationDocGen}}. Improve and simplify {{DefaultConfiguration}}. -- This message was sent by Atlassian JIRA (v6.2#6252)