[jboss-cvs] JBossAS SVN: r101098 - projects/jpa/trunk/vfs3/src/main/java/org/jboss/jpa/deployment/vfs3.
jboss-cvs-commits at lists.jboss.org
jboss-cvs-commits at lists.jboss.org
Wed Feb 17 19:49:57 EST 2010
Author: johnbailey
Date: 2010-02-17 19:49:56 -0500 (Wed, 17 Feb 2010)
New Revision: 101098
Modified:
projects/jpa/trunk/vfs3/src/main/java/org/jboss/jpa/deployment/vfs3/PersistenceUnitDeploymentImpl.java
Log:
[JBJPA-23] - Fixed bug in VFS3 URL handling for EJB3Configuration from JPA Deployers
Modified: projects/jpa/trunk/vfs3/src/main/java/org/jboss/jpa/deployment/vfs3/PersistenceUnitDeploymentImpl.java
===================================================================
--- projects/jpa/trunk/vfs3/src/main/java/org/jboss/jpa/deployment/vfs3/PersistenceUnitDeploymentImpl.java 2010-02-18 00:46:00 UTC (rev 101097)
+++ projects/jpa/trunk/vfs3/src/main/java/org/jboss/jpa/deployment/vfs3/PersistenceUnitDeploymentImpl.java 2010-02-18 00:49:56 UTC (rev 101098)
@@ -67,7 +67,7 @@
try {
VirtualFile metaData = di.getMetaDataFile("persistence.xml");
assert metaData != null : "Can't find persistence.xml in " + di;
- return metaData.getParent().getParent().toURL();
+ return metaData.getParent().getParent().getPhysicalFile().toURI().toURL(); // Hack, but needed for the way Hibernate looks for classes in Jar..
}
catch (Exception e) {
throw new RuntimeException(e);
@@ -89,7 +89,7 @@
VirtualFile jarFile = baseDir.getChild(jar);
if (jarFile == null)
throw new RuntimeException("could not find child '" + jar + "' on '" + baseDir + "'");
- return jarFile.toURL();
+ return jarFile.getPhysicalFile().toURI().toURL(); // Hack, but needed for the way Hibernate looks for classes in Jar..
}
catch (Exception e1) {
throw new RuntimeException("could not find relative path: " + jar, e1);
More information about the jboss-cvs-commits
mailing list