org.elasticsearch.xpack.core.monitoring.MonitoringField Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of x-pack-core Show documentation
Show all versions of x-pack-core Show documentation
Elasticsearch Expanded Pack Plugin - Core
/*
* Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
* or more contributor license agreements. Licensed under the Elastic License
* 2.0; you may not use this file except in compliance with the Elastic License
* 2.0.
*/
package org.elasticsearch.xpack.core.monitoring;
import org.elasticsearch.common.settings.Setting;
import org.elasticsearch.common.unit.TimeValue;
import static org.elasticsearch.common.settings.Setting.timeSetting;
public final class MonitoringField {
/**
* The minimum amount of time allowed for the history duration.
*/
public static final TimeValue HISTORY_DURATION_MINIMUM = TimeValue.timeValueHours(24);
/**
* The default retention duration of the monitoring history data.
*
* Expected values:
*
* - Default: 7 days
* - Minimum: 1 day
*
*
* @see MonitoringField#HISTORY_DURATION_MINIMUM
*/
public static final Setting HISTORY_DURATION = timeSetting("xpack.monitoring.history.duration",
TimeValue.timeValueHours(7 * 24), // default value (7 days)
HISTORY_DURATION_MINIMUM, // minimum value
Setting.Property.Dynamic, Setting.Property.NodeScope);
private MonitoringField() {}
}