@@ -55,7 +55,6 @@ public class Job implements ToXContentObject {
55
55
public static final ParseField DAILY_MODEL_SNAPSHOT_RETENTION_AFTER_DAYS =
56
56
new ParseField ("daily_model_snapshot_retention_after_days" );
57
57
public static final ParseField RESULTS_RETENTION_DAYS = new ParseField ("results_retention_days" );
58
- public static final ParseField SYSTEM_ANNOTATIONS_RETENTION_DAYS = new ParseField ("system_annotations_retention_days" );
59
58
public static final ParseField MODEL_SNAPSHOT_ID = new ParseField ("model_snapshot_id" );
60
59
public static final ParseField RESULTS_INDEX_NAME = new ParseField ("results_index_name" );
61
60
public static final ParseField DELETING = new ParseField ("deleting" );
@@ -84,7 +83,6 @@ public class Job implements ToXContentObject {
84
83
PARSER .declareString ((builder , val ) -> builder .setBackgroundPersistInterval (
85
84
TimeValue .parseTimeValue (val , BACKGROUND_PERSIST_INTERVAL .getPreferredName ())), BACKGROUND_PERSIST_INTERVAL );
86
85
PARSER .declareLong (Builder ::setResultsRetentionDays , RESULTS_RETENTION_DAYS );
87
- PARSER .declareLong (Builder ::setSystemAnnotationsRetentionDays , SYSTEM_ANNOTATIONS_RETENTION_DAYS );
88
86
PARSER .declareLong (Builder ::setModelSnapshotRetentionDays , MODEL_SNAPSHOT_RETENTION_DAYS );
89
87
PARSER .declareLong (Builder ::setDailyModelSnapshotRetentionAfterDays , DAILY_MODEL_SNAPSHOT_RETENTION_AFTER_DAYS );
90
88
PARSER .declareField (Builder ::setCustomSettings , (p , c ) -> p .mapOrdered (), CUSTOM_SETTINGS , ValueType .OBJECT );
@@ -110,7 +108,6 @@ public class Job implements ToXContentObject {
110
108
private final Long modelSnapshotRetentionDays ;
111
109
private final Long dailyModelSnapshotRetentionAfterDays ;
112
110
private final Long resultsRetentionDays ;
113
- private final Long systemAnnotationsRetentionDays ;
114
111
private final Map <String , Object > customSettings ;
115
112
private final String modelSnapshotId ;
116
113
private final String resultsIndexName ;
@@ -122,7 +119,7 @@ private Job(String jobId, String jobType, List<String> groups, String descriptio
122
119
AnalysisConfig analysisConfig , AnalysisLimits analysisLimits , DataDescription dataDescription ,
123
120
ModelPlotConfig modelPlotConfig , Long renormalizationWindowDays , TimeValue backgroundPersistInterval ,
124
121
Long modelSnapshotRetentionDays , Long dailyModelSnapshotRetentionAfterDays , Long resultsRetentionDays ,
125
- Long systemAnnotationsRetentionDays , Map <String , Object > customSettings , String modelSnapshotId , String resultsIndexName ,
122
+ Map <String , Object > customSettings , String modelSnapshotId , String resultsIndexName ,
126
123
Boolean deleting , Boolean allowLazyOpen ) {
127
124
128
125
this .jobId = jobId ;
@@ -140,7 +137,6 @@ private Job(String jobId, String jobType, List<String> groups, String descriptio
140
137
this .modelSnapshotRetentionDays = modelSnapshotRetentionDays ;
141
138
this .dailyModelSnapshotRetentionAfterDays = dailyModelSnapshotRetentionAfterDays ;
142
139
this .resultsRetentionDays = resultsRetentionDays ;
143
- this .systemAnnotationsRetentionDays = systemAnnotationsRetentionDays ;
144
140
this .customSettings = customSettings == null ? null : Collections .unmodifiableMap (customSettings );
145
141
this .modelSnapshotId = modelSnapshotId ;
146
142
this .resultsIndexName = resultsIndexName ;
@@ -266,10 +262,6 @@ public Long getResultsRetentionDays() {
266
262
return resultsRetentionDays ;
267
263
}
268
264
269
- public Long getSystemAnnotationsRetentionDays () {
270
- return systemAnnotationsRetentionDays ;
271
- }
272
-
273
265
public Map <String , Object > getCustomSettings () {
274
266
return customSettings ;
275
267
}
@@ -332,9 +324,6 @@ public XContentBuilder toXContent(XContentBuilder builder, Params params) throws
332
324
if (resultsRetentionDays != null ) {
333
325
builder .field (RESULTS_RETENTION_DAYS .getPreferredName (), resultsRetentionDays );
334
326
}
335
- if (systemAnnotationsRetentionDays != null ) {
336
- builder .field (SYSTEM_ANNOTATIONS_RETENTION_DAYS .getPreferredName (), systemAnnotationsRetentionDays );
337
- }
338
327
if (customSettings != null ) {
339
328
builder .field (CUSTOM_SETTINGS .getPreferredName (), customSettings );
340
329
}
@@ -383,7 +372,6 @@ public boolean equals(Object other) {
383
372
&& Objects .equals (this .customSettings , that .customSettings )
384
373
&& Objects .equals (this .modelSnapshotId , that .modelSnapshotId )
385
374
&& Objects .equals (this .resultsIndexName , that .resultsIndexName )
386
- && Objects .equals (this .systemAnnotationsRetentionDays , that .systemAnnotationsRetentionDays )
387
375
&& Objects .equals (this .deleting , that .deleting )
388
376
&& Objects .equals (this .allowLazyOpen , that .allowLazyOpen );
389
377
}
@@ -393,7 +381,7 @@ public int hashCode() {
393
381
return Objects .hash (jobId , jobType , groups , description , createTime , finishedTime ,
394
382
analysisConfig , analysisLimits , dataDescription , modelPlotConfig , renormalizationWindowDays ,
395
383
backgroundPersistInterval , modelSnapshotRetentionDays , dailyModelSnapshotRetentionAfterDays , resultsRetentionDays ,
396
- systemAnnotationsRetentionDays , customSettings , modelSnapshotId , resultsIndexName , deleting , allowLazyOpen );
384
+ customSettings , modelSnapshotId , resultsIndexName , deleting , allowLazyOpen );
397
385
}
398
386
399
387
@ Override
@@ -422,7 +410,6 @@ public static class Builder {
422
410
private Long modelSnapshotRetentionDays ;
423
411
private Long dailyModelSnapshotRetentionAfterDays ;
424
412
private Long resultsRetentionDays ;
425
- private Long systemAnnotationsRetentionDays ;
426
413
private Map <String , Object > customSettings ;
427
414
private String modelSnapshotId ;
428
415
private String resultsIndexName ;
@@ -452,7 +439,6 @@ public Builder(Job job) {
452
439
this .modelSnapshotRetentionDays = job .getModelSnapshotRetentionDays ();
453
440
this .dailyModelSnapshotRetentionAfterDays = job .getDailyModelSnapshotRetentionAfterDays ();
454
441
this .resultsRetentionDays = job .getResultsRetentionDays ();
455
- this .systemAnnotationsRetentionDays = job .getSystemAnnotationsRetentionDays ();
456
442
this .customSettings = job .getCustomSettings () == null ? null : new LinkedHashMap <>(job .getCustomSettings ());
457
443
this .modelSnapshotId = job .getModelSnapshotId ();
458
444
this .resultsIndexName = job .getResultsIndexNameNoPrefix ();
@@ -544,11 +530,6 @@ public Builder setResultsRetentionDays(Long resultsRetentionDays) {
544
530
return this ;
545
531
}
546
532
547
- public Builder setSystemAnnotationsRetentionDays (Long systemAnnotationsRetentionDays ) {
548
- this .systemAnnotationsRetentionDays = systemAnnotationsRetentionDays ;
549
- return this ;
550
- }
551
-
552
533
public Builder setModelSnapshotId (String modelSnapshotId ) {
553
534
this .modelSnapshotId = modelSnapshotId ;
554
535
return this ;
@@ -581,7 +562,7 @@ public Job build() {
581
562
id , jobType , groups , description , createTime , finishedTime ,
582
563
analysisConfig , analysisLimits , dataDescription , modelPlotConfig , renormalizationWindowDays ,
583
564
backgroundPersistInterval , modelSnapshotRetentionDays , dailyModelSnapshotRetentionAfterDays , resultsRetentionDays ,
584
- systemAnnotationsRetentionDays , customSettings , modelSnapshotId , resultsIndexName , deleting , allowLazyOpen );
565
+ customSettings , modelSnapshotId , resultsIndexName , deleting , allowLazyOpen );
585
566
}
586
567
}
587
568
}
0 commit comments