Class DatabaseHealthCheck
java.lang.Object
org.gcube.informationsystem.resourceregistry.persistence.orientdb.health.DatabaseHealthCheck
- All Implemented Interfaces:
org.gcube.common.health.api.HealthCheck
Readiness of the database: the service is down when the database does not answer, since no
operation can run without it.
- Author:
- Luca Frosini (ISTI - CNR)
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
NAME
The name of the check in the health report.- See Also:
-
-
Constructor Details
-
DatabaseHealthCheck
public DatabaseHealthCheck()
-
-
Method Details
-
getName
- Specified by:
getNamein interfaceorg.gcube.common.health.api.HealthCheck
-
check
public org.gcube.common.health.api.response.HealthCheckResponse check()Runs a trivial query on a session of the pool.- Specified by:
checkin interfaceorg.gcube.common.health.api.HealthCheck- Returns:
upwhen the database answers,downwith the reason otherwise
-