Skip to content

Commit

Permalink
Update synthetic source cutoff date (elastic#118069)
Browse files Browse the repository at this point in the history
Updating from 01-02-2025T00:00:00UTC to 04-02-2025T00:00:00UTC
  • Loading branch information
martijnvg committed Dec 5, 2024
1 parent fbb42f1 commit 53c64a6
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ final class SyntheticSourceLicenseService {
// You can only override this property if you received explicit approval from Elastic.
static final String CUTOFF_DATE_SYS_PROP_NAME = "es.mapping.synthetic_source_fallback_to_stored_source.cutoff_date_restricted_override";
private static final Logger LOGGER = LogManager.getLogger(SyntheticSourceLicenseService.class);
static final long DEFAULT_CUTOFF_DATE = LocalDateTime.of(2025, 2, 1, 0, 0).toInstant(ZoneOffset.UTC).toEpochMilli();
static final long DEFAULT_CUTOFF_DATE = LocalDateTime.of(2025, 2, 4, 0, 0).toInstant(ZoneOffset.UTC).toEpochMilli();

/**
* A setting that determines whether source mode should always be stored source. Regardless of licence.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,8 @@ public void testSyntheticSourceUsageWithLegacyLicense() {
}

public void testSyntheticSourceUsageWithLegacyLicensePastCutoff() throws Exception {
long startPastCutoff = LocalDateTime.of(2025, 11, 12, 0, 0).toInstant(ZoneOffset.UTC).toEpochMilli();
// One day after default cutoff date
long startPastCutoff = LocalDateTime.of(2025, 2, 5, 0, 0).toInstant(ZoneOffset.UTC).toEpochMilli();
putLicense(createGoldOrPlatinumLicense(startPastCutoff));
ensureGreen();

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ public void testGetAdditionalIndexSettingsTsdb() throws IOException {
}

public void testGetAdditionalIndexSettingsTsdbAfterCutoffDate() throws Exception {
long start = LocalDateTime.of(2025, 2, 2, 0, 0).toInstant(ZoneOffset.UTC).toEpochMilli();
long start = LocalDateTime.of(2025, 2, 5, 0, 0).toInstant(ZoneOffset.UTC).toEpochMilli();
License license = createGoldOrPlatinumLicense(start);
long time = LocalDateTime.of(2024, 12, 31, 0, 0).toInstant(ZoneOffset.UTC).toEpochMilli();
var licenseState = new XPackLicenseState(() -> time, new XPackLicenseStatus(license.operationMode(), true, null));
Expand Down

0 comments on commit 53c64a6

Please sign in to comment.