-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 
Author Message
 Post subject: Configuring Hibernate with Proxool connection pool in JBoss
PostPosted: Thu Mar 29, 2007 11:34 am 
Newbie

Joined: Wed Dec 06, 2006 4:04 pm
Posts: 8
Location: New Hampshire
Hi,
I am setting up Hibernate programmatically, so that I can supply a secure password to the database in the code, rather than have it hardcoded in a file.

I am attempting to add connection pooling (everything is working fine without it for our demos) . I have read the how-tos in the wiki, searched the web and documents, and from what I can tell, the following code *should* be working.

Code:
         Configuration cfg = new Configuration();
         cfg.setProperty("hibernate.proxool.properties", path + "/conf/pool.properties");
          cfg.setProperty("hibernate.proxool.pool_alias", "jdbc-0");
          cfg.setProperty("hibernate.connection.password", pwdClear);
          cfg.setProperty("hibernate.connection.dialect", dialect);
          cfg.setProperty("hibernate.show_sql", showsql);
          cfg.setProperty("hibernate.order_updates", "true");
         
          //load the entity hbm file
          path += "/conf/";
          File f = new File(path + db + ".hbm.xml");
          cfg.addFile(f);
         
          //get the sessionFactory
          sessionFactory = cfg.buildSessionFactory();

However, on JBoss startup, I am still getting the message:
Code:
11:31:23,421 INFO  [DriverManagerConnectionProvider] Using Hibernate built-in connection pool (not for production use!).


So, clearly I have something configured incorrectly, but I can't figure it out. Also, would Apache dbcp be a better choice than proxool?
Thanks,
Jreifsnyder

Hibernate version: 3.2.1 GA

Name and version of the database you are using: Oracle 10g

JBoss version: 4.0.5


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 1 post ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.