ZooKeeper proxy (proto)

This extension has the qualified name envoy.filters.network.zookeeper_proxy

Note

This extension is functional but has not had substantial production burn time, use only with this caveat.

This extension is not hardened and should only be used in deployments where both the downstream and upstream are trusted.

Tip

This extension extends and can be used with the following extension category:

This extension must be configured with one of the following type URLs:

ZooKeeper Proxy configuration overview.

extensions.filters.network.zookeeper_proxy.v3.ZooKeeperProxy

[extensions.filters.network.zookeeper_proxy.v3.ZooKeeperProxy proto]

{
  "stat_prefix": ...,
  "max_packet_bytes": {...},
  "enable_latency_threshold_metrics": ...,
  "default_latency_threshold": {...},
  "latency_threshold_overrides": [],
  "enable_per_opcode_request_bytes_metrics": ...,
  "enable_per_opcode_response_bytes_metrics": ...
}
stat_prefix

(string, REQUIRED) The human readable prefix to use when emitting statistics.

max_packet_bytes

(UInt32Value) Messages — requests, responses and events — that are bigger than this value will be ignored. If it is not set, the default value is 1Mb.

The value here should match the jute.maxbuffer property in your cluster configuration:

https://zookeeper.apache.org/doc/r3.4.10/zookeeperAdmin.html#Unsafe+Options

if that is set. If it isn’t, ZooKeeper’s default is also 1Mb.

enable_latency_threshold_metrics

(bool) Whether to emit latency threshold metrics. If not set, it defaults to false. If false, setting default_latency_threshold and latency_threshold_overrides will not have effect.

default_latency_threshold

(Duration) The default latency threshold to decide the fast/slow responses and emit metrics (used for error budget calculation).

https://sre.google/workbook/implementing-slos/

If it is not set, the default value is 100 milliseconds.

latency_threshold_overrides

(repeated extensions.filters.network.zookeeper_proxy.v3.LatencyThresholdOverride) List of latency threshold overrides for opcodes. If the threshold override of one opcode is not set, it will fallback to the default latency threshold. Specifying latency threshold overrides multiple times for one opcode is not allowed.

enable_per_opcode_request_bytes_metrics

(bool) Whether to emit per opcode request bytes metrics. If not set, it defaults to false.

enable_per_opcode_response_bytes_metrics

(bool) Whether to emit per opcode response bytes metrics. If not set, it defaults to false.

extensions.filters.network.zookeeper_proxy.v3.LatencyThresholdOverride

[extensions.filters.network.zookeeper_proxy.v3.LatencyThresholdOverride proto]

{
  "opcode": ...,
  "threshold": {...}
}
opcode

(extensions.filters.network.zookeeper_proxy.v3.LatencyThresholdOverride.Opcode) The ZooKeeper opcodes. Can be found as part of the ZooKeeper source code:

https://github.com/apache/zookeeper/blob/master/zookeeper-server/src/main/java/org/apache/zookeeper/ZooDefs.java

threshold

(Duration, REQUIRED) The latency threshold override of certain opcode.

Enum extensions.filters.network.zookeeper_proxy.v3.LatencyThresholdOverride.Opcode

[extensions.filters.network.zookeeper_proxy.v3.LatencyThresholdOverride.Opcode proto]

Connect

(DEFAULT)

Create

Delete

Exists

GetData

SetData

GetAcl

SetAcl

GetChildren

Sync

Ping

GetChildren2

Check

Multi

Create2

Reconfig

CheckWatches

RemoveWatches

CreateContainer

CreateTtl

Close

SetAuth

SetWatches

GetEphemerals

GetAllChildrenNumber

SetWatches2

AddWatch