You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Michael Shuler (JIRA)" <ji...@apache.org> on 2014/12/02 00:28:13 UTC

[jira] [Updated] (CASSANDRA-8315) cassandra-env.sh doesn't handle correctly non numeric JDK versions

     [ https://issues.apache.org/jira/browse/CASSANDRA-8315?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Michael Shuler updated CASSANDRA-8315:
--------------------------------------
    Attachment: 8315.txt

It looks like I was previously testing a 1.8 -ea version, so that particular test failed, since it wasn't < 1.8..

I grabbed the latest 1.7 early access build, 1.7.0_80-ea-b03, and it looks like the attached patch gives us a lexical comparison that should work fine. It appears this particular line is just in the 2.1 branch.

> cassandra-env.sh doesn't handle correctly non numeric JDK versions
> ------------------------------------------------------------------
>
>                 Key: CASSANDRA-8315
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-8315
>             Project: Cassandra
>          Issue Type: Bug
>            Reporter: Michaël Figuière
>            Assignee: Michael Shuler
>            Priority: Trivial
>             Fix For: 2.1.3
>
>         Attachments: 8315.txt
>
>
> Trying to work around a JDK bug, I've installed a Early Access release of the JDK, which lead to a small, non-blocking error, in {{cassandra-env.sh}} as it expects the patch part of the JDK version to be a number, but on Oracle EA JDKs, the patch number is followed by an {{-ea}} qualifier as in:
> {code}
> $ java -version
> java version "1.7.0_80-ea"
> Java(TM) SE Runtime Environment (build 1.7.0_80-ea-b02)
> Java HotSpot(TM) 64-Bit Server VM (build 24.80-b07, mixed mode)
> {code}
> This lead to the following error:
> {code}
> bin/../conf/cassandra-env.sh: line 102: [: 80-ea: integer expression expected
> {code}
> Obviously not a big deal, but we may want to cover this corner case properly by just ignoring the qualifier part of the version.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)