Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Getting Better Debugging Information  From OC4J

Panel

By default, some run time errors that you'll see when testing web apps in OC4J are not too helpful. You can coax OC4J into giving you more information about certain errors by making the following changes in global-web-application.xml:

Open ${ORACLE_HOME}/j2ee/home/config/global-web-application.xml with a text editor.

  1. Turn on "development" mode - in the <orion-web-app> section at the top of the file, change the "development" setting to true:
Code Block

<orion-web-app
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xsi:noNamespaceSchemaLocation="http://xmlns.oracle.com/oracleas/schema/orion-web-10_0.xsd"
  jsp-cache-directory="./persistence"
  servlet-webdir="/servlet"
  development="true"
  jsp-timeout="0"
  jsp-cache-tlds="standard"
  schema-major-version="10"
  schema-minor-version="0">

...


  1. Turn on debug mode. In the "jsp" servlet section, set a parameter debug_mode to true. The section should look like this:
    Code Block
    
    <servlet>
          <servlet-name>jsp</servlet-name>
          <servlet-class>oracle.jsp.runtimev2.JspServlet</servlet-class>
          <init-param>
            <param-name>debug_mode</param-name>
            <param-value>true</param-value>    
          </init-param>
          <load-on-startup>0</load-on-startup>
    </servlet>
    
    With these settings, you should get more meaningful messages in your browser when you run into certain errors (JSP syntax errors for example).

Add a Datasource

Wiki Markup
We need to add a datasource to our applications can pull data from the database.&nbsp; Edit \[j2ee.home\]/config/data-sources.xml to add a datasource.&nbsp; Here's an example of adding a MITSIS datasource:

...