You are viewing a plain text version of this content. The canonical link for it is here.
Posted to scm@geronimo.apache.org by am...@apache.org on 2006/05/19 00:26:05 UTC
svn commit: r407646 - in /geronimo/branches/1.1:
assemblies/j2ee-jetty-server/src/var/config/
assemblies/j2ee-tomcat-server/src/var/config/
assemblies/minimal-jetty-server/src/var/config/
assemblies/minimal-tomcat-server/src/var/config/ assemblies/zzzz...
Author: ammulder
Date: Thu May 18 15:26:02 2006
New Revision: 407646
URL: http://svn.apache.org/viewvc?rev=407646&view=rev
Log:
Update the local attribute manager XML
- update to reflect 1.1 syntax
- validates when loading config.xml
- hooks for plugins to include config.xml snippets
Added:
geronimo/branches/1.1/modules/system/src/schema/local-attributes-1.1.xsd
- copied, changed from r407411, geronimo/branches/1.1/modules/system/src/schema/local-attribute.xsd
Removed:
geronimo/branches/1.1/modules/system/src/schema/local-attribute.xsd
Modified:
geronimo/branches/1.1/assemblies/j2ee-jetty-server/src/var/config/config.xml
geronimo/branches/1.1/assemblies/j2ee-tomcat-server/src/var/config/config.xml
geronimo/branches/1.1/assemblies/minimal-jetty-server/src/var/config/config.xml
geronimo/branches/1.1/assemblies/minimal-tomcat-server/src/var/config/config.xml
geronimo/branches/1.1/assemblies/zzzzj2ee-installer/src/var/config/config.xml
geronimo/branches/1.1/modules/system/src/java/org/apache/geronimo/system/configuration/GBeanOverride.java
geronimo/branches/1.1/modules/system/src/java/org/apache/geronimo/system/configuration/LocalAttributeManager.java
geronimo/branches/1.1/modules/system/src/java/org/apache/geronimo/system/configuration/ServerOverride.java
Modified: geronimo/branches/1.1/assemblies/j2ee-jetty-server/src/var/config/config.xml
URL: http://svn.apache.org/viewvc/geronimo/branches/1.1/assemblies/j2ee-jetty-server/src/var/config/config.xml?rev=407646&r1=407645&r2=407646&view=diff
==============================================================================
--- geronimo/branches/1.1/assemblies/j2ee-jetty-server/src/var/config/config.xml (original)
+++ geronimo/branches/1.1/assemblies/j2ee-jetty-server/src/var/config/config.xml Thu May 18 15:26:02 2006
@@ -6,7 +6,7 @@
<!-- any comments added to this file will be lost. -->
<!-- ======================================================== -->
-<attributes xmlns="http://geronimo.apache.org/xml/ns/attributes">
+<attributes xmlns="http://geronimo.apache.org/xml/ns/attributes-1.1">
<module name="geronimo/rmi-naming/${pom.currentVersion}/car">
<gbean name="RMIRegistry">
<attribute name="port">${PlanNamingPort}</attribute>
Modified: geronimo/branches/1.1/assemblies/j2ee-tomcat-server/src/var/config/config.xml
URL: http://svn.apache.org/viewvc/geronimo/branches/1.1/assemblies/j2ee-tomcat-server/src/var/config/config.xml?rev=407646&r1=407645&r2=407646&view=diff
==============================================================================
--- geronimo/branches/1.1/assemblies/j2ee-tomcat-server/src/var/config/config.xml (original)
+++ geronimo/branches/1.1/assemblies/j2ee-tomcat-server/src/var/config/config.xml Thu May 18 15:26:02 2006
@@ -6,7 +6,7 @@
<!-- any comments added to this file will be lost. -->
<!-- ======================================================== -->
-<attributes xmlns="http://geronimo.apache.org/xml/ns/attributes">
+<attributes xmlns="http://geronimo.apache.org/xml/ns/attributes-1.1">
<module name="geronimo/rmi-naming/${pom.currentVersion}/car">
<gbean name="RMIRegistry">
<attribute name="port">${PlanNamingPort}</attribute>
Modified: geronimo/branches/1.1/assemblies/minimal-jetty-server/src/var/config/config.xml
URL: http://svn.apache.org/viewvc/geronimo/branches/1.1/assemblies/minimal-jetty-server/src/var/config/config.xml?rev=407646&r1=407645&r2=407646&view=diff
==============================================================================
--- geronimo/branches/1.1/assemblies/minimal-jetty-server/src/var/config/config.xml (original)
+++ geronimo/branches/1.1/assemblies/minimal-jetty-server/src/var/config/config.xml Thu May 18 15:26:02 2006
@@ -6,7 +6,7 @@
<!-- any comments added to this file will be lost. -->
<!-- ======================================================== -->
-<attributes xmlns="http://geronimo.apache.org/xml/ns/attributes">
+<attributes xmlns="http://geronimo.apache.org/xml/ns/attributes-1.1">
<module name="geronimo/rmi-naming/${pom.currentVersion}/car">
<gbean name="RMIRegistry">
<attribute name="port">${PlanNamingPort}</attribute>
Modified: geronimo/branches/1.1/assemblies/minimal-tomcat-server/src/var/config/config.xml
URL: http://svn.apache.org/viewvc/geronimo/branches/1.1/assemblies/minimal-tomcat-server/src/var/config/config.xml?rev=407646&r1=407645&r2=407646&view=diff
==============================================================================
--- geronimo/branches/1.1/assemblies/minimal-tomcat-server/src/var/config/config.xml (original)
+++ geronimo/branches/1.1/assemblies/minimal-tomcat-server/src/var/config/config.xml Thu May 18 15:26:02 2006
@@ -6,7 +6,7 @@
<!-- any comments added to this file will be lost. -->
<!-- ======================================================== -->
-<attributes xmlns="http://geronimo.apache.org/xml/ns/attributes">
+<attributes xmlns="http://geronimo.apache.org/xml/ns/attributes-1.1">
<module name="geronimo/rmi-naming/${pom.currentVersion}/car">
<gbean name="RMIRegistry">
<attribute name="port">${PlanNamingPort}</attribute>
Modified: geronimo/branches/1.1/assemblies/zzzzj2ee-installer/src/var/config/config.xml
URL: http://svn.apache.org/viewvc/geronimo/branches/1.1/assemblies/zzzzj2ee-installer/src/var/config/config.xml?rev=407646&r1=407645&r2=407646&view=diff
==============================================================================
--- geronimo/branches/1.1/assemblies/zzzzj2ee-installer/src/var/config/config.xml (original)
+++ geronimo/branches/1.1/assemblies/zzzzj2ee-installer/src/var/config/config.xml Thu May 18 15:26:02 2006
@@ -6,7 +6,7 @@
<!-- any comments added to this file will be lost. -->
<!-- ======================================================== -->
-<attributes xmlns="http://geronimo.apache.org/xml/ns/attributes">
+<attributes xmlns="http://geronimo.apache.org/xml/ns/attributes-1.1">
<module name="geronimo/rmi-naming/${pom.currentVersion}/car" load="${J2EE.Features.enable}">
<gbean name="RMIRegistry">
<attribute name="port">${PlanNamingPort}</attribute>
Modified: geronimo/branches/1.1/modules/system/src/java/org/apache/geronimo/system/configuration/GBeanOverride.java
URL: http://svn.apache.org/viewvc/geronimo/branches/1.1/modules/system/src/java/org/apache/geronimo/system/configuration/GBeanOverride.java?rev=407646&r1=407645&r2=407646&view=diff
==============================================================================
--- geronimo/branches/1.1/modules/system/src/java/org/apache/geronimo/system/configuration/GBeanOverride.java (original)
+++ geronimo/branches/1.1/modules/system/src/java/org/apache/geronimo/system/configuration/GBeanOverride.java Thu May 18 15:26:02 2006
@@ -167,7 +167,7 @@
continue;
}
- for (int p = 0; p < references.getLength(); p++) {
+ for (int p = 0; p < patterns.getLength(); p++) {
Element pattern = (Element) patterns.item(p);
if (pattern == null)
continue;
Modified: geronimo/branches/1.1/modules/system/src/java/org/apache/geronimo/system/configuration/LocalAttributeManager.java
URL: http://svn.apache.org/viewvc/geronimo/branches/1.1/modules/system/src/java/org/apache/geronimo/system/configuration/LocalAttributeManager.java?rev=407646&r1=407645&r2=407646&view=diff
==============================================================================
--- geronimo/branches/1.1/modules/system/src/java/org/apache/geronimo/system/configuration/LocalAttributeManager.java (original)
+++ geronimo/branches/1.1/modules/system/src/java/org/apache/geronimo/system/configuration/LocalAttributeManager.java Thu May 18 15:26:02 2006
@@ -333,9 +333,15 @@
}
FileInputStream fis = new FileInputStream(attributeFile);
InputSource in = new InputSource(fis);
- DocumentBuilderFactory dfactory = DocumentBuilderFactory.newInstance();
+ DocumentBuilderFactory dFactory = DocumentBuilderFactory.newInstance();
try {
- Document doc = dfactory.newDocumentBuilder().parse(in);
+ dFactory.setValidating(true);
+ dFactory.setNamespaceAware(true);
+ dFactory.setAttribute("http://java.sun.com/xml/jaxp/properties/schemaLanguage",
+ "http://www.w3.org/2001/XMLSchema");
+ dFactory.setAttribute("http://java.sun.com/xml/jaxp/properties/schemaSource",
+ LocalAttributeManager.class.getResourceAsStream("/META-INF/schema/local-attributes-1.1.xsd"));
+ Document doc = dFactory.newDocumentBuilder().parse(in);
Element root = doc.getDocumentElement();
serverOverride = new ServerOverride(root);
} catch (SAXException e) {
Modified: geronimo/branches/1.1/modules/system/src/java/org/apache/geronimo/system/configuration/ServerOverride.java
URL: http://svn.apache.org/viewvc/geronimo/branches/1.1/modules/system/src/java/org/apache/geronimo/system/configuration/ServerOverride.java?rev=407646&r1=407645&r2=407646&view=diff
==============================================================================
--- geronimo/branches/1.1/modules/system/src/java/org/apache/geronimo/system/configuration/ServerOverride.java (original)
+++ geronimo/branches/1.1/modules/system/src/java/org/apache/geronimo/system/configuration/ServerOverride.java Thu May 18 15:26:02 2006
@@ -97,10 +97,10 @@
out.println("<!-- Warning - This XML file is re-generated by Geronimo when -->");
out.println("<!-- changes are made to Geronimo's configuration, therefore -->");
out.println("<!-- any comments added to this file will be lost. -->");
- out.println("<!-- Do not edit this file whilst Geronimo is running. -->");
+ out.println("<!-- Do not edit this file while Geronimo is running. -->");
out.println("<!-- ======================================================== -->");
out.println();
- out.println("<attributes xmlns=\"http://geronimo.apache.org/xml/ns/attributes\">");
+ out.println("<attributes xmlns=\"http://geronimo.apache.org/xml/ns/attributes-1.1\">");
for (Iterator it = configurations.entrySet().iterator(); it.hasNext();) {
Map.Entry entry = (Map.Entry) it.next();
ConfigurationOverride configurationOverride = (ConfigurationOverride) entry.getValue();
Copied: geronimo/branches/1.1/modules/system/src/schema/local-attributes-1.1.xsd (from r407411, geronimo/branches/1.1/modules/system/src/schema/local-attribute.xsd)
URL: http://svn.apache.org/viewvc/geronimo/branches/1.1/modules/system/src/schema/local-attributes-1.1.xsd?p2=geronimo/branches/1.1/modules/system/src/schema/local-attributes-1.1.xsd&p1=geronimo/branches/1.1/modules/system/src/schema/local-attribute.xsd&r1=407411&r2=407646&rev=407646&view=diff
==============================================================================
--- geronimo/branches/1.1/modules/system/src/schema/local-attribute.xsd (original)
+++ geronimo/branches/1.1/modules/system/src/schema/local-attributes-1.1.xsd Thu May 18 15:26:02 2006
@@ -17,12 +17,12 @@
-->
<xsd:schema
- targetNamespace="http://geronimo.apache.org/xml/ns/attributes"
- xmlns:atts="http://geronimo.apache.org/xml/ns/attributes"
+ targetNamespace="http://geronimo.apache.org/xml/ns/attributes-1.1"
+ xmlns:atts="http://geronimo.apache.org/xml/ns/attributes-1.1"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
elementFormDefault="qualified"
attributeFormDefault="unqualified"
- version="1.0">
+ >
<xsd:annotation>
<xsd:documentation>
@@ -42,12 +42,12 @@
</xsd:documentation>
</xsd:annotation>
- <!--
- temporary (I hope) individual elements while xmlbeans group handling is straightened out
- -->
-
+ <!-- Main element for the manageable attribute store configuration -->
<xsd:element name="attributes" type="atts:attributesType"/>
+ <!-- Element used by the plugin system to list individual GBeans -->
+ <xsd:element name="gbean" type="atts:gbeanType" />
+
<xsd:complexType name="attributesType">
<xsd:choice>
<xsd:element name="module" type="atts:configurationType" minOccurs="0" maxOccurs="unbounded" />
@@ -91,6 +91,7 @@
<xsd:simpleContent>
<xsd:extension base="xsd:string">
<xsd:attribute name="name" use="required"/>
+ <xsd:attribute name="null" use="optional"/>
</xsd:extension>
</xsd:simpleContent>
</xsd:complexType>
@@ -100,7 +101,12 @@
<xsd:element name="pattern" minOccurs="1" maxOccurs="unbounded">
<xsd:complexType>
<xsd:sequence>
- <xsd:element name="gbean-name" type="xsd:string"/>
+ <xsd:element name="groupId" type="xsd:string" minOccurs="0"/>
+ <xsd:element name="artifactId" type="xsd:string" minOccurs="0"/>
+ <xsd:element name="version" type="xsd:string" minOccurs="0"/>
+ <xsd:element name="type" type="xsd:string" minOccurs="0"/>
+ <xsd:element name="module" type="xsd:string" minOccurs="0"/>
+ <xsd:element name="name" type="xsd:string"/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>