# Copyright 2017 Yahoo Holdings. Licensed under the terms of the Apache 2.0 license. See LICENSE in the project root.
namespace=cloud.config

# Ports
rpcport int default=19070
httpport int default=19071
# 0 means use the number of CPU cores available
numRpcThreads int default=0

# ZooKeeper
zookeeperserver[].hostname string
zookeeperserver[].port int default=2181
# ZK write timeout in seconds, must be long enough to write application packages to other nodes
zookeeper.barrierTimeout long default=360
zookeeperLocalhostAffinity bool default=true

# Directories
configModelPluginDir[] string
configServerDBDir string default="var/db/vespa/config_server/serverdb/"
configDefinitionsDir string default="share/vespa/configdefinitions/"
fileReferencesDir string default="var/db/vespa/filedistribution/"

# Misc
sessionLifetime long default=3600 # in seconds
masterGeneration long default=0
multitenant bool default=false
numDelayedResponseThreads int default=1
serverId string default="localhost"
hostedVespa bool default=false
numParallelTenantLoaders int default=4

# Configserver app
applicationDirectory string default="conf/configserver-app"

# Zone information
environment string default="prod"
region string default="default"
system string default="main"
defaultFlavor string default="default"
defaultAdminFlavor string default="default"
defaultContainerFlavor string default="default"
defaultContentFlavor string default="default"

# RPC protocol
maxgetconfigclients int default=1000000
maxoutputbuffersize int default=65536
useVespaVersionInRequest bool default=false
payloadCompressionType enum { UNCOMPRESSED, LZ4 } default=LZ4

# Athenz config
loadBalancerAddress string default=""
athenzDnsSuffix string default=""
ztsUrl string default=""

# Node admin
nodeAdminInContainer bool default=false

# Maintainers
maintainerIntervalMinutes int default=60
# TODO: Default set to a high value (1 year) => maintainer will not run, change when maintainer verified out in prod
tenantsMaintainerIntervalMinutes int default=525600

# Bootstrapping
# How long bootstrapping can take before giving up (in seconds)
maxDurationOfBootstrap long default=7200
# How long to sleep before redeploying again if it fails (in seconds)
sleepTimeWhenRedeployingFails long default=30

# Feature Flags (poor man's feature flags, to be overridden in configserver-config.xml if needed)
deleteApplicationLegacy bool default=false
buildMinimalSetOfConfigModels bool default=true
useDedicatedNodeForLogserver bool default=true
throwIfBootstrappingTenantRepoFails bool default=true
bootstrapInSeparateThread bool default=true
