GeeCON Prague 2014*
The moose likes EJB and other Java EE Technologies and the fly likes DataSource problem in Weblogic6 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "DataSource problem in Weblogic6" Watch "DataSource problem in Weblogic6" New topic
Author

DataSource problem in Weblogic6

karthikeyan balakrishnan
Greenhorn

Joined: Sep 21, 2001
Posts: 1
I have created a Connectionpool for Oracle and a dataSource for it,through the console.I confirmed the presence of these details in the config.xml.
But during runtime DATASOURCE NAME not found exception is arising.
The same setup is running well in Weblogic 5.1.
What might be the problem.
Suggest me some solutions
Ranjith R
Greenhorn

Joined: Sep 18, 2001
Posts: 22
Hi there..

Please check the following

is there any messages like Creation of data source failed ..
cominup while you start the default server? if yes, you need
to do some reconfigurations. Make sure that the path where
the Oracle jdbc driver resides is included in Your Classpath as well as the web logic class path.. and as a desporate
measure, you can edit the startWebLogic.cmd file to
include the path in the web logic class path.

it should help..
take care


Take care<BR>r@njith
Sreenivas Pitchuka
Greenhorn

Joined: Oct 06, 2001
Posts: 2
Hi,
In Weblogic 6.0 , there is different mechanism to get the connection pools.You have to specifically use the classes provided by the weblogic.
you have to use the package weblogic.db.jdbc.* and you have to look up as
Class.forName("weblogic.jdbc.pool.Driver").newInstance();
dbConnection = DriverManager.getConnection("jdbc:weblogic ool:tc4Pool");
I hope this will help u.
Have a nice time,
Sreenivas
------------------
Engineer R&D,
CMC Ltd,Hyd,India


Engineer R&D,<BR>CMC Ltd,Hyd,India
Rahul Mahindrakar
Ranch Hand

Joined: Jul 28, 2000
Posts: 1850
"bkarthikn"
The Java Ranch has thousands of visitors every week, many with surprisingly similar names. To avoid confusion we have a naming convention, described at http://www.javaranch.com/name.jsp . We require names to have at least two words, separated by a space, and strongly recommend that you use your full real name. Please log in with a new name which meets the requirements.
Secondly,
This is not the forum to post your queries on Weblogic. The appropriate forum is Weblogic Servers. Please post your queries in the appropriate forums.
Thanks.
Toyin Sogeke
Greenhorn

Joined: Oct 08, 2001
Posts: 14
Hi,
Check if your server was setup as a target
machine.
To do this, check your connection pool from
the console.

Originally posted by bkarthikn:
I have created a Connectionpool for Oracle and a dataSource for it,through the console.I confirmed the presence of these details in the config.xml.
But during runtime DATASOURCE NAME not found exception is arising.
The same setup is running well in Weblogic 5.1.
What might be the problem.
Suggest me some solutions


homeboy
Marcos Maia
Ranch Hand

Joined: Jan 06, 2001
Posts: 977
Hi,
rigth clic on the name of the server where you have the DataSource and go to "view jndi tree" or something like that, you should see the jndi name bind to the jndi tree from that server if you�re not able to see it there something is wrong,
also try to use:
// Put connection properties in to a hashtable.
Hashtable ht = new Hashtable();
ht.put(Context.INITIAL_CONTEXT_FACTORY,
"weblogic.jndi.WLInitialContextFactory");
ht.put(Context.PROVIDER_URL,
"here_server_url_ex_t3://localhost:7001");
// Get a context for the JNDI look up
ctx = new InitialContext(ht);
javax.sql.DataSource ds
= (javax.sql.DataSource) ctx.lookup ("jndi_name_goes_here");
conn = ds.getConnection();
regards.
 
GeeCON Prague 2014
 
subject: DataSource problem in Weblogic6