You are viewing a plain text version of this content. The canonical link for it is here.
Posted to scm@geronimo.apache.org by di...@apache.org on 2004/10/18 21:01:56 UTC
svn commit: rev 55028 - in geronimo/trunk/modules/axis: . src/java/org/apache/geronimo/axis src/test/org/apache/geronimo/axis
Author: dims
Date: Mon Oct 18 12:01:55 2004
New Revision: 55028
Modified:
geronimo/trunk/modules/axis/maven.xml
geronimo/trunk/modules/axis/project.xml
geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/AxisGbean.java
geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/AxisGeronimoUtils.java
geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/DependancyManager.java
geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/J2EEManager.java
geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/WebServiceDeployer.java
geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/WebServiceManager.java
geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/AdminClientDeploymentTest.java
geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/DynamicEJBDeploymentTest.java
geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/TestServer.java
Log:
* Remove dependency on JAXB
* Remove extra System.out.println
* Enable all the tests.
* Some code cleanup
Modified: geronimo/trunk/modules/axis/maven.xml
==============================================================================
--- geronimo/trunk/modules/axis/maven.xml (original)
+++ geronimo/trunk/modules/axis/maven.xml Mon Oct 18 12:01:55 2004
@@ -36,12 +36,10 @@
word is used in the source code being compiled.
The generated ANT file might need to pass the
-source 1.4 option to the java compiler -->
- <!--
<ant:ant antfile="build.xml"
inheritall="true"
inheritrefs="true"
dir="target/generated/samples"/>
- -->
</j:jelly>
</preGoal>
</project>
Modified: geronimo/trunk/modules/axis/project.xml
==============================================================================
--- geronimo/trunk/modules/axis/project.xml (original)
+++ geronimo/trunk/modules/axis/project.xml Mon Oct 18 12:01:55 2004
@@ -295,6 +295,7 @@
<module>true</module>
</properties>
</dependency>
+ <!--
<dependency>
<groupId>jaxb-ri</groupId>
<artifactId>jaxb-api</artifactId>
@@ -343,6 +344,17 @@
<module>true</module>
</properties>
</dependency>
+ -->
+
+ <dependency>
+ <groupId>xmlbeans</groupId>
+ <artifactId>xbean-apache-1.0</artifactId>
+ <version>DEV</version>
+ <properties>
+ <module>true</module>
+ </properties>
+ </dependency>
+
<dependency>
<groupId>axis</groupId>
<artifactId>axis</artifactId>
@@ -430,8 +442,8 @@
<exclude>**/Abstract*.java</exclude>
<exclude>**/EWSTest.java</exclude>
<exclude>**/ComplexTypeWebServiceTest.java</exclude>
- <!-- Temporary ignore for all tests -->
- <exclude>**/*.java</exclude>
+ <!-- Temporary ignore for all tests
+ <exclude>**/*.java</exclude> -->
</excludes>
<resources>
Modified: geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/AxisGbean.java
==============================================================================
--- geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/AxisGbean.java (original)
+++ geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/AxisGbean.java Mon Oct 18 12:01:55 2004
@@ -16,6 +16,10 @@
package org.apache.geronimo.axis;
+import javax.management.ObjectName;
+
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
import org.apache.geronimo.gbean.GBeanInfo;
import org.apache.geronimo.gbean.GBeanInfoFactory;
import org.apache.geronimo.gbean.GBeanLifecycle;
@@ -23,13 +27,11 @@
import org.apache.geronimo.kernel.Kernel;
import org.apache.geronimo.kernel.jmx.JMXUtil;
-import javax.management.ObjectName;
-
/**
* Class AxisGbean
*/
public class AxisGbean implements GBeanLifecycle {
-
+ private static Log log = LogFactory.getLog(AxisGbean.class);
/**
* Field name
*/
@@ -101,7 +103,7 @@
* Method doFail
*/
public void doFail() {
- System.out.println("Axis GBean has failed");
+ log.info("Axis GBean has failed");
}
/**
@@ -111,9 +113,9 @@
* @throws Exception
*/
public void doStart() throws WaitingException, Exception {
- System.out.println("Axis GBean has started");
- System.out.println(kernel);
- System.out.println(objectName);
+ log.info("Axis GBean has started");
+ log.info(kernel);
+ log.info(objectName);
j2eeManager.startJ2EEContainer(kernel);
wscontiner.doStart();
wsdeployer = new WebServiceDeployer(AxisGeronimoConstants.TEMP_OUTPUT,
@@ -128,7 +130,7 @@
* @throws Exception
*/
public void doStop() throws WaitingException, Exception {
- System.out.println("Axis GBean has stoped");
+ log.info("Axis GBean has stoped");
wscontiner.doStop();
j2eeManager.stopJ2EEContainer(kernel);
}
Modified: geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/AxisGeronimoUtils.java
==============================================================================
--- geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/AxisGeronimoUtils.java (original)
+++ geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/AxisGeronimoUtils.java Mon Oct 18 12:01:55 2004
@@ -49,12 +49,11 @@
try {
ContainerIndex index = ContainerIndex.getInstance();
int length = index.length();
- System.out.println("number of continers " + length);
+ log.info("number of continers " + length);
for (int i = 0; i < length; i++) {
EJBContainer contianer = index.getContainer(i);
if (contianer != null) {
String name = contianer.getEJBName();
- System.out.println("found the ejb " + name);
log.debug("found the ejb " + name);
if (ejbName.equals(name)) {
EJBHome statelessHome = contianer.getEJBHome();
@@ -66,20 +65,20 @@
return methods[j].invoke(stateless, parameters);
} catch (Exception e) {
Class[] classes = methods[j].getParameterTypes();
- System.out.print(methodName + "(");
+ log.info(methodName + "(");
if (parameters == null || classes == null) {
- System.out.println("both or one is null");
+ log.debug("both or one is null");
} else {
if (parameters.length != classes.length)
- System.out.println("parameter length do not match expected parametes");
+ log.debug("parameter length do not match expected parametes");
for (int k = 0; k < classes.length; k++) {
Object obj = parameters[k];
Class theClass = classes[k];
if (theClass != obj.getClass()) {
- System.out.println("calsses are differant");
+ log.debug("calsses are differant");
}
- System.out.println("ejb class loader " + theClass.getClassLoader());
- System.out.println("parameter class loader = " + obj.getClass().getClassLoader());
+ log.debug("ejb class loader " + theClass.getClassLoader());
+ log.debug("parameter class loader = " + obj.getClass().getClassLoader());
}
}
throw e;
@@ -90,7 +89,6 @@
throw new NoSuchMethodException(methodName + " not found");
}
} else {
- System.out.println("Continer is null");
log.debug("Continer is null");
}
}
@@ -129,9 +127,9 @@
try {
if (!checkAlreadyStarted(objectName, kernel)) {
startGBean(objectName, gbean, kernel);
- System.out.println("Started .. " + objectName);
+ log.info("Started .. " + objectName);
} else {
- System.out.println(objectName + " GBean already started");
+ log.info(objectName + " GBean already started");
}
} catch (Exception e) {
throw new DeploymentException(e);
@@ -151,9 +149,9 @@
if (startedGbeans.contains(objectName)) {
kernel.stopGBean(objectName);
kernel.unloadGBean(objectName);
- System.out.println("stoped .. " + objectName);
+ log.info("stoped .. " + objectName);
} else {
- System.out.println(objectName + " was runing when axis start it "
+ log.info(objectName + " was runing when axis start it "
+ "Axis will not stop it");
}
} catch (Exception e) {
@@ -199,7 +197,7 @@
public static boolean checkAlreadyStarted(ObjectName name, Kernel kernel) {
Set set = kernel.listGBeans(name);
- System.out.println(name + " = " + set);
+ log.info(name + " = " + set);
if (set == null)
return false;
if (set.isEmpty()) {
Modified: geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/DependancyManager.java
==============================================================================
--- geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/DependancyManager.java (original)
+++ geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/DependancyManager.java Mon Oct 18 12:01:55 2004
@@ -41,7 +41,7 @@
* Class DependancyEJBManager
*/
public class DependancyManager {
- protected final Log log = LogFactory.getLog(getClass());
+ protected static final Log log = LogFactory.getLog(DependancyManager.class);
/**
* Field j2eeServerObjectName
*/
@@ -118,7 +118,6 @@
for (int i = 0; i < dependedEJBs.size(); i++) {
ObjectName gbeanName = (ObjectName) dependedEJBs.get(i);
AxisGeronimoUtils.stopGBean(gbeanName, kernel);
- System.out.println("stop the dependent EJB name=" + gbeanName);
log.debug("stop the dependent EJB name=" + gbeanName);
}
}
@@ -138,7 +137,6 @@
try {
// load the configuration
GBeanMBean config = loadConfig(unpackedDir);
- System.out.println("Context Loader " + Thread.currentThread().getContextClassLoader());
ObjectName objectName = service;
dependedEJBs.add(objectName);
@@ -150,7 +148,7 @@
ClassLoader cl = (ClassLoader) kernel.getAttribute(objectName, "classLoader");
- System.out.println("start dependent EJB name=" + objectName
+ log.info("start dependent EJB name=" + objectName
+ " dir=" + unpackedDir.getAbsolutePath() + "the config CL =" + cl);
return cl;
} catch (DeploymentException e) {
Modified: geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/J2EEManager.java
==============================================================================
--- geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/J2EEManager.java (original)
+++ geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/J2EEManager.java Mon Oct 18 12:01:55 2004
@@ -40,6 +40,23 @@
public void init() throws AxisFault {
}
+
+// containerName = new ObjectName("geronimo.jetty:role=Container");
+// containerPatterns = Collections.singleton(containerName);
+// connectorName = new ObjectName("geronimo.jetty:role=Connector");
+// appName = new ObjectName("geronimo.jetty:app=test");
+//
+// tmName = new ObjectName("geronimo.test:role=TransactionManager");
+// tcmName = new ObjectName("geronimo.test:role=TransactionContextManager");
+// tcaName = new ObjectName("geronimo.test:role=ConnectionTrackingCoordinator");
+//
+// kernel = new Kernel("test.kernel", "test");
+// kernel.boot();
+// mbServer = kernel.getMBeanServer();
+// container = new GBeanMBean(JettyContainerImpl.GBEAN_INFO);
+//
+//
+
public void startJ2EEContainer(Kernel kernel) throws AxisFault {
try {
@@ -95,6 +112,7 @@
GBeanMBean tmGBean = new GBeanMBean(GeronimoTransactionManager.GBEAN_INFO);
Set rmpatterns = new HashSet();
rmpatterns.add(ObjectName.getInstance("geronimo.server:j2eeType=JCAManagedConnectionFactory,*"));
+ tmGBean.setAttribute("defaultTransactionTimeoutSeconds", new Integer(10));
tmGBean.setReferencePatterns("ResourceManagers", rmpatterns);
AxisGeronimoUtils.startGBeanOnlyIfNotStarted(AxisGeronimoConstants.TRANSACTION_MANAGER_NAME, tmGBean, kernel);
Modified: geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/WebServiceDeployer.java
==============================================================================
--- geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/WebServiceDeployer.java (original)
+++ geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/WebServiceDeployer.java Mon Oct 18 12:01:55 2004
@@ -173,25 +173,16 @@
if (packageModule.getEjbJarfile() != null) {
this.hasEJB = true;
- System.out.println("the web service is based on a ejb.");
- //log.info("the web service is based on a ejb.");
+
+ log.info("the web service is based on a ejb.");
} else if (packageModule.getWebddfile() != null) {
this.hasEJB = false;
-
- System.out.println("the web service is based on a java class.");
- //log.info("the web service is based on a java class.");
+ log.info("the web service is based on a java class.");
} else {
throw new DeploymentException("the module must have web.xml or ejb-jar.xml file");
}
File file = findTheImpl();
-
-// ZipFile zipfile = new ZipFile(module);
-// ZipEntry pentry = new ZipEntry("ws.properties");
-// Properties p = new Properties();
-// InputStream in = zipfile.getInputStream(pentry);
-// p.load(in);
-// in.close();
deployTheWebService(file);
}
@@ -311,12 +302,9 @@
ArrayList classList = AxisGeronimoUtils.getClassFileList(new ZipFile(module));
for (int i = 0; i < classList.size(); i++) {
String className = (String) classList.get(i);
- System.out.println(className);
ClassUtils.setClassLoader(className, classloader);
}
- System.out.println("Calss Utils class lader set at deployment =" + classloader);
-
//This must come after the Classloader set as axis try to load the
//Classes at the deployment
addEntryToAxisDD(module);
@@ -465,7 +453,7 @@
Call call = adminClient.getCall();
call.setTargetEndpointAddress(requestUrl);
String result = adminClient.process(null, deplydd);
- System.out.println(result);
+ log.info(result);
} else {
throw new DeploymentException("the deploy.wsdd can not be found");
}
Modified: geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/WebServiceManager.java
==============================================================================
--- geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/WebServiceManager.java (original)
+++ geronimo/trunk/modules/axis/src/java/org/apache/geronimo/axis/WebServiceManager.java Mon Oct 18 12:01:55 2004
@@ -15,16 +15,6 @@
*/
package org.apache.geronimo.axis;
-import org.apache.axis.utils.ClassUtils;
-import org.apache.commons.logging.Log;
-import org.apache.commons.logging.LogFactory;
-import org.apache.geronimo.deployment.DeploymentException;
-import org.apache.geronimo.gbean.jmx.GBeanMBean;
-import org.apache.geronimo.kernel.Kernel;
-import org.apache.geronimo.transaction.UserTransactionImpl;
-
-import javax.management.MBeanServer;
-import javax.management.ObjectName;
import java.io.File;
import java.io.FileInputStream;
import java.net.MalformedURLException;
@@ -37,6 +27,17 @@
import java.util.Set;
import java.util.zip.ZipFile;
+import javax.management.MBeanServer;
+import javax.management.ObjectName;
+
+import org.apache.axis.utils.ClassUtils;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
+import org.apache.geronimo.deployment.DeploymentException;
+import org.apache.geronimo.gbean.jmx.GBeanMBean;
+import org.apache.geronimo.kernel.Kernel;
+import org.apache.geronimo.transaction.OnlineUserTransaction;
+
/**
* Class WebServiceContainer
*/
@@ -104,6 +105,8 @@
//test has changed
ClassUtils.setDefaultClassLoader(Thread.currentThread().getContextClassLoader());
loadDeployedWebservices();
+
+ org.apache.geronimo.jetty.JettyWebAppContext c = null;
GBeanMBean app = new GBeanMBean("org.apache.geronimo.jetty.JettyWebAppContext");
URL url =
@@ -112,14 +115,17 @@
app.setAttribute("uri", URI.create(url.toString()));
app.setAttribute("contextPath", "/axis");
app.setAttribute("componentContext", null);
- UserTransactionImpl userTransaction = new UserTransactionImpl();
+ OnlineUserTransaction userTransaction = new OnlineUserTransaction();
app.setAttribute("userTransaction", userTransaction);
- app.setReferencePatterns("Configuration", Collections.EMPTY_SET);
+// app.setReferencePatterns("Configuration", Collections.EMPTY_SET);
+ app.setAttribute("webClassPath", new URI[0]);
+ app.setAttribute("contextPriorityClassLoader", Boolean.FALSE);
app.setReferencePatterns("JettyContainer", containerPatterns);
+ app.setAttribute("configurationBaseUrl", Thread.currentThread().getContextClassLoader().getResource("deployables/"));
app.setReferencePattern("TransactionContextManager", AxisGeronimoConstants.TRANSACTION_CONTEXT_MANAGER_NAME);
app.setReferencePattern("TrackedConnectionAssociator", AxisGeronimoConstants.TRACKED_CONNECTION_ASSOCIATOR_NAME);
- start(appName, app);
+ AxisGeronimoUtils.startGBean(appName, app,kernel);
log.debug("Axis started as a web application inside Jetty");
}
@@ -132,28 +138,28 @@
ejbManager.stopDependancies();
}
- /**
- * Method start
- *
- * @param name
- * @param instance
- * @throws Exception
- */
- private void start(ObjectName name, Object instance) throws Exception {
- mbServer.registerMBean(instance, name);
- mbServer.invoke(name, "start", null, null);
- }
-
- /**
- * Method stop
- *
- * @param name
- * @throws Exception
- */
- private void stop(ObjectName name) throws Exception {
- mbServer.invoke(name, "stop", null, null);
- mbServer.unregisterMBean(name);
- }
+// /**
+// * Method start
+// *
+// * @param name
+// * @param instance
+// * @throws Exception
+// */
+// private void start(ObjectName name, Object instance) throws Exception {
+// mbServer.registerMBean(instance, name);
+// mbServer.invoke(name, "start", null, null);
+// }
+//
+// /**
+// * Method stop
+// *
+// * @param name
+// * @throws Exception
+// */
+// private void stop(ObjectName name) throws Exception {
+// mbServer.invoke(name, "stop", null, null);
+// mbServer.unregisterMBean(name);
+// }
/**
* Method loadDeployedWebservices
@@ -202,7 +208,6 @@
ArrayList classList = AxisGeronimoUtils.getClassFileList(new ZipFile(module));
for (int j = 0; j < classList.size(); j++) {
String className = (String) classList.get(i);
- System.out.println(className);
ClassUtils.setClassLoader(className, classloader);
}
}
Modified: geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/AdminClientDeploymentTest.java
==============================================================================
--- geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/AdminClientDeploymentTest.java (original)
+++ geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/AdminClientDeploymentTest.java Mon Oct 18 12:01:55 2004
@@ -87,7 +87,6 @@
Call call = adminClient.getCall();
call.setTargetEndpointAddress(requestUrl);
String result = adminClient.process(null, deplydd);
- System.out.println(result);
URL wsdlrequestUrl = new URL("http://localhost:"
+ AxisGeronimoConstants.AXIS_SERVICE_PORT
Modified: geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/DynamicEJBDeploymentTest.java
==============================================================================
--- geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/DynamicEJBDeploymentTest.java (original)
+++ geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/DynamicEJBDeploymentTest.java Mon Oct 18 12:01:55 2004
@@ -48,6 +48,7 @@
private static final ObjectName transactionManagerObjectName = JMXUtil.getObjectName(j2eeDomainName + ":type=TransactionManager");
private static final ObjectName connectionTrackerObjectName = JMXUtil.getObjectName(j2eeDomainName + ":type=ConnectionTracker");
private Kernel kernel;
+ private J2EEManager j2eeManager;
/**
* @param testName
@@ -57,7 +58,6 @@
}
protected void setUp() throws Exception {
- super.setUp();
String str = System.getProperty(javax.naming.Context.URL_PKG_PREFIXES);
if (str == null) {
str = ":org.apache.geronimo.naming";
@@ -67,39 +67,40 @@
System.setProperty(javax.naming.Context.URL_PKG_PREFIXES, str);
kernel = new Kernel("blah");
kernel.boot();
-
- GBeanMBean serverInfoGBean = new GBeanMBean(ServerInfo.GBEAN_INFO);
- serverInfoGBean.setAttribute("baseDirectory", ".");
- ObjectName serverInfoObjectName = ObjectName.getInstance(j2eeDomainName + ":type=ServerInfo");
- kernel.loadGBean(serverInfoObjectName, serverInfoGBean);
- kernel.startGBean(serverInfoObjectName);
- assertRunning(kernel, serverInfoObjectName);
-
- GBeanMBean j2eeServerGBean = new GBeanMBean(J2EEServerImpl.GBEAN_INFO);
- j2eeServerGBean.setReferencePatterns("ServerInfo", Collections.singleton(serverInfoObjectName));
- ObjectName j2eeServerObjectName = ObjectName.getInstance(j2eeDomainName + ":j2eeType=J2EEServer,name=" + j2eeServerName);
- kernel.loadGBean(j2eeServerObjectName, j2eeServerGBean);
- kernel.startGBean(j2eeServerObjectName);
- assertRunning(kernel, j2eeServerObjectName);
-
- GBeanMBean tmGBean = new GBeanMBean(GeronimoTransactionManager.GBEAN_INFO);
- Set patterns = new HashSet();
- patterns.add(ObjectName.getInstance("geronimo.server:j2eeType=JCAManagedConnectionFactory,*"));
- patterns.add(ObjectName.getInstance("geronimo.server:j2eeType=ActivationSpec,*"));
- tmGBean.setReferencePatterns("ResourceManagers", patterns);
- kernel.loadGBean(transactionManagerObjectName, tmGBean);
- kernel.startGBean(transactionManagerObjectName);
- assertRunning(kernel, transactionManagerObjectName);
-
- GBeanMBean connectionTrackerGBean = new GBeanMBean(ConnectionTrackingCoordinator.GBEAN_INFO);
- ObjectName connectionTrackerObjectName = ObjectName.getInstance(j2eeDomainName + ":type=ConnectionTracker");
- kernel.loadGBean(connectionTrackerObjectName, connectionTrackerGBean);
- kernel.startGBean(connectionTrackerObjectName);
- assertRunning(kernel, connectionTrackerObjectName);
-
- //load mock resource adapter for mdb
-// DeploymentHelper.setUpResourceAdapter(kernel);
-
+//
+// GBeanMBean serverInfoGBean = new GBeanMBean(ServerInfo.GBEAN_INFO);
+// serverInfoGBean.setAttribute("baseDirectory", ".");
+// ObjectName serverInfoObjectName = ObjectName.getInstance(j2eeDomainName + ":type=ServerInfo");
+// kernel.loadGBean(serverInfoObjectName, serverInfoGBean);
+// kernel.startGBean(serverInfoObjectName);
+// assertRunning(kernel, serverInfoObjectName);
+//
+// GBeanMBean j2eeServerGBean = new GBeanMBean(J2EEServerImpl.GBEAN_INFO);
+// j2eeServerGBean.setReferencePatterns("ServerInfo", Collections.singleton(serverInfoObjectName));
+// ObjectName j2eeServerObjectName = ObjectName.getInstance(j2eeDomainName + ":j2eeType=J2EEServer,name=" + j2eeServerName);
+// kernel.loadGBean(j2eeServerObjectName, j2eeServerGBean);
+// kernel.startGBean(j2eeServerObjectName);
+// assertRunning(kernel, j2eeServerObjectName);
+//
+// GBeanMBean tmGBean = new GBeanMBean(GeronimoTransactionManager.GBEAN_INFO);
+// Set patterns = new HashSet();
+// patterns.add(ObjectName.getInstance("geronimo.server:j2eeType=JCAManagedConnectionFactory,*"));
+// patterns.add(ObjectName.getInstance("geronimo.server:j2eeType=ActivationSpec,*"));
+// tmGBean.setReferencePatterns("ResourceManagers", patterns);
+// kernel.loadGBean(transactionManagerObjectName, tmGBean);
+// kernel.startGBean(transactionManagerObjectName);
+// assertRunning(kernel, transactionManagerObjectName);
+//
+// GBeanMBean connectionTrackerGBean = new GBeanMBean(ConnectionTrackingCoordinator.GBEAN_INFO);
+// ObjectName connectionTrackerObjectName = ObjectName.getInstance(j2eeDomainName + ":type=ConnectionTracker");
+// kernel.loadGBean(connectionTrackerObjectName, connectionTrackerGBean);
+// kernel.startGBean(connectionTrackerObjectName);
+// assertRunning(kernel, connectionTrackerObjectName);
+//
+// //load mock resource adapter for mdb
+//// DeploymentHelper.setUpResourceAdapter(kernel);
+ j2eeManager = new J2EEManager();
+ j2eeManager.startJ2EEContainer(kernel);
}
public void testEJBJarDeploy() throws Exception {
@@ -154,9 +155,10 @@
}
protected void tearDown() throws Exception {
- kernel.stopGBean(connectionTrackerObjectName);
- kernel.stopGBean(transactionManagerObjectName);
- kernel.shutdown();
+ j2eeManager.stopJ2EEContainer(kernel);
+// kernel.stopGBean(connectionTrackerObjectName);
+// kernel.stopGBean(transactionManagerObjectName);
+// kernel.shutdown();
}
private void assertRunning(Kernel kernel, ObjectName objectName) throws Exception {
Modified: geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/TestServer.java
==============================================================================
--- geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/TestServer.java (original)
+++ geronimo/trunk/modules/axis/src/test/org/apache/geronimo/axis/TestServer.java Mon Oct 18 12:01:55 2004
@@ -54,7 +54,7 @@
}
public void stop()throws Exception{
- System.out.println("Shutting down the kernel");
+ //System.out.println("Shutting down the kernel");
kernel.stopGBean(name);
kernel.unloadGBean(name);