You are viewing a plain text version of this content. The canonical link for it is here.
Posted to scm@geronimo.apache.org by ge...@apache.org on 2011/01/25 06:19:33 UTC

svn commit: r1063143 - /geronimo/server/branches/3.0-M2/framework/modules/geronimo-system/src/main/java/org/apache/geronimo/system/configuration/LocalAttributeManager.java

Author: genspring
Date: Tue Jan 25 05:19:33 2011
New Revision: 1063143

URL: http://svn.apache.org/viewvc?rev=1063143&view=rev
Log:
GERONIMO-5283 Server restart fails after a hard stop

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

Modified: geronimo/server/branches/3.0-M2/framework/modules/geronimo-system/src/main/java/org/apache/geronimo/system/configuration/LocalAttributeManager.java
URL: http://svn.apache.org/viewvc/geronimo/server/branches/3.0-M2/framework/modules/geronimo-system/src/main/java/org/apache/geronimo/system/configuration/LocalAttributeManager.java?rev=1063143&r1=1063142&r2=1063143&view=diff
==============================================================================
--- geronimo/server/branches/3.0-M2/framework/modules/geronimo-system/src/main/java/org/apache/geronimo/system/configuration/LocalAttributeManager.java (original)
+++ geronimo/server/branches/3.0-M2/framework/modules/geronimo-system/src/main/java/org/apache/geronimo/system/configuration/LocalAttributeManager.java Tue Jan 25 05:19:33 2011
@@ -62,6 +62,7 @@ import org.apache.geronimo.system.config
 import org.apache.geronimo.system.configuration.condition.ParserUtils;
 import org.apache.geronimo.system.plugin.model.AttributesType;
 import org.apache.geronimo.system.plugin.model.GbeanType;
+import org.apache.geronimo.system.plugin.model.ModuleType;
 import org.apache.geronimo.system.serverinfo.ServerInfo;
 import org.xml.sax.SAXException;
 import org.osgi.framework.Bundle;
@@ -438,6 +439,15 @@ public class LocalAttributeManager imple
 
     static void write(ServerOverride serverOverride, Writer writer) throws XMLStreamException, JAXBException, IOException {
         AttributesType attributes = serverOverride.writeXml();
+        
+        // we don't need to write wab configuration to config.xml
+        for (Iterator<ModuleType> it = attributes.getModule().iterator(); it.hasNext();) {
+            ModuleType module = it.next();
+            if (module.getName().endsWith("wab")) {
+                it.remove();
+            }
+        }
+        
         AttributesXmlUtil.writeAttributes(attributes, writer);
         writer.flush();
     }