Hitachi Vantara Pentaho Community Forums
Results 1 to 5 of 5

Thread: What's the right version of JVM

  1. #1
    Join Date
    Oct 2006
    Posts
    5

    Default What's the right version of JVM

    I am trying to get RC3 up and running on Tomcat 5.0. The difficulty I am having is that
    1) The BI deployment needs J2RE 1.4
    2) The report designer needs J2RE 1.5.0_06
    3) The only 1.5 version for download on Sun's site is 1.5.0_09 and that version does not work with the BI deployment.

    So what version should be installed to get it all to work on one machine? Or is the only answer that we need to recompile from source? When will such a version be supplied by pentaho?

  2. #2
    Join Date
    Mar 2003
    Posts
    8,085

    Default Re:What's the right version of JVM

    Hi,

    JDKs are backward compatible - so the JDK 1.5.0_09 is a valid replacement for JDK 1.5.0_06 or any previous version (including the JDK 1.4.2).

    if the JDK 1.5.0_09 did not work, then chances are good that JDK 1.5.0_06 wouldn't have worked either. But without any information about the error, it is particulary hard to tell what went wrong.

    The Pentaho-Plattform (the 'server' thing) runs well on JDK 1.5 as well. The development team, however will only use features from JDK 1.4 to make sure that the plattform runs on all plattforms that support JDK 1.4.2 (Version 1.5 is not available on all operating systems).

    When developing under JDK 1.5, there is no reason that your code does not run in JDK 1.4 - as long as you dont use any of the newer features and as long as you tell your compiler to generate code for JDK 1.4.

    Regards,
    Thomas
    Get the latest news and tips and tricks for Pentaho Reporting at the Pentaho Reporting Blog.

  3. #3
    Join Date
    Oct 2006
    Posts
    5

    Default Re:What's the right version of JVM

    Ok. I thought perhapse a broad question would have more specific answer. Here is the detail:

    I had the entire BI site running and then in my wisdom thought I should upgrade to JDK and JRE 1.5.0_09. I re-built the war file deployed it and then tried to use it. But I got -

    2006-10-19 02:13:47 StandardWrapperValve[jsp]: Servlet.service() for servlet jsp threw exception
    org.apache.jasper.JasperException: Unable to compile class for JSP

    An error occurred at line: -1 in the jsp file: null

    Generated servlet error:
    [javac] Compiling 1 source file

    C:\\Program Files\\Apache Software Foundation\\Tomcat 5.0\\work\\Catalina\\localhost\\pentaho\\org\\apache\\jsp\\index_jsp.java:7: cannot access java.lang.Object
    bad class file: C:\\Program Files\\Java\\jre1.5.0_06\\lib\\rt.jar(java/lang/Object.class)
    class file has wrong version 49.0, should be 48.0
    Please remove or make sure it appears in the correct subdirectory of the classpath.
    public final class index_jsp extends org.apache.jasper.runtime.HttpJspBase
    ^
    1 error
    [ERROR] Compiler - -Javac exception <Compile failed; see the compiler error output for details.>Compile failed; see the compiler error output for details.
    at org.apache.tools.ant.taskdefs.Javac.compile(Javac.java:978)
    at org.apache.tools.ant.taskdefs.Javac.execute(Javac.java:799)
    at org.apache.jasper.compiler.Compiler.generateClass(Compiler.java:390)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:458)
    at org.apache.jasper.compiler.Compiler.compile(Compiler.java:439)
    at org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:553)
    at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:291)
    at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:301)
    at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:248)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)

    ....

    I rolled it all back to 1.4.2_12 and it all works well again. Problem is now I can't use the report designer.

    So do I live with 1.4.2_12 as the jdk and use 1.5.0_09 as the jre? I am just not very knowlegable about Java and don't understand the implications of decisions like this.

    BTW the platform is:
    Windows 2000
    Tomcat 5.0
    Pentaho RC3

  4. #4
    Join Date
    Oct 2006
    Posts
    5

    Default Re:What's the right version of JVM

    The auto-upgrade scheduler that comes with the jre allowed me to upgrade from 1.4.2_12 to 1.5.0_06 which I did. So everything still works and I can use the report designer as well. I am still running jdk 1.4.2_12.

    So no problems at the moment. 3 reports up-and-running.

  5. #5
    Join Date
    Mar 2003
    Posts
    8,085

    Default Re:What's the right version of JVM

    That version 48 vs 49 error is caused, if you try to run JDK 1.5 classes in a JDK 1.4 JVM. To me it seems, that somehow you used/mixed the old JDK 1.4 binaries with the runtime classes of JDK 1.5. Really strange, so I would say, somehow the installations of the various JDKs got mixed up *or* the JDK configuration of the JBoss server is screwed up.

    (Notice that the error occurs in java.lang.Object - a class so fundamental that no outside programmer can mess it up using standard java means. Errors in the java.* namespace always indicate errors in the JDK or the way, the JDK is installed.

    Regards,
    Thomas
    Get the latest news and tips and tricks for Pentaho Reporting at the Pentaho Reporting Blog.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Privacy Policy | Legal Notices | Safe Harbor Privacy Policy

Copyright © 2005 - 2019 Hitachi Vantara Corporation. All Rights Reserved.