Class DiagnosticsResult
java.lang.Object
com.couchbase.client.core.diagnostics.DiagnosticsResult
This report provides insight into the current cluster state from the point of view of the client.
-
Constructor Summary
ConstructorDescriptionDiagnosticsResult
(Map<ServiceType, List<EndpointDiagnostics>> endpoints, String sdk, String id) Creates the new diagnostics report. -
Method Summary
Modifier and TypeMethodDescriptionReturns the diagnostic reports of each individual endpoint.boolean
Exports this report into the standard JSON format which is consistent across different SDKs.int
hashCode()
id()
The ID of this report.sdk()
The identifier of this SDK (useful when exporting to JSON).state()
Returns the aggregated and simplified cluster state.toString()
int
version()
The version of this report (useful when exporting to JSON).
-
Constructor Details
-
DiagnosticsResult
@Internal public DiagnosticsResult(Map<ServiceType, List<EndpointDiagnostics>> endpoints, String sdk, String id) Creates the new diagnostics report.Note that this is internal API and should not be called at the application level.
- Parameters:
endpoints
- the health of each individual endpoint.sdk
- the sdk identifier.id
- the report ID.
-
-
Method Details
-
id
The ID of this report.- Returns:
- the ID, either automatically generated or the one provided by the user.
-
version
public int version()The version of this report (useful when exporting to JSON).- Returns:
- the version format of this report.
-
sdk
The identifier of this SDK (useful when exporting to JSON).- Returns:
- the identifier of this SDK.
-
endpoints
Returns the diagnostic reports of each individual endpoint. -
state
Returns the aggregated and simplified cluster state. -
exportToJson
Exports this report into the standard JSON format which is consistent across different SDKs.- Returns:
- the report encoded as JSON.
-
toString
-
equals
-
hashCode
public int hashCode()
-