You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The destination controller has a hardcoded stream queue capacity of 100. This
commit introduces a new command-line argument `--stream-queue-capacity` that
allows users to customize this value according to their needs.
We believe that '1' is a better default value for most use cases, as it reduces
memory consumption and latency. However, we want to be incremental about this
change. Therefore, this configuration allows for us to test this new default
value in a controlled manner.
Copy file name to clipboardExpand all lines: controller/cmd/destination/main.go
+6Lines changed: 6 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -47,6 +47,7 @@ func Main(args []string) {
47
47
// This will default to true. It can be overridden with experimental CLI
48
48
// flags. Currently not exposed as a configuration value through Helm.
49
49
exportControllerQueueMetrics:=cmd.Bool("export-queue-metrics", true, "Exports queue metrics for the external workload controller")
50
+
streamQueueCapacity:=cmd.Int("stream-queue-capacity", destination.DefaultStreamQueueCapacity, "Maximum number of updates buffered per stream before the stream is closed")
50
51
51
52
traceCollector:=flags.AddTraceFlags(cmd)
52
53
@@ -66,6 +67,10 @@ func Main(args []string) {
66
67
67
68
flags.ConfigureAndParse(cmd, args)
68
69
70
+
if*streamQueueCapacity<=0 {
71
+
log.Fatalf("--stream-queue-capacity must be greater than 0")
72
+
}
73
+
69
74
if*enableIPv6&&!*enableEndpointSlices {
70
75
log.Fatal("If --enable-ipv6=true then --enable-endpoint-slices needs to be true")
0 commit comments