epugh 2003/12/08 12:49:47 Modified: xmlrpc/src/java/org/apache/fulcrum/xmlrpc DefaultXmlRpcComponent.java Log: XmlRpc now actually runs! unit tests pass! Thanks Ronald! Revision Changes Path 1.4 +16 -28 jakarta-turbine-fulcrum/xmlrpc/src/java/org/apache/fulcrum/xmlrpc/DefaultXmlRpcComponent.java Index: DefaultXmlRpcComponent.java =================================================================== RCS file: /home/cvs/jakarta-turbine-fulcrum/xmlrpc/src/java/org/apache/fulcrum/xmlrpc/DefaultXmlRpcComponent.java,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- DefaultXmlRpcComponent.java 2 May 2003 18:28:18 -0000 1.3 +++ DefaultXmlRpcComponent.java 8 Dec 2003 20:49:47 -0000 1.4 @@ -62,9 +62,6 @@ import org.apache.avalon.framework.configuration.Configurable; import org.apache.avalon.framework.configuration.Configuration; import org.apache.avalon.framework.configuration.ConfigurationException; -import org.apache.avalon.framework.context.Context; -import org.apache.avalon.framework.context.ContextException; -import org.apache.avalon.framework.context.Contextualizable; import org.apache.avalon.framework.logger.AbstractLogEnabled; import org.apache.avalon.framework.service.ServiceException; import org.apache.avalon.framework.service.ServiceManager; @@ -96,7 +93,7 @@ */ public class DefaultXmlRpcComponent extends AbstractLogEnabled - implements Contextualizable,Configurable, Initializable, Startable, + implements Configurable, Initializable, Startable, Disposable, Serviceable, XmlRpcComponent { /** The service manager for this component. */ @@ -129,9 +126,6 @@ /** Message Listeners. */ private List listeners; - /** Current working directory */ - String workingDirectory; - /** Default Constructor. */ public DefaultXmlRpcComponent() { @@ -139,16 +133,9 @@ } // ---------------------------------------------------------------------- - // Lifecylce Management + // Lifecycle Management // ---------------------------------------------------------------------- - /** @see Contextualizable#contextualize */ - public void contextualize( Context context ) - throws ContextException - { - workingDirectory = (String) context.get("ComponentAppRoot"); - } - public void configure(Configuration configuration) throws ConfigurationException { @@ -236,6 +223,7 @@ public void start() throws Exception { + webserver.start(); } /** @@ -342,18 +330,6 @@ public void stop() throws Exception { - dispose(); - } - - // ------------------------------------------------------------------------ - // D I S P O S A B L E - // ------------------------------------------------------------------------ - - /** - * Shuts down this service, stopping running threads. - */ - public void dispose() - { // Stop the XML RPC server. org.apache.xmlrpc.WebServer blocks in a // call to ServerSocket.accept() until a socket connection is made. webserver.shutdown(); @@ -369,6 +345,18 @@ "It's possible the xmlrpc server was not shutdown: " + notShutdown.getMessage()); } + } + + // ------------------------------------------------------------------------ + // D I S P O S A B L E + // ------------------------------------------------------------------------ + + /** + * Shuts down this service, stopping running threads. + */ + public void dispose() + { + webserver = null; } // ------------------------------------------------------------------------
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]