Author: markt Date: Sun May 24 17:54:19 2009 New Revision: 778200 URL: http://svn.apache.org/viewvc?rev=778200&view=rev Log: Remove unused methods, and with them a few more references to ServerFactory
Modified: tomcat/trunk/java/org/apache/catalina/mbeans/MBeanFactory.java Modified: tomcat/trunk/java/org/apache/catalina/mbeans/MBeanFactory.java URL: http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/mbeans/MBeanFactory.java?rev=778200&r1=778199&r2=778200&view=diff ============================================================================== --- tomcat/trunk/java/org/apache/catalina/mbeans/MBeanFactory.java (original) +++ tomcat/trunk/java/org/apache/catalina/mbeans/MBeanFactory.java Sun May 24 17:54:19 2009 @@ -644,48 +644,6 @@ } - /** - * Create a new StandardEngine. - * - * @param parent MBean Name of the associated parent component - * @param engineName Unique name of this Engine - * @param defaultHost Default hostname of this Engine - * @param serviceName Unique name of this Service - * - * @exception Exception if an MBean cannot be created or registered - */ - - public Vector<ObjectName> createStandardEngineService(String parent, - String engineName, String defaultHost, String serviceName) - throws Exception { - - // Create a new StandardService instance - StandardService service = new StandardService(); - service.setName(serviceName); - // Create a new StandardEngine instance - StandardEngine engine = new StandardEngine(); - engine.setName(engineName); - engine.setDefaultHost(defaultHost); - // Need to set engine before adding it to server in order to set domain - service.setContainer(engine); - // Add the new instance to its parent component - Server server = ServerFactory.getServer(); - server.addService(service); - Vector<ObjectName> onames = new Vector<ObjectName>(); - // FIXME service & engine.getObjectName - //ObjectName oname = engine.getObjectName(); - ObjectName oname = - MBeanUtils.createObjectName(engineName, engine); - onames.add(0, oname); - //oname = service.getObjectName(); - oname = - MBeanUtils.createObjectName(engineName, service); - onames.add(1, oname); - return (onames); - - } - - /** * Create a new StandardHost. * @@ -768,32 +726,6 @@ /** - * Create a new StandardService. - * - * @param parent MBean Name of the associated parent component - * @param name Unique name of this StandardService - * - * @exception Exception if an MBean cannot be created or registered - */ - public String createStandardService(String parent, String name, String domain) - throws Exception { - - // Create a new StandardService instance - StandardService service = new StandardService(); - service.setName(name); - - // Add the new instance to its parent component - Server server = ServerFactory.getServer(); - server.addService(service); - - // Return the corresponding MBean name - return (service.getObjectName().toString()); - - } - - - - /** * Create a new UserDatabaseRealm. * * @param parent MBean Name of the associated parent component @@ -1024,27 +956,6 @@ /** - * Remove an existing Service. - * - * @param name MBean Name of the component to remove - * - * @exception Exception if a component cannot be removed - */ - public void removeService(String name) throws Exception { - - // Acquire a reference to the component to be removed - ObjectName oname = new ObjectName(name); - String serviceName = oname.getKeyProperty("serviceName"); - Server server = ServerFactory.getServer(); - Service service = server.findService(serviceName); - - // Remove this component from its parent component - server.removeService(service); - - } - - - /** * Remove an existing Valve. * * @param name MBean Name of the comonent to remove --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org