Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(#609) Introducing async health checks #1077

Merged
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Fix DateFormat issue
  • Loading branch information
arkigabor committed Feb 18, 2017
commit 4a0b79b240cc6c2d80f28649eaf5627d40ba0774
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ public abstract class HealthCheck {
* or unhealthy (with either an error message or a thrown exception and optional details).
*/
public static class Result {
private static final SimpleDateFormat DATE_FORMAT = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSSXXX");
private static final String DATE_FORMAT_PATTERN = "yyyy-MM-dd'T'HH:mm:ss.SSSXXX";
private static final int PRIME = 31;

/**
Expand Down Expand Up @@ -115,7 +115,7 @@ private Result(boolean isHealthy, String message, Throwable error, Map<String, O
this.message = message;
this.error = error;
this.details = details == null ? null : Collections.unmodifiableMap(details);
timestamp = DATE_FORMAT.format(new Date());
timestamp = new SimpleDateFormat(DATE_FORMAT_PATTERN).format(new Date());
}

/**
Expand Down