geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ga...@apache.org
Subject svn commit: r1065699 - /geronimo/server/branches/3.0-M2/framework/modules/geronimo-main/src/main/java/org/apache/geronimo/main/FrameworkLauncher.java
Date Mon, 31 Jan 2011 17:57:01 GMT
Author: gawor
Date: Mon Jan 31 17:57:00 2011
New Revision: 1065699

URL: http://svn.apache.org/viewvc?rev=1065699&view=rev
Log:
GERONIMO-5798: obr:addurl/removeurl generate incorrect obr.repository.url property

Modified:
    geronimo/server/branches/3.0-M2/framework/modules/geronimo-main/src/main/java/org/apache/geronimo/main/FrameworkLauncher.java

Modified: geronimo/server/branches/3.0-M2/framework/modules/geronimo-main/src/main/java/org/apache/geronimo/main/FrameworkLauncher.java
URL: http://svn.apache.org/viewvc/geronimo/server/branches/3.0-M2/framework/modules/geronimo-main/src/main/java/org/apache/geronimo/main/FrameworkLauncher.java?rev=1065699&r1=1065698&r2=1065699&view=diff
==============================================================================
--- geronimo/server/branches/3.0-M2/framework/modules/geronimo-main/src/main/java/org/apache/geronimo/main/FrameworkLauncher.java
(original)
+++ geronimo/server/branches/3.0-M2/framework/modules/geronimo-main/src/main/java/org/apache/geronimo/main/FrameworkLauncher.java
Mon Jan 31 17:57:00 2011
@@ -260,9 +260,24 @@ public class FrameworkLauncher {
                                     Utils.substVars(configProps.getProperty(name), name,
null, configProps));
         }
 
+        updateObrRepositoryList(configProps);
+
         return configProps;
     }
 
+    /*
+     * OBR expects the "obr.repository.url" property to be a space-separated 
+     * list while Karaf generates a comma-seprated list. This function is a
+     * temporary work-around that fixes that property.
+     */
+    private static void updateObrRepositoryList(Properties properties) {
+        String value = (String) properties.get("obr.repository.url");
+        if (value != null) {
+            String newValue = value.replaceAll(",", " ");
+            properties.put("obr.repository.url", newValue);
+        }
+    }
+
     protected static void copySystemProperties(Properties configProps) {
         for (Enumeration e = System.getProperties().propertyNames(); e.hasMoreElements();)
{
             String key = (String) e.nextElement();



Mime
View raw message