Win a copy of Practical SVG this week in the HTML/CSS/JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Need Help regarding OpenEJB's error

Leonardo Carreira
Ranch Hand
Posts: 494
Eclipse IDE Java Postgres Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello friends..

i was trying to do practice about OpenEJB which use MySQL as database server..
but i got error..
i am confused for the strange error..

here is my Simple Entity Bean :

and here is my persistence.xml :

and here is the message error :

ERRRRRRRRRRRRORThe bean encountered a non-application exception; nested exception is:
<openjpa-1.2.1-r752877:753278 nonfatal general error> org.apache.openjpa.persistence.PersistenceException: There were errors initializing your configuration: <openjpa-1.2.1-r752877:753278 fatal user error> org.apache.openjpa.util.UserException: A connection could not be obtained for driver class "com.mysql.jdbc.Driver" and URL "jdbc:mysql://". You may have specified an invalid URL.
at org.apache.openjpa.jdbc.schema.DataSourceFactory.newConnectException(
at org.apache.openjpa.jdbc.schema.DataSourceFactory.installDBDictionary(
at org.apache.openjpa.jdbc.conf.JDBCConfigurationImpl.getConnectionFactory(
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)

Caused by: java.lang.UnsupportedOperationException: Not supported by BasicDataSource
at org.apache.commons.dbcp.BasicDataSource.getConnection(
at org.apache.openjpa.lib.jdbc.DelegatingDataSource.getConnection(
at org.apache.openjpa.lib.jdbc.DecoratingDataSource.getConnection(
at org.apache.openjpa.jdbc.schema.DataSourceFactory.installDBDictionary(
... 39 more

when i tried to persist data i got the error..

Please give me any suggestion..

Thanks in advance sir...
look! it's a bird! it's a plane! It's .... a teeny tiny ad
the new thread boost feature: great for the advertiser and smooth for the coderanch user
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!