Author: djencks Date: Wed Oct 27 22:30:57 2004 New Revision: 55788 Modified: geronimo/trunk/modules/j2ee/src/java/org/apache/geronimo/j2ee/deployment/EARConfigBuilder.java geronimo/trunk/modules/j2ee/src/schema/geronimo-application.xsd Log: Add ability to specify application name distinct from configId. GERONIMO-401
Modified: geronimo/trunk/modules/j2ee/src/java/org/apache/geronimo/j2ee/deployment/EARConfigBuilder.java ============================================================================== --- geronimo/trunk/modules/j2ee/src/java/org/apache/geronimo/j2ee/deployment/EARConfigBuilder.java (original) +++ geronimo/trunk/modules/j2ee/src/java/org/apache/geronimo/j2ee/deployment/EARConfigBuilder.java Wed Oct 27 22:30:57 2004 @@ -46,6 +46,7 @@ import org.apache.geronimo.gbean.GBeanInfoFactory; import org.apache.geronimo.gbean.jmx.GBeanMBean; import org.apache.geronimo.j2ee.ApplicationInfo; +import org.apache.geronimo.j2ee.deployment.j2eeobjectnames.NameFactory; import org.apache.geronimo.j2ee.management.impl.J2EEApplicationImpl; import org.apache.geronimo.kernel.Kernel; import org.apache.geronimo.kernel.config.ConfigurationModuleType; @@ -135,7 +136,7 @@ return new ApplicationInfo(module.getType(), module.getConfigId(), module.getParentId(), - "null", + NameFactory.NULL, null, null, Collections.singleton(module), @@ -222,10 +223,12 @@ throw new DeploymentException(e); } + String applicationName = gerApplication.isSetApplicationName()? gerApplication.getApplicationName(): configId.toString(); + return new ApplicationInfo(ConfigurationModuleType.EAR, configId, parentId, - configId.toString(), + applicationName, application, gerApplication, modules, Modified: geronimo/trunk/modules/j2ee/src/schema/geronimo-application.xsd ============================================================================== --- geronimo/trunk/modules/j2ee/src/schema/geronimo-application.xsd (original) +++ geronimo/trunk/modules/j2ee/src/schema/geronimo-application.xsd Wed Oct 27 22:30:57 2004 @@ -37,6 +37,7 @@ <xs:attribute name="configId" type="xs:string" use="required"/> <xs:attribute name="parentId" type="xs:string" use="optional"/> + <xs:attribute name="application-name" type="xs:string" use="optional"/> </xs:complexType> <xs:complexType name="moduleType">