fix DateMathParser compilation error
Original commit: elastic/x-pack-elasticsearch@e3cd2e0e45
This commit is contained in:
parent
900ea3cd20
commit
c48770c525
|
@ -25,7 +25,7 @@ import static org.junit.Assert.assertThat;
|
||||||
public class TestUtils {
|
public class TestUtils {
|
||||||
|
|
||||||
private final static FormatDateTimeFormatter formatDateTimeFormatter = Joda.forPattern("yyyy-MM-dd");
|
private final static FormatDateTimeFormatter formatDateTimeFormatter = Joda.forPattern("yyyy-MM-dd");
|
||||||
private final static DateMathParser dateMathParser = new DateMathParser(formatDateTimeFormatter, TimeUnit.MILLISECONDS);
|
private final static DateMathParser dateMathParser = new DateMathParser(formatDateTimeFormatter);
|
||||||
private final static org.elasticsearch.common.joda.time.format.DateTimeFormatter dateTimeFormatter = formatDateTimeFormatter.printer();
|
private final static org.elasticsearch.common.joda.time.format.DateTimeFormatter dateTimeFormatter = formatDateTimeFormatter.printer();
|
||||||
|
|
||||||
public static void isSame(Set<License> firstLicenses, Set<License> secondLicenses) {
|
public static void isSame(Set<License> firstLicenses, Set<License> secondLicenses) {
|
||||||
|
|
|
@ -36,7 +36,7 @@ public class TestUtils {
|
||||||
public static final String PRIVATE_KEY_RESOURCE = "/private.key";
|
public static final String PRIVATE_KEY_RESOURCE = "/private.key";
|
||||||
|
|
||||||
private final static FormatDateTimeFormatter formatDateTimeFormatter = Joda.forPattern("yyyy-MM-dd");
|
private final static FormatDateTimeFormatter formatDateTimeFormatter = Joda.forPattern("yyyy-MM-dd");
|
||||||
private final static DateMathParser dateMathParser = new DateMathParser(formatDateTimeFormatter, TimeUnit.MILLISECONDS);
|
private final static DateMathParser dateMathParser = new DateMathParser(formatDateTimeFormatter);
|
||||||
private final static org.elasticsearch.common.joda.time.format.DateTimeFormatter dateTimeFormatter = formatDateTimeFormatter.printer();
|
private final static org.elasticsearch.common.joda.time.format.DateTimeFormatter dateTimeFormatter = formatDateTimeFormatter.printer();
|
||||||
|
|
||||||
public static void isSame(Set<License> firstLicenses, Set<License> secondLicenses) {
|
public static void isSame(Set<License> firstLicenses, Set<License> secondLicenses) {
|
||||||
|
|
|
@ -44,7 +44,7 @@ public abstract class AbstractLicensesIntegrationTests extends ElasticsearchInte
|
||||||
|
|
||||||
private final static FormatDateTimeFormatter formatDateTimeFormatter = Joda.forPattern("yyyy-MM-dd");
|
private final static FormatDateTimeFormatter formatDateTimeFormatter = Joda.forPattern("yyyy-MM-dd");
|
||||||
private final static org.elasticsearch.common.joda.time.format.DateTimeFormatter dateTimeFormatter = formatDateTimeFormatter.printer();
|
private final static org.elasticsearch.common.joda.time.format.DateTimeFormatter dateTimeFormatter = formatDateTimeFormatter.printer();
|
||||||
private final static DateMathParser dateMathParser = new DateMathParser(formatDateTimeFormatter, TimeUnit.MILLISECONDS);
|
private final static DateMathParser dateMathParser = new DateMathParser(formatDateTimeFormatter);
|
||||||
|
|
||||||
public static String dateMathString(String time, final long now) {
|
public static String dateMathString(String time, final long now) {
|
||||||
return dateTimeFormatter.print(dateMathParser.parse(time, new Callable<Long>() {
|
return dateTimeFormatter.print(dateMathParser.parse(time, new Callable<Long>() {
|
||||||
|
|
Loading…
Reference in New Issue