Ce contenu n'est pas disponible dans la langue sélectionnée.
Chapter 44. ZookeeperClusterSpec schema reference
Used in: KafkaSpec
Full list of ZookeeperClusterSpec
schema properties
Configures a ZooKeeper cluster.
44.1. config Copier lienLien copié sur presse-papiers!
Use the config
properties to configure ZooKeeper options as keys.
The values can be one of the following JSON types:
- String
- Number
- Boolean
Exceptions
You can specify and configure the options listed in the ZooKeeper documentation.
However, AMQ Streams takes care of configuring and managing options related to the following, which cannot be changed:
- Security (encryption, authentication, and authorization)
- Listener configuration
- Configuration of data directories
- ZooKeeper cluster composition
Properties with the following prefixes cannot be set:
-
4lw.commands.whitelist
-
authProvider
-
clientPort
-
dataDir
-
dataLogDir
-
quorum.auth
-
reconfigEnabled
-
requireClientAuthScheme
-
secureClientPort
-
server.
-
snapshot.trust.empty
-
standaloneEnabled
-
serverCnxnFactory
-
ssl.
-
sslQuorum
If the config
property contains an option that cannot be changed, it is disregarded, and a warning message is logged to the Cluster Operator log file. All other supported options are forwarded to ZooKeeper, including the following exceptions to the options configured by AMQ Streams:
-
Any
ssl
configuration for supported TLS versions and cipher suites
Example ZooKeeper configuration
44.2. logging Copier lienLien copié sur presse-papiers!
ZooKeeper has a configurable logger:
-
zookeeper.root.logger
ZooKeeper uses the Apache log4j
logger implementation.
Use the logging
property to configure loggers and logger levels.
You can set the log levels by specifying the logger and level directly (inline) or use a custom (external) ConfigMap. If a ConfigMap is used, you set logging.valueFrom.configMapKeyRef.name
property to the name of the ConfigMap containing the external logging configuration. Inside the ConfigMap, the logging configuration is described using log4j.properties
. Both logging.valueFrom.configMapKeyRef.name
and logging.valueFrom.configMapKeyRef.key
properties are mandatory. A ConfigMap using the exact logging configuration specified is created with the custom resource when the Cluster Operator is running, then recreated after each reconciliation. If you do not specify a custom ConfigMap, default logging settings are used. If a specific logger value is not set, upper-level logger settings are inherited for that logger. For more information about log levels, see Apache logging services.
Here we see examples of inline
and external
logging. The inline
logging specifies the root logger level. You can also set log levels for specific classes or loggers by adding them to the loggers property.
Inline logging
Setting a log level to DEBUG
may result in a large amount of log output and may have performance implications.
External logging
Garbage collector (GC)
Garbage collector logging can also be enabled (or disabled) using the jvmOptions
property.
44.3. ZookeeperClusterSpec schema properties Copier lienLien copié sur presse-papiers!
Property | Description |
---|---|
replicas | The number of pods in the cluster. |
integer | |
image | The docker image for the pods. |
string | |
storage |
Storage configuration (disk). Cannot be updated. The type depends on the value of the |
config | The ZooKeeper broker config. Properties with the following prefixes cannot be set: server., dataDir, dataLogDir, clientPort, authProvider, quorum.auth, requireClientAuthScheme, snapshot.trust.empty, standaloneEnabled, reconfigEnabled, 4lw.commands.whitelist, secureClientPort, ssl., serverCnxnFactory, sslQuorum (with the exception of: ssl.protocol, ssl.quorum.protocol, ssl.enabledProtocols, ssl.quorum.enabledProtocols, ssl.ciphersuites, ssl.quorum.ciphersuites, ssl.hostnameVerification, ssl.quorum.hostnameVerification). |
map | |
livenessProbe | Pod liveness checking. |
readinessProbe | Pod readiness checking. |
jvmOptions | JVM Options for pods. |
jmxOptions | JMX Options for Zookeeper nodes. |
resources | CPU and memory resources to reserve. For more information, see the external documentation for core/v1 resourcerequirements. |
metricsConfig |
Metrics configuration. The type depends on the value of the |
logging |
Logging configuration for ZooKeeper. The type depends on the value of the |
template | Template for ZooKeeper cluster resources. The template allows users to specify how the OpenShift resources are generated. |