[hibernate-issues] [Hibernate-JIRA] Commented: (HBX-1032) HibernateConsoleRuntimeException: "Could not load JPA Configuration" for JavaSE JPA project
Antony Stubbs (JIRA)
noreply at atlassian.com
Fri May 1 01:27:18 EDT 2009
[ http://opensource.atlassian.com/projects/hibernate/browse/HBX-1032?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=33069#action_33069 ]
Antony Stubbs commented on HBX-1032:
------------------------------------
yes- but that was just me suggesting an error message that should be shown - i don't think i actually spelt it like that :) mind you, it was a while ago :)
> HibernateConsoleRuntimeException: "Could not load JPA Configuration" for JavaSE JPA project
> -------------------------------------------------------------------------------------------
>
> Key: HBX-1032
> URL: http://opensource.atlassian.com/projects/hibernate/browse/HBX-1032
> Project: Hibernate Tools
> Issue Type: Bug
> Affects Versions: 3.2.0.GA
> Environment: Eclipse 3.3.1.1, HibernateTools 3.2.0 GA, JDK 1.6.0_03
> Reporter: Donatas Ciuksys
> Priority: Blocker
> Attachments: ProjectStructure.jpg
>
>
> I have Java SE (not EE) project in Eclipse with standard structure like:
> /src
> /META-INF/persistence.xml
> /bin
> ...
> I try to create new Hibernate Configuration in "Hibernate Configurations" pannel. I choose project, select JPA (jdk 1.5+) option, fill in persistence unit "InventorizacijaPU", check whether Classpath tab is OK (it contains my project). Press OK. Trying to expand configuration created, I get this exception:
> org.hibernate.console.HibernateConsoleRuntimeException: Could not create JPA based Configuration
> at org.hibernate.console.ConsoleConfiguration.buildJPAConfiguration(ConsoleConfiguration.java:142)
> at org.hibernate.console.ConsoleConfiguration.buildConfiguration(ConsoleConfiguration.java:496)
> at org.hibernate.console.ConsoleConfiguration.access$0(ConsoleConfiguration.java:484)
> at org.hibernate.console.ConsoleConfiguration$2.execute(ConsoleConfiguration.java:203)
> at org.hibernate.console.execution.DefaultExecutionContext.execute(DefaultExecutionContext.java:65)
> at org.hibernate.console.ConsoleConfiguration.buildWith(ConsoleConfiguration.java:185)
> at org.hibernate.console.ConsoleConfiguration.build(ConsoleConfiguration.java:106)
> at org.hibernate.eclipse.console.workbench.ConsoleConfigurationWorkbenchAdapter.getChildren(ConsoleConfigurationWorkbenchAdapter.java:38)
> at org.hibernate.eclipse.console.workbench.BasicWorkbenchAdapter.getChildren(BasicWorkbenchAdapter.java:97)
> at org.hibernate.eclipse.console.workbench.BasicWorkbenchAdapter.fetchDeferredChildren(BasicWorkbenchAdapter.java:103)
> at org.eclipse.ui.progress.DeferredTreeContentManager$1.run(DeferredTreeContentManager.java:196)
> at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)
> Caused by: org.hibernate.console.HibernateConsoleRuntimeException: Persistence unit not found: 'InventorizacijaPU'.
> at org.hibernate.console.ConsoleConfiguration.buildJPAConfiguration(ConsoleConfiguration.java:134)
> ... 11 more
> This is my persistence.xml:
> <?xml version="1.0" encoding="UTF-8"?>
> <persistence version="1.0"
> xmlns="http://java.sun.com/xml/ns/persistence"
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> xsi:schemaLocation="http://java.sun.com/xml/ns/persistence http://java.sun.com/xml/ns/persistence/persistence_1_0.xsd">
> <persistence-unit name="InventorizacijaPU"
> transaction-type="RESOURCE_LOCAL">
> <provider>org.hibernate.ejb.HibernatePersistence</provider>
> <class>lt.mitsoft.inventorizacija.domain.BuvimoVieta</class>
> <class>lt.mitsoft.inventorizacija.domain.Inventorizacija</class>
> <class>lt.mitsoft.inventorizacija.domain.Irasas</class>
> <class>lt.mitsoft.inventorizacija.domain.IrasuBlokas</class>
> <class>lt.mitsoft.inventorizacija.domain.Preke</class>
> <class>lt.mitsoft.inventorizacija.domain.Skanuotojas</class>
> <properties>
> <property name="hibernate.dialect"
> value="org.hibernate.dialect.DerbyDialect" />
>
> <!-- <property name="hibernate.connection.url"
> value="jdbc:derby:InventorizacijaDB" /> -->
> <property name="hibernate.connection.url"
> value="jdbc:derby://localhost:1527/InventorizacijaDB" />
> <!-- <property name="hibernate.connection.driver_class"
> value="org.apache.derby.jdbc.EmbeddedDriver"/> -->
> <property name="hibernate.connection.driver_class"
> value="org.apache.derby.jdbc.ClientDriver" />
> <property name="hibernate.connection.username"
> value="admin" />
> <property name="hibernate.connection.password"
> value="admin" />
> <property name="hibernate.cache.provider_class"
> value="org.hibernate.cache.NoCacheProvider" />
>
> <!-- <property name="hibernate.show_sql" value="true" /> -->
> </properties>
> </persistence-unit>
> </persistence>
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the hibernate-issues
mailing list