• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

No connection properties specified

 
Daniel Winz
Greenhorn
Posts: 8
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I get a "No connection properties specified .." warning when I execute the following line of code:



Stacktrace:

2010-08-24 11:54:21,586 DEBUG [org.hibernate.ejb.Ejb3Configuration] (http-127.0.0.1-8080-1) Look up for persistence unit: Employee-Details
2010-08-24 11:54:21,661 DEBUG [org.hibernate.ejb.util.NamingHelper] (http-127.0.0.1-8080-1) Not Ejb3Configuration to JNDI, no JNDI name configured
2010-08-24 11:54:21,662 DEBUG [org.hibernate.cfg.Configuration] (http-127.0.0.1-8080-1) Preparing to build session factory with filters : {}
2010-08-24 11:54:21,662 DEBUG [org.hibernate.cfg.AnnotationConfiguration] (http-127.0.0.1-8080-1) Execute first pass mapping processing
2010-08-24 11:54:21,663 DEBUG [org.hibernate.cfg.AnnotationConfiguration] (http-127.0.0.1-8080-1) Process hbm files
2010-08-24 11:54:21,663 DEBUG [org.hibernate.cfg.AnnotationConfiguration] (http-127.0.0.1-8080-1) Process annotated classes
2010-08-24 11:54:21,663 DEBUG [org.hibernate.cfg.AnnotationConfiguration] (http-127.0.0.1-8080-1) processing fk mappings (*ToOne and JoinedSubclass)
2010-08-24 11:54:21,663 DEBUG [org.hibernate.cfg.Configuration] (http-127.0.0.1-8080-1) processing extends queue
2010-08-24 11:54:21,664 DEBUG [org.hibernate.cfg.Configuration] (http-127.0.0.1-8080-1) processing collection mappings
2010-08-24 11:54:21,664 DEBUG [org.hibernate.cfg.Configuration] (http-127.0.0.1-8080-1) processing native query and ResultSetMapping mappings
2010-08-24 11:54:21,664 DEBUG [org.hibernate.cfg.Configuration] (http-127.0.0.1-8080-1) processing association property references
2010-08-24 11:54:21,664 DEBUG [org.hibernate.cfg.Configuration] (http-127.0.0.1-8080-1) processing foreign key constraints
2010-08-24 11:54:21,668 WARN [org.hibernate.connection.UserSuppliedConnectionProvider] (http-127.0.0.1-8080-1) No connection properties specified - the user must supply JDBC connections


The persistence unit "Employee-Details" I have set in my persistence.xml file. The unit was started without error before (Log: Starting persistence unit persistence.unit:unitName=#Employee-Details).

content of my persistence.xml:



Content of my data source file "mysql-ds.xml" at jboss folder "server/default/deploy":



According to some articles that I have found at the web, because I use JPA, I use a persistence.xml file instead of a hibernate.cnf.xml file to configure the connection.

Why is hibernate not satisfied with the JDBC connection that I have provided? Is something wrong with my configuration?
 
David Newton
Author
Rancher
Posts: 12617
IntelliJ IDE Ruby
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please UseCodeTags when posting code or configuration. Unformatted code and configuration is unnecessarily difficult to read. You can edit your post by using the button.
 
Daniel Winz
Greenhorn
Posts: 8
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
After adding javax.persistence properties to my persistence.xml the warning ("No connection properties specified ..") doesn't appear anymore.

persistence.xml:



But is this a proper solution? I don't realy believe.
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic