Examples of dropResourceFromCluster()


Examples of com.linkedin.helix.tools.ClusterSetup.dropResourceFromCluster()

    TestDriver.setIdealState(uniqClusterName, 2000, 50);
    TestDriver.verifyCluster(uniqClusterName, 3000, 50 * 1000);

    // drop resource group
    ClusterSetup setup = new ClusterSetup(ZK_ADDR);
    setup.dropResourceFromCluster(uniqClusterName, "TestDB0");

    TestHelper.verifyWithTimeout("verifyEmptyCurStateAndExtView",
                                 30 * 1000,
                                 uniqClusterName,
                                 "TestDB0",
View Full Code Here

Examples of com.linkedin.helix.tools.ClusterSetup.dropResourceFromCluster()

          (String) getRequest().getAttributes().get("resourceName");
      ZkClient zkClient =
          (ZkClient) getContext().getAttributes().get(RestAdminApplication.ZKCLIENT);
     
      ClusterSetup setupTool = new ClusterSetup(zkClient);
      setupTool.dropResourceFromCluster(clusterName, resourceGroupName);
      getResponse().setStatus(Status.SUCCESS_OK);
    }
    catch (Exception e)
    {
      getResponse().setEntity(ClusterRepresentationUtil.getErrorAsJsonStringFromException(e),
View Full Code Here

Examples of org.apache.helix.api.accessor.ClusterAccessor.dropResourceFromCluster()

  void dropResource(String[] optValues) {
    String clusterName = optValues[0];
    String resourceName = optValues[1];

    ClusterAccessor accessor = clusterAccessor(clusterName);
    accessor.dropResourceFromCluster(ResourceId.from(resourceName));
  }

  void dropInstance(String[] optValues) {
    String clusterName = optValues[0];
    String[] instanceIds = optValues[1].split(";");
View Full Code Here

Examples of org.apache.helix.tools.ClusterSetup.dropResourceFromCluster()

          (String) getRequest().getAttributes().get("resourceName");
      ZkClient zkClient =
          (ZkClient) getContext().getAttributes().get(RestAdminApplication.ZKCLIENT);
     
      ClusterSetup setupTool = new ClusterSetup(zkClient);
      setupTool.dropResourceFromCluster(clusterName, resourceGroupName);
      getResponse().setStatus(Status.SUCCESS_OK);
    }
    catch (Exception e)
    {
      getResponse().setEntity(ClusterRepresentationUtil.getErrorAsJsonStringFromException(e),
View Full Code Here

Examples of org.apache.helix.tools.ClusterSetup.dropResourceFromCluster()

    TestDriver.setIdealState(uniqClusterName, 2000, 50);
    TestDriver.verifyCluster(uniqClusterName, 3000, 50 * 1000);

    // drop resource group
    ClusterSetup setup = new ClusterSetup(ZK_ADDR);
    setup.dropResourceFromCluster(uniqClusterName, "TestDB0");

    TestHelper.verifyWithTimeout("verifyEmptyCurStateAndExtView", 30 * 1000, uniqClusterName, "TestDB0",
        TestHelper.<String> setOf("localhost_12918", "localhost_12919", "localhost_12920",
            "localhost_12921", "localhost_12922"), ZK_ADDR);

View Full Code Here

Examples of org.apache.helix.tools.ClusterSetup.dropResourceFromCluster()

    Thread.sleep(1000);
    Assert.assertTrue(nMbeansUnregistered == listener._nMbeansUnregistered - 7);
    Assert.assertTrue(nMbeansRegistered == listener._nMbeansRegistered - 8);

    // remove resource, no change
    setupTool.dropResourceFromCluster(_firstClusterName, "TestDB1");
    Thread.sleep(1000);
    Assert.assertTrue(nMbeansUnregistered == listener._nMbeansUnregistered - 7);
    Assert.assertTrue(nMbeansRegistered == listener._nMbeansRegistered - 8);

  }
View Full Code Here

Examples of org.apache.helix.tools.ClusterSetup.dropResourceFromCluster()

      String resourceGroupName = (String) getRequest().getAttributes().get("resourceName");
      ZkClient zkClient =
          (ZkClient) getContext().getAttributes().get(RestAdminApplication.ZKCLIENT);

      ClusterSetup setupTool = new ClusterSetup(zkClient);
      setupTool.dropResourceFromCluster(clusterName, resourceGroupName);
      getResponse().setStatus(Status.SUCCESS_OK);
    } catch (Exception e) {
      getResponse().setEntity(ClusterRepresentationUtil.getErrorAsJsonStringFromException(e),
          MediaType.APPLICATION_JSON);
      getResponse().setStatus(Status.SUCCESS_OK);
View Full Code Here

Examples of org.apache.helix.tools.ClusterSetup.dropResourceFromCluster()

    TestDriver.setIdealState(uniqClusterName, 2000, 50);
    TestDriver.verifyCluster(uniqClusterName, 3000, 50 * 1000);

    // drop resource group
    ClusterSetup setup = new ClusterSetup(ZK_ADDR);
    setup.dropResourceFromCluster(uniqClusterName, "TestDB0");

    TestHelper.verifyWithTimeout("verifyEmptyCurStateAndExtView", 30 * 1000, uniqClusterName,
        "TestDB0", TestHelper.<String> setOf("localhost_12918", "localhost_12919",
            "localhost_12920", "localhost_12921", "localhost_12922"), ZK_ADDR);

View Full Code Here

Examples of org.apache.helix.tools.ClusterSetup.dropResourceFromCluster()

      String resourceGroupName = (String) getRequest().getAttributes().get("resourceName");
      ZkClient zkClient =
          (ZkClient) getContext().getAttributes().get(RestAdminApplication.ZKCLIENT);

      ClusterSetup setupTool = new ClusterSetup(zkClient);
      setupTool.dropResourceFromCluster(clusterName, resourceGroupName);
      getResponse().setStatus(Status.SUCCESS_OK);
    } catch (Exception e) {
      getResponse().setEntity(ClusterRepresentationUtil.getErrorAsJsonStringFromException(e),
          MediaType.APPLICATION_JSON);
      getResponse().setStatus(Status.SUCCESS_OK);
View Full Code Here

Examples of org.apache.helix.tools.ClusterSetup.dropResourceFromCluster()

    // Verify that the bean was created
    boolean noTimeout = _registerLatch.await(30000, TimeUnit.MILLISECONDS);
    Assert.assertTrue(noTimeout);

    // Drop the resource
    setupTool.dropResourceFromCluster(clusterName, RESOURCE_NAME);

    // Verify that the bean was removed
    noTimeout = _unregisterLatch.await(30000, TimeUnit.MILLISECONDS);
    Assert.assertTrue(noTimeout);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.