faban
  1. faban
  2. FABAN-1

JAVA_HOME flag in the Faban UI is not propagated to drivers

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Labels:
      None
    • Environment:

      Solaris 10 on x86

      Description

      >>> In the "Schedule Run" button, in the Java tab there are two text
      >>> fields "JAVA HOME" and "JVM Options".
      The JVM options flags propagate fine, JAVA_HOME doesn't seem to.

        Activity

        Hide
        yaominchen added a comment -
        • On Faban master, if the UI's JAVA_HOME flag (such as /export/home/java) is a soft link, then it is first extracted to point to the physical folder (e.g. /export/home/jdk1.7) before it is sent to the faban agents on other clients.

        There is inconsistency between two files related to the javaHome parameter. One file refers to it "fh:jvmConfig/fh:home" while the other file "fh:jvmConfig/fh:javaHome".

        faban~source/harness/src/com/sun/faban/harness/engine/CmdService.java:

        public boolean setup(String benchName, ParamRepository par) {

        String home = par.getParameter("fh:jvmConfig/fh:home");

        if (home != null)
        home = home.trim();

        if (home == null || home.length() == 0) {
        home = Utilities.getJavaHome();
        logger.log(Level.CONFIG, "JAVA_HOME set to

        {0}", home);
        }

        if(!(new File(home)).isDirectory()) {
        logger.log(Level.SEVERE, "Cannot set JAVA_HOME. {0}

        is not a valid JAVA_HOME. Exiting", home);
        return false;
        }

        javaHome = home;

        ~/faban/faban~source/common/src/com/sun/faban/common/ParamReader.java:

        public class ParamReader {

        static final Logger logger = Logger.getLogger(ParamReader.class.getName());

        /** The base Faban namespace URI. */
        public static final String FABANURI = "http://faban.sunsource.net/ns/faban";

        /** List of xpaths and their prefixes. */
        private static final String[][] PREFIX_TABLE = {

        { "jvmConfig", "fh" }

        ,

        { "jvmConfig/javaHome", "fh" }

        ,

        { "jvmConfig/jvmOptions", "fh" }

        ,

        Show
        yaominchen added a comment - On Faban master, if the UI's JAVA_HOME flag (such as /export/home/java) is a soft link, then it is first extracted to point to the physical folder (e.g. /export/home/jdk1.7) before it is sent to the faban agents on other clients. There is inconsistency between two files related to the javaHome parameter. One file refers to it "fh:jvmConfig/fh:home" while the other file "fh:jvmConfig/fh:javaHome". faban~source/harness/src/com/sun/faban/harness/engine/CmdService.java: public boolean setup(String benchName, ParamRepository par) { String home = par.getParameter("fh:jvmConfig/fh:home"); if (home != null) home = home.trim(); if (home == null || home.length() == 0) { home = Utilities.getJavaHome(); logger.log(Level.CONFIG, "JAVA_HOME set to {0}", home); } if(!(new File(home)).isDirectory()) { logger.log(Level.SEVERE, "Cannot set JAVA_HOME. {0} is not a valid JAVA_HOME. Exiting", home); return false; } javaHome = home; ~/faban/faban~source/common/src/com/sun/faban/common/ParamReader.java: public class ParamReader { static final Logger logger = Logger.getLogger(ParamReader.class.getName()); /** The base Faban namespace URI. */ public static final String FABANURI = "http://faban.sunsource.net/ns/faban"; /** List of xpaths and their prefixes. */ private static final String[][] PREFIX_TABLE = { { "jvmConfig", "fh" } , { "jvmConfig/javaHome", "fh" } , { "jvmConfig/jvmOptions", "fh" } ,
        Hide
        yaominchen added a comment -

        Fixed by the 12/05/11 check in. A kit fanan-kit-120811 was built, verified and uploaded.

        Show
        yaominchen added a comment - Fixed by the 12/05/11 check in. A kit fanan-kit-120811 was built, verified and uploaded.
        Hide
        yaominchen added a comment -

        Fixed by code change.

        Show
        yaominchen added a comment - Fixed by code change.

          People

          • Assignee:
            yaominchen
            Reporter:
            yaominchen
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Due:
              Created:
              Updated:
              Resolved: