Search in sources :

Example 1 with ServicesDetails

use of com.cloudera.thunderhead.telemetry.nodestatus.NodeStatusProto.ServicesDetails in project cloudbreak by hortonworks.

the class NodeServicesCheckerConclusionStepTest method createNodeStatusResponse.

private RPCResponse<NodeStatusReport> createNodeStatusResponse(HealthStatus saltBootstrapServiceStatus) {
    StatusDetails statusDetails = StatusDetails.newBuilder().setHost("host1").build();
    ServiceStatus serviceStatus = ServiceStatus.newBuilder().setName("salt-bootstrap").setStatus(saltBootstrapServiceStatus).build();
    ServicesDetails servicesDetails = ServicesDetails.newBuilder().addInfraServices(serviceStatus).build();
    NodeStatus nodeStatus = NodeStatus.newBuilder().setStatusDetails(statusDetails).setServicesDetails(servicesDetails).build();
    NodeStatusReport nodeStatusReport = NodeStatusReport.newBuilder().addNodes(nodeStatus).build();
    RPCResponse<NodeStatusReport> response = new RPCResponse<>();
    response.setResult(nodeStatusReport);
    return response;
}
Also used : ServiceStatus(com.cloudera.thunderhead.telemetry.nodestatus.NodeStatusProto.ServiceStatus) StatusDetails(com.cloudera.thunderhead.telemetry.nodestatus.NodeStatusProto.StatusDetails) NodeStatusReport(com.cloudera.thunderhead.telemetry.nodestatus.NodeStatusProto.NodeStatusReport) RPCResponse(com.sequenceiq.cloudbreak.client.RPCResponse) NodeStatus(com.cloudera.thunderhead.telemetry.nodestatus.NodeStatusProto.NodeStatus) ServicesDetails(com.cloudera.thunderhead.telemetry.nodestatus.NodeStatusProto.ServicesDetails)

Aggregations

NodeStatus (com.cloudera.thunderhead.telemetry.nodestatus.NodeStatusProto.NodeStatus)1 NodeStatusReport (com.cloudera.thunderhead.telemetry.nodestatus.NodeStatusProto.NodeStatusReport)1 ServiceStatus (com.cloudera.thunderhead.telemetry.nodestatus.NodeStatusProto.ServiceStatus)1 ServicesDetails (com.cloudera.thunderhead.telemetry.nodestatus.NodeStatusProto.ServicesDetails)1 StatusDetails (com.cloudera.thunderhead.telemetry.nodestatus.NodeStatusProto.StatusDetails)1 RPCResponse (com.sequenceiq.cloudbreak.client.RPCResponse)1