mirror of
https://github.com/elastic/elasticsearch.git
synced 2025-04-25 07:37:19 -04:00
[ML] Remove unused method AutodetectParams.Builder.setFilters (#63662)
This commit is contained in:
parent
8527183f91
commit
281c702988
2 changed files with 1 additions and 11 deletions
|
@ -110,14 +110,13 @@ public class AutodetectParams {
|
||||||
private TimingStats timingStats;
|
private TimingStats timingStats;
|
||||||
private ModelSnapshot modelSnapshot;
|
private ModelSnapshot modelSnapshot;
|
||||||
private Quantiles quantiles;
|
private Quantiles quantiles;
|
||||||
private Set<MlFilter> filters;
|
private final Set<MlFilter> filters = new HashSet<>();
|
||||||
private List<ScheduledEvent> scheduledEvents;
|
private List<ScheduledEvent> scheduledEvents;
|
||||||
|
|
||||||
public Builder(String jobId) {
|
public Builder(String jobId) {
|
||||||
dataCounts = new DataCounts(jobId);
|
dataCounts = new DataCounts(jobId);
|
||||||
modelSizeStats = new ModelSizeStats.Builder(jobId).build();
|
modelSizeStats = new ModelSizeStats.Builder(jobId).build();
|
||||||
timingStats = new TimingStats(jobId);
|
timingStats = new TimingStats(jobId);
|
||||||
filters = new HashSet<>();
|
|
||||||
scheduledEvents = new ArrayList<>();
|
scheduledEvents = new ArrayList<>();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -160,11 +159,6 @@ public class AutodetectParams {
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
public Builder setFilters(Set<MlFilter> filters) {
|
|
||||||
filters = Objects.requireNonNull(filters);
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
public AutodetectParams build() {
|
public AutodetectParams build() {
|
||||||
return new AutodetectParams(dataCounts, modelSizeStats, timingStats, modelSnapshot, quantiles,
|
return new AutodetectParams(dataCounts, modelSizeStats, timingStats, modelSnapshot, quantiles,
|
||||||
filters, scheduledEvents);
|
filters, scheduledEvents);
|
||||||
|
|
|
@ -38,7 +38,6 @@ import org.elasticsearch.xpack.core.ml.job.config.Job;
|
||||||
import org.elasticsearch.xpack.core.ml.job.config.JobState;
|
import org.elasticsearch.xpack.core.ml.job.config.JobState;
|
||||||
import org.elasticsearch.xpack.core.ml.job.config.JobTaskState;
|
import org.elasticsearch.xpack.core.ml.job.config.JobTaskState;
|
||||||
import org.elasticsearch.xpack.core.ml.job.config.JobUpdate;
|
import org.elasticsearch.xpack.core.ml.job.config.JobUpdate;
|
||||||
import org.elasticsearch.xpack.core.ml.job.config.MlFilter;
|
|
||||||
import org.elasticsearch.xpack.core.ml.job.config.ModelPlotConfig;
|
import org.elasticsearch.xpack.core.ml.job.config.ModelPlotConfig;
|
||||||
import org.elasticsearch.xpack.core.ml.job.persistence.AnomalyDetectorsIndex;
|
import org.elasticsearch.xpack.core.ml.job.persistence.AnomalyDetectorsIndex;
|
||||||
import org.elasticsearch.xpack.core.ml.job.persistence.AnomalyDetectorsIndexFields;
|
import org.elasticsearch.xpack.core.ml.job.persistence.AnomalyDetectorsIndexFields;
|
||||||
|
@ -75,7 +74,6 @@ import java.util.Date;
|
||||||
import java.util.HashSet;
|
import java.util.HashSet;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Optional;
|
import java.util.Optional;
|
||||||
import java.util.Set;
|
|
||||||
import java.util.concurrent.Callable;
|
import java.util.concurrent.Callable;
|
||||||
import java.util.concurrent.CountDownLatch;
|
import java.util.concurrent.CountDownLatch;
|
||||||
import java.util.concurrent.ExecutorService;
|
import java.util.concurrent.ExecutorService;
|
||||||
|
@ -137,7 +135,6 @@ public class AutodetectProcessManagerTests extends ESTestCase {
|
||||||
private ModelSizeStats modelSizeStats = new ModelSizeStats.Builder("foo").build();
|
private ModelSizeStats modelSizeStats = new ModelSizeStats.Builder("foo").build();
|
||||||
private ModelSnapshot modelSnapshot = new ModelSnapshot.Builder("foo").build();
|
private ModelSnapshot modelSnapshot = new ModelSnapshot.Builder("foo").build();
|
||||||
private Quantiles quantiles = new Quantiles("foo", new Date(), "state");
|
private Quantiles quantiles = new Quantiles("foo", new Date(), "state");
|
||||||
private Set<MlFilter> filters = new HashSet<>();
|
|
||||||
|
|
||||||
@Before
|
@Before
|
||||||
public void setup() throws Exception {
|
public void setup() throws Exception {
|
||||||
|
@ -707,7 +704,6 @@ public class AutodetectProcessManagerTests extends ESTestCase {
|
||||||
.setModelSizeStats(modelSizeStats)
|
.setModelSizeStats(modelSizeStats)
|
||||||
.setModelSnapshot(modelSnapshot)
|
.setModelSnapshot(modelSnapshot)
|
||||||
.setQuantiles(quantiles)
|
.setQuantiles(quantiles)
|
||||||
.setFilters(filters)
|
|
||||||
.build();
|
.build();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue