23.8.07

Missing ODBC connection strings?

Here is a cool site for instructing how to define OCBC connection strings for different data sources:

http://www.connectionstrings.com

Oracle BAM 10.1.3 External Data Source and Access DB

When preparing for a BAM demo I needed to show information from BAM external data source (MS Access sample database Northwind). Manual only described how to configure Oracle Database, but didn't give a sample how to configure Access DB.

After a while of tweaking out the configuration I got Access DB set up as an external data source. The key is to define following values as a sample:

Driver: Microsoft Access Driver (*.mdb)

Connection string: Dbq=d:\demodb\Nwind.mdb;

26.7.07

OpenCMS 7.0.1 and Jetty

Finally had some time to play around with OpenCMS again. This time trying to get OpenCMS running on Jetty servlet engine.

Installing on Jetty is pretty straight forward. Just downloaded the OpenCMS zip file, unpacked the war file under $JETTY_HOME/webapps/opencms and extracted the war file with jar xvf opencms.war.

After bouncing the Jetty engine and trying to startup the OpenCMS setup screen I got an exception:

2007-07-25 19:21:06.019::WARN:  EXCEPTION
javax.servlet.ServletException: Critical error during OpenCms initialization: The OpenCms setup wizard is still enabled.
        at org.opencms.main.OpenCmsServlet.init(OpenCmsServlet.java:262)
        at org.mortbay.jetty.servlet.ServletHolder.initServlet(ServletHolder.java:400)
...

This actually caused the whole Jetty engine to misbehave since I could not any more use other applications on the Servlet engine. And naturally the OpenCMS could not be started at all.

Downloaded the source code from read-only CVS repository and looked at the problem. This seems to be the same issue as with BEA WL9, so I needed to uncomment the "OnErrorExitWithoutException" parameter setting under $JETTY_HOME/webapps/opencms/WEB-INF/web.xml.

After uncommenting the servlet parameter and bouncing the Jetty engine I was able to startup OpenCMS setup screen successfully.

25.5.07

Running Liferay on OracleAS 10.1.2

Liferay portal installation on OracleAS 10.1.2 doesn't necessarily follow the installation instructions mentioned in the liferay.com site.

Here are the rough steps to configure Liferay 3.0.6 on OracleAS 10.1.2. J2EE and Web Cache installation.

1. Download the Liferay EAR file. Follow the instructions to update the config files mentioned in the Liferay home pages.

2. Liferay uses different XML parser that is by default configured in OracleAS 10.1.2. To make the container use Xerces parser you need to set up parameters for starting up the container. Make sure you change the "/home/oracle/xerces/xerces-2_9_0" path to reflect your environment.

Edit opmn.xml:
         <ias-component id="OC4J">
            <process-type id="home" module-id="OC4J" status="enabled">
               <module-data>
                  <category id="start-parameters">
                     <data id="java-options" value="-server -Doc4j.userThreads=true -Djava.security.policy=$ORACLE_HOME/j2ee/home/config/java2.policy -Djava.awt.headless=true -Xbootclasspath/a:/home/oracle/xerces/xerces-2_9_0/xml-apis.jar -Dorg.xml.sax.driver=org.apache.xerces.parsers.SAXParser -Djavax.xml.parsers.SAXParserFactory=org.apache.xerces.jaxp.SAXParserFactoryImpl -Djavax.xml.parsers.TransformerFactory=org.apache.xalan.processor.TransformerFactoryImpl -Djavax.xml.transform.TransformerFactory=org.apache.xalan.processor.TransformerFactoryImpl"/>
                  </category>

After editing the opmn.xml manually, validate the opmn.xml with command:

$ORACLE_HOME/opmn/bin/opmnctl validate

Reload the changes in opmn with command

$ORACLE_HOME/opmn/bin/opmnctl reload

Update the dcm repository with command:

$ORACLE_HOME/dcm/bin/dcmctl updateconfig

3. Configure OC4J global-web-application.xml:

To avoid this exception:

OracleJSP: oracle.jsp.parse.JspParseException: /html/themes/brochure/templates/init.jsp: Line # 27, <theme:defineObjects />
Error: Tag attempted to define a bean which already exists: themeDisplay

Resolve: Add following in $ORACLE_HOME/j2ee/home/config/global-web-application.xml

<init-param>
  <param-name>req_time_introspection</param-name>
  <param-value>true</param-value>
</init-param>

4. Copy following jar files to $ORACLE_HOME/j2ee/home/applib

liferay-jdbc.jar
xercesImpl.jar
xml-apis.jar
xmlParserAPIs.jar

The link to Liferay's JDBC driver can be found from Liferay.com. Xerces parser can be downloaded from Apache.org site.

5. Bounce the OC4J container

6. Deploy Liferay EAR file using OracleAS Enterprise Manager.

Test and make sure everything works. If you have any additions, pls let me know and I'll update the notes here.

Looks like a new version of Liferay 4.x.x just popped out. You might give a shot and try above installation instructions with the latest release as well.