See gh-15134
This commit is contained in:
Johnny Lim
2018-11-09 00:41:22 +09:00
committed by Stephane Nicoll
parent 2c3b455b8b
commit fd5aa3ebf1
10 changed files with 23 additions and 27 deletions

View File

@@ -34,7 +34,7 @@ import org.springframework.util.Assert;
import org.springframework.util.StringUtils;
/**
* Class that can be used to managed the pushing of metrics to a {@link PushGateway
* Class that can be used to manage the pushing of metrics to a {@link PushGateway
* Prometheus PushGateway}. Handles the scheduling of push operations, error handling and
* shutdown operations.
*
@@ -115,9 +115,9 @@ public class PrometheusPushGatewayManager {
}
catch (UnknownHostException ex) {
String host = ex.getMessage();
String message = "Unable to locate prometheus push gateway host";
message += StringUtils.hasLength(host) ? " '" + host + "'" : "";
message += ". No longer attempting metrics publication to this host";
String message = "Unable to locate prometheus push gateway host"
+ (StringUtils.hasLength(host) ? " '" + host + "'" : "")
+ ". No longer attempting metrics publication to this host";
logger.error(message, ex);
shutdown(ShutdownOperation.NONE);
}