glassfish
  1. glassfish
  2. GLASSFISH-3785

Upgrading to V2 from V1 can be improved ...

    Details

    • Issuezilla Id:
      3,785
    • Status Whiteboard:
      Hide

      91ur1Approved

      Show
      91ur1Approved

      Description

      The ordeal is explained at length at given URL.

      Please see: http://blogs.sun.com/bloggerkedar/entry/upgrading_from_glassfish_v1_to

      to understand the issue. The fix is simple and has already been tested by
      the GlassFish V1 customer!

      Please approve/fix this for 9.1 UR1.

      The impact is minimal. The returns are high.

        Activity

        Hide
        basler added a comment -

        Approved for check into the SJSAS91_UR1_BRANCH

        Show
        basler added a comment - Approved for check into the SJSAS91_UR1_BRANCH
        Hide
        Byron Nevins added a comment -

        .

        Show
        Byron Nevins added a comment - .
        Hide
        Byron Nevins added a comment -

        ? admin.log
        ? build
        ? diffs.txt
        ? nup.txt
        Index: src/java/com/sun/enterprise/admin/servermgmt/launch/ASLauncher.java
        ===================================================================
        RCS file:
        /cvs/glassfish/admin/servermgmt/src/java/com/sun/enterprise/admin/servermgmt/launch/ASLauncher.java,v
        retrieving revision 1.25
        diff -u -r1.25 ASLauncher.java
        — src/java/com/sun/enterprise/admin/servermgmt/launch/ASLauncher.java 1 Aug
        2007 03:25:18 -0000 1.25
        +++ src/java/com/sun/enterprise/admin/servermgmt/launch/ASLauncher.java 22 Oct
        2007 19:06:38 -0000
        @@ -972,7 +972,10 @@
        if (getProcessLauncherProfile().equals(AS9_INTERNAL_SERVER_PROFILE))
        {
        String classpathPrefix=javaConfig.getClasspathPrefix();

        • String classpathSuffix=javaConfig.getClasspathSuffix();
          +
          + // WBN Oct 2007 – possibly add the uer's CP to suffix...
          + String classpathSuffix=getClasspathSuffix(javaConfig);
          +
          String serverClasspath=javaConfig.getServerClasspath();
          getLogger().log(FINE_LEVEL, " prefix :: " + classpathPrefix
          + " suffix :: " + classpathSuffix);
          @@ -1356,8 +1359,7 @@
          {
          String classpathPrefix=javaConfig.getClasspathPrefix();
          String classpathSystem=javaConfig.getSystemClasspath();
        • String classpathSuffix=javaConfig.getClasspathSuffix();
        • + String classpathSuffix=getClasspathSuffix(javaConfig);
          if(isValidString(classpathSystem))
          {
          classpath += File.pathSeparator + classpathSystem;
          @@ -1369,6 +1371,7 @@
          //the classpaths in PELaunch
          if (getProcessLauncherProfile().equals(INTERNAL_SERVER_PROFILE))
          {
          + // wbn note that INTERNAL_SERVER_PROFILE is obsolete – we
          should never see this as true
          if(isValidString(classpathPrefix))
          {
          classpath=classpathPrefix + File.pathSeparator + classpath;
          @@ -1384,15 +1387,6 @@

          { classpath += File.pathSeparator + profilerClasspath; }
        • // See if need to add user classpath
        • // WBN changed to use JDK 1.5 built-in getEnv()
        • if(!javaConfig.isEnvClasspathIgnored())
        • { - // Add user classpath... - String userCP = System.getenv(CLASSPATH_ENV_NAME); - if(userCP != null && userCP.length() > 0) - classpath += File.pathSeparator + userCP; - }

          }

        getLogger().log(FINE_LEVEL, "Final classpath - \n" + classpath);
        @@ -2360,7 +2354,35 @@
        + File.separator
        + APPSERV_LAUNCH_JAR;
        }

        • +
          + private String getClasspathSuffix(JavaConfig cfg)
          + {
          + String suffix = cfg.getClasspathSuffix();
          +
          + // if there is no suffix we will not get null but rather this String:
          "null"
          +
          + if(suffix == null || suffix.equals("null"))
          + suffix = "";
          +
          + if(cfg.isEnvClasspathIgnored() == false)
          +

          Unknown macro: {+ // Add user classpath...+ String userCP = System.getenv(CLASSPATH_ENV_NAME);++ if(userCP != null && userCP.length() > 0)+ { + if(isValidString(suffix)) + suffix += File.pathSeparator; + + suffix += userCP; + + getLogger().log(Level.INFO, "Environmental Variable CLASSPATH's value" + + " was appended to classpath-suffix. Here is the final classpath-suffix:\n" + suffix); + }+ }

          + return suffix;
          + }
          +
          // END END END END ENDEND – this is here for grepping to the end of this
          gigantic class!!

        //**************************************************************************

        Show
        Byron Nevins added a comment - ? admin.log ? build ? diffs.txt ? nup.txt Index: src/java/com/sun/enterprise/admin/servermgmt/launch/ASLauncher.java =================================================================== RCS file: /cvs/glassfish/admin/servermgmt/src/java/com/sun/enterprise/admin/servermgmt/launch/ASLauncher.java,v retrieving revision 1.25 diff -u -r1.25 ASLauncher.java — src/java/com/sun/enterprise/admin/servermgmt/launch/ASLauncher.java 1 Aug 2007 03:25:18 -0000 1.25 +++ src/java/com/sun/enterprise/admin/servermgmt/launch/ASLauncher.java 22 Oct 2007 19:06:38 -0000 @@ -972,7 +972,10 @@ if (getProcessLauncherProfile().equals(AS9_INTERNAL_SERVER_PROFILE)) { String classpathPrefix=javaConfig.getClasspathPrefix(); String classpathSuffix=javaConfig.getClasspathSuffix(); + + // WBN Oct 2007 – possibly add the uer's CP to suffix... + String classpathSuffix=getClasspathSuffix(javaConfig); + String serverClasspath=javaConfig.getServerClasspath(); getLogger().log(FINE_LEVEL, " prefix :: " + classpathPrefix + " suffix :: " + classpathSuffix); @@ -1356,8 +1359,7 @@ { String classpathPrefix=javaConfig.getClasspathPrefix(); String classpathSystem=javaConfig.getSystemClasspath(); String classpathSuffix=javaConfig.getClasspathSuffix(); + String classpathSuffix=getClasspathSuffix(javaConfig); if(isValidString(classpathSystem)) { classpath += File.pathSeparator + classpathSystem; @@ -1369,6 +1371,7 @@ //the classpaths in PELaunch if (getProcessLauncherProfile().equals(INTERNAL_SERVER_PROFILE)) { + // wbn note that INTERNAL_SERVER_PROFILE is obsolete – we should never see this as true if(isValidString(classpathPrefix)) { classpath=classpathPrefix + File.pathSeparator + classpath; @@ -1384,15 +1387,6 @@ { classpath += File.pathSeparator + profilerClasspath; } // See if need to add user classpath // WBN changed to use JDK 1.5 built-in getEnv() if(!javaConfig.isEnvClasspathIgnored()) { - // Add user classpath... - String userCP = System.getenv(CLASSPATH_ENV_NAME); - if(userCP != null && userCP.length() > 0) - classpath += File.pathSeparator + userCP; - } } getLogger().log(FINE_LEVEL, "Final classpath - \n" + classpath); @@ -2360,7 +2354,35 @@ + File.separator + APPSERV_LAUNCH_JAR; } + + private String getClasspathSuffix(JavaConfig cfg) + { + String suffix = cfg.getClasspathSuffix(); + + // if there is no suffix we will not get null but rather this String: "null" + + if(suffix == null || suffix.equals("null")) + suffix = ""; + + if(cfg.isEnvClasspathIgnored() == false) + Unknown macro: {+ // Add user classpath...+ String userCP = System.getenv(CLASSPATH_ENV_NAME);++ if(userCP != null && userCP.length() > 0)+ { + if(isValidString(suffix)) + suffix += File.pathSeparator; + + suffix += userCP; + + getLogger().log(Level.INFO, "Environmental Variable CLASSPATH's value" + + " was appended to classpath-suffix. Here is the final classpath-suffix:\n" + suffix); + }+ } + return suffix; + } + // END END END END ENDEND – this is here for grepping to the end of this gigantic class!! //**************************************************************************

          People

          • Assignee:
            Byron Nevins
            Reporter:
            km
          • Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: