geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From djen...@apache.org
Subject svn commit: r447998 [2/2] - in /geronimo/server/trunk: assemblies/geronimo-jetty-j2ee/src/main/var/config/ assemblies/geronimo-jetty-minimal/ assemblies/geronimo-jetty-minimal/src/main/var/config/ assemblies/geronimo-tomcat-j2ee/src/main/var/config/ as...
Date Tue, 19 Sep 2006 22:23:50 GMT
Modified: geronimo/server/trunk/configs/webconsole-tomcat/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/configs/webconsole-tomcat/pom.xml?view=diff&rev=447998&r1=447997&r2=447998
==============================================================================
--- geronimo/server/trunk/configs/webconsole-tomcat/pom.xml (original)
+++ geronimo/server/trunk/configs/webconsole-tomcat/pom.xml Tue Sep 19 15:23:47 2006
@@ -79,14 +79,6 @@
             <type>car</type>
         </dependency>
 
-        <!-- for login module manager -->
-        <dependency>
-            <groupId>org.apache.geronimo.configs</groupId>
-            <artifactId>j2ee-security</artifactId>
-            <version>${pom.version}</version>
-            <type>car</type>
-        </dependency>
-        
         <dependency>
             <groupId>org.apache.geronimo.applications.console</groupId>
             <artifactId>geronimo-console-core</artifactId>
@@ -113,37 +105,18 @@
             <version>${pom.version}</version>
         </dependency>
 
-        <!--<dependency>-->
-            <!--<groupId>org.apache.geronimo.modules</groupId>-->
-            <!--<artifactId>geronimo-deploy-config</artifactId>-->
-            <!--<version>${pom.version}</version>-->
-        <!--</dependency>-->
-
         <dependency>
             <groupId>org.apache.geronimo.modules</groupId>
             <artifactId>geronimo-management</artifactId>
             <version>${pom.version}</version>
         </dependency>
 
-        <!--<dependency>-->
-            <!--<groupId>org.apache.geronimo.modules</groupId>-->
-            <!--<artifactId>geronimo-test-ddbean</artifactId>-->
-            <!--<version>${pom.version}</version>-->
-        <!--</dependency>-->
-
         <dependency>
             <groupId>org.apache.geronimo.modules</groupId>
             <artifactId>geronimo-upgrade</artifactId>
             <version>${pom.version}</version>
         </dependency>
 
-        <!--<dependency>-->
-            <!--<groupId>org.apache.geronimo.modules</groupId>-->
-            <!--<artifactId>geronimo-util</artifactId>-->
-            <!--<version>${pom.version}</version>-->
-        <!--</dependency>-->
-
-
         <dependency>
             <groupId>org.apache.geronimo.modules</groupId>
             <artifactId>geronimo-activemq-gbean</artifactId>
@@ -190,9 +163,9 @@
                         <deploymentConfig>${gbeanDeployer}</deploymentConfig>
                         <deploymentConfig>${j2eeDeployer}</deploymentConfig>
                         <deploymentConfig>${tomcatDeployer}</deploymentConfig>
-                        <deploymentConfig>${clientDeployer}</deploymentConfig>
-                        <deploymentConfig>${openejbDeployer}</deploymentConfig>
-                        <deploymentConfig>${axisDeployer}</deploymentConfig>
+                        <!--<deploymentConfig>${clientDeployer}</deploymentConfig>-->
+                        <!--<deploymentConfig>${openejbDeployer}</deploymentConfig>-->
+                        <!--<deploymentConfig>${axisDeployer}</deploymentConfig>-->
                     </deploymentConfigs>
                     <module>
                         <groupId>org.apache.geronimo.applications.console</groupId>

Modified: geronimo/server/trunk/configs/webconsole-tomcat/src/plan/plan.xml
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/configs/webconsole-tomcat/src/plan/plan.xml?view=diff&rev=447998&r1=447997&r2=447998
==============================================================================
--- geronimo/server/trunk/configs/webconsole-tomcat/src/plan/plan.xml (original)
+++ geronimo/server/trunk/configs/webconsole-tomcat/src/plan/plan.xml Tue Sep 19 15:23:47
2006
@@ -34,6 +34,14 @@
             <context-root>/console-standard</context-root>
             <cross-context/>
             <security-realm-name>geronimo-properties-realm</security-realm-name>
+            <gbean name="PropertiesLoginManager" class="org.apache.geronimo.console.core.security.PropertiesLoginModuleManager">
+                <reference name="ServerInfo">
+                    <name>ServerInfo</name>
+                </reference>
+                <reference name="LoginModule">
+                    <name>properties-login</name>
+                </reference>
+            </gbean>
         </web-app>
     </module>
 
@@ -55,20 +63,19 @@
     </security>
 
     <!-- Console specific server info -->
-    <gbean name="PropertiesLoginManager" class="org.apache.geronimo.console.core.security.PropertiesLoginModuleManager">
-        <reference name="ServerInfo">
-            <name>ServerInfo</name>
-        </reference>
-        <reference name="LoginModule">
-            <name>properties-login</name>
-        </reference>
-    </gbean>
+    <!--<gbean name="PropertiesLoginManager" class="org.apache.geronimo.console.core.security.PropertiesLoginModuleManager">-->
+        <!--<reference name="ServerInfo">-->
+            <!--<name>ServerInfo</name>-->
+        <!--</reference>-->
+        <!--<reference name="LoginModule">-->
+            <!--<name>properties-login</name>-->
+        <!--</reference>-->
+    <!--</gbean>-->
 
     <!-- Keystore configuration -->
     <gbean name="KeyStore" class="org.apache.geronimo.console.core.keystore.KeyStoreGBean">
         <attribute name="keyStoreLocation">var/security/ssl-keystore-1</attribute>
-        <attribute name="keyStoreType">jks</attribute>
-        <attribute name="keyStoreProvider">SUN</attribute>
+        <attribute name="keyStoreType">PKCS12</attribute>
         <attribute name="keyStorePassword">password</attribute>
         <reference name="serverInfo">
             <name>ServerInfo</name>

Modified: geronimo/server/trunk/modules/geronimo-client-builder/src/main/java/org/apache/geronimo/client/builder/AppClientModuleBuilder.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-client-builder/src/main/java/org/apache/geronimo/client/builder/AppClientModuleBuilder.java?view=diff&rev=447998&r1=447997&r2=447998
==============================================================================
--- geronimo/server/trunk/modules/geronimo-client-builder/src/main/java/org/apache/geronimo/client/builder/AppClientModuleBuilder.java
(original)
+++ geronimo/server/trunk/modules/geronimo-client-builder/src/main/java/org/apache/geronimo/client/builder/AppClientModuleBuilder.java
Tue Sep 19 15:23:47 2006
@@ -62,6 +62,7 @@
 import org.apache.geronimo.j2ee.deployment.CorbaGBeanNameSource;
 import org.apache.geronimo.j2ee.deployment.NamingBuilder;
 import org.apache.geronimo.j2ee.deployment.NamingBuilderCollection;
+import org.apache.geronimo.j2ee.deployment.ConnectorModule;
 import org.apache.geronimo.j2ee.j2eeobjectnames.NameFactory;
 import org.apache.geronimo.j2ee.management.impl.J2EEAppClientModuleImpl;
 import org.apache.geronimo.kernel.GBeanAlreadyExistsException;
@@ -103,6 +104,8 @@
     private final NamespaceDrivenBuilderCollection serviceBuilder;
     private final NamingBuilderCollection namingBuilders;
 
+    private final Collection repositories;
+
     private static final String GERAPPCLIENT_NAMESPACE = GerApplicationClientDocument.type.getDocumentElementName().getNamespaceURI();
 
     public AppClientModuleBuilder(Environment defaultClientEnvironment,
@@ -110,6 +113,7 @@
             AbstractNameQuery transactionManagerObjectName,
             AbstractNameQuery connectionTrackerObjectName,
             AbstractNameQuery corbaGBeanObjectName,
+            Collection repositories,
             ModuleBuilder connectorModuleBuilder,
             NamespaceDrivenBuilder securityBuilder,
             NamespaceDrivenBuilder serviceBuilder,
@@ -119,7 +123,7 @@
                 transactionManagerObjectName,
                 connectionTrackerObjectName,
                 corbaGBeanObjectName,
-                new SingleElementCollection(connectorModuleBuilder),
+                repositories, new SingleElementCollection(connectorModuleBuilder),
                 new SingleElementCollection(securityBuilder),
                 serviceBuilder == null ? Collections.EMPTY_SET : Collections.singleton(serviceBuilder),
                 namingBuilders == null ? Collections.EMPTY_SET : namingBuilders);
