Swing connection to database using EJB deployed on JBOSS
Sharad Rangaswamy
Greenhorn
Joined: Nov 03, 2004
Posts: 1
posted
0
Hi,
My question though it pertains to a Swing issue is actually JBoss related and hence am posting it here
Brief Problem Statement: Web portion of an application connects to database A while Swing portion connects to database B. How to make Swing portion connect to database A?
Technologies Used : JBoss, Eclipse, SQLServer 2000, Java Swing
I have an application that has a web component and a Swing component. To be clearer I will quickly run through a typical way to access the Swing part of the application
1. Access the web URL 2. Logon 3. Click a link called 'Business Order Application'.
That link opens up a logon dialog box (Swing based) which authenticates the user against the SAME database that step 1 above does.
Now, for testing a new enhancement to the system, I made the web part of the application point to a 'test' DB by modifying the mssql-ds.xml file in the jboss /server/default/deploy directory. Things worked fine.
But when I now access the Swing application, it is still accessing the 'prod' database. So it is obviously not taking the mssql-ds.xml change I made (although the web app does).
Question is, how to make the Swing access the 'test' DB too?
In step 3 above, a .JNLP XML file is called. That XML file points to the following JAR files
The last JAR file is my creation. I have built and rebuilt that file to solve the problem but without success. I am also pasting below the entire JNLP file
----------------------------------------------------------------------------------------------------------------------- <?xml version="1.0" encoding="utf-8"?> <!-- JNLP File for SwingSet2 Demo Application MODIFIED --> <jnlp spec="1.0+" codebase="$$codebase" href="orderApp.jnlp"> <information> <title>Order Management Application</title> <vendor>APA, Inc.</vendor> <homepage href="../index.jsp"/> <description>Order Management Application</description> <description kind="short">A webstart application to administer business office orders.</description> </information>