4

I try to add BoneCP to hibernate and have:

java.lang.ClassNotFoundException: org.hibernate.connection.ConnectionProvider

I couldn't find this interface in new hibernate packages and have 2 questions :

1) Could you share link or example how to manually configure BoneCP 0.7.1 with hibernate 4.1.*? (I only added connection.provider_class=com.jolbox.bonecp.provider.BoneCPConnectionProvider in hibernate.cfg.xml)

2) Someone tested BoneCP 0.8.0-alpha1? It's work good with new hibarnate, but has scary "alpha1" in version

Thank for your time.

pushistic
  • 3,406
  • 3
  • 21
  • 35

1 Answers1

5

1) The JVM cannot find the ConnectionProvider interface because it moved to a different package from Hibernate 3 to Hibernate 4, so you'll need to use BoneCP 0.8.0-alpha1.

2) So far it hasn't caused me any problems, but others should contribute their experience.

augusto callejas
  • 509
  • 3
  • 12
  • For Hibernate 4.3.x I had to get the source code and fix a broken import, and change the version of Hibernate specified. Hibernate repackaged the dang ConnectionProvider class again. – Teresa Carrigan Mar 19 '14 at 20:10