You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@juddi.apache.org by tc...@apache.org on 2010/03/20 01:13:09 UTC
svn commit: r925496 -
/webservices/juddi/trunk/juddi-core/src/main/java/org/apache/juddi/config/Install.java
Author: tcunning
Date: Sat Mar 20 00:13:08 2010
New Revision: 925496
URL: http://svn.apache.org/viewvc?rev=925496&view=rev
Log:
JUDDI-381
Make the publisher install work on Windows, where there doesn't seem
to be a "!" separating the JAR and the juddi_install_data in the URI.
Modified:
webservices/juddi/trunk/juddi-core/src/main/java/org/apache/juddi/config/Install.java
Modified: webservices/juddi/trunk/juddi-core/src/main/java/org/apache/juddi/config/Install.java
URL: http://svn.apache.org/viewvc/webservices/juddi/trunk/juddi-core/src/main/java/org/apache/juddi/config/Install.java?rev=925496&r1=925495&r2=925496&view=diff
==============================================================================
--- webservices/juddi/trunk/juddi-core/src/main/java/org/apache/juddi/config/Install.java (original)
+++ webservices/juddi/trunk/juddi-core/src/main/java/org/apache/juddi/config/Install.java Sat Mar 20 00:13:08 2010
@@ -510,10 +510,23 @@ public class Install {
}
}
} else {
- String[] paths = path.split("!");
+ String[] paths = {};
+ Enumeration<JarEntry> en = null;
try {
+
+ if (path.indexOf("!") > 0) {
+ paths = path.split("!");
+ en = new JarFile(new File(new URI(paths[0]))).entries();
+ } else {
+ // Handle Windows / jboss-5.1.0 case
+ if (path.indexOf(".jar") > 0) {
+ paths = path.split(".jar");
+ paths[0] = paths[0] + ".jar";
+ en = new JarFile(new File(paths[0])).entries();
+ }
+ }
+
log.debug("Discovering the Publisher XML data files in jar: " + paths[0]);
- Enumeration<JarEntry> en = new JarFile(new File(new URI(paths[0]))).entries();
while (en.hasMoreElements()) {
String name = en.nextElement().getName();
if (name.endsWith(FILE_PUBLISHER)) {
---------------------------------------------------------------------
To unsubscribe, e-mail: juddi-cvs-unsubscribe@ws.apache.org
For additional commands, e-mail: juddi-cvs-help@ws.apache.org