Merge branch '2.7.x' into 3.0.x
This commit is contained in:
@@ -39,8 +39,8 @@ public class MailHealthIndicator extends AbstractHealthIndicator {
|
||||
@Override
|
||||
protected void doHealthCheck(Builder builder) throws Exception {
|
||||
int port = this.mailSender.getPort();
|
||||
builder.withDetail("location", (port == JavaMailSenderImpl.DEFAULT_PORT) ? this.mailSender.getHost()
|
||||
: this.mailSender.getHost() + ":" + this.mailSender.getPort());
|
||||
builder.withDetail("location", (port != JavaMailSenderImpl.DEFAULT_PORT)
|
||||
? this.mailSender.getHost() + ":" + this.mailSender.getPort() : this.mailSender.getHost());
|
||||
this.mailSender.testConnection();
|
||||
builder.up();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user