Uploaded image for project: 'Cocoon'
  1. Cocoon
  2. COCOON-1467

ESQL exception handling problem

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Minor
    • Resolution: Unresolved
    • 2.1.6
    • None
    • Blocks: Databases
    • None
    • Operating System: Windows XP
      Platform: PC
    • 33922
    • Patch available

    Description

      the esql logicsheet
      /src/blocks/databases/java/org/apache/cocoon/components/language/markup/xsp/java/esql.xsl
      has an exception handling block that catches an exception but then just logs the
      error and does nothing. This is a problem as I need the exception to come out.

      This is inside the esql:connection template. Here's svn diff for my patch:

      C:\local>svn diff
      src\blocks\databases\java\org\apache\cocoon\components\language\markup\xsp\java\esql.xsl
      Index:
      src/blocks/databases/java/org/apache/cocoon/components/language/markup/xsp/java/esql.xsl
      ===================================================================
      ---
      src/blocks/databases/java/org/apache/cocoon/components/language/markup/xsp/java/esql.xsl
         (revision 46070)
      +++
      src/blocks/databases/java/org/apache/cocoon/components/language/markup/xsp/java/esql.xsl
         (working copy)
      @@ -306,7 +306,7 @@
             <xsl:apply-templates/>
           }
           catch (SQLException _esql_exception_<xsl:value-of select="generate-id(.)"/>
      ) {
      - getLogger().error("",_esql_exception_<xsl:value-of select="generate-id(.)
      "/>);
      + throw new RuntimeException("Error connecting to db to execute query: " +
      _esql_exception_<xsl:value-of select="generate-id(.)"/>);
           }
           finally {
             try {

      Attachments

        Activity

          People

            Unassigned Unassigned
            oliver.powell@tvnz.co.nz Oliver Powell
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated: