geronimo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "viola.lu (JIRA)" <j...@apache.org>
Subject [jira] Created: (GERONIMO-5585) OpenJPA Fatal Error when access blog-jpa-eba
Date Wed, 08 Sep 2010 09:16:17 GMT
OpenJPA Fatal Error when access blog-jpa-eba
--------------------------------------------

                 Key: GERONIMO-5585
                 URL: https://issues.apache.org/jira/browse/GERONIMO-5585
             Project: Geronimo
          Issue Type: Bug
      Security Level: public (Regular issues)
          Components: Aries
    Affects Versions: 3.0
         Environment: OS:winxp
JDK:1.6.0_20
            Reporter: viola.lu
             Fix For: 3.0


1.Deloy blog-jpa-eba sample to server
2.Access http://localhost:8080/blog/ViewBlog, but got errors below:
<openjpa-2.0.1-r422266:989424 nonfatal general error> org.apache.openjpa.persistence.PersistenceException:
There were errors initializing your configuration: <openjpa-2.0.1-r422266:989424 fatal
user error> org.apache.openjpa.util.UserException: A connection could not be obtained for
driver class "null" and URL "null".  You may have specified an invalid URL.
	at org.apache.openjpa.jdbc.schema.DataSourceFactory.newConnectException(DataSourceFactory.java:261)
	at org.apache.openjpa.jdbc.schema.DataSourceFactory.installDBDictionary(DataSourceFactory.java:247)
	at org.apache.openjpa.jdbc.conf.JDBCConfigurationImpl.getConnectionFactory(JDBCConfigurationImpl.java:728)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:597)
	at org.apache.openjpa.lib.conf.ConfigurationImpl.instantiateAll(ConfigurationImpl.java:294)
	at org.apache.openjpa.conf.OpenJPAConfigurationImpl.instantiateAll(OpenJPAConfigurationImpl.java:1602)
	at org.apache.openjpa.kernel.AbstractBrokerFactory.makeReadOnly(AbstractBrokerFactory.java:647)
	at org.apache.openjpa.kernel.AbstractBrokerFactory.newBroker(AbstractBrokerFactory.java:206)
	at org.apache.openjpa.kernel.DelegatingBrokerFactory.newBroker(DelegatingBrokerFactory.java:156)
	at org.apache.openjpa.persistence.EntityManagerFactoryImpl.createEntityManager(EntityManagerFactoryImpl.java:227)
	at org.apache.openjpa.persistence.EntityManagerFactoryImpl.createEntityManager(EntityManagerFactoryImpl.java:60)
	at org.apache.aries.jpa.container.impl.CountingEntityManagerFactory.createEntityManager(CountingEntityManagerFactory.java:70)
	at org.apache.aries.jpa.container.context.transaction.impl.JTAPersistenceContextRegistry.getCurrentPersistenceContext(JTAPersistenceContextRegistry.java:131)
	at org.apache.aries.jpa.container.context.transaction.impl.JTAEntityManager.getPersistenceContext(JTAEntityManager.java:86)
	at org.apache.aries.jpa.container.context.transaction.impl.JTAEntityManager.createQuery(JTAEntityManager.java:163)
	at org.apache.aries.samples.blog.persistence.jpa.BlogPersistenceServiceImpl.getNoOfBlogEntries(BlogPersistenceServiceImpl.java:119)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:597)
	at org.apache.aries.blueprint.proxy.Collaborator$1.invoke(Collaborator.java:66)
	at org.apache.aries.blueprint.proxy.Collaborator.invoke(Collaborator.java:151)
	at org.apache.aries.samples.blog.persistence.jpa.$BlogPersistenceServiceImpl25233972.getNoOfBlogEntries(Unknown
Source)
	at org.apache.aries.samples.blog.api.persistence.BlogPersistenceService$$EnhancerByCGLIB$$b610020c.getNoOfBlogEntries(<generated>)
	at org.apache.aries.samples.blog.biz.BlogEntryManagerImpl.getNoOfPosts(BlogEntryManagerImpl.java:89)
	at org.apache.aries.samples.blog.biz.BloggingServiceImpl.getNoOfEntries(BloggingServiceImpl.java:98)
	at org.apache.aries.samples.blog.api.BloggingService$$EnhancerByCGLIB$$b334d7e9.getNoOfEntries(<generated>)
	at org.apache.aries.samples.blog.web.ViewBlog.doGet(ViewBlog.java:66)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:575)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:668)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:243)
	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:201)
	at org.apache.geronimo.tomcat.GeronimoStandardContext$SystemMethodValve.invoke(GeronimoStandardContext.java:719)
	at org.apache.geronimo.tomcat.valve.GeronimoBeforeAfterValve.invoke(GeronimoBeforeAfterValve.java:47)
	at org.apache.geronimo.tomcat.valve.ProtectedTargetValve.invoke(ProtectedTargetValve.java:53)
	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:146)
	at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:108)
	at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:402)
	at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:254)
	at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:267)
	at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:245)
	at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:260)
	at org.apache.geronimo.pool.ThreadPool$1.run(ThreadPool.java:241)
	at org.apache.geronimo.pool.ThreadPool$ContextClassLoaderRunnable.run(ThreadPool.java:371)
	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
	at java.lang.Thread.run(Thread.java:619)
Caused by: java.lang.RuntimeException: The DataSource osgi:service/javax.sql.DataSource/(osgi.jndi.service.name=jdbc/blogdb)
could not be used.
	at org.apache.aries.jpa.container.unit.impl.DelayedLookupDataSource.getDs(DelayedLookupDataSource.java:47)
	at org.apache.aries.jpa.container.unit.impl.DelayedLookupDataSource.getConnection(DelayedLookupDataSource.java:60)
	at org.apache.openjpa.lib.jdbc.DelegatingDataSource.getConnection(DelegatingDataSource.java:137)
	at org.apache.openjpa.lib.jdbc.DecoratingDataSource.getConnection(DecoratingDataSource.java:112)
	at org.apache.openjpa.jdbc.schema.DataSourceFactory.installDBDictionary(DataSourceFactory.java:239)
	... 51 more
Caused by: javax.naming.NameNotFoundException: osgi:service/javax.sql.DataSource/"(osgi.jndi.service.name=jdbc/blogdb)"
	at org.apache.aries.jndi.url.ServiceRegistryContext.lookup(ServiceRegistryContext.java:110)
	at org.apache.aries.jndi.url.ServiceRegistryContext.lookup(ServiceRegistryContext.java:141)
	at org.apache.aries.jndi.DelegateContext.lookup(DelegateContext.java:148)
	at javax.naming.InitialContext.lookup(InitialContext.java:392)
	at org.apache.aries.jpa.container.unit.impl.DelayedLookupDataSource.getDs(DelayedLookupDataSource.java:43)
	... 55 more