@@ -128,6 +132,7 @@
     public AppClientModuleBuilder(AbstractNameQuery transactionManagerObjectName,
             AbstractNameQuery connectionTrackerObjectName,
             AbstractNameQuery corbaGBeanObjectName,
+            Collection repositories,
             Collection connectorModuleBuilder,
             Collection securityBuilder,
             Collection serviceBuilder,
@@ -139,7 +144,7 @@
                 transactionManagerObjectName,
                 connectionTrackerObjectName,
                 corbaGBeanObjectName,
-                new SingleElementCollection(connectorModuleBuilder),
+                repositories, new SingleElementCollection(connectorModuleBuilder),
                 new SingleElementCollection(securityBuilder),
                 serviceBuilder,
                 namingBuilders);
@@ -150,6 +155,7 @@
             AbstractNameQuery transactionManagerObjectName,
             AbstractNameQuery connectionTrackerObjectName,
             AbstractNameQuery corbaGBeanObjectName,
+            Collection repositories,
             SingleElementCollection connectorModuleBuilder,
             SingleElementCollection securityBuilder,
             Collection serviceBuilder, Collection namingBuilders) {
@@ -158,6 +164,7 @@
         this.corbaGBeanObjectName = corbaGBeanObjectName;
         this.transactionManagerObjectName = transactionManagerObjectName;
         this.connectionTrackerObjectName = connectionTrackerObjectName;
+        this.repositories = repositories;
         this.connectorModuleBuilder = connectorModuleBuilder;
         this.securityBuilder = securityBuilder;
         this.serviceBuilder = new NamespaceDrivenBuilderCollection(serviceBuilder);
@@ -250,8 +257,48 @@
         } else {
             moduleName = naming.createChildName(earName, targetPath, NameFactory.APP_CLIENT_MODULE);
         }
+        AbstractName clientBaseName = naming.createRootName(clientEnvironment.getConfigId(),
clientEnvironment.getConfigId().toString(), NameFactory.J2EE_APPLICATION);
+
+        //start installing the resource adapters in the client.
+        Collection resourceModules = new ArrayList();
+        GerResourceType[] resources = gerAppClient.getResourceArray();
+        for (int i = 0; i < resources.length; i++) {
+            GerResourceType resource = resources[i];
+            String path;
+            JarFile connectorFile;
+            if (resource.isSetExternalRar()) {
+                path = resource.getExternalRar().trim();
+                Artifact artifact = Artifact.create(path);
+                File file = null;
+                for (Iterator iterator = repositories.iterator(); iterator.hasNext();) {
+                    Repository repository = (Repository) iterator.next();
+                    if (repository.contains(artifact)) {
+                        file = repository.getLocation(artifact);
+                        break;
+                    }
+                }
+                if (file == null) {
+                    throw new DeploymentException("Missing rar in repositories: " + path);
+                }
+                try {
+                    connectorFile = new JarFile(file);
+                } catch (IOException e) {
+                    throw new DeploymentException("Could not access rar contents", e);
+                }
+            } else {
+                path = resource.getInternalRar();
+                try {
+                    connectorFile = new NestedJarFile(moduleFile, path);
+                } catch (IOException e) {
+                    throw new DeploymentException("Could not locate connector inside ear",
e);
+                }
+            }
+            XmlObject connectorPlan = resource.getConnector();
+            Module connectorModule = getConnectorModuleBuilder().createModule(connectorPlan,
connectorFile, path, null, clientEnvironment, null, clientBaseName, naming, idBuilder);
+            resourceModules.add(connectorModule);
+        }
 
