Author: vhalbert(a)redhat.com
Date: 2009-06-24 15:36:12 -0400 (Wed, 24 Jun 2009)
New Revision: 1079
Modified:
trunk/server/src/test/java/com/metamatrix/admin/server/TestServerConfigAdminImpl.java
Log:
Teiid-570 - reverse these changes, removing the configuration related methods that were
added
Modified:
trunk/server/src/test/java/com/metamatrix/admin/server/TestServerConfigAdminImpl.java
===================================================================
---
trunk/server/src/test/java/com/metamatrix/admin/server/TestServerConfigAdminImpl.java 2009-06-24
18:50:28 UTC (rev 1078)
+++
trunk/server/src/test/java/com/metamatrix/admin/server/TestServerConfigAdminImpl.java 2009-06-24
19:36:12 UTC (rev 1079)
@@ -25,6 +25,7 @@
import java.util.Collection;
import java.util.HashSet;
import java.util.Iterator;
+import java.util.List;
import java.util.Properties;
import junit.framework.TestCase;
@@ -368,34 +369,8 @@
}
}
- public void testGetConnectorBindings() throws Exception {
- Collection<ConnectorBinding> bindings =
admin.getConnectorBindingsToConfigure("*");
- assertEquals(3, bindings.size());
-
- bindings = admin.getConnectorBindingsToConfigure("connectorBinding2");
- assertEquals(1, bindings.size());
-
- bindings = admin.getConnectorBindingsToConfigure("*2");
- assertEquals(1, bindings.size());
-
-
-
- }
+
- public void testGetServices() throws Exception {
- Collection<Service> bindings = admin.getServicesToConfigure("*");
- assertEquals(10, bindings.size());
-
- Service svc = bindings.iterator().next();
-
- bindings = admin.getServicesToConfigure("QueryService");
- assertEquals(1, bindings.size());
-
- bindings = admin.getServicesToConfigure("Query*");
- assertEquals(1, bindings.size());
-
- }
-
public void testgetNodeCount() throws Exception {
assertEquals(1, admin.getNodeCount(BOGUS_HOST_FULLY_QUALIFIED));
@@ -404,58 +379,58 @@
}
- public void testUpdateProperties() throws Exception {
-
- //Test update properties for deployed connector
- Properties properties = new Properties();
- properties.put(DQPConfigSource.PROCESS_POOL_MAX_THREADS, "11");
-
admin.updateProperties(HOST_2_2_2_2_PROCESS2_CONNECTOR_BINDING2,com.metamatrix.admin.api.objects.ConnectorBinding.class.getName(),
properties);
- //Verify results
- DeployedComponent dc =
admin.getDeployedComponent(HOST_2_2_2_2_PROCESS2_CONNECTOR_BINDING2);
- String actualPropValue = dc.getProperty(DQPConfigSource.PROCESS_POOL_MAX_THREADS);
- assertEquals("11", actualPropValue);
-
- //Test update properties for a connector binding from configuration
- properties = new Properties();
- properties.put(DQPConfigSource.PROCESS_POOL_MAX_THREADS, "22");
-
admin.updateProperties("connectorbinding2",com.metamatrix.admin.api.objects.ConnectorBinding.class.getName(),
properties);
- //Verify results
- Collection<MMConnectorBinding> objs1 =
admin.getConnectorBindingsToConfigure("connectorBinding2");
- MMConnectorBinding binding = objs1.iterator().next();
- actualPropValue =
binding.getPropertyValue(DQPConfigSource.PROCESS_POOL_MAX_THREADS);
- assertEquals("22", actualPropValue);
-
- //Test update properties for deployed service
- properties = new Properties();
- properties.put("ProcessPoolThreadTTL", "9");
-
admin.updateProperties(HOST_2_2_2_2_PROCESS2_DQP2,com.metamatrix.admin.api.objects.Service.class.getName(),
properties);
- //Verify results
- dc = admin.getDeployedComponent(HOST_2_2_2_2_PROCESS2_DQP2);
- actualPropValue = dc.getProperty("ProcessPoolThreadTTL");
- assertEquals("9", actualPropValue);
-
- //Test update properties for a service from configuration
- properties = new Properties();
- properties.put(MembershipServiceInterface.SECURITY_ENABLED, "false");
-
admin.updateProperties(MembershipServiceInterface.NAME,com.metamatrix.admin.api.objects.Service.class.getName(),
properties);
- //Verify results
- ServiceComponentDefn service =
admin.getServiceByName(MembershipServiceInterface.NAME);
- actualPropValue =
service.getProperty(MembershipServiceInterface.SECURITY_ENABLED);
- assertEquals("false", actualPropValue);
-
- //Test update properties for process
- properties = new Properties();
- properties.put(ProcessObject.TIMETOLIVE, "99");
-
admin.updateProperties(HOST_2_2_2_2_PROCESS2,com.metamatrix.admin.api.objects.ProcessObject.class.getName(),
properties);
- //Verify results
- Collection<MMProcess> processObjs =
admin.getAdminObjects(HOST_2_2_2_2_PROCESS2,com.metamatrix.admin.api.objects.ProcessObject.class.getName());
- MMProcess process = processObjs.iterator().next();
- actualPropValue = process.getPropertyValue(ProcessObject.TIMETOLIVE);
- assertEquals("99", actualPropValue);
-
- }
+// public void testUpdateProperties() throws Exception {
+//
+// //Test update properties for deployed connector
+// Properties properties = new Properties();
+// properties.put(DQPConfigSource.PROCESS_POOL_MAX_THREADS, "11");
+//
admin.updateProperties(HOST_2_2_2_2_PROCESS2_CONNECTOR_BINDING2,com.metamatrix.admin.api.objects.ConnectorBinding.class.getName(),
properties);
+// //Verify results
+// DeployedComponent dc =
admin.getDeployedComponent(HOST_2_2_2_2_PROCESS2_CONNECTOR_BINDING2);
+// String actualPropValue =
dc.getProperty(DQPConfigSource.PROCESS_POOL_MAX_THREADS);
+// assertEquals("11", actualPropValue);
+//
+// //Test update properties for a connector binding from configuration
+// properties = new Properties();
+// properties.put(DQPConfigSource.PROCESS_POOL_MAX_THREADS, "22");
+//
admin.updateProperties("connectorbinding2",com.metamatrix.admin.api.objects.ConnectorBinding.class.getName(),
properties);
+// //Verify results
+// List<com.metamatrix.common.config.api.ConnectorBinding> objs1 =
admin.getConnectorBindingsByName(new String[] {"connectorBinding2"});
+// MMConnectorBinding binding = objs1.iterator().next();
+// actualPropValue =
binding.getPropertyValue(DQPConfigSource.PROCESS_POOL_MAX_THREADS);
+// assertEquals("22", actualPropValue);
+//
+// //Test update properties for deployed service
+// properties = new Properties();
+// properties.put("ProcessPoolThreadTTL", "9");
+//
admin.updateProperties(HOST_2_2_2_2_PROCESS2_DQP2,com.metamatrix.admin.api.objects.Service.class.getName(),
properties);
+// //Verify results
+// dc = admin.getDeployedComponent(HOST_2_2_2_2_PROCESS2_DQP2);
+// actualPropValue = dc.getProperty("ProcessPoolThreadTTL");
+// assertEquals("9", actualPropValue);
+//
+// //Test update properties for a service from configuration
+// properties = new Properties();
+// properties.put(MembershipServiceInterface.SECURITY_ENABLED, "false");
+//
admin.updateProperties(MembershipServiceInterface.NAME,com.metamatrix.admin.api.objects.Service.class.getName(),
properties);
+// //Verify results
+// ServiceComponentDefn service =
admin.getServiceByName(MembershipServiceInterface.NAME);
+// actualPropValue =
service.getProperty(MembershipServiceInterface.SECURITY_ENABLED);
+// assertEquals("false", actualPropValue);
+//
+// //Test update properties for process
+// properties = new Properties();
+// properties.put(ProcessObject.TIMETOLIVE, "99");
+//
admin.updateProperties(HOST_2_2_2_2_PROCESS2,com.metamatrix.admin.api.objects.ProcessObject.class.getName(),
properties);
+// //Verify results
+// Collection<MMProcess> processObjs =
admin.getAdminObjects(HOST_2_2_2_2_PROCESS2,com.metamatrix.admin.api.objects.ProcessObject.class.getName());
+// MMProcess process = processObjs.iterator().next();
+// actualPropValue = process.getPropertyValue(ProcessObject.TIMETOLIVE);
+// assertEquals("99", actualPropValue);
+//
+// }
+//
-
}