Package com.vmware.bdd.service.resmgmt

Examples of com.vmware.bdd.service.resmgmt.IResourcePoolService


            "http://localhost/distros/apache/1.0.1/hbase-0.94.0.tar.gz");
      Mockito.when(
            distroMgr.getPackageUrlByDistroRole("apache",
                  HadoopRole.ZOOKEEPER_ROLE.toString())).thenReturn(
            "http://localhost/distros/apache/1.0.1/zookeeper-3.4.3.tar.gz");
      IResourcePoolService resPoolSvc =
            context.getBean("resourcePoolService", IResourcePoolService.class);
      IDatastoreService dsSvc =
            context.getBean("datastoreService", IDatastoreService.class);
      INetworkService netSvc =
            context.getBean("networkService", INetworkService.class);
      cleanUpUtils = new TestResourceCleanupUtils();
      cleanUpUtils.setDsSvc(dsSvc);
      cleanUpUtils.setNetSvc(netSvc);
      cleanUpUtils.setResPoolSvc(resPoolSvc);
      cleanupResources();

      try {
         Set<String> rpNames = resPoolSvc.getAllRPNames();
         logger.info("available resource pools: " + rpNames);
         resPoolSvc.addResourcePool("myRp1", "cluster1", "rp1");
      } catch (Exception e) {
         logger.error("ignore create resource pool myRp1 exception. ", e);
      }
      try {
         resPoolSvc.addResourcePool("myRp2", "cluster1", "rp2");
      } catch (Exception e) {
         logger.error("ignore create resource pool myRp2 exception. ", e);
      }
      try {
         resPoolSvc.addResourcePool("myRp3", "cluster2", "rp1");
      } catch (Exception e) {
         logger.error("ignore create resource pool myRp3 exception. ", e);
      }
      try {
         resPoolSvc.addResourcePool("myRp4", "cluster2", "rp2");
      } catch (Exception e) {
         logger.error("ignore create resource pool myRp4 exception. ", e);
      }
      try {
         resPoolSvc.addResourcePool("myRp5", "cluster4", "rp1");
      } catch (Exception e) {
         logger.error("ignore create resource pool myRp5 exception. ", e);
      }
      try {
         resPoolSvc.addResourcePool("myRp6", "cluster4", "rp2");
      } catch (Exception e) {
         logger.error("ignore create resource pool myRp6 exception. ", e);
      }
      try {
         netSvc.addDhcpNetwork("dhcpNet1", "CFNetwork");
View Full Code Here


   }

   @Test(groups = { "res-mgmt", "dependsOnVC", "dependsOnDB"})
   public void testgetAllResourcePoolForRest() {
      super.init();
      IResourcePoolService rpSvc = ctx.getBean(IResourcePoolService.class);
      List<ResourcePoolRead> rps = rpSvc.getAllResourcePoolForRest();
      Assert.assertNotNull(rps);
   }
View Full Code Here

TOP

Related Classes of com.vmware.bdd.service.resmgmt.IResourcePoolService

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.