BC4J (ADF Business Components) logging and debugging – great blog from Sandra!

Lucas Jellema

The JHeadstart Blog just published a very good blog by my former colleague Sandra Muller: ADF Business Components Diagnostics. Previously, I knew to find a few remarks on this topic in the Trouble Shooting chapter in the JHeadstart Developer’s Guide, and it has saved my life more than once. I remember the time where an application that tested perfectly crashed i the production environment. The BC4J logging – which I learned how to turn on from the JHeadstart Developer’s guide – told us that BC4J was running in statefulll mode and attempted to ‘dehydrate’ (that’s a term I learned from Oracle BPEL Process Manager) the Application Module’s state to the database. In order to do so, it needed to create a couple of tables in the database and the Application’s Database User did not have the CREATE TABLE privilege in the Production Database!

In short, you can switch on BC4J tracing/logging/debugging and get a lot of information about e.g. the SQL being performed and the values of Bind Parameters used by BC4J. MOost useful for developers is probably the following:

During development, the easiest way is visiting your JDeveloper project properties and going to the “Runner” panel. Enter a string like this into the “Java Options” field there: -Djbo.debugoutput=console -Djbo.logging.show.function=true . When you run again, you’ll see the diagnostics printed out in the Embedded OC4J Log.

In the production environment:

In the production environment, an easy way is to include the file Diagnostic.properties in the classpath. It must be in package oracle.jbo.common and you can extract an example from [JDevHome]BC4Jlibbc4jct.jar.

For more details, see Sandra’s blog.

Next Post

Migration from MySQL to Oracle - using Oracle Migration Workbench

Facebook0TwitterLinkedinAll statistics on the visits to the posts in the AMIS Technology Weblog are gathered in a MySQL database that sist underneath WordPress. We would like to do some analysis on these statistics, for several reasons: to try out the Oracle Warehouse Builder 10gR2 Beta Paris Release we have currently […]