geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From djen...@apache.org
Subject svn commit: r562293 - in /geronimo/server/trunk: applications/console/geronimo-console-standard/src/main/java/org/apache/geronimo/console/util/ modules/geronimo-jetty6/src/main/java/org/apache/geronimo/jetty6/ modules/geronimo-jetty6/src/main/java/org/...
Date Thu, 02 Aug 2007 23:54:49 GMT
Author: djencks
Date: Thu Aug  2 16:54:48 2007
New Revision: 562293

URL: http://svn.apache.org/viewvc?view=rev&rev=562293
Log:
GERONIMO-3350 cleanup now-unused methods

Modified:
    geronimo/server/trunk/applications/console/geronimo-console-standard/src/main/java/org/apache/geronimo/console/util/PortletManager.java
    geronimo/server/trunk/modules/geronimo-jetty6/src/main/java/org/apache/geronimo/jetty6/JettyManagerImpl.java
    geronimo/server/trunk/modules/geronimo-jetty6/src/main/java/org/apache/geronimo/jetty6/connector/HTTPSSelectChannelConnector.java
    geronimo/server/trunk/modules/geronimo-management/src/main/java/org/apache/geronimo/management/geronimo/WebManager.java
    geronimo/server/trunk/modules/geronimo-tomcat6/src/main/java/org/apache/geronimo/tomcat/TomcatManagerImpl.java

Modified: geronimo/server/trunk/applications/console/geronimo-console-standard/src/main/java/org/apache/geronimo/console/util/PortletManager.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/applications/console/geronimo-console-standard/src/main/java/org/apache/geronimo/console/util/PortletManager.java?view=diff&rev=562293&r1=562292&r2=562293
==============================================================================
--- geronimo/server/trunk/applications/console/geronimo-console-standard/src/main/java/org/apache/geronimo/console/util/PortletManager.java
(original)
+++ geronimo/server/trunk/applications/console/geronimo-console-standard/src/main/java/org/apache/geronimo/console/util/PortletManager.java
Thu Aug  2 16:54:48 2007
@@ -249,12 +249,6 @@
         return (WebContainer) helper.getObject(containerName);
     }
 
