[jboss-cvs] JBossAS SVN: r83894 - projects/jpa/trunk/deployers/src/main/java/org/jboss/jpa/deployment.
jboss-cvs-commits at lists.jboss.org
jboss-cvs-commits at lists.jboss.org
Thu Feb 5 06:39:27 EST 2009
Author: alesj
Date: 2009-02-05 06:39:26 -0500 (Thu, 05 Feb 2009)
New Revision: 83894
Modified:
projects/jpa/trunk/deployers/src/main/java/org/jboss/jpa/deployment/PersistenceUnitDeployment.java
Log:
[JBJPA-8]; use VFSUtils to get compatible jpa url.
Modified: projects/jpa/trunk/deployers/src/main/java/org/jboss/jpa/deployment/PersistenceUnitDeployment.java
===================================================================
--- projects/jpa/trunk/deployers/src/main/java/org/jboss/jpa/deployment/PersistenceUnitDeployment.java 2009-02-05 11:11:56 UTC (rev 83893)
+++ projects/jpa/trunk/deployers/src/main/java/org/jboss/jpa/deployment/PersistenceUnitDeployment.java 2009-02-05 11:39:26 UTC (rev 83894)
@@ -265,23 +265,8 @@
VirtualFile root = getPersistenceUnitRoot();
log.debug("Persistence root: " + root);
- // TODO - update this with VFSUtils helper method
// hack the JPA url
- URL url = root.toURL();
- // is not nested, so direct VFS URL is not an option
- if (VFSUtils.isNestedFile(root) == false)
- {
- String urlString = url.toExternalForm();
- if (urlString.startsWith("vfs"))
- {
- // treat vfszip as file
- if (urlString.startsWith("vfszip"))
- url = new URL("file" + urlString.substring(6));
- else
- url = new URL(urlString.substring(3)); // (vfs)file and (vfs)jar are ok
- }
- }
-
+ URL url = VFSUtils.getCompatibleURL(root);
PersistenceUnitInfoImpl pi = new PersistenceUnitInfoImpl(metaData, props, di.getClassLoader(), url, jarFiles, initialContext);
if (explicitEntityClasses.size() > 0)
More information about the jboss-cvs-commits
mailing list