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 996CF180AF for ; Thu, 10 Mar 2016 21:24:41 +0000 (UTC) Received: (qmail 42488 invoked by uid 500); 10 Mar 2016 21:24:41 -0000 Delivered-To: apmail-cassandra-commits-archive@cassandra.apache.org Received: (qmail 42428 invoked by uid 500); 10 Mar 2016 21:24:41 -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 42104 invoked by uid 99); 10 Mar 2016 21:24:41 -0000 Received: from arcas.apache.org (HELO arcas) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 10 Mar 2016 21:24:41 +0000 Received: from arcas.apache.org (localhost [127.0.0.1]) by arcas (Postfix) with ESMTP id DB4302C1F5D for ; Thu, 10 Mar 2016 21:24:40 +0000 (UTC) Date: Thu, 10 Mar 2016 21:24:40 +0000 (UTC) From: "Yuki Morishita (JIRA)" To: commits@cassandra.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (CASSANDRA-9598) bad classapth for 'sstablerepairedset' in 'cassandra-tools' package MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/CASSANDRA-9598?page=3Dcom.atla= ssian.jira.plugin.system.issuetabpanels:all-tabpanel ] Yuki Morishita updated CASSANDRA-9598: -------------------------------------- Fix Version/s: 3.0.x 2.2.x 2.1.x > bad classapth for 'sstablerepairedset' in 'cassandra-tools' package > ------------------------------------------------------------------- > > Key: CASSANDRA-9598 > URL: https://issues.apache.org/jira/browse/CASSANDRA-9598 > Project: Cassandra > Issue Type: Bug > Components: Tools > Environment: Debian 3.16.7, cassandra-tools 2.1.6, cassandra 2.1.= 6 > Reporter: Cl=C3=A9ment Lardeur > Priority: Minor > Fix For: 2.1.x, 2.2.x, 3.0.x > > > The script 'sstablerepairedset' is not ready out of the box for debian di= stro, maybe due to the refactoring of CASSANDRA-7160 to pack out tools from= the bin directory. > Actually in 'sstablerepairedset' the classapth is calculated with: > {code} > if [ "x$CLASSPATH" =3D "x" ]; then > =20 > # execute from the build dir. > if [ -d `dirname $0`/../../build/classes ]; then > for directory in `dirname $0`/../../build/classes/*; do > CLASSPATH=3D$CLASSPATH:$directory > done > else > if [ -f `dirname $0`/../lib/stress.jar ]; then > CLASSPATH=3D`dirname $0`/../lib/stress.jar > fi > fi > for jar in `dirname $0`/../../lib/*.jar; do > CLASSPATH=3D$CLASSPATH:$jar > done > fi > {code} > Whereas in other scripts from the 'bin/tools', the classpath is calculate= d with: > {code} > if [ "x$CASSANDRA_INCLUDE" =3D "x" ]; then > for include in "`dirname "$0"`/cassandra.in.sh" \ > "$HOME/.cassandra.in.sh" \ > /usr/share/cassandra/cassandra.in.sh \ > /usr/local/share/cassandra/cassandra.in.sh \ > /opt/cassandra/cassandra.in.sh; do > if [ -r "$include" ]; then > . "$include" > break > fi > done > elif [ -r "$CASSANDRA_INCLUDE" ]; then > . "$CASSANDRA_INCLUDE" > fi > {code} > I think that a little refactoring could be good to extract the common par= t of these scripts like the computation of the CLASSPATH and the set of JAV= A_HOME. -- This message was sent by Atlassian JIRA (v6.3.4#6332)