-        return new AppClientModule(standAlone, moduleName, serverEnvironment, clientEnvironment,
moduleFile, targetPath, appClient, gerAppClient, specDD);
+        return new AppClientModule(standAlone, moduleName, clientBaseName, serverEnvironment,
clientEnvironment, moduleFile, targetPath, appClient, gerAppClient, specDD, resourceModules);
     }
 
     GerApplicationClientType getGeronimoAppClient(Object plan, JarFile moduleFile, boolean
standAlone, String targetPath, ApplicationClientType appClient, Environment environment) throws
DeploymentException {
@@ -334,13 +381,12 @@
         appClientModule.setEarFile(earFile);
         //create the ear context for the app client.
         Environment clientEnvironment = appClientModule.getClientEnvironment();
-        if (!appClientModule.isStandAlone() || clientEnvironment.getConfigId() == null) {
-            Artifact earConfigId = earContext.getConfigID();
-            Artifact configId = new Artifact(earConfigId.getGroupId(), earConfigId.getArtifactId()
+ "_" + module.getTargetPath(), earConfigId.getVersion(), "car");
-            clientEnvironment.setConfigId(configId);
-        }
+//        if (!appClientModule.isStandAlone() || clientEnvironment.getConfigId() == null)
{
+//            Artifact earConfigId = earContext.getConfigID();
+//            Artifact configId = new Artifact(earConfigId.getGroupId(), earConfigId.getArtifactId()
+ "_" + module.getTargetPath(), earConfigId.getVersion(), "car");
+//            clientEnvironment.setConfigId(configId);
+//        }
 
-        AbstractName clientBaseName = earContext.getNaming().createRootName(clientEnvironment.getConfigId(),
clientEnvironment.getConfigId().toString(), NameFactory.J2EE_APPLICATION);
         File appClientDir;
         try {
             appClientDir = targetConfigurationStore.createNewConfigurationDir(clientEnvironment.getConfigId());
@@ -349,16 +395,17 @@
         }
 
         // construct the app client deployment context... this is the same class used by
the ear context
+        EARContext appClientDeploymentContext;
         try {
 
-            EARContext appClientDeploymentContext = new EARContext(appClientDir,
+            appClientDeploymentContext = new EARContext(appClientDir,
                     null,
                     clientEnvironment,
                     ConfigurationModuleType.CAR,
                     earContext.getNaming(),
                     earContext.getConfigurationManager(),
                     null, //no server name needed on client
-                    clientBaseName,
+                    appClientModule.getAppClientName(),
                     transactionManagerObjectName,
                     connectionTrackerObjectName,
                     null,
@@ -371,10 +418,19 @@
             cleanupAppClientDir(appClientDir);
             throw e;
         }
+        for (Iterator resources = appClientModule.getResourceModules().iterator(); resources.hasNext();)
{
+            ConnectorModule connectorModule = (ConnectorModule) resources.next();
+            getConnectorModuleBuilder().installModule(connectorModule.getModuleFile(), appClientDeploymentContext,
connectorModule, configurationStores, targetConfigurationStore, repositories);
+        }
 
     }
 
-    public void initContext(EARContext earContext, Module clientModule, ClassLoader cl) {
+    public void initContext(EARContext earContext, Module clientModule, ClassLoader cl) throws
DeploymentException {
+        AppClientModule appClientModule = ((AppClientModule) clientModule);
+        for (Iterator resources = appClientModule.getResourceModules().iterator(); resources.hasNext();)
{
+            ConnectorModule connectorModule = (ConnectorModule) resources.next();
+            getConnectorModuleBuilder().initContext(appClientModule.getEarContext(), connectorModule,
cl);
+        }
     }
 
     public void addGBeans(EARContext earContext, Module module, ClassLoader earClassLoader,
Collection repositories) throws DeploymentException {
@@ -387,7 +443,6 @@
         // get the app client main class
         JarFile moduleFile = module.getModuleFile();
         String mainClasss;
-//        String classPath = null;
         try {
             Manifest manifest = moduleFile.getManifest();
             if (manifest == null) {
@@ -428,7 +483,6 @@
         }
 
         EARContext appClientDeploymentContext = appClientModule.getEarContext();
-//        ConfigurationData appClientConfigurationData = null;
 
         // Create a Module ID Builder defaulting to similar settings to use for any children
we create
         ModuleIDBuilder idBuilder = new ModuleIDBuilder();
@@ -457,62 +511,10 @@
                 if (geronimoAppClient != null) {
                     serviceBuilder.build(geronimoAppClient, appClientDeploymentContext, appClientDeploymentContext);
                     //deploy the resource adapters specified in the geronimo-application.xml
-                    Collection resourceModules = new ArrayList();
-                    try {
-                        GerResourceType[] resources = geronimoAppClient.getResourceArray();
-                        for (int i = 0; i < resources.length; i++) {
-                            GerResourceType resource = resources[i];
-                            String path;
-                            JarFile connectorFile;
-                            if (resource.isSetExternalRar()) {
-                                path = resource.getExternalRar().trim();
-                                Artifact artifact = Artifact.create(path);
-                                File file = null;
-                                for (Iterator iterator = repositories.iterator(); iterator.hasNext();)
{
-                                    Repository repository = (Repository) iterator.next();
-                                    if (repository.contains(artifact)) {
-                                        file = repository.getLocation(artifact);
-                                        break;
-                                    }
-                                }
-                                if (file == null) {
-                                    throw new DeploymentException("Missing rar in repositories:
" + path);
-                                }
-                                try {
-                                    connectorFile = new JarFile(file);
-                                } catch (IOException e) {
-                                    throw new DeploymentException("Could not access rar contents",
e);
-                                }
-                            } else {
-                                path = resource.getInternalRar();
-                                try {
-                                    connectorFile = new NestedJarFile(appClientModule.getEarFile(),
path);
-                                } catch (IOException e) {
-                                    throw new DeploymentException("Could not locate connector
inside ear", e);
-                                }
-                            }
-                            XmlObject connectorPlan = resource.getConnector();
-                            Module connectorModule = getConnectorModuleBuilder().createModule(connectorPlan,
connectorFile, path, null, appClientModule.getClientEnvironment(), null, appClientDeploymentContext.getModuleName(),
earContext.getNaming(), idBuilder);
-                            resourceModules.add(connectorModule);
-                            //TODO configStore == null is fishy, consider moving these stages
for connectors into the corresponding stages for this module.
-                            getConnectorModuleBuilder().installModule(connectorFile, appClientDeploymentContext,
connectorModule, null, null, repositories);
-                        }
-                        //the install step could have added more dependencies... we need
a new cl.
-                        appClientClassLoader = appClientDeploymentContext.getClassLoader();
-                        for (Iterator iterator = resourceModules.iterator(); iterator.hasNext();)
{
-                            Module connectorModule = (Module) iterator.next();
-                            getConnectorModuleBuilder().initContext(appClientDeploymentContext,
connectorModule, appClientClassLoader);
-                        }
-
-                        for (Iterator iterator = resourceModules.iterator(); iterator.hasNext();)
{
-                            Module connectorModule = (Module) iterator.next();
-                            getConnectorModuleBuilder().addGBeans(appClientDeploymentContext,
connectorModule, appClientClassLoader, repositories);
-                        }
-                    } finally {
-                        for (Iterator iterator = resourceModules.iterator(); iterator.hasNext();)
{
-                            Module connectorModule = (Module) iterator.next();
-                            connectorModule.close();
-                        }
+
+                    for (Iterator resources = appClientModule.getResourceModules().iterator();
resources.hasNext();) {
+                        ConnectorModule connectorModule = (ConnectorModule) resources.next();
+                        getConnectorModuleBuilder().addGBeans(appClientDeploymentContext,
connectorModule, appClientClassLoader, repositories);
                     }
                 }
 
@@ -530,7 +532,6 @@
                 appClientDeploymentContext.addGBean(jndiContextGBeanData);
 
                 // finally add the app client container
-//                AbstractName appClientContainerName = earContext.getNaming().createChildName(appClientDeploymentContext.getModuleName(),
"ClientContainer", "ClientContainer");
                 AbstractName appClientContainerName = appClientDeploymentContext.getModuleName();
                 GBeanData appClientContainerGBeanData = new GBeanData(appClientContainerName,
AppClientContainer.GBEAN_INFO);
                 try {
@@ -691,6 +692,7 @@
         infoBuilder.addAttribute("transactionManagerObjectName", AbstractNameQuery.class,
true);
         infoBuilder.addAttribute("connectionTrackerObjectName", AbstractNameQuery.class,
true);
         infoBuilder.addAttribute("corbaGBeanObjectName", AbstractNameQuery.class, true);
+        infoBuilder.addReference("Repositories", Repository.class, "Repository");
         infoBuilder.addReference("ConnectorModuleBuilder", ModuleBuilder.class, NameFactory.MODULE_BUILDER);
         infoBuilder.addReference("SecurityBuilder", SecurityBuilder.class, NameFactory.MODULE_BUILDER);
         infoBuilder.addReference("ServiceBuilders", NamespaceDrivenBuilder.class, NameFactory.MODULE_BUILDER);
@@ -701,6 +703,7 @@
         infoBuilder.setConstructor(new String[]{"transactionManagerObjectName",
                 "connectionTrackerObjectName",
                 "corbaGBeanObjectName",
+                "Repositories",
                 "ConnectorModuleBuilder",
                 "SecurityBuilder",
                 "ServiceBuilders",

Modified: geronimo/server/trunk/modules/geronimo-client-builder/src/test/java/org/apache/geronimo/client/builder/PlanParsingTest.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-client-builder/src/test/java/org/apache/geronimo/client/builder/PlanParsingTest.java?view=diff&rev=447998&r1=447997&r2=447998
==============================================================================
--- geronimo/server/trunk/modules/geronimo-client-builder/src/test/java/org/apache/geronimo/client/builder/PlanParsingTest.java
(original)
+++ geronimo/server/trunk/modules/geronimo-client-builder/src/test/java/org/apache/geronimo/client/builder/PlanParsingTest.java
Tue Sep 19 15:23:47 2006
@@ -1,6 +1,7 @@
 package org.apache.geronimo.client.builder;
 
 import java.io.File;
+import java.util.Collections;
 
 import org.apache.geronimo.testsupport.TestSupport;
 
@@ -19,7 +20,7 @@
     private AppClientModuleBuilder builder;
 
     protected void setUp() throws Exception {
-        builder = new AppClientModuleBuilder(new Environment(), null, null, null, null, null,
null, null, null);
+        builder = new AppClientModuleBuilder(new Environment(), null, null, null, null, Collections.EMPTY_LIST,
null, null, null, null);
     }
 
     public void testResourceRef() throws Exception {

Modified: geronimo/server/trunk/modules/geronimo-j2ee-builder/src/main/java/org/apache/geronimo/j2ee/deployment/AppClientModule.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-j2ee-builder/src/main/java/org/apache/geronimo/j2ee/deployment/AppClientModule.java?view=diff&rev=447998&r1=447997&r2=447998
==============================================================================
--- geronimo/server/trunk/modules/geronimo-j2ee-builder/src/main/java/org/apache/geronimo/j2ee/deployment/AppClientModule.java
(original)
+++ geronimo/server/trunk/modules/geronimo-j2ee-builder/src/main/java/org/apache/geronimo/j2ee/deployment/AppClientModule.java
Tue Sep 19 15:23:47 2006
@@ -20,6 +20,7 @@
 import java.net.URI;
 import java.net.URISyntaxException;
 import java.util.Collection;
+import java.util.Iterator;
 import java.util.jar.JarFile;
 
 import org.apache.geronimo.deployment.DeploymentContext;
@@ -34,12 +35,15 @@
 public class AppClientModule extends Module {
     private final Environment clientEnvironment;
     private JarFile earFile;
-    private Collection resourceModules;
+    private final AbstractName appClientName;
+    private final Collection resourceModules;
 
 
-    public AppClientModule(boolean standAlone, AbstractName moduleName, Environment serverEnvironment,
Environment clientEnvironment, JarFile moduleFile, String targetPath, XmlObject specDD, XmlObject
vendorDD, String originalSpecDD) {
+    public AppClientModule(boolean standAlone, AbstractName moduleName, AbstractName appClientName,
Environment serverEnvironment, Environment clientEnvironment, JarFile moduleFile, String targetPath,
XmlObject specDD, XmlObject vendorDD, String originalSpecDD, Collection resourceModules) {
         super(standAlone, moduleName, serverEnvironment, moduleFile, targetPath, specDD,
vendorDD, originalSpecDD, null);
         this.clientEnvironment = clientEnvironment;
+        this.appClientName = appClientName;
+        this.resourceModules = resourceModules;
     }
 
     public ConfigurationModuleType getType() {
@@ -58,17 +62,28 @@
         this.earFile = earFile;
     }
 
-    public void addClass(URI location, String fqcn, byte[] bytes, DeploymentContext context)
throws IOException, URISyntaxException {
-        context.addClass(location, fqcn, bytes);
+    public AbstractName getAppClientName() {
+        return appClientName;
     }
 
-    public void setResourceModules(Collection resourceModules) {
-        this.resourceModules = resourceModules;
+    public void addClass(URI location, String fqcn, byte[] bytes, DeploymentContext context)
throws IOException, URISyntaxException {
+        context.addClass(location, fqcn, bytes);
     }
 
     public Collection getResourceModules() {
         return resourceModules;
     }
+
+    public void close() {
+        if (resourceModules != null) {
+            for (Iterator iterator = resourceModules.iterator(); iterator.hasNext();) {
+                ConnectorModule connectorModule = (ConnectorModule) iterator.next();
+                connectorModule.close();
+            }
+        }
+        super.close();
+    }
+
 }
 
 



Mime
View raw message