All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.camunda.operate.property.OperateElasticsearchProperties Maven / Gradle / Ivy

There is a newer version: 8.6.0-alpha5
Show newest version
/*
 * Copyright Camunda Services GmbH and/or licensed to Camunda Services GmbH under
 * one or more contributor license agreements. See the NOTICE file distributed
 * with this work for additional information regarding copyright ownership.
 * Licensed under the Camunda License 1.0. You may not use this file
 * except in compliance with the Camunda License 1.0.
 */
package io.camunda.operate.property;

import java.util.Map;

public class OperateElasticsearchProperties extends ElasticsearchProperties {

  public static final String DEFAULT_INDEX_PREFIX = "operate";
  private static final int DEFAULT_NUMBER_OF_SHARDS = 1;
  private static final int DEFAULT_NUMBER_OF_REPLICAS = 0;
  private static final String DEFAULT_REFRESH_INTERVAL = "1s";

  private String indexPrefix = DEFAULT_INDEX_PREFIX;
  private int numberOfShards = DEFAULT_NUMBER_OF_SHARDS;
  private Map numberOfShardsForIndices = Map.of();
  private int numberOfReplicas = DEFAULT_NUMBER_OF_REPLICAS;
  private Map numberOfReplicasForIndices = Map.of();
  private String refreshInterval = DEFAULT_REFRESH_INTERVAL;

  public String getIndexPrefix() {
    return indexPrefix;
  }

  public void setIndexPrefix(String indexPrefix) {
    this.indexPrefix = indexPrefix;
  }

  public void setDefaultIndexPrefix() {
    setIndexPrefix(DEFAULT_INDEX_PREFIX);
  }

  public int getNumberOfShards() {
    return numberOfShards;
  }

  public void setNumberOfShards(final int numberOfShards) {
    this.numberOfShards = numberOfShards;
  }

  public int getNumberOfReplicas() {
    return numberOfReplicas;
  }

  public void setNumberOfReplicas(final int numberOfReplicas) {
    this.numberOfReplicas = numberOfReplicas;
  }

  public String getRefreshInterval() {
    return refreshInterval;
  }

  public void setRefreshInterval(String refreshInterval) {
    this.refreshInterval = refreshInterval;
  }

  public Map getNumberOfShardsForIndices() {
    return numberOfShardsForIndices;
  }

  public void setNumberOfShardsForIndices(Map numberOfShardsForIndices) {
    this.numberOfShardsForIndices = numberOfShardsForIndices;
  }

  public Map getNumberOfReplicasForIndices() {
    return numberOfReplicasForIndices;
  }

  public void setNumberOfReplicasForIndices(Map numberOfReplicasForIndices) {
    this.numberOfReplicasForIndices = numberOfReplicasForIndices;
  }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy