Skip to content

Commit b91340c

Browse files
committed
only load health status manager if GRPC enabled
1 parent 183c22b commit b91340c

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

grpc-server-spring-boot-starter/src/main/java/net/devh/boot/grpc/server/autoconfigure/GrpcHealthServiceAutoConfiguration.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,8 @@ public class GrpcHealthServiceAutoConfiguration {
5151
*/
5252
@Bean
5353
@ConditionalOnMissingBean
54+
@ConditionalOnProperty(prefix = "grpc.server", name = "health-service-type", havingValue = "GRPC",
55+
matchIfMissing = true)
5456
HealthStatusManager healthStatusManager() {
5557
return new HealthStatusManager();
5658
}

0 commit comments

Comments
 (0)