[jbosstools-issues] [JBoss JIRA] (JBIDE-11659) Could not create JPA based configuration when hibernate configuration is referenced in persistence.xml as absolute path
Dmitry Geraskov (JIRA)
jira-events at lists.jboss.org
Thu Apr 26 06:12:18 EDT 2012
[ https://issues.jboss.org/browse/JBIDE-11659?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Dmitry Geraskov resolved JBIDE-11659.
-------------------------------------
Resolution: Rejected
Not a bug. I checked the code in simple java project:
new Ejb3Configuration().configure("persUnitName", new Properties());
where persistence.xml has absolute link to hibernate.cfg.xml file and it throws the same exception. So the behaviour is as expected.
> Could not create JPA based configuration when hibernate configuration is referenced in persistence.xml as absolute path
> -----------------------------------------------------------------------------------------------------------------------
>
> Key: JBIDE-11659
> URL: https://issues.jboss.org/browse/JBIDE-11659
> Project: Tools (JBoss Tools)
> Issue Type: Bug
> Components: hibernate
> Affects Versions: 3.3.0.Beta3
> Environment: JBT 3.3.0.beta3-trunk, L64
> Reporter: Jiri Peterka
> Assignee: Dmitry Geraskov
> Priority: Critical
> Fix For: 3.3.0.Beta3
>
> Attachments: jpa-hb-conf1.png, jpa-hb-conf2.png, jpa-hb-conf3.png
>
>
> org.hibernate.console.HibernateConsoleRuntimeException: Could not create JPA based Configuration
> at org.hibernate.console.ConfigurationFactory.buildJPAConfiguration(ConfigurationFactory.java:245)
> at org.hibernate.console.ConfigurationFactory.buildConfiguration(ConfigurationFactory.java:174)
> at org.hibernate.console.ConfigurationFactory.createConfiguration(ConfigurationFactory.java:96)
> at org.hibernate.console.ConsoleConfiguration$3.execute(ConsoleConfiguration.java:240)
> at org.hibernate.console.execution.DefaultExecutionContext.execute(DefaultExecutionContext.java:63)
> at org.hibernate.console.ConsoleConfiguration.execute(ConsoleConfiguration.java:107)
> at org.hibernate.console.ConsoleConfiguration.buildWith(ConsoleConfiguration.java:237)
> at org.hibernate.console.ConsoleConfiguration.build(ConsoleConfiguration.java:188)
> at org.hibernate.eclipse.console.workbench.ConsoleConfigurationWorkbenchAdapter.getChildren(ConsoleConfigurationWorkbenchAdapter.java:39)
> at org.hibernate.eclipse.console.workbench.BasicWorkbenchAdapter.getChildren(BasicWorkbenchAdapter.java:100)
> at org.hibernate.eclipse.console.workbench.BasicWorkbenchAdapter.fetchDeferredChildren(BasicWorkbenchAdapter.java:106)
> at org.eclipse.ui.progress.DeferredTreeContentManager$1.run(DeferredTreeContentManager.java:235)
> at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)
> Caused by: java.lang.reflect.InvocationTargetException
> 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.hibernate.console.ConfigurationFactory.buildJPAConfiguration(ConfigurationFactory.java:231)
> ... 12 more
> Caused by: javax.persistence.PersistenceException: [PersistenceUnit: unifieddb-jpa] Unable to configure EntityManagerFactory
> at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:376)
> ... 17 more
> Caused by: org.hibernate.HibernateException: /home/jpeterka/workspace/prj/unifieddb/hibernatelib/cfg/hibernate-localhost.cfg.xml not found
> at org.hibernate.util.ConfigHelper.getResourceAsStream(ConfigHelper.java:170)
> at org.hibernate.cfg.Configuration.getConfigurationInputStream(Configuration.java:1497)
> at org.hibernate.cfg.Configuration.configure(Configuration.java:1519)
> at org.hibernate.cfg.AnnotationConfiguration.configure(AnnotationConfiguration.java:1194)
> at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:985)
> at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:280)
> at org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configuration.java:364)
> ... 17 more
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the jbosstools-issues
mailing list