<openjpa-2.0.1-r422266:989424 fatal user error> org.apache.openjpa.util.UserException:
A connection could not be obtained for driver class "null" and URL "null".  You may have specified
an invalid URL.
	at org.apache.openjpa.jdbc.schema.DataSourceFactory.newConnectException(DataSourceFactory.java:261)
	at org.apache.openjpa.jdbc.schema.DataSourceFactory.installDBDictionary(DataSourceFactory.java:247)
	at org.apache.openjpa.jdbc.conf.JDBCConfigurationImpl.getConnectionFactory2(JDBCConfigurationImpl.java:802)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:597)
	at org.apache.openjpa.lib.conf.ConfigurationImpl.instantiateAll(ConfigurationImpl.java:294)
	at org.apache.openjpa.conf.OpenJPAConfigurationImpl.instantiateAll(OpenJPAConfigurationImpl.java:1602)
	at org.apache.openjpa.kernel.AbstractBrokerFactory.makeReadOnly(AbstractBrokerFactory.java:647)
	at org.apache.openjpa.kernel.AbstractBrokerFactory.newBroker(AbstractBrokerFactory.java:206)
	at org.apache.openjpa.kernel.DelegatingBrokerFactory.newBroker(DelegatingBrokerFactory.java:156)
	at org.apache.openjpa.persistence.EntityManagerFactoryImpl.createEntityManager(EntityManagerFactoryImpl.java:227)
	at org.apache.openjpa.persistence.EntityManagerFactoryImpl.createEntityManager(EntityManagerFactoryImpl.java:60)
	at org.apache.aries.jpa.container.impl.CountingEntityManagerFactory.createEntityManager(CountingEntityManagerFactory.java:70)
	at org.apache.aries.jpa.container.context.transaction.impl.JTAPersistenceContextRegistry.getCurrentPersistenceContext(JTAPersistenceContextRegistry.java:131)
	at org.apache.aries.jpa.container.context.transaction.impl.JTAEntityManager.getPersistenceContext(JTAEntityManager.java:86)
	at org.apache.aries.jpa.container.context.transaction.impl.JTAEntityManager.createQuery(JTAEntityManager.java:163)
	at org.apache.aries.samples.blog.persistence.jpa.BlogPersistenceServiceImpl.getNoOfBlogEntries(BlogPersistenceServiceImpl.java:119)
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	at java.lang.reflect.Method.invoke(Method.java:597)
	at org.apache.aries.blueprint.proxy.Collaborator$1.invoke(Collaborator.java:66)
	at org.apache.aries.blueprint.proxy.Collaborator.invoke(Collaborator.java:151)
	at org.apache.aries.samples.blog.persistence.jpa.$BlogPersistenceServiceImpl25233972.getNoOfBlogEntries(Unknown
Source)
	at org.apache.aries.samples.blog.api.persistence.BlogPersistenceService$$EnhancerByCGLIB$$b610020c.getNoOfBlogEntries(<generated>)
	at org.apache.aries.samples.blog.biz.BlogEntryManagerImpl.getNoOfPosts(BlogEntryManagerImpl.java:89)
	at org.apache.aries.samples.blog.biz.BloggingServiceImpl.getNoOfEntries(BloggingServiceImpl.java:98)
	at org.apache.aries.samples.blog.api.BloggingService$$EnhancerByCGLIB$$b334d7e9.getNoOfEntries(<generated>)
	at org.apache.aries.samples.blog.web.ViewBlog.doGet(ViewBlog.java:66)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:575)
	at javax.servlet.http.HttpServlet.service(HttpServlet.java:668)
	at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:303)
	at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:208)
	at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:243)
	at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:201)
	at org.apache.geronimo.tomcat.GeronimoStandardContext$SystemMethodValve.invoke(GeronimoStandardContext.java:719)
	at org.apache.geronimo.tomcat.valve.GeronimoBeforeAfterValve.invoke(GeronimoBeforeAfterValve.java:47)
	at org.apache.geronimo.tomcat.valve.ProtectedTargetValve.invoke(ProtectedTargetValve.java:53)
	at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:146)
	at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:108)
	at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
	at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:402)
	at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:254)
	at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:267)
	at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:245)
	at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:260)
	at org.apache.geronimo.pool.ThreadPool$1.run(ThreadPool.java:241)
	at org.apache.geronimo.pool.ThreadPool$ContextClassLoaderRunnable.run(ThreadPool.java:371)
	at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
	at java.lang.Thread.run(Thread.java:619)
Caused by: java.lang.RuntimeException: The DataSource osgi:service/javax.sql.DataSource/(osgi.jndi.service.name=jdbc/blogdbnojta)
could not be used.
	at org.apache.aries.jpa.container.unit.impl.DelayedLookupDataSource.getDs(DelayedLookupDataSource.java:47)
	at org.apache.aries.jpa.container.unit.impl.DelayedLookupDataSource.getConnection(DelayedLookupDataSource.java:60)
	at org.apache.openjpa.lib.jdbc.DelegatingDataSource.getConnection(DelegatingDataSource.java:137)
	at org.apache.openjpa.lib.jdbc.DecoratingDataSource.getConnection(DecoratingDataSource.java:112)
	at org.apache.openjpa.jdbc.schema.DataSourceFactory.installDBDictionary(DataSourceFactory.java:242)
	... 51 more
Caused by: javax.naming.NameNotFoundException: osgi:service/javax.sql.DataSource/"(osgi.jndi.service.name=jdbc/blogdbnojta)"
	at org.apache.aries.jndi.url.ServiceRegistryContext.lookup(ServiceRegistryContext.java:110)
	at org.apache.aries.jndi.url.ServiceRegistryContext.lookup(ServiceRegistryContext.java:141)
	at org.apache.aries.jndi.DelegateContext.lookup(DelegateContext.java:148)
	at javax.naming.InitialContext.lookup(InitialContext.java:392)
	at org.apache.aries.jpa.container.unit.impl.DelayedLookupDataSource.getDs(DelayedLookupDataSource.java:43)
	... 55 more

	org.apache.openjpa.kernel.AbstractBrokerFactory.newBroker(AbstractBrokerFactory.java:221)
	org.apache.openjpa.kernel.DelegatingBrokerFactory.newBroker(DelegatingBrokerFactory.java:156)
	org.apache.openjpa.persistence.EntityManagerFactoryImpl.createEntityManager(EntityManagerFactoryImpl.java:227)
	org.apache.openjpa.persistence.EntityManagerFactoryImpl.createEntityManager(EntityManagerFactoryImpl.java:60)
	org.apache.aries.jpa.container.impl.CountingEntityManagerFactory.createEntityManager(CountingEntityManagerFactory.java:70)
	org.apache.aries.jpa.container.context.transaction.impl.JTAPersistenceContextRegistry.getCurrentPersistenceContext(JTAPersistenceContextRegistry.java:131)
	org.apache.aries.jpa.container.context.transaction.impl.JTAEntityManager.getPersistenceContext(JTAEntityManager.java:86)
	org.apache.aries.jpa.container.context.transaction.impl.JTAEntityManager.createQuery(JTAEntityManager.java:163)
	org.apache.aries.samples.blog.persistence.jpa.BlogPersistenceServiceImpl.getNoOfBlogEntries(BlogPersistenceServiceImpl.java:119)
	sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
	sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
	sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
	java.lang.reflect.Method.invoke(Method.java:597)
	org.apache.aries.blueprint.proxy.Collaborator$1.invoke(Collaborator.java:66)
	org.apache.aries.blueprint.proxy.Collaborator.invoke(Collaborator.java:151)
	org.apache.aries.samples.blog.persistence.jpa.$BlogPersistenceServiceImpl25233972.getNoOfBlogEntries(Unknown
Source)
	org.apache.aries.samples.blog.api.persistence.BlogPersistenceService$$EnhancerByCGLIB$$b610020c.getNoOfBlogEntries(<generated>)
	org.apache.aries.samples.blog.biz.BlogEntryManagerImpl.getNoOfPosts(BlogEntryManagerImpl.java:89)
	org.apache.aries.samples.blog.biz.BloggingServiceImpl.getNoOfEntries(BloggingServiceImpl.java:98)
	org.apache.aries.samples.blog.api.BloggingService$$EnhancerByCGLIB$$b334d7e9.getNoOfEntries(<generated>)
	org.apache.aries.samples.blog.web.ViewBlog.doGet(ViewBlog.java:66)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:575)
	javax.servlet.http.HttpServlet.service(HttpServlet.java:668)
root cause

but blog-jdbc-eba works well without errors.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message