cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tyler Hobbs (JIRA)" <j...@apache.org>
Subject [jira] [Created] (CASSANDRA-4271) Exit status of bin/cassandra without -f is wrong
Date Tue, 22 May 2012 01:29:40 GMT
Tyler Hobbs created CASSANDRA-4271:
--------------------------------------

             Summary: Exit status of bin/cassandra without -f is wrong
                 Key: CASSANDRA-4271
                 URL: https://issues.apache.org/jira/browse/CASSANDRA-4271
             Project: Cassandra
          Issue Type: Bug
          Components: Core
    Affects Versions: 1.1.0, 1.0.10
            Reporter: Tyler Hobbs
            Priority: Minor


The launch_service() function returns {{$?}} after exec'ing java, and the script then exits
with that same status.

The problem is that we do a {{[ ! -z "$pidpath"] && ...}} conditional statment after
exec'ing when the foreground flag isn't set.  The value of {{$?}} then depends on that conditional
and the statement, typically returning 1, because {{$pidpath}} isn't set.  So, even if everything
appears to execute normally, you will get an exit status of 1 for the whole script.

I suspect the right thing to do is just return 0 when backgrounding.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Mime
View raw message