glassfish
  1. glassfish
  2. GLASSFISH-15831

Regression: Exception printed on screen when deploying scrumtoys application second time

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 3.1_b40
    • Fix Version/s: 3.1_b41
    • Component/s: admin_gui
    • Labels:
      None
    • Environment:

      ogs-3.1-b40.zip

      Description

      The scrumtoys application requires derby database running and a jdbc resource created. When the application is deployed to DAS and the resource does not exist, an exception is printed on the GUI page.

      Steps to reproduce:
      1. Start database.
      2. In Admin Console, deploy scrumtoys application (you can access it to see that it works).
      3. Undeploy the application.
      4. Deploy it again and the following exception is displayed on the screen:

      HTTP Status 500 -

      type Exception report

      message

      descriptionThe server encountered an internal error () that prevented it from fulfilling this request.

      exception

      javax.servlet.ServletException: java.lang.reflect.InvocationTargetException while attempting to process a 'command' event for 'uploadButton'.

      root cause

      java.lang.RuntimeException: java.lang.reflect.InvocationTargetException while attempting to process a 'command' event for 'uploadButton'.

      root cause

      java.lang.reflect.InvocationTargetException

      root cause

      java.lang.UnsupportedOperationException

      I have reinstalled Glassfish a couple times to verify that this exception happens on the clean install.

      While the application may be invalid (I'll check with JSF team if I have the latest version, since there some issues with this app in the past, e.g. see a related http://java.net/jira/browse/GLASSFISH-14942 issue), Admin Console should not throw an exception on the screen.

      1. server.log
        33 kB
        lidiam
      1. deploy-exception.JPG
        87 kB
      2. warning.jpg
        417 kB

        Activity

        Hide
        Chris Kasso added a comment -

        Approved for RC2.

        Show
        Chris Kasso added a comment - Approved for RC2.
        Hide
        lidiam added a comment -

        Anissa, the warning you got (in the attached screenshot) means that the database was most likely not started before deploying the app. In my case database is running and I see the following warning (from the attached server.log files):

        java.sql.SQLException: Table/View 'PROJECTS' already exists in Schema 'APP'

        So the issue is that the application tries to create tables that already exist from previous deployment. I'm not sure if it's supposed to be part of undeployment to clear those tables.

        Show
        lidiam added a comment - Anissa, the warning you got (in the attached screenshot) means that the database was most likely not started before deploying the app. In my case database is running and I see the following warning (from the attached server.log files): java.sql.SQLException: Table/View 'PROJECTS' already exists in Schema 'APP' So the issue is that the application tries to create tables that already exist from previous deployment. I'm not sure if it's supposed to be part of undeployment to clear those tables.
        Hide
        Anissa Lam added a comment -

        I have checked in the fix to catch any unexpected exception, so no stack trace shown on screen.
        I am going to downgrade this to P4, and when we have more cycle to get to the bottom of this context request issue, we will revisit.

        Fix checked into both trunk and 3.1 branch.
        trunk: rev# 44903
        3.1 branch: rev# 44904.

        ====================

        Project: glassfish
        Repository: svn
        Revision: 44904
        Author: anilam
        Date: 2011-02-04 19:19:19 UTC
        Link:

        Log Message:
        ------------
        GLASSFISH-15831. Catch unexpected exception to ensure stack trace won't show on screen.

        Fix checked into the trunk as rev# 44903

        Reviewed by Siraj
        Approved by Chris

        Revisions:
        ----------
        44904

        Modified Paths:
        ---------------
        branches/3.1/admingui/common/src/main/java/org/glassfish/admingui/common/util/GuiUtil.java

        Show
        Anissa Lam added a comment - I have checked in the fix to catch any unexpected exception, so no stack trace shown on screen. I am going to downgrade this to P4, and when we have more cycle to get to the bottom of this context request issue, we will revisit. Fix checked into both trunk and 3.1 branch. trunk: rev# 44903 3.1 branch: rev# 44904. ==================== Project: glassfish Repository: svn Revision: 44904 Author: anilam Date: 2011-02-04 19:19:19 UTC Link: Log Message: ------------ GLASSFISH-15831 . Catch unexpected exception to ensure stack trace won't show on screen. Fix checked into the trunk as rev# 44903 Reviewed by Siraj Approved by Chris Revisions: ---------- 44904 Modified Paths: --------------- branches/3.1/admingui/common/src/main/java/org/glassfish/admingui/common/util/GuiUtil.java
        Hide
        marina vatkina added a comment -

        The app is set not to drop tables on undeploy:
        <property name="eclipselink.ddl-generation" value="create-tables"/>

        Show
        marina vatkina added a comment - The app is set not to drop tables on undeploy: <property name="eclipselink.ddl-generation" value="create-tables"/>
        Hide
        lidiam added a comment -

        verified in promoted build b41

        Show
        lidiam added a comment - verified in promoted build b41

          People

          • Assignee:
            Anissa Lam
            Reporter:
            lidiam
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Due:
              Created:
              Updated:
              Resolved: