Return-Path: X-Original-To: apmail-cassandra-commits-archive@www.apache.org Delivered-To: apmail-cassandra-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 727DD187F5 for ; Tue, 13 Oct 2015 18:48:08 +0000 (UTC) Received: (qmail 31263 invoked by uid 500); 13 Oct 2015 18:48:05 -0000 Delivered-To: apmail-cassandra-commits-archive@cassandra.apache.org Received: (qmail 31222 invoked by uid 500); 13 Oct 2015 18:48:05 -0000 Mailing-List: contact commits-help@cassandra.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cassandra.apache.org Delivered-To: mailing list commits@cassandra.apache.org Received: (qmail 31207 invoked by uid 99); 13 Oct 2015 18:48:05 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 13 Oct 2015 18:48:05 +0000 Date: Tue, 13 Oct 2015 18:48:05 +0000 (UTC) From: "Paulo Motta (JIRA)" To: commits@cassandra.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (CASSANDRA-10447) Stop TeeingAppender on shutdown hook 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/CASSANDRA-10447?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Paulo Motta updated CASSANDRA-10447: ------------------------------------ Summary: Stop TeeingAppender on shutdown hook (was: Stop TeeingAppender (and wrapped appenders) on shutdown hook) > Stop TeeingAppender on shutdown hook > ------------------------------------ > > Key: CASSANDRA-10447 > URL: https://issues.apache.org/jira/browse/CASSANDRA-10447 > Project: Cassandra > Issue Type: Bug > Reporter: Ariel Weisberg > Assignee: Ariel Weisberg > Fix For: 3.0.0 rc2 > > > Stefania discovered that tests that don't produce a lot of log output end up producing 0 debug output to files because the data is not flushed as part of the shutdown hook. I traced through and it looks like the shutdown hook doesn't actually invoke code that does anything useful. It shuts down an executor service in the logging context but doesn't call stop on any appenders. > A hackish thing we can do is use a status listener to collect all the appenders and then stop them when the shutdown hook runs. Even adding a small delay to the shutdown hook (no code changes on our part) would in let the async appender flush in 90% of cases. > We still need to fix it for test which uses a different config file and for which a small delay is not desirable. -- This message was sent by Atlassian JIRA (v6.3.4#6332)