From oak-issues-return-74050-archive-asf-public=cust-asf.ponee.io@jackrabbit.apache.org Tue Aug 6 12:39:02 2019 Return-Path: X-Original-To: archive-asf-public@cust-asf.ponee.io Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [207.244.88.153]) by mx-eu-01.ponee.io (Postfix) with SMTP id F088D180595 for ; Tue, 6 Aug 2019 14:39:01 +0200 (CEST) Received: (qmail 74242 invoked by uid 500); 6 Aug 2019 12:39:01 -0000 Mailing-List: contact oak-issues-help@jackrabbit.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: oak-dev@jackrabbit.apache.org Delivered-To: mailing list oak-issues@jackrabbit.apache.org Received: (qmail 74181 invoked by uid 99); 6 Aug 2019 12:39:01 -0000 Received: from mailrelay1-us-west.apache.org (HELO mailrelay1-us-west.apache.org) (209.188.14.139) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 06 Aug 2019 12:39:01 +0000 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 618C2E2FC2 for ; Tue, 6 Aug 2019 12:39:00 +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 1147726660 for ; Tue, 6 Aug 2019 12:39:00 +0000 (UTC) Date: Tue, 6 Aug 2019 12:39:00 +0000 (UTC) From: "Marcel Reutegger (JIRA)" To: oak-issues@jackrabbit.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (OAK-8521) Add shutdown hook for oak-run commands 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/OAK-8521?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16900986#comment-16900986 ] Marcel Reutegger commented on OAK-8521: --------------------------------------- Vinod proposed changes in https://github.com/apache/jackrabbit-oak/pull/137 > Add shutdown hook for oak-run commands > -------------------------------------- > > Key: OAK-8521 > URL: https://issues.apache.org/jira/browse/OAK-8521 > Project: Jackrabbit Oak > Issue Type: Improvement > Components: documentmk, run > Reporter: Vinod Holani > Assignee: Marcel Reutegger > Priority: Minor > Attachments: OAK-8521.patch > > > Ensure there are shutdown hooks in place for the various oak-run commands that properly stop the repository and release the clusterId. > Many command construct a repository, then perform some operation and then shut down the repository again. Shutting down the repository will release the clusterId change the state of the clusterNodes entry back to inactive. In some cases commands execute for a longer period of time and a user might kill the process. When this happens, the clusterId is not released and stays in the active state with a lease that eventually expires. The command implementations should be improved to register a JVM shutdown hook that ensures the repository is shut down, even when the process is killed. -- This message was sent by Atlassian JIRA (v7.6.14#76016)