-    public static WebConnector createWebConnector(PortletRequest request, AbstractName managerName,
AbstractName containerName, String name, String protocol, String host, int port) {
-        ManagementHelper helper = getManagementHelper(request);
-        WebManager manager = (WebManager) helper.getObject(managerName);
-        return manager.addConnector((WebContainer) helper.getObject(containerName), name,
protocol, host, port);
-    }
-
     public static NetworkConnector[] getNetworkConnectors(PortletRequest request, AbstractName
managerName) {
         ManagementHelper helper = getManagementHelper(request);
         WebManager manager = (WebManager) helper.getObject(managerName);

Modified: geronimo/server/trunk/modules/geronimo-jetty6/src/main/java/org/apache/geronimo/jetty6/JettyManagerImpl.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-jetty6/src/main/java/org/apache/geronimo/jetty6/JettyManagerImpl.java?view=diff&rev=562293&r1=562292&r2=562293
==============================================================================
--- geronimo/server/trunk/modules/geronimo-jetty6/src/main/java/org/apache/geronimo/jetty6/JettyManagerImpl.java
(original)
+++ geronimo/server/trunk/modules/geronimo-jetty6/src/main/java/org/apache/geronimo/jetty6/JettyManagerImpl.java
Thu Aug  2 16:54:48 2007
@@ -22,8 +22,8 @@
 import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
-import java.util.Set;
 import java.util.Map.Entry;
+import java.util.Set;
 
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
@@ -51,7 +51,6 @@
 import org.apache.geronimo.management.geronimo.KeystoreManager;
 import org.apache.geronimo.management.geronimo.NetworkConnector;
 import org.apache.geronimo.management.geronimo.WebAccessLog;
-import org.apache.geronimo.management.geronimo.WebConnector;
 import org.apache.geronimo.management.geronimo.WebContainer;
 import org.apache.geronimo.management.geronimo.WebManager;
 
@@ -81,7 +80,6 @@
 
     private static Map<ConnectorType, List<ConnectorAttribute>> CONNECTOR_ATTRIBUTES
= new HashMap<ConnectorType, List<ConnectorAttribute>>();
 
-    //"host", "port", "minThreads", "maxThreads", "bufferSizeBytes", "acceptQueueSize", "lingerMillis",
"protocol", "redirectPort", "connectUrl", "maxIdleTimeMs"
     static {
         List<ConnectorAttribute> connectorAttributes = new ArrayList<ConnectorAttribute>();
         connectorAttributes.add(new ConnectorAttribute<String>("host", "0.0.0.0", "The
host name or IP to bind to. The normal values are 0.0.0.0 (all interfaces) or localhost (local
connections only)", String.class, true));
@@ -190,50 +188,6 @@
 
     public String getProductName() {
         return "Jetty";
-    }
-
-    /**
-     * Creates a new connector, and returns the ObjectName for it.  Note that
-     * the connector may well require further customization before being fully
-     * functional (e.g. SSL settings for an HTTPS connector).
-     */
-    public WebConnector addConnector(WebContainer container, String uniqueName, String protocol,
String host, int port) {
-        AbstractName containerName = kernel.getAbstractNameFor(container);
-        AbstractName name = kernel.getNaming().createSiblingName(containerName, uniqueName,
NameFactory.GERONIMO_SERVICE);
-        GBeanData connector;
-        if (protocol.equals(PROTOCOL_HTTP)) {
-            connector = new GBeanData(name, HTTPSocketConnector.GBEAN_INFO);
-        } else if (protocol.equals(PROTOCOL_HTTPS)) {
-            connector = new GBeanData(name, HTTPSSocketConnector.GBEAN_INFO);
-            AbstractNameQuery query = new AbstractNameQuery(KeystoreManager.class.getName());
-            connector.setReferencePattern("KeystoreManager", query);
-            //todo: default HTTPS settings
-        } else if (protocol.equals(PROTOCOL_AJP)) {
-            connector = new GBeanData(name, AJP13Connector.GBEAN_INFO);
-        } else {
-            throw new IllegalArgumentException("Invalid protocol '" + protocol + "'");
-        }
-        connector.setAttribute("host", host);
-        connector.setAttribute("port", new Integer(port));
-        //connector.setAttribute("minThreads", new Integer(10));        
-        connector.setAttribute("protocol", protocol);
-        connector.setAttribute("maxThreads", new Integer(50));
-        connector.setReferencePattern(JettyConnector.CONNECTOR_CONTAINER_REFERENCE, containerName);
-        EditableConfigurationManager mgr = ConfigurationUtil.getEditableConfigurationManager(kernel);
-        if (mgr != null) {
-            try {
-                mgr.addGBeanToConfiguration(containerName.getArtifact(), connector, false);
-                return (WebConnector) kernel.getProxyManager().createProxy(name, JettyWebConnector.class.getClassLoader());
-            } catch (InvalidConfigException e) {
-                log.error("Unable to add GBean", e);
-                return null;
-            } finally {
-                ConfigurationUtil.releaseConfigurationManager(kernel, mgr);
-            }
-        } else {
-            log.warn("The ConfigurationManager in the kernel does not allow editing");
-            return null;
-        }
     }
 
     /**

Modified: geronimo/server/trunk/modules/geronimo-jetty6/src/main/java/org/apache/geronimo/jetty6/connector/HTTPSSelectChannelConnector.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-jetty6/src/main/java/org/apache/geronimo/jetty6/connector/HTTPSSelectChannelConnector.java?view=diff&rev=562293&r1=562292&r2=562293
==============================================================================
--- geronimo/server/trunk/modules/geronimo-jetty6/src/main/java/org/apache/geronimo/jetty6/connector/HTTPSSelectChannelConnector.java
(original)
+++ geronimo/server/trunk/modules/geronimo-jetty6/src/main/java/org/apache/geronimo/jetty6/connector/HTTPSSelectChannelConnector.java
Thu Aug  2 16:54:48 2007
@@ -22,13 +22,13 @@
 
 import javax.net.ssl.KeyManagerFactory;
 
-import org.apache.geronimo.jetty6.JettySecureConnector;
-import org.apache.geronimo.jetty6.JettyContainer;
-import org.apache.geronimo.management.geronimo.KeystoreManager;
-import org.apache.geronimo.management.geronimo.WebManager;
 import org.apache.geronimo.gbean.GBeanInfo;
 import org.apache.geronimo.gbean.GBeanInfoBuilder;
 import org.apache.geronimo.j2ee.j2eeobjectnames.NameFactory;
+import org.apache.geronimo.jetty6.JettyContainer;
+import org.apache.geronimo.jetty6.JettySecureConnector;
+import org.apache.geronimo.management.geronimo.KeystoreManager;
+import org.apache.geronimo.management.geronimo.WebManager;
 import org.apache.geronimo.system.threads.ThreadPool;
 import org.mortbay.jetty.nio.SelectChannelConnector;
 

Modified: geronimo/server/trunk/modules/geronimo-management/src/main/java/org/apache/geronimo/management/geronimo/WebManager.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-management/src/main/java/org/apache/geronimo/management/geronimo/WebManager.java?view=diff&rev=562293&r1=562292&r2=562293
==============================================================================
--- geronimo/server/trunk/modules/geronimo-management/src/main/java/org/apache/geronimo/management/geronimo/WebManager.java
(original)
+++ geronimo/server/trunk/modules/geronimo-management/src/main/java/org/apache/geronimo/management/geronimo/WebManager.java
Thu Aug  2 16:54:48 2007
@@ -34,23 +34,6 @@
     public final static String PROTOCOL_AJP = "AJP";
 
     /**
-     * Creates and returns a new web connector.  Note that the connector may
-     * well require further customization before being fully functional (e.g.
-     * SSL settings for a secure connector).  This may need to be done before
-     * starting the resulting connector.
-     *
-     * @param container    The container to add the connector to
-     * @param uniqueName   A name fragment that's unique to this connector
-     * @param protocol     The protocol that the connector should use
-     * @param host         The host name or IP that the connector should listen on
-     * @param port         The port that the connector should listen on
-     *
-     * @return The ObjectName of the new connector.
-     * @deprecated
-     */
-    public WebConnector addConnector(WebContainer container, String uniqueName, String protocol,
String host, int port);
-
-    /**
      * Gets the WebAccessLog implementation for a web container.
      * May be null if the access log cannot be managed.
      *

Modified: geronimo/server/trunk/modules/geronimo-tomcat6/src/main/java/org/apache/geronimo/tomcat/TomcatManagerImpl.java
URL: http://svn.apache.org/viewvc/geronimo/server/trunk/modules/geronimo-tomcat6/src/main/java/org/apache/geronimo/tomcat/TomcatManagerImpl.java?view=diff&rev=562293&r1=562292&r2=562293
==============================================================================
--- geronimo/server/trunk/modules/geronimo-tomcat6/src/main/java/org/apache/geronimo/tomcat/TomcatManagerImpl.java
(original)
+++ geronimo/server/trunk/modules/geronimo-tomcat6/src/main/java/org/apache/geronimo/tomcat/TomcatManagerImpl.java
Thu Aug  2 16:54:48 2007
@@ -22,8 +22,8 @@
 import java.util.Iterator;
 import java.util.List;
 import java.util.Map;
-import java.util.Set;
 import java.util.Map.Entry;
+import java.util.Set;
 
 import javax.net.ssl.KeyManagerFactory;
 
@@ -44,7 +44,6 @@
 import org.apache.geronimo.kernel.proxy.ProxyManager;
 import org.apache.geronimo.management.geronimo.NetworkConnector;
 import org.apache.geronimo.management.geronimo.WebAccessLog;
-import org.apache.geronimo.management.geronimo.WebConnector;
 import org.apache.geronimo.management.geronimo.WebContainer;
 import org.apache.geronimo.management.geronimo.WebManager;
 import org.apache.geronimo.system.serverinfo.ServerInfo;
@@ -495,63 +494,6 @@
 
     public String getProductName() {
         return "Tomcat";
-    }
-
-    /**
-     * Creates and returns a new connector.  Note that the connector may well
-     * require further customization before being fully functional (e.g. SSL
-     * settings for a secure connector).  This may need to be done before
-     * starting the resulting connector.
-     *
-     * @param container    The container to add the connector to
-     * @param uniqueName   A name fragment that's unique to this connector
-     * @param protocol     The protocol that the connector should use
-     * @param host         The host name or IP that the connector should listen on
-     * @param port         The port that the connector should listen on
-     */
-    public WebConnector addConnector(WebContainer container, String uniqueName, String protocol,
String host, int port) {
-        AbstractName containerName = kernel.getAbstractNameFor(container);
-        AbstractName name = kernel.getNaming().createSiblingName(containerName, uniqueName,
NameFactory.GERONIMO_SERVICE);
-        //Get the server info
-        AbstractNameQuery query = new AbstractNameQuery(ServerInfo.class.getName());
-        Set set = kernel.listGBeans(query);
-        AbstractName serverInfo = (AbstractName)set.iterator().next();
-        GBeanData connector;
-        if(protocol.equals(PROTOCOL_HTTP)) {
-            connector = new GBeanData(name, Http11ConnectorGBean.GBEAN_INFO);
-            connector.setReferencePattern("ServerInfo", serverInfo);
-        } else if(protocol.equals(PROTOCOL_HTTPS)) {
-            connector = new GBeanData(name, Https11ConnectorGBean.GBEAN_INFO);
-            connector.setReferencePattern("ServerInfo", serverInfo);
-            //todo: default HTTPS settings
-        } else if(protocol.equals(PROTOCOL_AJP)) {
-            connector = new GBeanData(name, AJP13ConnectorGBean.GBEAN_INFO);
-            connector.setReferencePattern("ServerInfo", serverInfo);
-        } else {
-            throw new IllegalArgumentException("Invalid protocol '"+protocol+"'");
-        }
-//        connector.setAttribute("protocol", protocol);
-        connector.setAttribute("host", host);
-        connector.setAttribute("port", new Integer(port));
-        connector.setAttribute("maxThreads", new Integer(50));
-        connector.setAttribute("acceptCount", new Integer(100));
-        connector.setReferencePattern(ConnectorGBean.CONNECTOR_CONTAINER_REFERENCE, containerName);
-        connector.setAttribute("name", uniqueName);
-        EditableConfigurationManager mgr = ConfigurationUtil.getEditableConfigurationManager(kernel);
-        if(mgr != null) {
-            try {
-                mgr.addGBeanToConfiguration(containerName.getArtifact(), connector, false);
-                return (WebConnector) kernel.getProxyManager().createProxy(name, TomcatWebConnector.class.getClassLoader());
-            } catch (InvalidConfigException e) {
-                log.error("Unable to add GBean", e);
-                return null;
-            } finally {
-                ConfigurationUtil.releaseConfigurationManager(kernel, mgr);
-            }
-        } else {
-            log.warn("The ConfigurationManager in the kernel does not allow editing");
-            return null;
-        }
     }
 
     /**



Mime
View raw message