public class SpannerHealthIndicator
extends org.springframework.boot.actuate.health.AbstractHealthIndicator
HealthIndicator
for
Spanner. Validates if connection is successful by executing query from the spannerTemplate using
SpannerTemplate.executeQuery(Statement, SpannerQueryOptions)
.
If there is no error, this health indicator will signal "up".
Constructor and Description |
---|
SpannerHealthIndicator(SpannerTemplate spannerTemplate,
String validationQuery)
SpannerHealthIndicator constructor.
|
Modifier and Type | Method and Description |
---|---|
protected void |
doHealthCheck(org.springframework.boot.actuate.health.Health.Builder builder) |
public SpannerHealthIndicator(SpannerTemplate spannerTemplate, String validationQuery)
spannerTemplate
- spannerTemplate to execute queryvalidationQuery
- query to executeCopyright © 2021. All rights reserved.