Examples of monitorHealth()


Examples of org.apache.hadoop.hdfs.server.protocol.NamenodeProtocols.monitorHealth()

          .setNNResourceChecker(mockResourceChecker);
     
      NamenodeProtocols rpc = cluster.getNameNodeRpc(0);
     
      // Should not throw error, which indicates healthy.
      rpc.monitorHealth();
     
      Mockito.doReturn(false).when(mockResourceChecker).hasAvailableDiskSpace();
     
      try {
        // Should throw error - NN is unhealthy.
View Full Code Here

Examples of org.apache.hadoop.hdfs.server.protocol.NamenodeProtocols.monitorHealth()

     
      Mockito.doReturn(false).when(mockResourceChecker).hasAvailableDiskSpace();
     
      try {
        // Should throw error - NN is unhealthy.
        rpc.monitorHealth();
        fail("Should not have succeeded in calling monitorHealth");
      } catch (HealthCheckFailedException hcfe) {
        GenericTestUtils.assertExceptionContains(
            "The NameNode has no resources available", hcfe);
      }
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.