Uploaded image for project: 'Nuxeo Platform'
  1. Nuxeo Platform
  2. NXP-14534

Check Java version in Shell scripts

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 5.9.5

      Description

      The check on the Java version (greater or equal to 1.7) cannot be done in the Launcher Java code anymore if we want to use Java 7 features in the Launcher.
      So, it must be done in nuxeoctl and nuxeoctl.bat. Else, display a comprehensive message.

      Nuxeo 5.8
      $ ./bin/nuxeoctl start
      Detected Tomcat server.
      Nuxeo home:          /media/julien/1To/download/nuxeo-cap-5.8-tomcat
      Nuxeo configuration: /media/julien/1To/download/nuxeo-cap-5.8-tomcat/bin/nuxeo.conf
      Include template: /media/julien/1To/download/nuxeo-cap-5.8-tomcat/templates/common-base
      Include template: /media/julien/1To/download/nuxeo-cap-5.8-tomcat/templates/common
      Include template: /media/julien/1To/download/nuxeo-cap-5.8-tomcat/templates/default
      Could not run configuration: Nuxeo requires Java {1.7} (detected 1.6.0_38).
      Nuxeo 5.9.3
      $ ./bin/nuxeoctl start
      Exception in thread "main" java.lang.UnsupportedClassVersionError: org/nuxeo/connect/identity/LogicalInstanceIdentifier$NoCLID : Unsupported major.minor version 51.0
      	at java.lang.ClassLoader.defineClass1(Native Method)
      	at java.lang.ClassLoader.defineClassCond(ClassLoader.java:631)
      	at java.lang.ClassLoader.defineClass(ClassLoader.java:615)
      	at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:141)
      	at java.net.URLClassLoader.defineClass(URLClassLoader.java:283)
      	at java.net.URLClassLoader.access$000(URLClassLoader.java:58)
      	at java.net.URLClassLoader$1.run(URLClassLoader.java:197)
      	at java.security.AccessController.doPrivileged(Native Method)
      	at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
      	at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
      	at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:301)
      	at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
      Could not find the main class: org.nuxeo.launcher.NuxeoLauncher. Program will exit.

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Time Tracking

                  Estimated:
                  Original Estimate - 2 hours
                  2h
                  Remaining:
                  Remaining Estimate - 2 hours
                  2h
                  Logged:
                  Time Spent - Not Specified
                  Not Specified