Howto deploy a ADFBC app developed to Tomcat6.0.14 and MySQL 5.0

Posted: April 22, 2008 in ADFBC, HowTo, Java, MySQL, Oracle, Tips, WebProgramming
Tags: , , , ,

Source: OTN JDeveloper Forum


Just successfully deployed a JSF/ADF-BC4J app developed in Jdev to Tomcat-6.0.14 and MySQL 5.0

Thought I would share since i could not find anything out there that gave me the steps for this configuration combo.

1. install MySQL 5.0 database with some tables.
2. install Tomcat-6.0.14 ( probably any 6.x build would be same
3. Application Modules developed in Jdev are currently configured to run on MySQL (SQL92 flavor / Java type mappings)
4. This is for ADF-BC4J only. TopLink would require add’l steps, though I assume the only difference would be add’l jar files

I did all development in Jdev using the internal OC4J and a local MySQL before deploying to Tomcat.

1. copy following jars from <JDEV_INSTALL> to <TOMCAT_HOME>\lib\
(Note that ‘Tools -> ADF Runtime Installer’ does not work for Tomcat 6.x, so this has to be manual)


2. copy <JDEV_INSTALL>\BC4J\redist\webapp.war to <TOMCAT_HOME>\webapps\webapp.war

3. in your application’s webroot, create a META-INF folder containing a single file, named ‘context.xml’, with the following (enter your appropriate values as usual):

<?xml version=”1.0″ encoding=”UTF-8″?>

4. in all Application Modules, set the Configuration to use a ‘JDBC Datasource’ with the name set to the named datasource in the context.xml created above, e.g.: ‘java:comp/env/jdbc/MySqlDS’

5. create a deployment profile with ‘Platform -> target connection’ set to the Tomcat instance (need to create an entry in ‘Connections -> Application Server’ for it to show up) make sure to include the correct mysql-connector.jar in the ‘WEB-INF/lib’ contributors.
Right-click -> Deploy to your tomcat

6. Make sure MySQL is on and fire up Tomcat, and youre set.

Hope it helps

  1. grorsdeep says:

    Hello my friends 🙂

  2. Archean says:

    Somehow i missed the point. Probably lost in translation 🙂 Anyway … nice blog to visit.

    cheers, Archean.

  3. oldlight says:

    Thank you, Archean, for encouraging me…

    Hope you find something interest…

    Cheers, Minh Tran

  4. faizal says:

    how if i’m using oracle xe database, deploy on tomcat installed in my laptop.tq

  5. oldlight says:

    Hi Faizal,

    You need to package Oracle JDBC Thin driver with your war or making it work within Tomcat as normal.

    Happy programming.

    Minh Tran

  6. Isaac says:

    I’ve managed to run ADF app over tomcat 6 . I’ve take advantage on this great video . But I have some problmes when I try to use dvt components from ADF 11g Does any body have the solution to this? also I was tried adding all libraries included here but even that is not a solution.

  7. you’re truly a just right webmaster. The web site loading pace is amazing. It sort of feels that you’re doing
    any unique trick. Moreover, The contents are masterpiece.
    you have done a fantastic job in this matter!

  8. Florida says:

    I really love your blog.. Excellent colors & theme. Did you develop this website yourself?
    Please reply back as I’m trying to create my own website
    and want to learn where you got this from or exactly what the theme is called.

  9. Sean says:

    This web page can be a walk-

    by means of for all the info you

    wished about this and didn’t know who to ask.
    Glimpse right here, and also you’ll

    undoubtedly uncover it.1
    There is noticeably a bundle to learn about this. I assume you

    certain nice factors in features also.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s