You are viewing a plain text version of this content. The canonical link for it is here.
Posted to scm@geronimo.apache.org by sp...@apache.org on 2006/08/25 15:26:27 UTC
svn commit: r436786 [2/3] - in /geronimo/server/branches/sachin: ./
applications/console/ applications/console/console-core/
applications/console/console-core/src/java/
applications/console/console-core/src/main/
applications/console/console-core/src/m...
Modified: geronimo/server/branches/sachin/applications/console/console-ear/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/applications/console/console-ear/pom.xml?rev=436786&r1=436785&r2=436786&view=diff
==============================================================================
--- geronimo/server/branches/sachin/applications/console/console-ear/pom.xml (original)
+++ geronimo/server/branches/sachin/applications/console/console-ear/pom.xml Fri Aug 25 06:22:45 2006
@@ -47,6 +47,7 @@
</scm>
<dependencies>
+
<dependency>
<groupId>org.apache.geronimo.applications.console</groupId>
<artifactId>geronimo-console-framework</artifactId>
@@ -60,6 +61,7 @@
<version>${pom.version}</version>
<type>war</type>
</dependency>
+
</dependencies>
<build>
Modified: geronimo/server/branches/sachin/applications/console/console-framework/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/applications/console/console-framework/pom.xml?rev=436786&r1=436785&r2=436786&view=diff
==============================================================================
--- geronimo/server/branches/sachin/applications/console/console-framework/pom.xml (original)
+++ geronimo/server/branches/sachin/applications/console/console-framework/pom.xml Fri Aug 25 06:22:45 2006
@@ -47,6 +47,7 @@
</scm>
<dependencies>
+
<dependency>
<groupId>org.apache.geronimo.specs</groupId>
<artifactId>geronimo-servlet_2.4_spec</artifactId>
@@ -79,6 +80,7 @@
<groupId>tomcat</groupId>
<artifactId>jasper-runtime</artifactId>
</dependency>
+
</dependencies>
<build>
Modified: geronimo/server/branches/sachin/applications/console/console-standard/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/applications/console/console-standard/pom.xml?rev=436786&r1=436785&r2=436786&view=diff
==============================================================================
--- geronimo/server/branches/sachin/applications/console/console-standard/pom.xml (original)
+++ geronimo/server/branches/sachin/applications/console/console-standard/pom.xml Fri Aug 25 06:22:45 2006
@@ -153,15 +153,21 @@
<groupId>tomcat</groupId>
<artifactId>jasper-runtime</artifactId>
</dependency>
+
</dependencies>
<build>
+ <!--
+
+ FIXME:
+
<resources>
<resource>
<directory>${pom.basedir}/src/conf</directory>
<filtering>true</filtering>
</resource>
</resources>
+ -->
<plugins>
<plugin>
Modified: geronimo/server/branches/sachin/applications/console/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/applications/console/pom.xml?rev=436786&r1=436785&r2=436786&view=diff
==============================================================================
--- geronimo/server/branches/sachin/applications/console/pom.xml (original)
+++ geronimo/server/branches/sachin/applications/console/pom.xml Fri Aug 25 06:22:45 2006
@@ -30,10 +30,11 @@
<groupId>org.apache.geronimo.applications.console</groupId>
<artifactId>console</artifactId>
- <packaging>pom</packaging>
<name>Geronimo Applications :: Console</name>
-
+ <packaging>pom</packaging>
+
<dependencies>
+
<dependency>
<groupId>portlet-api</groupId>
<artifactId>portlet-api</artifactId>
@@ -45,6 +46,7 @@
<artifactId>geronimo-jsp_2.0_spec</artifactId>
<scope>provided</scope>
</dependency>
+
</dependencies>
<modules>
Modified: geronimo/server/branches/sachin/applications/geronimo-examples/geronimo-jsp-examples/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/applications/geronimo-examples/geronimo-jsp-examples/pom.xml?rev=436786&r1=436785&r2=436786&view=diff
==============================================================================
--- geronimo/server/branches/sachin/applications/geronimo-examples/geronimo-jsp-examples/pom.xml (original)
+++ geronimo/server/branches/sachin/applications/geronimo-examples/geronimo-jsp-examples/pom.xml Fri Aug 25 06:22:45 2006
@@ -65,27 +65,6 @@
</dependencies>
<build>
- <!--
- HACK: Remove when the root pom specifies the std m2 layout.
- -->
- <sourceDirectory>${pom.basedir}/src/main/java</sourceDirectory>
- <testSourceDirectory>${pom.basedir}/src/test/java</testSourceDirectory>
-
- <resources>
- <resource>
- <directory>${pom.basedir}/src/main/resources</directory>
- </resource>
- </resources>
-
- <testResources>
- <testResource>
- <directory>${pom.basedir}/src/test/resources</directory>
- </testResource>
- <testResource>
- <directory>${pom.basedir}/src/test/data</directory>
- </testResource>
- </testResources>
-
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
Modified: geronimo/server/branches/sachin/applications/geronimo-examples/geronimo-servlet-examples/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/applications/geronimo-examples/geronimo-servlet-examples/pom.xml?rev=436786&r1=436785&r2=436786&view=diff
==============================================================================
--- geronimo/server/branches/sachin/applications/geronimo-examples/geronimo-servlet-examples/pom.xml (original)
+++ geronimo/server/branches/sachin/applications/geronimo-examples/geronimo-servlet-examples/pom.xml Fri Aug 25 06:22:45 2006
@@ -43,27 +43,6 @@
</dependencies>
<build>
- <!--
- HACK: Remove when the root pom specifies the std m2 layout.
- -->
- <sourceDirectory>${pom.basedir}/src/main/java</sourceDirectory>
- <testSourceDirectory>${pom.basedir}/src/test/java</testSourceDirectory>
-
- <resources>
- <resource>
- <directory>${pom.basedir}/src/main/resources</directory>
- </resource>
- </resources>
-
- <testResources>
- <testResource>
- <directory>${pom.basedir}/src/test/resources</directory>
- </testResource>
- <testResource>
- <directory>${pom.basedir}/src/test/data</directory>
- </testResource>
- </testResources>
-
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
Modified: geronimo/server/branches/sachin/applications/ldap-realm-demo/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/applications/ldap-realm-demo/pom.xml?rev=436786&r1=436785&r2=436786&view=diff
==============================================================================
--- geronimo/server/branches/sachin/applications/ldap-realm-demo/pom.xml (original)
+++ geronimo/server/branches/sachin/applications/ldap-realm-demo/pom.xml Fri Aug 25 06:22:45 2006
@@ -52,11 +52,13 @@
</scm>
<dependencies>
+
<!-- Required for JSPC compilation -->
<dependency>
<groupId>tomcat</groupId>
<artifactId>jasper-runtime</artifactId>
</dependency>
+
</dependencies>
<build>
Modified: geronimo/server/branches/sachin/applications/magicGball/magicGball-ear/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/applications/magicGball/magicGball-ear/pom.xml?rev=436786&r1=436785&r2=436786&view=diff
==============================================================================
--- geronimo/server/branches/sachin/applications/magicGball/magicGball-ear/pom.xml (original)
+++ geronimo/server/branches/sachin/applications/magicGball/magicGball-ear/pom.xml Fri Aug 25 06:22:45 2006
@@ -33,6 +33,7 @@
<packaging>ear</packaging>
<dependencies>
+
<dependency>
<groupId>org.apache.geronimo.applications.magicGball</groupId>
<artifactId>magicGball-client</artifactId>
@@ -51,6 +52,7 @@
<version>${pom.version}</version>
<type>war</type>
</dependency>
+
</dependencies>
</project>
Modified: geronimo/server/branches/sachin/applications/magicGball/magicGball-web/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/applications/magicGball/magicGball-web/pom.xml?rev=436786&r1=436785&r2=436786&view=diff
==============================================================================
--- geronimo/server/branches/sachin/applications/magicGball/magicGball-web/pom.xml (original)
+++ geronimo/server/branches/sachin/applications/magicGball/magicGball-web/pom.xml Fri Aug 25 06:22:45 2006
@@ -33,6 +33,7 @@
<packaging>war</packaging>
<dependencies>
+
<dependency>
<groupId>org.apache.geronimo.applications.magicGball</groupId>
<artifactId>magicGball-ejb</artifactId>
@@ -44,6 +45,7 @@
<groupId>tomcat</groupId>
<artifactId>jasper-runtime</artifactId>
</dependency>
+
</dependencies>
<build>
Modified: geronimo/server/branches/sachin/applications/magicGball/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/applications/magicGball/pom.xml?rev=436786&r1=436785&r2=436786&view=diff
==============================================================================
--- geronimo/server/branches/sachin/applications/magicGball/pom.xml (original)
+++ geronimo/server/branches/sachin/applications/magicGball/pom.xml Fri Aug 25 06:22:45 2006
@@ -34,6 +34,7 @@
<packaging>pom</packaging>
<dependencies>
+
<dependency>
<groupId>org.apache.geronimo.specs</groupId>
<artifactId>geronimo-servlet_2.4_spec</artifactId>
@@ -63,6 +64,7 @@
<artifactId>geronimo-jaxrpc_1.1_spec</artifactId>
<scope>provided</scope>
</dependency>
+
</dependencies>
<modules>
Modified: geronimo/server/branches/sachin/applications/remote-deploy/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/applications/remote-deploy/pom.xml?rev=436786&r1=436785&r2=436786&view=diff
==============================================================================
--- geronimo/server/branches/sachin/applications/remote-deploy/pom.xml (original)
+++ geronimo/server/branches/sachin/applications/remote-deploy/pom.xml Fri Aug 25 06:22:45 2006
@@ -53,6 +53,7 @@
</scm>
<dependencies>
+
<dependency>
<groupId>org.apache.geronimo.specs</groupId>
<artifactId>geronimo-servlet_2.4_spec</artifactId>
@@ -70,6 +71,7 @@
<groupId>tomcat</groupId>
<artifactId>jasper-runtime</artifactId>
</dependency>
+
</dependencies>
<build>
Modified: geronimo/server/branches/sachin/applications/uddi-db/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/applications/uddi-db/pom.xml?rev=436786&r1=436785&r2=436786&view=diff
==============================================================================
--- geronimo/server/branches/sachin/applications/uddi-db/pom.xml (original)
+++ geronimo/server/branches/sachin/applications/uddi-db/pom.xml Fri Aug 25 06:22:45 2006
@@ -99,7 +99,7 @@
<onError>abort</onError>
<delimiter>;</delimiter>
<srcFiles>
- <srcFile>${pom.basedir}/src/sql/juddi.sql</srcFile>
+ <srcFile>${pom.basedir}/src/main/sql/juddi.sql</srcFile>
</srcFiles>
</configuration>
</execution>
Modified: geronimo/server/branches/sachin/modules/activemq-embedded-rar/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/modules/activemq-embedded-rar/pom.xml?rev=436786&r1=436785&r2=436786&view=diff
==============================================================================
--- geronimo/server/branches/sachin/modules/activemq-embedded-rar/pom.xml (original)
+++ geronimo/server/branches/sachin/modules/activemq-embedded-rar/pom.xml Fri Aug 25 06:22:45 2006
@@ -47,19 +47,8 @@
<url>http://svn.apache.org/viewvc/geronimo/trunk/modules/activemq-embedded-rar</url>
</scm>
- <build>
- <plugins>
- <plugin>
- <artifactId>maven-rar-plugin</artifactId>
- <configuration>
- <raXmlFile>${basedir}/src/rar/META-INF/ra.xml</raXmlFile>
- <includeJar>false</includeJar>
- </configuration>
- </plugin>
- </plugins>
- </build>
-
<dependencies>
+
<dependency>
<groupId>activemq</groupId>
<artifactId>activemq-core</artifactId>
@@ -69,7 +58,19 @@
<groupId>activemq</groupId>
<artifactId>activemq-ra</artifactId>
</dependency>
+
</dependencies>
+
+ <build>
+ <plugins>
+ <plugin>
+ <artifactId>maven-rar-plugin</artifactId>
+ <configuration>
+ <includeJar>false</includeJar>
+ </configuration>
+ </plugin>
+ </plugins>
+ </build>
<!--
HACK: Currently need to pickup the Codehaus m1 repo for activemq-*:3.2.4-SNAPSHOT
Modified: geronimo/server/branches/sachin/modules/activemq-gbean-management/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/modules/activemq-gbean-management/pom.xml?rev=436786&r1=436785&r2=436786&view=diff
==============================================================================
--- geronimo/server/branches/sachin/modules/activemq-gbean-management/pom.xml (original)
+++ geronimo/server/branches/sachin/modules/activemq-gbean-management/pom.xml Fri Aug 25 06:22:45 2006
@@ -58,11 +58,5 @@
</dependency>
</dependencies>
-
- <build>
- <!-- FIXME: Remove when the default is to use the m2 standard layout -->
- <sourceDirectory>${pom.basedir}/src/main/java</sourceDirectory>
- <testSourceDirectory>${pom.basedir}/src/test/java</testSourceDirectory>
- </build>
</project>
Modified: geronimo/server/branches/sachin/modules/activemq-gbean/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/modules/activemq-gbean/pom.xml?rev=436786&r1=436785&r2=436786&view=diff
==============================================================================
--- geronimo/server/branches/sachin/modules/activemq-gbean/pom.xml (original)
+++ geronimo/server/branches/sachin/modules/activemq-gbean/pom.xml Fri Aug 25 06:22:45 2006
@@ -94,12 +94,6 @@
</dependency>
</dependencies>
-
- <build>
- <!-- FIXME: Remove when the default is to use the m2 standard layout -->
- <sourceDirectory>${pom.basedir}/src/main/java</sourceDirectory>
- <testSourceDirectory>${pom.basedir}/src/test/java</testSourceDirectory>
- </build>
<!--
HACK: Need the Apache m1 snapshot repo to pick up incubator-activemq:*
Modified: geronimo/server/branches/sachin/modules/axis-builder/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/modules/axis-builder/pom.xml?rev=436786&r1=436785&r2=436786&view=diff
==============================================================================
--- geronimo/server/branches/sachin/modules/axis-builder/pom.xml (original)
+++ geronimo/server/branches/sachin/modules/axis-builder/pom.xml Fri Aug 25 06:22:45 2006
@@ -119,20 +119,16 @@
<artifactId>wsdl4j</artifactId>
</dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.modules</groupId>
+ <artifactId>geronimo-testsupport</artifactId>
+ <version>${pom.version}</version>
+ <scope>test</scope>
+ </dependency>
+
</dependencies>
<build>
- <resources>
- <!-- This schema is NOT compiled to xmlobjects. Do not remove! Used by SchemaInfoBuilder -->
- <resource>
- <directory>src/schema</directory>
- <includes>
- <include>soap_encoding_1_1.xsd</include>
- </includes>
- <targetPath>META-INF/schema</targetPath>
- </resource>
- </resources>
-
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
Propchange: geronimo/server/branches/sachin/modules/axis-builder/src/main/java/
------------------------------------------------------------------------------
--- svk:merge (added)
+++ svk:merge Fri Aug 25 06:22:45 2006
@@ -0,0 +1 @@
+13f79535-47bb-0310-9956-ffa450edef68:/geronimo/sandbox/svkmerge/trunk/modules/axis-builder/src/java:423551
Copied: geronimo/server/branches/sachin/modules/axis-builder/src/main/java/org/apache/geronimo/axis/builder/AxisBuilder.java (from r436742, geronimo/server/trunk/modules/axis-builder/src/main/java/org/apache/geronimo/axis/builder/AxisBuilder.java)
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/modules/axis-builder/src/main/java/org/apache/geronimo/axis/builder/AxisBuilder.java?p2=geronimo/server/branches/sachin/modules/axis-builder/src/main/java/org/apache/geronimo/axis/builder/AxisBuilder.java&p1=geronimo/server/trunk/modules/axis-builder/src/main/java/org/apache/geronimo/axis/builder/AxisBuilder.java&r1=436742&r2=436786&rev=436786&view=diff
==============================================================================
--- geronimo/server/trunk/modules/axis-builder/src/main/java/org/apache/geronimo/axis/builder/AxisBuilder.java (original)
+++ geronimo/server/branches/sachin/modules/axis-builder/src/main/java/org/apache/geronimo/axis/builder/AxisBuilder.java Fri Aug 25 06:22:45 2006
@@ -58,6 +58,7 @@
import org.apache.geronimo.axis.server.ServiceInfo;
import org.apache.geronimo.common.DeploymentException;
import org.apache.geronimo.deployment.DeploymentContext;
+import org.apache.geronimo.deployment.DeployableModule;
import org.apache.geronimo.gbean.GBeanData;
import org.apache.geronimo.gbean.GBeanInfo;
import org.apache.geronimo.gbean.GBeanInfoBuilder;
@@ -84,11 +85,11 @@
//WebServiceBuilder
- public Map parseWebServiceDescriptor(URL wsDDUrl, JarFile moduleFile, boolean isEJB, Map servletLocations) throws DeploymentException {
- return WSDescriptorParser.parseWebServiceDescriptor(wsDDUrl, moduleFile, isEJB, servletLocations);
+ public Map parseWebServiceDescriptor(URL wsDDUrl, DeployableModule deployableModule, boolean isEJB, Map servletLocations) throws DeploymentException {
+ return WSDescriptorParser.parseWebServiceDescriptor(wsDDUrl, deployableModule, isEJB, servletLocations);
}
- public void configurePOJO(GBeanData targetGBean, JarFile moduleFile, Object portInfoObject, String seiClassName, ClassLoader classLoader) throws DeploymentException {
+ public void configurePOJO(GBeanData targetGBean, DeployableModule deployableModule, Object portInfoObject, String seiClassName, ClassLoader classLoader) throws DeploymentException {
PortInfo portInfo = (PortInfo) portInfoObject;
ServiceInfo serviceInfo = AxisServiceBuilder.createServiceInfo(portInfo, classLoader);
JavaServiceDesc serviceDesc = serviceInfo.getServiceDesc();
@@ -127,7 +128,7 @@
targetGBean.setAttribute("webServiceContainer", axisWebServiceContainer);
}
- public void configureEJB(GBeanData targetGBean, JarFile moduleFile, Object portInfoObject, ClassLoader classLoader) throws DeploymentException {
+ public void configureEJB(GBeanData targetGBean, DeployableModule deployableModule, Object portInfoObject, ClassLoader classLoader) throws DeploymentException {
PortInfo portInfo = (PortInfo) portInfoObject;
ServiceInfo serviceInfo = AxisServiceBuilder.createServiceInfo(portInfo, classLoader);
targetGBean.setAttribute("serviceInfo", serviceInfo);
@@ -147,13 +148,13 @@
//ServicereferenceBuilder
public Object createService(Class serviceInterface, URI wsdlURI, URI jaxrpcMappingURI, QName serviceQName, Map portComponentRefMap, List handlerInfos, Object serviceRefType, DeploymentContext deploymentContext, Module module, ClassLoader classLoader) throws DeploymentException {
GerServiceRefType gerServiceRefType = (GerServiceRefType) serviceRefType;
- JarFile moduleFile = module.getModuleFile();
+ DeployableModule deployableModule = module.getModuleFile();
SchemaInfoBuilder schemaInfoBuilder = null;
JavaWsdlMappingType mapping = null;
if (wsdlURI != null) {
- schemaInfoBuilder = new SchemaInfoBuilder(moduleFile, wsdlURI);
+ schemaInfoBuilder = new SchemaInfoBuilder(deployableModule, wsdlURI);
- mapping = WSDescriptorParser.readJaxrpcMapping(moduleFile, jaxrpcMappingURI);
+ mapping = WSDescriptorParser.readJaxrpcMapping(deployableModule, jaxrpcMappingURI);
}
return createService(serviceInterface, schemaInfoBuilder, mapping, serviceQName, SOAP_VERSION, handlerInfos, gerServiceRefType, deploymentContext, module, classLoader);
Copied: geronimo/server/branches/sachin/modules/axis-builder/src/main/java/org/apache/geronimo/axis/builder/SchemaInfoBuilder.java (from r436742, geronimo/server/trunk/modules/axis-builder/src/main/java/org/apache/geronimo/axis/builder/SchemaInfoBuilder.java)
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/modules/axis-builder/src/main/java/org/apache/geronimo/axis/builder/SchemaInfoBuilder.java?p2=geronimo/server/branches/sachin/modules/axis-builder/src/main/java/org/apache/geronimo/axis/builder/SchemaInfoBuilder.java&p1=geronimo/server/trunk/modules/axis-builder/src/main/java/org/apache/geronimo/axis/builder/SchemaInfoBuilder.java&r1=436742&r2=436786&rev=436786&view=diff
==============================================================================
--- geronimo/server/trunk/modules/axis-builder/src/main/java/org/apache/geronimo/axis/builder/SchemaInfoBuilder.java (original)
+++ geronimo/server/branches/sachin/modules/axis-builder/src/main/java/org/apache/geronimo/axis/builder/SchemaInfoBuilder.java Fri Aug 25 06:22:45 2006
@@ -54,6 +54,7 @@
import org.apache.geronimo.xbeans.wsdl.TPort;
import org.apache.geronimo.xbeans.wsdl.TService;
import org.apache.geronimo.deployment.xmlbeans.XmlBeansUtil;
+import org.apache.geronimo.deployment.DeployableModule;
import org.apache.xmlbeans.SchemaField;
import org.apache.xmlbeans.SchemaGlobalElement;
import org.apache.xmlbeans.SchemaParticle;
@@ -112,7 +113,7 @@
}
}
- private final JarFile moduleFile;
+ private final DeployableModule deployableModule;
private final Definition definition;
private final Stack uris = new Stack();
private final Map wsdlMap = new HashMap();
@@ -123,24 +124,24 @@
private final Map portMap;
- public SchemaInfoBuilder(JarFile moduleFile, URI wsdlUri) throws DeploymentException {
- this(moduleFile, wsdlUri, null, null);
+ public SchemaInfoBuilder(DeployableModule deployableModule, URI wsdlUri) throws DeploymentException {
+ this(deployableModule, wsdlUri, null, null);
}
- public SchemaInfoBuilder(JarFile moduleFile, Definition definition) throws DeploymentException {
- this(moduleFile, null, definition, null);
+ public SchemaInfoBuilder(DeployableModule deployableModule, Definition definition) throws DeploymentException {
+ this(deployableModule, null, definition, null);
}
- SchemaInfoBuilder(JarFile moduleFile, URI uri, SchemaTypeSystem schemaTypeSystem) throws DeploymentException {
- this(moduleFile, uri, null, schemaTypeSystem);
+ SchemaInfoBuilder(DeployableModule deployableModule, URI uri, SchemaTypeSystem schemaTypeSystem) throws DeploymentException {
+ this(deployableModule, uri, null, schemaTypeSystem);
}
- SchemaInfoBuilder(JarFile moduleFile, URI uri, Definition definition, SchemaTypeSystem schemaTypeSystem) throws DeploymentException {
- this.moduleFile = moduleFile;
+ SchemaInfoBuilder(DeployableModule deployableModle, URI uri, Definition definition, SchemaTypeSystem schemaTypeSystem) throws DeploymentException {
+ this.deployableModule = deployableModle;
if (uri != null) {
uris.push(uri);
if (definition == null && schemaTypeSystem == null) {
- definition = readWsdl(moduleFile, uri);
+ definition = readWsdl(deployableModle, uri);
}
} else if (definition != null) {
try {
@@ -513,7 +514,7 @@
}
- public Definition readWsdl(JarFile moduleFile, URI wsdlURI) throws DeploymentException {
+ public Definition readWsdl(DeployableModule deployableModule, URI wsdlURI) throws DeploymentException {
Definition definition;
WSDLFactory wsdlFactory = null;
try {
@@ -619,12 +620,12 @@
URI location = ((URI) uris.peek()).resolve(systemId);
InputStream wsdlInputStream = null;
try {
- ZipEntry entry = moduleFile.getEntry(location.toString());
- wsdlInputStream = moduleFile.getInputStream(entry);
+ ZipEntry entry = deployableModule.getEntry(location.toString());
+ wsdlInputStream = deployableModule.getInputStream(entry);
XmlObject xmlObject = SchemaDocument.Factory.parse(wsdlInputStream);
wsdlMap.put(location, xmlObject);
wsdlInputStream.close();
- wsdlInputStream = moduleFile.getInputStream(entry);
+ wsdlInputStream = deployableModule.getInputStream(entry);
} catch (XmlException e) {
throw (IOException) new IOException("Could not parse schema document").initCause(e);
}
@@ -644,12 +645,12 @@
public InputSource getBaseInputSource() {
InputStream wsdlInputStream = null;
try {
- ZipEntry entry = moduleFile.getEntry(wsdlURI.toString());
- wsdlInputStream = moduleFile.getInputStream(entry);
+ ZipEntry entry = deployableModule.getEntry(wsdlURI.toString());
+ wsdlInputStream = deployableModule.getInputStream(entry);
DefinitionsDocument definition = DefinitionsDocument.Factory.parse(wsdlInputStream);
wsdlMap.put(wsdlURI, definition);
wsdlInputStream.close();
- wsdlInputStream = moduleFile.getInputStream(entry);
+ wsdlInputStream = deployableModule.getInputStream(entry);
} catch (Exception e) {
throw new RuntimeException("Could not open stream to wsdl file", e);
}
@@ -665,8 +666,8 @@
latestImportURI = parentURI.resolve(relativeLocation);
InputStream importInputStream = null;
try {
- ZipEntry entry = moduleFile.getEntry(latestImportURI.toString());
- importInputStream = moduleFile.getInputStream(entry);
+ ZipEntry entry = deployableModule.getEntry(latestImportURI.toString());
+ importInputStream = deployableModule.getInputStream(entry);
try {
DefinitionsDocument definition = DefinitionsDocument.Factory.parse(importInputStream);
importInputStream.close();
@@ -675,7 +676,7 @@
} catch (XmlException e) {
//probably was a schema rather than wsdl. If there are real problems they will show up later.
}
- importInputStream = moduleFile.getInputStream(entry);
+ importInputStream = deployableModule.getInputStream(entry);
} catch (Exception e) {
throw new RuntimeException("Could not open stream to import file", e);
}
Copied: geronimo/server/branches/sachin/modules/axis-builder/src/main/java/org/apache/geronimo/axis/builder/WSDescriptorParser.java (from r436742, geronimo/server/trunk/modules/axis-builder/src/main/java/org/apache/geronimo/axis/builder/WSDescriptorParser.java)
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/modules/axis-builder/src/main/java/org/apache/geronimo/axis/builder/WSDescriptorParser.java?p2=geronimo/server/branches/sachin/modules/axis-builder/src/main/java/org/apache/geronimo/axis/builder/WSDescriptorParser.java&p1=geronimo/server/trunk/modules/axis-builder/src/main/java/org/apache/geronimo/axis/builder/WSDescriptorParser.java&r1=436742&r2=436786&rev=436786&view=diff
==============================================================================
--- geronimo/server/trunk/modules/axis-builder/src/main/java/org/apache/geronimo/axis/builder/WSDescriptorParser.java (original)
+++ geronimo/server/branches/sachin/modules/axis-builder/src/main/java/org/apache/geronimo/axis/builder/WSDescriptorParser.java Fri Aug 25 06:22:45 2006
@@ -76,6 +76,7 @@
import org.apache.geronimo.xbeans.j2ee.WebservicesType;
import org.apache.geronimo.xbeans.j2ee.XsdQNameType;
import org.apache.geronimo.deployment.xmlbeans.XmlBeansUtil;
+import org.apache.geronimo.deployment.DeployableModule;
import org.apache.xmlbeans.XmlException;
/**
@@ -84,20 +85,20 @@
public class WSDescriptorParser {
- public static JavaWsdlMappingType readJaxrpcMapping(JarFile moduleFile, URI jaxrpcMappingURI) throws DeploymentException {
+ public static JavaWsdlMappingType readJaxrpcMapping(DeployableModule deployableModule, URI jaxrpcMappingURI) throws DeploymentException {
String jaxrpcMappingPath = jaxrpcMappingURI.toString();
- return readJaxrpcMapping(moduleFile, jaxrpcMappingPath);
+ return readJaxrpcMapping(deployableModule, jaxrpcMappingPath);
}
- public static JavaWsdlMappingType readJaxrpcMapping(JarFile moduleFile, String jaxrpcMappingPath) throws DeploymentException {
+ public static JavaWsdlMappingType readJaxrpcMapping(DeployableModule deployableModule, String jaxrpcMappingPath) throws DeploymentException {
JavaWsdlMappingType mapping;
InputStream jaxrpcInputStream = null;
try {
- ZipEntry zipEntry = moduleFile.getEntry(jaxrpcMappingPath);
+ ZipEntry zipEntry = deployableModule.getEntry(jaxrpcMappingPath);
if(zipEntry == null){
throw new DeploymentException("The JAX-RPC mapping file "+jaxrpcMappingPath+" specified in webservices.xml for the ejb module could not be found.");
}
- jaxrpcInputStream = moduleFile.getInputStream(zipEntry);
+ jaxrpcInputStream = deployableModule.getInputStream(zipEntry);
} catch (IOException e) {
throw new DeploymentException("Could not open stream to jaxrpc mapping document", e);
}
@@ -291,13 +292,13 @@
* corresponding ejb-link or servlet-link element .
*
* @param webservicesType
- * @param moduleFile
+ * @param deployableModule
* @param isEJB
* @param servletLocations
* @return
* @throws org.apache.geronimo.common.DeploymentException
*/
- public static Map parseWebServiceDescriptor(WebservicesType webservicesType, JarFile moduleFile, boolean isEJB, Map servletLocations) throws DeploymentException {
+ public static Map parseWebServiceDescriptor(WebservicesType webservicesType, DeployableModule deployableModule, boolean isEJB, Map servletLocations) throws DeploymentException {
Map portMap = new HashMap();
WebserviceDescriptionType[] webserviceDescriptions = webservicesType.getWebserviceDescriptionArray();
for (int i = 0; i < webserviceDescriptions.length; i++) {
@@ -314,10 +315,10 @@
} catch (URISyntaxException e) {
throw new DeploymentException("Could not construct jaxrpc mapping uri from " + webserviceDescription.getJaxrpcMappingFile(), e);
}
- SchemaInfoBuilder schemaInfoBuilder = new SchemaInfoBuilder(moduleFile, wsdlURI);
+ SchemaInfoBuilder schemaInfoBuilder = new SchemaInfoBuilder(deployableModule, wsdlURI);
Map wsdlPortMap = schemaInfoBuilder.getPortMap();
- JavaWsdlMappingType javaWsdlMapping = readJaxrpcMapping(moduleFile, jaxrpcMappingURI);
+ JavaWsdlMappingType javaWsdlMapping = readJaxrpcMapping(deployableModule, jaxrpcMappingURI);
HashMap seiMappings = new HashMap();
ServiceEndpointInterfaceMappingType[] mappings = javaWsdlMapping.getServiceEndpointInterfaceMappingArray();
for (int j = 0; j < mappings.length; j++) {
@@ -376,12 +377,12 @@
return portMap;
}
- public static Map parseWebServiceDescriptor(URL wsDDUrl, JarFile moduleFile, boolean isEJB, Map servletLocations) throws DeploymentException {
+ public static Map parseWebServiceDescriptor(URL wsDDUrl, DeployableModule deployableModule, boolean isEJB, Map servletLocations) throws DeploymentException {
try {
WebservicesDocument webservicesDocument = WebservicesDocument.Factory.parse(wsDDUrl);
XmlBeansUtil.validateDD(webservicesDocument);
WebservicesType webservicesType = webservicesDocument.getWebservices();
- return parseWebServiceDescriptor(webservicesType, moduleFile, isEJB, servletLocations);
+ return parseWebServiceDescriptor(webservicesType, deployableModule, isEJB, servletLocations);
} catch (XmlException e) {
throw new DeploymentException("Could not read descriptor document", e);
} catch (IOException e) {
Modified: geronimo/server/branches/sachin/modules/axis/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/modules/axis/pom.xml?rev=436786&r1=436785&r2=436786&view=diff
==============================================================================
--- geronimo/server/branches/sachin/modules/axis/pom.xml (original)
+++ geronimo/server/branches/sachin/modules/axis/pom.xml Fri Aug 25 06:22:45 2006
@@ -48,6 +48,7 @@
</scm>
<dependencies>
+
<dependency>
<groupId>org.apache.geronimo.modules</groupId>
<artifactId>geronimo-kernel</artifactId>
@@ -122,15 +123,15 @@
<groupId>wsdl4j</groupId>
<artifactId>wsdl4j</artifactId>
</dependency>
+
+ <dependency>
+ <groupId>org.apache.geronimo.modules</groupId>
+ <artifactId>geronimo-testsupport</artifactId>
+ <version>${pom.version}</version>
+ <scope>test</scope>
+ </dependency>
+
</dependencies>
-
- <build>
- <resources>
- <resource>
- <directory>src/resources2</directory>
- </resource>
- </resources>
- </build>
</project>
Modified: geronimo/server/branches/sachin/modules/client-builder/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/modules/client-builder/pom.xml?rev=436786&r1=436785&r2=436786&view=diff
==============================================================================
--- geronimo/server/branches/sachin/modules/client-builder/pom.xml (original)
+++ geronimo/server/branches/sachin/modules/client-builder/pom.xml Fri Aug 25 06:22:45 2006
@@ -66,16 +66,17 @@
<artifactId>geronimo-security-builder</artifactId>
<version>${pom.version}</version>
</dependency>
-
+
+ <dependency>
+ <groupId>org.apache.geronimo.modules</groupId>
+ <artifactId>geronimo-testsupport</artifactId>
+ <version>${pom.version}</version>
+ <scope>test</scope>
+ </dependency>
+
</dependencies>
<build>
- <resources>
- <resource>
- <directory>${pom.basedir}/src/resources2</directory>
- </resource>
- </resources>
-
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
Copied: geronimo/server/branches/sachin/modules/client-builder/src/main/java/org/apache/geronimo/client/builder/AppClientModuleBuilder.java (from r436742, geronimo/server/trunk/modules/client-builder/src/main/java/org/apache/geronimo/client/builder/AppClientModuleBuilder.java)
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/modules/client-builder/src/main/java/org/apache/geronimo/client/builder/AppClientModuleBuilder.java?p2=geronimo/server/branches/sachin/modules/client-builder/src/main/java/org/apache/geronimo/client/builder/AppClientModuleBuilder.java&p1=geronimo/server/trunk/modules/client-builder/src/main/java/org/apache/geronimo/client/builder/AppClientModuleBuilder.java&r1=436742&r2=436786&rev=436786&view=diff
==============================================================================
--- geronimo/server/trunk/modules/client-builder/src/main/java/org/apache/geronimo/client/builder/AppClientModuleBuilder.java (original)
+++ geronimo/server/branches/sachin/modules/client-builder/src/main/java/org/apache/geronimo/client/builder/AppClientModuleBuilder.java Fri Aug 25 06:22:45 2006
@@ -38,16 +38,11 @@
import org.apache.geronimo.client.AppClientContainer;
import org.apache.geronimo.client.StaticJndiContextPlugin;
import org.apache.geronimo.common.DeploymentException;
-import org.apache.geronimo.deployment.DeploymentContext;
-import org.apache.geronimo.deployment.ModuleIDBuilder;
-import org.apache.geronimo.deployment.NamespaceDrivenBuilder;
-import org.apache.geronimo.deployment.NamespaceDrivenBuilderCollection;
+import org.apache.geronimo.deployment.*;
import org.apache.geronimo.deployment.service.EnvironmentBuilder;
-import org.apache.geronimo.deployment.service.ServiceConfigBuilder;
import org.apache.geronimo.deployment.util.DeploymentUtil;
import org.apache.geronimo.deployment.util.NestedJarFile;
import org.apache.geronimo.deployment.xbeans.EnvironmentType;
-import org.apache.geronimo.deployment.xbeans.GbeanType;
import org.apache.geronimo.deployment.xmlbeans.XmlBeansUtil;
import org.apache.geronimo.gbean.AbstractName;
import org.apache.geronimo.gbean.AbstractNameQuery;
@@ -203,15 +198,15 @@
return (SecurityBuilder) securityBuilder.getElement();
}
- public Module createModule(File plan, JarFile moduleFile, Naming naming, ModuleIDBuilder idBuilder) throws DeploymentException {
+ public Module createModule(File plan, DeployableModule moduleFile, Naming naming, ModuleIDBuilder idBuilder) throws DeploymentException {
return createModule(plan, moduleFile, "app-client", null, null, null, naming, idBuilder);
}
- public Module createModule(Object plan, JarFile moduleFile, String targetPath, URL specDDUrl, Environment environment, Object moduleContextInfo, AbstractName earName, Naming naming, ModuleIDBuilder idBuilder) throws DeploymentException {
+ public Module createModule(Object plan, DeployableModule moduleFile, String targetPath, URL specDDUrl, Environment environment, Object moduleContextInfo, AbstractName earName, Naming naming, ModuleIDBuilder idBuilder) throws DeploymentException {
return createModule(plan, moduleFile, targetPath, specDDUrl, environment, earName, naming, idBuilder);
}
- private Module createModule(Object plan, JarFile moduleFile, String targetPath, URL specDDUrl, Environment earEnvironment, AbstractName earName, Naming naming, ModuleIDBuilder idBuilder) throws DeploymentException {
+ private Module createModule(Object plan, DeployableModule moduleFile, String targetPath, URL specDDUrl, Environment earEnvironment, AbstractName earName, Naming naming, ModuleIDBuilder idBuilder) throws DeploymentException {
assert moduleFile != null: "moduleFile is null";
assert targetPath != null: "targetPath is null";
assert !targetPath.endsWith("/"): "targetPath must not end with a '/'";
@@ -221,7 +216,7 @@
ApplicationClientType appClient;
try {
if (specDDUrl == null) {
- specDDUrl = DeploymentUtil.createJarURL(moduleFile, "META-INF/application-client.xml");
+ specDDUrl = moduleFile.resolve("META-INF/application-client.xml");
}
// read in the entire specDD as a string, we need this for getDeploymentDescriptor
@@ -248,12 +243,12 @@
EnvironmentType clientEnvironmentType = gerAppClient.getClientEnvironment();
Environment clientEnvironment = EnvironmentBuilder.buildEnvironment(clientEnvironmentType, defaultClientEnvironment);
+ String name = moduleFile.getRoot().getName();
if(standAlone) {
- String name = new File(moduleFile.getName()).getName();
idBuilder.resolve(clientEnvironment, name+"_"+name, "jar");
} else {
Artifact earConfigId = earEnvironment.getConfigId();
- idBuilder.resolve(clientEnvironment, earConfigId.getArtifactId() + "_" + new File(moduleFile.getName()).getName(), "jar");
+ idBuilder.resolve(clientEnvironment, earConfigId.getArtifactId() + "_" + name, "jar");
}
EnvironmentType serverEnvironmentType = gerAppClient.getServerEnvironment();
Environment serverEnvironment = EnvironmentBuilder.buildEnvironment(serverEnvironmentType, defaultServerEnvironment);
@@ -264,7 +259,7 @@
throw new IllegalStateException("Server environment module ID should be fully resolved (not "+serverEnvironment.getConfigId()+")");
}
} else {
- idBuilder.resolve(serverEnvironment, new File(moduleFile.getName()).getName(), "jar");
+ idBuilder.resolve(serverEnvironment, name, "jar");
}
AbstractName moduleName;
@@ -278,7 +273,7 @@
return new AppClientModule(standAlone, moduleName, serverEnvironment, clientEnvironment, moduleFile, targetPath, appClient, gerAppClient, specDD);
}
- GerApplicationClientType getGeronimoAppClient(Object plan, JarFile moduleFile, boolean standAlone, String targetPath, ApplicationClientType appClient, Environment environment) throws DeploymentException {
+ GerApplicationClientType getGeronimoAppClient(Object plan, DeployableModule moduleFile, boolean standAlone, String targetPath, ApplicationClientType appClient, Environment environment) throws DeploymentException {
GerApplicationClientType gerAppClient;
XmlObject rawPlan = null;
try {
@@ -290,7 +285,7 @@
if (plan != null) {
rawPlan = XmlBeansUtil.parse((File) plan);
} else {
- URL path = DeploymentUtil.createJarURL(moduleFile, "META-INF/geronimo-application-client.xml");
+ URL path = moduleFile.resolve("META-INF/geronimo-application-client.xml");
rawPlan = XmlBeansUtil.parse(path, getClass().getClassLoader());
}
}
@@ -305,7 +300,7 @@
String path;
if (standAlone) {
// default configId is based on the moduleFile name
- path = new File(moduleFile.getName()).getName();
+ path = moduleFile.getRoot().getName();
} else {
// default configId is based on the module uri from the application.xml
path = targetPath;
@@ -346,7 +341,7 @@
return geronimoAppClient;
}
- public void installModule(JarFile earFile, EARContext earContext, Module module, Collection configurationStores, ConfigurationStore targetConfigurationStore, Collection repositories) throws DeploymentException {
+ public void installModule(DeployableModule earFile, EARContext earContext, Module module, Collection configurationStores, ConfigurationStore targetConfigurationStore, Collection repositories) throws DeploymentException {
// extract the app client jar file into a standalone packed jar file and add the contents to the output
JarFile moduleFile = module.getModuleFile();
try {
@@ -355,7 +350,7 @@
throw new DeploymentException("Unable to copy app client module jar into configuration: " + moduleFile.getName());
}
AppClientModule appClientModule = (AppClientModule) module;
- appClientModule.setEarFile(earFile);
+ appClientModule.setEar(earFile);
//create the ear context for the app client.
Environment clientEnvironment = appClientModule.getClientEnvironment();
if (!appClientModule.isStandAlone() || clientEnvironment.getConfigId() == null) {
@@ -474,7 +469,7 @@
}
// add manifest class path entries to the app client context
- addManifestClassPath(appClientDeploymentContext, appClientModule.getEarFile(), moduleFile, moduleBase);
+ addManifestClassPath(appClientDeploymentContext, appClientModule.getEar(), moduleFile, moduleBase);
// get the classloader
ClassLoader appClientClassLoader = appClientDeploymentContext.getClassLoader();
@@ -512,7 +507,7 @@
} else {
path = resource.getInternalRar();
try {
- connectorFile = new NestedJarFile(appClientModule.getEarFile(), path);
+ connectorFile = new NestedJarFile(appClientModule.getEar(), path);
} catch (IOException e) {
throw new DeploymentException("Could not locate connector inside ear", e);
}
@@ -619,7 +614,7 @@
return GERAPPCLIENT_NAMESPACE;
}
- public void addManifestClassPath(DeploymentContext deploymentContext, JarFile earFile, JarFile jarFile, URI jarFileLocation) throws DeploymentException {
+ public void addManifestClassPath(DeploymentContext deploymentContext, DeployableModule earFile, DeployableModule jarFile, URI jarFileLocation) throws DeploymentException {
Manifest manifest;
try {
manifest = jarFile.getManifest();
Modified: geronimo/server/branches/sachin/modules/client/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/modules/client/pom.xml?rev=436786&r1=436785&r2=436786&view=diff
==============================================================================
--- geronimo/server/branches/sachin/modules/client/pom.xml (original)
+++ geronimo/server/branches/sachin/modules/client/pom.xml Fri Aug 25 06:22:45 2006
@@ -88,5 +88,6 @@
</dependency>
</dependencies>
+
</project>
Modified: geronimo/server/branches/sachin/modules/connector-builder/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/modules/connector-builder/pom.xml?rev=436786&r1=436785&r2=436786&view=diff
==============================================================================
--- geronimo/server/branches/sachin/modules/connector-builder/pom.xml (original)
+++ geronimo/server/branches/sachin/modules/connector-builder/pom.xml Fri Aug 25 06:22:45 2006
@@ -80,20 +80,16 @@
<artifactId>tranql</artifactId>
</dependency>
+ <dependency>
+ <groupId>org.apache.geronimo.modules</groupId>
+ <artifactId>geronimo-testsupport</artifactId>
+ <version>${pom.version}</version>
+ <scope>test</scope>
+ </dependency>
+
</dependencies>
<build>
- <resources>
- <!-- TODO this should not be needed -->
- <!--<resource>-->
- <!--<directory>${pom.basedir}/src/schema</directory>-->
- <!--<targetPath>META-INF</targetPath>-->
- <!--<includes>-->
- <!--<include>geronimo-connector-1.2.xsd</include>-->
- <!--</includes>-->
- <!--</resource>-->
- </resources>
-
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
@@ -112,7 +108,7 @@
<phase>process-test-resources</phase>
<configuration>
<tasks>
- <ant antfile="${pom.basedir}/src/test/test-setup.xml"/>
+ <ant antfile="${pom.basedir}/src/test/script/test-setup.xml"/>
</tasks>
</configuration>
<goals>
Copied: geronimo/server/branches/sachin/modules/connector-builder/src/main/java/org/apache/geronimo/connector/deployment/ConnectorModuleBuilder.java (from r436742, geronimo/server/trunk/modules/connector-builder/src/main/java/org/apache/geronimo/connector/deployment/ConnectorModuleBuilder.java)
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/modules/connector-builder/src/main/java/org/apache/geronimo/connector/deployment/ConnectorModuleBuilder.java?p2=geronimo/server/branches/sachin/modules/connector-builder/src/main/java/org/apache/geronimo/connector/deployment/ConnectorModuleBuilder.java&p1=geronimo/server/trunk/modules/connector-builder/src/main/java/org/apache/geronimo/connector/deployment/ConnectorModuleBuilder.java&r1=436742&r2=436786&rev=436786&view=diff
==============================================================================
--- geronimo/server/trunk/modules/connector-builder/src/main/java/org/apache/geronimo/connector/deployment/ConnectorModuleBuilder.java (original)
+++ geronimo/server/branches/sachin/modules/connector-builder/src/main/java/org/apache/geronimo/connector/deployment/ConnectorModuleBuilder.java Fri Aug 25 06:22:45 2006
@@ -64,6 +64,7 @@
import org.apache.geronimo.deployment.ModuleIDBuilder;
import org.apache.geronimo.deployment.NamespaceDrivenBuilderCollection;
import org.apache.geronimo.deployment.NamespaceDrivenBuilder;
+import org.apache.geronimo.deployment.DeployableModule;
import org.apache.geronimo.deployment.service.EnvironmentBuilder;
import org.apache.geronimo.deployment.util.DeploymentUtil;
import org.apache.geronimo.deployment.xbeans.EnvironmentType;
@@ -153,15 +154,15 @@
this.serviceBuilders = new NamespaceDrivenBuilderCollection(serviceBuilders);
}
- public Module createModule(File plan, JarFile moduleFile, Naming naming, ModuleIDBuilder idBuilder) throws DeploymentException {
+ public Module createModule(File plan, DeployableModule moduleFile, Naming naming, ModuleIDBuilder idBuilder) throws DeploymentException {
return createModule(plan, moduleFile, "rar", null, null, null, naming, idBuilder);
}
- public Module createModule(Object plan, JarFile moduleFile, String targetPath, URL specDDUrl, Environment environment, Object moduleContextInfo, AbstractName earName, Naming naming, ModuleIDBuilder idBuilder) throws DeploymentException {
+ public Module createModule(Object plan, DeployableModule moduleFile, String targetPath, URL specDDUrl, Environment environment, Object moduleContextInfo, AbstractName earName, Naming naming, ModuleIDBuilder idBuilder) throws DeploymentException {
return createModule(plan, moduleFile, targetPath, specDDUrl, environment, earName, naming, idBuilder);
}
- private Module createModule(Object plan, JarFile moduleFile, String targetPath, URL specDDUrl, Environment earEnvironment, AbstractName earName, Naming naming, ModuleIDBuilder idBuilder) throws DeploymentException {
+ private Module createModule(Object plan, DeployableModule moduleFile, String targetPath, URL specDDUrl, Environment earEnvironment, AbstractName earName, Naming naming, ModuleIDBuilder idBuilder) throws DeploymentException {
assert moduleFile != null: "moduleFile is null";
assert targetPath != null: "targetPath is null";
assert !targetPath.endsWith("/"): "targetPath must not end with a '/'";
@@ -170,7 +171,7 @@
XmlObject connector;
try {
if (specDDUrl == null) {
- specDDUrl = DeploymentUtil.createJarURL(moduleFile, "META-INF/ra.xml");
+ specDDUrl = moduleFile.resolve("META-INF/ra.xml");
}
// read in the entire specDD as a string, we need this for getDeploymentDescriptor
@@ -203,7 +204,7 @@
if (plan != null) {
gerConnectorDoc = GerConnectorDocument.Factory.parse((File) plan, XmlBeansUtil.createXmlOptions(errors));
} else {
- URL path = DeploymentUtil.createJarURL(moduleFile, "META-INF/geronimo-ra.xml");
+ URL path = moduleFile.resolve("META-INF/geronimo-ra.xml");
gerConnectorDoc = GerConnectorDocument.Factory.parse(path, XmlBeansUtil.createXmlOptions(errors));
}
if (errors.size() > 0) {
@@ -244,7 +245,7 @@
throw new IllegalStateException("Connector module ID should be fully resolved (not " + environment.getConfigId() + ")");
}
} else {
- idBuilder.resolve(environment, new File(moduleFile.getName()).getName(), "rar");
+ idBuilder.resolve(environment, moduleFile.getRoot().getName(), "rar");
}
AbstractName moduleName;
@@ -259,7 +260,7 @@
return new ConnectorModule(standAlone, moduleName, environment, moduleFile, targetPath, connector, gerConnector, specDD);
}
- public void installModule(JarFile earFile, EARContext earContext, Module module, Collection configurationStores, ConfigurationStore targetConfigurationStore, Collection repository) throws DeploymentException {
+ public void installModule(DeployableModule earFile, EARContext earContext, Module module, Collection configurationStores, ConfigurationStore targetConfigurationStore, Collection repository) throws DeploymentException {
try {
JarFile moduleFile = module.getModuleFile();
Propchange: geronimo/server/branches/sachin/modules/connector/src/main/java/org/apache/geronimo/connector/outbound/
------------------------------------------------------------------------------
--- svk:merge (added)
+++ svk:merge Fri Aug 25 06:22:45 2006
@@ -0,0 +1 @@
+13f79535-47bb-0310-9956-ffa450edef68:/geronimo/sandbox/svkmerge/trunk/modules/connector/src/java/org/apache/geronimo/connector/outbound:421368
Modified: geronimo/server/branches/sachin/modules/converter/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/modules/converter/pom.xml?rev=436786&r1=436785&r2=436786&view=diff
==============================================================================
--- geronimo/server/branches/sachin/modules/converter/pom.xml (original)
+++ geronimo/server/branches/sachin/modules/converter/pom.xml Fri Aug 25 06:22:45 2006
@@ -60,5 +60,6 @@
</dependency>
</dependencies>
+
</project>
Copied: geronimo/server/branches/sachin/modules/deploy-jsr88/src/main/java/org/apache/geronimo/deployment/plugin/jmx/CommandContext.java (from r436742, geronimo/server/trunk/modules/deploy-jsr88/src/main/java/org/apache/geronimo/deployment/plugin/jmx/CommandContext.java)
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/modules/deploy-jsr88/src/main/java/org/apache/geronimo/deployment/plugin/jmx/CommandContext.java?p2=geronimo/server/branches/sachin/modules/deploy-jsr88/src/main/java/org/apache/geronimo/deployment/plugin/jmx/CommandContext.java&p1=geronimo/server/trunk/modules/deploy-jsr88/src/main/java/org/apache/geronimo/deployment/plugin/jmx/CommandContext.java&r1=436742&r2=436786&rev=436786&view=diff
==============================================================================
--- geronimo/server/trunk/modules/deploy-jsr88/src/main/java/org/apache/geronimo/deployment/plugin/jmx/CommandContext.java (original)
+++ geronimo/server/branches/sachin/modules/deploy-jsr88/src/main/java/org/apache/geronimo/deployment/plugin/jmx/CommandContext.java Fri Aug 25 06:22:45 2006
@@ -27,6 +27,8 @@
private String password;
private boolean inPlace;
+ private String deployableModuleImplClass;
+
public CommandContext(boolean logErrors,
boolean verbose,
String username,
@@ -85,5 +87,13 @@
public void setInPlace(boolean inPlace) {
this.inPlace = inPlace;
+ }
+
+ public String getDeployableModuleImplClass() {
+ return deployableModuleImplClass;
+ }
+
+ public void setDeployableModuleImplClass(String deployableModuleImplClass) {
+ this.deployableModuleImplClass = deployableModuleImplClass;
}
}
Copied: geronimo/server/branches/sachin/modules/deploy-jsr88/src/main/java/org/apache/geronimo/deployment/plugin/jmx/JMXDeploymentManager.java (from r436742, geronimo/server/trunk/modules/deploy-jsr88/src/main/java/org/apache/geronimo/deployment/plugin/jmx/JMXDeploymentManager.java)
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/modules/deploy-jsr88/src/main/java/org/apache/geronimo/deployment/plugin/jmx/JMXDeploymentManager.java?p2=geronimo/server/branches/sachin/modules/deploy-jsr88/src/main/java/org/apache/geronimo/deployment/plugin/jmx/JMXDeploymentManager.java&p1=geronimo/server/trunk/modules/deploy-jsr88/src/main/java/org/apache/geronimo/deployment/plugin/jmx/JMXDeploymentManager.java&r1=436742&r2=436786&rev=436786&view=diff
==============================================================================
--- geronimo/server/trunk/modules/deploy-jsr88/src/main/java/org/apache/geronimo/deployment/plugin/jmx/JMXDeploymentManager.java (original)
+++ geronimo/server/branches/sachin/modules/deploy-jsr88/src/main/java/org/apache/geronimo/deployment/plugin/jmx/JMXDeploymentManager.java Fri Aug 25 06:22:45 2006
@@ -240,6 +240,14 @@
return command;
}
+ public void setModuleConfigurationClass(String className) {
+ commandContext.setDeployableModuleImplClass(className);
+ }
+
+ public String getModuleConfigurationClass() {
+ return commandContext.getDeployableModuleImplClass();
+ }
+
public Locale[] getSupportedLocales() {
return new Locale[]{getDefaultLocale()};
}
Copied: geronimo/server/branches/sachin/modules/deploy-jsr88/src/main/java/org/apache/geronimo/deployment/plugin/local/AbstractDeployCommand.java (from r436742, geronimo/server/trunk/modules/deploy-jsr88/src/main/java/org/apache/geronimo/deployment/plugin/local/AbstractDeployCommand.java)
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/modules/deploy-jsr88/src/main/java/org/apache/geronimo/deployment/plugin/local/AbstractDeployCommand.java?p2=geronimo/server/branches/sachin/modules/deploy-jsr88/src/main/java/org/apache/geronimo/deployment/plugin/local/AbstractDeployCommand.java&p1=geronimo/server/trunk/modules/deploy-jsr88/src/main/java/org/apache/geronimo/deployment/plugin/local/AbstractDeployCommand.java&r1=436742&r2=436786&rev=436786&view=diff
==============================================================================
--- geronimo/server/trunk/modules/deploy-jsr88/src/main/java/org/apache/geronimo/deployment/plugin/local/AbstractDeployCommand.java (original)
+++ geronimo/server/branches/sachin/modules/deploy-jsr88/src/main/java/org/apache/geronimo/deployment/plugin/local/AbstractDeployCommand.java Fri Aug 25 06:22:45 2006
@@ -30,7 +30,6 @@
import javax.enterprise.deploy.spi.Target;
import org.apache.geronimo.common.DeploymentException;
-import org.apache.geronimo.deployment.Deployer;
import org.apache.geronimo.deployment.plugin.TargetModuleIDImpl;
import org.apache.geronimo.gbean.AbstractName;
import org.apache.geronimo.gbean.AbstractNameQuery;
@@ -41,7 +40,7 @@
*/
public abstract class AbstractDeployCommand extends CommandSupport {
protected final Kernel kernel;
- private static final String[] DEPLOY_SIG = {boolean.class.getName(), File.class.getName(), File.class.getName(), String.class.getName()};
+ private static final String[] DEPLOY_SIG = {boolean.class.getName(), File.class.getName(), File.class.getName(), String.class.getName(), String.class.getName()};
protected final boolean spool;
protected File moduleArchive;
protected File deploymentPlan;
@@ -102,7 +101,7 @@
protected void doDeploy(Target target, boolean finished) throws Exception {
File[] args = {moduleArchive, deploymentPlan};
massageFileNames(args);
- Object deployParams[] = new Object[] {Boolean.valueOf(commandContext.isInPlace()), args[0], args[1], target.getName()};
+ Object deployParams[] = new Object[] {Boolean.valueOf(commandContext.isInPlace()), args[0], args[1], target.getName(), commandContext.getDeployableModuleImplClass()};
List objectNames = (List) kernel.invoke(deployer, "deploy", deployParams, DEPLOY_SIG);
if (objectNames == null || objectNames.isEmpty()) {
throw new DeploymentException("Server didn't deploy anything");
Propchange: geronimo/server/branches/sachin/modules/deploy-tool/src/main/java/org/apache/geronimo/deployment/cli/
------------------------------------------------------------------------------
--- svk:merge (added)
+++ svk:merge Fri Aug 25 06:22:45 2006
@@ -0,0 +1 @@
+13f79535-47bb-0310-9956-ffa450edef68:/geronimo/sandbox/svkmerge/trunk/modules/deploy-tool/src/java/org/apache/geronimo/deployment/cli:423294
Copied: geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/ConfigurationBuilder.java (from r436742, geronimo/server/trunk/modules/deployment/src/main/java/org/apache/geronimo/deployment/ConfigurationBuilder.java)
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/ConfigurationBuilder.java?p2=geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/ConfigurationBuilder.java&p1=geronimo/server/trunk/modules/deployment/src/main/java/org/apache/geronimo/deployment/ConfigurationBuilder.java&r1=436742&r2=436786&rev=436786&view=diff
==============================================================================
--- geronimo/server/trunk/modules/deployment/src/main/java/org/apache/geronimo/deployment/ConfigurationBuilder.java (original)
+++ geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/ConfigurationBuilder.java Fri Aug 25 06:22:45 2006
@@ -43,7 +43,7 @@
* @return the deployment plan, or null if this builder can not handle the module
* @throws org.apache.geronimo.common.DeploymentException if there was a problem with the configuration
*/
- Object getDeploymentPlan(File planFile, JarFile module, ModuleIDBuilder idBuilder) throws DeploymentException;
+ Object getDeploymentPlan(File planFile, DeployableModule module, ModuleIDBuilder idBuilder) throws DeploymentException;
/**
* Checks what configuration URL will be used for the provided module.
@@ -53,7 +53,7 @@
* @throws IOException if there was a problem reading or writing the files
* @throws org.apache.geronimo.common.DeploymentException if there was a problem with the configuration
*/
- Artifact getConfigurationID(Object plan, JarFile module, ModuleIDBuilder idBuilder) throws IOException, DeploymentException;
+ Artifact getConfigurationID(Object plan, DeployableModule module, ModuleIDBuilder idBuilder) throws IOException, DeploymentException;
/**
* Build a configuration from a local file
@@ -68,5 +68,5 @@
* @throws IOException if there was a problem reading or writing the files
* @throws org.apache.geronimo.common.DeploymentException if there was a problem with the configuration
*/
- DeploymentContext buildConfiguration(boolean inPlaceDeployment, Artifact configId, Object plan, JarFile module, Collection configurationStores, ArtifactResolver artifactResolver, ConfigurationStore targetConfigurationStore) throws IOException, DeploymentException;
+ DeploymentContext buildConfiguration(boolean inPlaceDeployment, Artifact configId, Object plan, DeployableModule module, Collection configurationStores, ArtifactResolver artifactResolver, ConfigurationStore targetConfigurationStore) throws IOException, DeploymentException;
}
Added: geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/DefaultDeployableModule.java
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/DefaultDeployableModule.java?rev=436786&view=auto
==============================================================================
--- geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/DefaultDeployableModule.java (added)
+++ geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/DefaultDeployableModule.java Fri Aug 25 06:22:45 2006
@@ -0,0 +1,134 @@
+package org.apache.geronimo.deployment;
+
+import org.apache.geronimo.deployment.util.DeploymentUtil;
+import org.apache.geronimo.deployment.util.NestedJarFile;
+
+import java.io.File;
+import java.io.IOException;
+import java.util.jar.JarFile;
+import java.net.URL;
+
+/**
+ * @version
+ */
+public class DefaultDeployableModule implements DeployableModule {
+
+ private String uri;
+ private File root;
+ private JarFile jarFile;
+
+ public DefaultDeployableModule(File root, JarFile jarFile) {
+ this.uri = uri;
+ this.root = root;
+ this.jarFile = jarFile;
+ }
+
+ public String getURI() {
+ return uri;
+ }
+
+ public File getRoot() {
+ return root;
+ }
+
+ public File[] getModuleContextResources() {
+ return null;
+ }
+
+ public File[] getClassesFolders() {
+ return null;
+ }
+
+ public boolean isArchived() {
+ return root.isFile();
+ }
+
+ public DeployableModule[] getModules() {
+ return null;
+ }
+
+ public URL resolve(String path) throws IOException {
+ return DeploymentUtil.createJarURL(jarFile, path);
+ }
+
+ public DeployableModule resolveModule(String uri) throws IOException {
+ JarFile nestedJar = new NestedJarFile(jarFile, uri);
+ return DeployableModuleFactory.createDeployableModule(nestedJar);
+ }
+
+ public JarFile getJarFile() {
+ return jarFile;
+ }
+
+ public void cleanup() {
+ DeploymentUtil.close(jarFile);
+ }
+
+}
+package org.apache.geronimo.deployment;
+
+import org.apache.geronimo.deployment.util.DeploymentUtil;
+import org.apache.geronimo.deployment.util.NestedJarFile;
+
+import java.io.File;
+import java.io.IOException;
+import java.util.jar.JarFile;
+import java.net.URL;
+
+/**
+ * @version
+ */
+public class DefaultDeployableModule implements DeployableModule {
+
+ private String uri;
+ private File root;
+ private JarFile jarFile;
+
+ public DefaultDeployableModule(File root, JarFile jarFile) {
+ this.uri = uri;
+ this.root = root;
+ this.jarFile = jarFile;
+ }
+
+ public String getURI() {
+ return uri;
+ }
+
+ public File getRoot() {
+ return root;
+ }
+
+ public File[] getModuleContextResources() {
+ return null;
+ }
+
+ public File[] getClassesFolders() {
+ return null;
+ }
+
+ public boolean isArchived() {
+ return root.isFile();
+ }
+
+ public DeployableModule[] getModules() {
+ return null;
+ }
+
+ public URL resolve(String path) throws IOException {
+ return DeploymentUtil.createJarURL(jarFile, path);
+ }
+
+ public DeployableModule resolveModule(String uri) throws IOException {
+ JarFile nestedJar = new NestedJarFile(jarFile, uri);
+ return DeployableModuleFactory.createDeployableModule(nestedJar);
+ }
+
+ public JarFile getJarFile() {
+ return jarFile;
+ }
+
+ public void cleanup() {
+ DeploymentUtil.close(jarFile);
+ }
+
+}
Propchange: geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/DefaultDeployableModule.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/DefaultDeployableModule.java
------------------------------------------------------------------------------
svn:keywords = Date Rev
Propchange: geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/DefaultDeployableModule.java
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/DeployableModule.java
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/DeployableModule.java?rev=436786&view=auto
==============================================================================
--- geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/DeployableModule.java (added)
+++ geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/DeployableModule.java Fri Aug 25 06:22:45 2006
@@ -0,0 +1,160 @@
+package org.apache.geronimo.deployment;
+
+import java.io.File;
+import java.io.IOException;
+import java.net.URL;
+
+/**
+ * @version
+ */
+public interface DeployableModule {
+
+ /**
+ * Returns the uri of the module, foo.ear, if a nested module then
+ * foo.ear/foo.war
+ *
+ * @return
+ */
+ String getURI();
+
+ /**
+ * Returns the root of the module, if isArchived then it return absolute
+ * location of the archive, otherwise the root folder of the module.
+ *
+ * @return
+ */
+ File getRoot();
+
+ /**
+ * Returns the root folders for the resources in this module that should be
+ * added to the module context. Returns an empty array if this is an
+ * archived module.
+ *
+ * @return a possibly-empty array of resource folders
+ */
+ File[] getModuleContextResources();
+
+ /**
+ * returns all the URLs that contain .class files, if isArchive then this
+ * would return an empty array
+ *
+ * @return
+ */
+ File[] getClassesFolders();
+
+ /**
+ * Returns true if this is an archived module. The archive can be a JarFile
+ * or an exploded archive.
+ *
+ * @return boolean
+ */
+ boolean isArchived();
+
+ /**
+ * Returns all the child modules for this module. For an ear module, this
+ * would return all of its contained j2ee modules and utility modules. For a
+ * web module, it would return its WEB-INF/lib entries.
+ *
+ * @return a possibly empty array of modules contained within this module
+ */
+ DeployableModule[] getModules();
+
+ /**
+ *
+ * @param path
+ * @return
+ */
+ URL resolve(String path) throws IOException;
+
+ DeployableModule resolveModule(String uri) throws IOException;
+
+ /**
+ * Peforms any cleanup on the instance, for a JarFile, would close it.
+ */
+ void cleanup();
+
+}
+package org.apache.geronimo.deployment;
+
+import java.io.File;
+import java.io.IOException;
+import java.net.URL;
+
+/**
+ * @version
+ */
+public interface DeployableModule {
+
+ /**
+ * Returns the uri of the module, foo.ear, if a nested module then
+ * foo.ear/foo.war
+ *
+ * //TODO GERONIMO-1526 Perhaps this should be getName() and use this method instead of getRoot().getName() in builders
+ *
+ * @return
+ */
+ String getURI();
+
+ /**
+ * Returns the root of the module, if isArchived then it return absolute
+ * location of the archive, otherwise the root folder of the module.
+ *
+ * @return
+ */
+ File getRoot();
+
+ /**
+ * Returns the root folders for the resources in this module that should be
+ * added to the module context. Returns an empty array if this is an
+ * archived module.
+ *
+ * @return a possibly-empty array of resource folders
+ */
+ File[] getModuleContextResources();
+
+ /**
+ * returns all the URLs that contain .class files, if isArchive then this
+ * would return an empty array
+ *
+ * @return
+ */
+ File[] getClassesFolders();
+
+ /**
+ * Returns true if this is an archived module. The archive can be a JarFile
+ * or an exploded archive.
+ *
+ * @return boolean
+ */
+ boolean isArchived();
+
+ /**
+ * Returns all the child modules for this module. For an ear module, this
+ * would return all of its contained j2ee modules and utility modules. For a
+ * web module, it would return its WEB-INF/lib entries.
+ *
+ * @return a possibly empty array of modules contained within this module
+ */
+ DeployableModule[] getModules();
+
+ /**
+ *
+ * @param path
+ * @return
+ */
+ URL resolve(String path) throws IOException;
+
+ /**
+ *
+ * @param uri
+ * @return
+ * @throws IOException
+ */
+ DeployableModule resolveModule(String uri) throws IOException;
+
+ /**
+ * Peforms any cleanup on the instance, for a JarFile, would close it.
+ */
+ void cleanup();
+
+}
Propchange: geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/DeployableModule.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/DeployableModule.java
------------------------------------------------------------------------------
svn:keywords = Date Rev
Propchange: geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/DeployableModule.java
------------------------------------------------------------------------------
svn:mime-type = text/plain
Added: geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/DeployableModuleFactory.java
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/DeployableModuleFactory.java?rev=436786&view=auto
==============================================================================
--- geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/DeployableModuleFactory.java (added)
+++ geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/DeployableModuleFactory.java Fri Aug 25 06:22:45 2006
@@ -0,0 +1,64 @@
+package org.apache.geronimo.deployment;
+
+import org.apache.geronimo.common.DeploymentException;
+import org.apache.geronimo.deployment.util.DeploymentUtil;
+
+import java.io.File;
+import java.io.IOException;
+import java.util.jar.JarFile;
+
+/**
+ * @version
+ */
+public class DeployableModuleFactory {
+
+ public static DeployableModule createDeployableModule(JarFile moduleFile) {
+ return new DefaultDeployableModule(null, moduleFile);
+ }
+
+ public static DeployableModule createDeployableModule(File moduleFile, String deployableModuleImplClass) throws DeploymentException {
+ if (deployableModuleImplClass == null) {
+ try {
+ JarFile jar = DeploymentUtil.createJarFile(moduleFile);
+ return new DefaultDeployableModule(moduleFile, jar);
+ } catch (IOException e) {
+ throw new DeploymentException("Cound not open module file: " + moduleFile.getAbsolutePath(), e);
+ }
+ } else {
+ //TODO
+ }
+ return null;
+ }
+}
+package org.apache.geronimo.deployment;
+
+import org.apache.geronimo.common.DeploymentException;
+import org.apache.geronimo.deployment.util.DeploymentUtil;
+
+import java.io.File;
+import java.io.IOException;
+import java.util.jar.JarFile;
+
+/**
+ * @version
+ */
+public class DeployableModuleFactory {
+
+ public static DeployableModule createDeployableModule(JarFile moduleFile) {
+ return new DefaultDeployableModule(null, moduleFile);
+ }
+
+ public static DeployableModule createDeployableModule(File moduleFile, String deployableModuleImplClass) throws DeploymentException {
+ if (deployableModuleImplClass == null) {
+ try {
+ JarFile jar = DeploymentUtil.createJarFile(moduleFile);
+ return new DefaultDeployableModule(moduleFile, jar);
+ } catch (IOException e) {
+ throw new DeploymentException("Cound not open module file: " + moduleFile.getAbsolutePath(), e);
+ }
+ } else {
+ //TODO
+ }
+ return null;
+ }
+}
Propchange: geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/DeployableModuleFactory.java
------------------------------------------------------------------------------
svn:eol-style = native
Propchange: geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/DeployableModuleFactory.java
------------------------------------------------------------------------------
svn:keywords = Date Rev
Propchange: geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/DeployableModuleFactory.java
------------------------------------------------------------------------------
svn:mime-type = text/plain
Copied: geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/Deployer.java (from r436742, geronimo/server/trunk/modules/deployment/src/main/java/org/apache/geronimo/deployment/Deployer.java)
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/Deployer.java?p2=geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/Deployer.java&p1=geronimo/server/trunk/modules/deployment/src/main/java/org/apache/geronimo/deployment/Deployer.java&r1=436742&r2=436786&rev=436786&view=diff
==============================================================================
--- geronimo/server/trunk/modules/deployment/src/main/java/org/apache/geronimo/deployment/Deployer.java (original)
+++ geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/Deployer.java Fri Aug 25 06:22:45 2006
@@ -30,7 +30,6 @@
import java.util.Properties;
import java.util.Set;
import java.util.jar.Attributes;
-import java.util.jar.JarFile;
import java.util.jar.Manifest;
import javax.management.ObjectName;
@@ -97,10 +96,14 @@
}
public List deploy(boolean inPlace, File moduleFile, File planFile) throws DeploymentException {
- return deploy(inPlace, moduleFile, planFile, null);
+ return deploy(inPlace, moduleFile, planFile, null, null);
}
public List deploy(boolean inPlace, File moduleFile, File planFile, String targetConfigStore) throws DeploymentException {
+ return deploy(inPlace, moduleFile, planFile, targetConfigStore, null);
+ }
+
+ public List deploy(boolean inPlace, File moduleFile, File planFile, String targetConfigStore, String deployableModuleImplClass) throws DeploymentException {
File originalModuleFile = moduleFile;
File tmpDir = null;
if (moduleFile != null && !moduleFile.isDirectory()) {
@@ -121,7 +124,7 @@
}
try {
- return deploy(inPlace, planFile, moduleFile, null, true, null, null, null, null, null, null, null, targetConfigStore);
+ return deploy(inPlace, planFile, moduleFile, null, true, null, null, null, null, null, null, null, targetConfigStore, deployableModuleImplClass);
} catch (DeploymentException e) {
log.debug("Deployment failed: plan=" + planFile + ", module=" + originalModuleFile, e);
throw e.cleanse();
@@ -193,7 +196,8 @@
String mainGBean, String mainMethod, String manifestConfigurations, String classPath,
String endorsedDirs,
String extensionDirs,
- String targetConfigurationStore) throws DeploymentException {
+ String targetConfigurationStore,
+ String deployableModuleImplClass) throws DeploymentException {
if (planFile == null && moduleFile == null) {
throw new DeploymentException("No plan or module specified");
}
@@ -207,7 +211,7 @@
}
}
- JarFile module = null;
+ DeployableModule module = null;
if (moduleFile != null) {
if (inPlace && !moduleFile.isDirectory()) {
throw new DeploymentException("In place deployment is not allowed for packed module");
@@ -215,11 +219,7 @@
if (!moduleFile.exists()) {
throw new DeploymentException("Module file does not exist: " + moduleFile.getAbsolutePath());
}
- try {
- module = DeploymentUtil.createJarFile(moduleFile);
- } catch (IOException e) {
- throw new DeploymentException("Cound not open module file: " + moduleFile.getAbsolutePath(), e);
- }
+ module = DeployableModuleFactory.createDeployableModule(moduleFile, deployableModuleImplClass);
}
// File configurationDir = null;
@@ -384,7 +384,7 @@
}
throw new Error(e);
} finally {
- DeploymentUtil.close(module);
+ module.cleanup();
}
}
Copied: geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/SingleFileHotDeployer.java (from r436742, geronimo/server/trunk/modules/deployment/src/main/java/org/apache/geronimo/deployment/SingleFileHotDeployer.java)
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/SingleFileHotDeployer.java?p2=geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/SingleFileHotDeployer.java&p1=geronimo/server/trunk/modules/deployment/src/main/java/org/apache/geronimo/deployment/SingleFileHotDeployer.java&r1=436742&r2=436786&rev=436786&view=diff
==============================================================================
--- geronimo/server/trunk/modules/deployment/src/main/java/org/apache/geronimo/deployment/SingleFileHotDeployer.java (original)
+++ geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/SingleFileHotDeployer.java Fri Aug 25 06:22:45 2006
@@ -24,7 +24,6 @@
import java.util.Iterator;
import java.util.List;
import java.util.LinkedList;
-import java.util.jar.JarFile;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
@@ -120,13 +119,7 @@
}
ModuleIDBuilder idBuilder = new ModuleIDBuilder();
-
- JarFile module = null;
- try {
- module = DeploymentUtil.createJarFile(dir);
- } catch (IOException e) {
- throw new DeploymentException("Cound not open module file: " + dir.getAbsolutePath(), e);
- }
+ DeployableModule module = DeployableModuleFactory.createDeployableModule(dir, null);
try {
// get the builder and plan
@@ -180,7 +173,7 @@
} catch (Exception e) {
throw new DeploymentException("Unable to deploy " + dir, e);
} finally {
- DeploymentUtil.close(module);
+ module.cleanup();
}
}
@@ -220,7 +213,7 @@
return new Artifact(group, artifactId, version, type);
}
- private List deployConfiguration(ConfigurationBuilder builder, ConfigurationStore store, Artifact configurationId, Object plan, JarFile module, Collection stores, ArtifactResolver artifactResolver) throws DeploymentException {
+ private List deployConfiguration(ConfigurationBuilder builder, ConfigurationStore store, Artifact configurationId, Object plan, DeployableModule module, Collection stores, ArtifactResolver artifactResolver) throws DeploymentException {
try {
// It's our responsibility to close this context, once we're done with it...
DeploymentContext context = builder.buildConfiguration(true, configurationId, plan, module, stores, artifactResolver, store);
@@ -265,7 +258,7 @@
}
throw new Error(e);
} finally {
- DeploymentUtil.close(module);
+ module.cleanup();
}
}
Copied: geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/util/DeploymentUtil.java (from r436742, geronimo/server/trunk/modules/deployment/src/main/java/org/apache/geronimo/deployment/util/DeploymentUtil.java)
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/util/DeploymentUtil.java?p2=geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/util/DeploymentUtil.java&p1=geronimo/server/trunk/modules/deployment/src/main/java/org/apache/geronimo/deployment/util/DeploymentUtil.java&r1=436742&r2=436786&rev=436786&view=diff
==============================================================================
--- geronimo/server/trunk/modules/deployment/src/main/java/org/apache/geronimo/deployment/util/DeploymentUtil.java (original)
+++ geronimo/server/branches/sachin/modules/deployment/src/main/java/org/apache/geronimo/deployment/util/DeploymentUtil.java Fri Aug 25 06:22:45 2006
@@ -16,6 +16,8 @@
*/
package org.apache.geronimo.deployment.util;
+import org.apache.geronimo.deployment.DeployableModule;
+
import java.io.BufferedOutputStream;
import java.io.File;
import java.io.FileInputStream;
@@ -97,8 +99,13 @@
}
out.flush();
}
+
public static File toTempFile(JarFile jarFile, String path) throws IOException {
return toTempFile(createJarURL(jarFile, path));
+ }
+
+ public static File toTempFile(DeployableModule module, String path) throws IOException {
+ return toTempFile(module.resolve(path));
}
public static File toTempFile(URL url) throws IOException {
Modified: geronimo/server/branches/sachin/modules/directory/pom.xml
URL: http://svn.apache.org/viewvc/geronimo/server/branches/sachin/modules/directory/pom.xml?rev=436786&r1=436785&r2=436786&view=diff
==============================================================================
--- geronimo/server/branches/sachin/modules/directory/pom.xml (original)
+++ geronimo/server/branches/sachin/modules/directory/pom.xml Fri Aug 25 06:22:45 2006
@@ -171,12 +171,6 @@
</dependencies>
<build>
- <resources>
- <resource>
- <directory>src/resources2</directory>
- </resource>
- </resources>
-
<plugins>
<plugin>
<groupId>org.codehaus.mojo</groupId>
@@ -184,7 +178,7 @@
<configuration>
<sourceSchemas>directory.xsd</sourceSchemas>
<outputDirectory>${pom.basedir}/target/classes/schemaorg_apache_xmlbeans</outputDirectory>
- <defaultXmlConfigDir>${pom.basedir}/src/schema/xmlconfig.xml</defaultXmlConfigDir>
+ <defaultXmlConfigDir>${pom.basedir}/src/main/schema/xmlconfig.xml</defaultXmlConfigDir>
</configuration>
</plugin>
@@ -222,7 +216,9 @@
<configuration>
<tasks>
<tstamp/>
- <copy todir="target/var/" file="src/test-resources/directory.xml"/>
+ <mkdir dir="${pom.basedir}/target/var"/>
+ <copy file="${pom.basedir}/src/test/resources/directory.xml"
+ todir="${pom.basedir}/target/var"/>
</tasks>
</configuration>
</execution>