Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id F3EDC200C86 for ; Wed, 31 May 2017 22:04:10 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id F234B160BDB; Wed, 31 May 2017 20:04:10 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 4585E160BC2 for ; Wed, 31 May 2017 22:04:10 +0200 (CEST) Received: (qmail 99954 invoked by uid 500); 31 May 2017 20:04:09 -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 99943 invoked by uid 99); 31 May 2017 20:04:09 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 31 May 2017 20:04:09 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id ECD9AC0C0B for ; Wed, 31 May 2017 20:04:08 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -99.202 X-Spam-Level: X-Spam-Status: No, score=-99.202 tagged_above=-999 required=6.31 tests=[KAM_ASCII_DIVIDERS=0.8, RP_MATCHES_RCVD=-0.001, SPF_PASS=-0.001, USER_IN_WHITELIST=-100] autolearn=disabled Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id 6L4EW4EboKAp for ; Wed, 31 May 2017 20:04:08 +0000 (UTC) Received: from mailrelay1-us-west.apache.org (mailrelay1-us-west.apache.org [209.188.14.139]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTP id D2C665F2A8 for ; Wed, 31 May 2017 20:04:07 +0000 (UTC) Received: from jira-lw-us.apache.org (unknown [207.244.88.139]) by mailrelay1-us-west.apache.org (ASF Mail Server at mailrelay1-us-west.apache.org) with ESMTP id 6494CE07D6 for ; Wed, 31 May 2017 20:04:07 +0000 (UTC) Received: from jira-lw-us.apache.org (localhost [127.0.0.1]) by jira-lw-us.apache.org (ASF Mail Server at jira-lw-us.apache.org) with ESMTP id 203C921B56 for ; Wed, 31 May 2017 20:04:07 +0000 (UTC) Date: Wed, 31 May 2017 20:04:07 +0000 (UTC) From: "Michael Miller (JIRA)" To: notifications@accumulo.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Assigned] (ACCUMULO-4642) Remove ServerConfiguration.getInstance() MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 archived-at: Wed, 31 May 2017 20:04:11 -0000 [ https://issues.apache.org/jira/browse/ACCUMULO-4642?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Michael Miller reassigned ACCUMULO-4642: ---------------------------------------- Assignee: Michael Miller (was: Christopher Tubbs) > Remove ServerConfiguration.getInstance() > ---------------------------------------- > > Key: ACCUMULO-4642 > URL: https://issues.apache.org/jira/browse/ACCUMULO-4642 > Project: Accumulo > Issue Type: Improvement > Components: server-base > Reporter: Christopher Tubbs > Assignee: Michael Miller > Priority: Minor > Attachments: ACCUMULO-4642-initial-draft.patch > > > In working with ACCUMULO-4050, I've realized that we need to do some internal refactoring to get better control over HdfsZooInstance. This would enable better testing (because we could inject a mock Instance more easily, and in more places). It would also allow us to reuse objects without storing them statically in the JVM. > Fully realizing this would involve a lot of work, moving the static state to a single "context" object constructed on server startup, and shared (in part or in whole) as needed throughout the runtime server code. > However, I think we can get there incrementally, by starting with eliminating the ServerConfiguration.getInstance() method. This causes SystemConfigurationFactory to also have a getInstance() method, and that means that SystemConfigurationFactory is being used like the context object I describe, but redundantly instead of AccumuloServerContext, or a server-specific subclass. > Eliminating ServerConfiguration.getInstance() might involve an intermediate step of adding Instance parameters to many methods which currently take only a SystemConfigurationFactory, because components will not be able to get the Instance from that configuration factory any longer. However, even this intermediate step will be progress towards moving to a single shared context object, which provides access to both the Instance and the configuration factory. > If we can move directly to the context object, that would probably be better, but it would involve a lot more changes, in particular to the way the server code is initialized. Then again, those changes might be good to prioritize anyway, because all our server components seem to initialize differently, and it would be nice to rewrite their bootstrap code to follow the same pattern. -- This message was sent by Atlassian JIRA (v6.3.15#6346)