Examples of InventoryReport


Examples of org.rhq.core.clientapi.server.discovery.InventoryReport

            doDeployment(deploymentOptions);
            ClusterInitService clusterInitService = new ClusterInitService();
            clusterInitService.waitForClusterToStart(new String [] {"127.0.0.2"}, new int[] {7400});

            InventoryManager inventoryManager = PluginContainer.getInstance().getInventoryManager();
            InventoryReport inventoryReport = inventoryManager.executeServerScanImmediately();
            Resource newStorageNode = null;

            if (inventoryReport.getAddedRoots().isEmpty()) {
                // could be empty if the storage node is already in inventory from
                // a prior discovery scan.
                Resource platform = inventoryManager.getPlatform();
                newStorageNode = findCassandraNode(platform.getChildResources(), "127.0.0.2");
            } else {
                newStorageNode = findCassandraNode(inventoryReport.getAddedRoots(), "127.0.0.2");
            }

            assertNotNull(newStorageNode, "Failed to discover Storage Node instance at 127.0.0.2");
            assertNodeIsUp("Expected " + newStorageNode + " to be UP after discovery");
View Full Code Here

Examples of org.rhq.core.clientapi.server.discovery.InventoryReport

    }

    @Test(dependsOnMethods = "testPluginLoad")
    public void testServerDiscovery() throws Exception {
        try {
            InventoryReport report = PluginContainer.getInstance().getInventoryManager().executeServerScanImmediately();
            assert report != null;
            System.out.println("Discovery took: " + (report.getEndTime() - report.getStartTime()) + "ms");
            Resource platform = PluginContainer.getInstance().getInventoryManager().getPlatform();
            Set<Resource> servers = platform.getChildResources();
            assert servers != null;
            System.out.println("Found " + servers.size() + " servers");
        } catch (Exception e) {
View Full Code Here

Examples of org.rhq.core.clientapi.server.discovery.InventoryReport

    }

    @Test(dependsOnMethods = "testServerDiscovery")
    public void testServiceDiscovery() throws Exception {
        try {
            InventoryReport report =
                PluginContainer.getInstance().getInventoryManager().executeServiceScanImmediately();
            Resource platform = PluginContainer.getInstance().getInventoryManager().getPlatform();
            System.out.println("RUNTIME SERVERS: " + platform.getChildResources().size());
            for (Resource server : platform.getChildResources()) {
                System.out.println("Server: " + server.toString());
View Full Code Here

Examples of org.rhq.core.clientapi.server.discovery.InventoryReport

     * Tests that the JON Agent can be discovered.
     *
     * @throws Exception
     */
    public void testServerDiscovery() throws Exception {
        InventoryReport report = pc.getInventoryManager().executeServerScanImmediately();
        assert report != null;

        Resource platform = pc.getInventoryManager().getPlatform();
        Set<Resource> servers = platform.getChildResources();
        assert servers.size() > 0;
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.