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
@@ -119,6 +121,7 @@ func (o *GrpcProxyAgentOptions) Flags() *pflag.FlagSet {
119
121
flags.StringVar(&o.AgentIdentifiers, "agent-identifiers", o.AgentIdentifiers, "Identifiers of the agent that will be used by the server when choosing agent. N.B. the list of identifiers must be in URL encoded format. e.g.,host=localhost&host=node1.mydomain.com&cidr=127.0.0.1/16&ipv4=1.2.3.4&ipv4=5.6.7.8&ipv6=:::::&default-route=true")
120
122
flags.BoolVar(&o.WarnOnChannelLimit, "warn-on-channel-limit", o.WarnOnChannelLimit, "Turns on a warning if the system is going to push to a full channel. The check involves an unsafe read.")
121
123
flags.BoolVar(&o.SyncForever, "sync-forever", o.SyncForever, "If true, the agent continues syncing, in order to support server count changes.")
124
+
flags.IntVar(&o.XrfChannelSize, "channel-size", 150, "Set the size of the channel")
122
125
returnflags
123
126
}
124
127
@@ -144,6 +147,7 @@ func (o *GrpcProxyAgentOptions) Print() {
144
147
klog.V(1).Infof("AgentIdentifiers set to %s.\n", util.PrettyPrintURL(o.AgentIdentifiers))
145
148
klog.V(1).Infof("WarnOnChannelLimit set to %t.\n", o.WarnOnChannelLimit)
146
149
klog.V(1).Infof("SyncForever set to %v.\n", o.SyncForever)
150
+
klog.V(1).Infof("ChannelSize set to %d.\n", o.XrfChannelSize)
147
151
}
148
152
149
153
func (o*GrpcProxyAgentOptions) Validate() error {
@@ -177,6 +181,9 @@ func (o *GrpcProxyAgentOptions) Validate() error {
177
181
ifo.AdminServerPort<=0 {
178
182
returnfmt.Errorf("admin server port %d must be greater than 0", o.AdminServerPort)
179
183
}
184
+
ifo.XrfChannelSize<=0 {
185
+
returnfmt.Errorf("channel size %d must be greater than 0", o.XrfChannelSize)
flags.StringVar(&o.ProxyStrategies, "proxy-strategies", o.ProxyStrategies, "The list of proxy strategies used by the server to pick an agent/tunnel, available strategies are: default, destHost, defaultRoute.")
138
139
flags.StringSliceVar(&o.CipherSuites, "cipher-suites", o.CipherSuites, "The comma separated list of allowed cipher suites. Has no effect on TLS1.3. Empty means allow default list.")
140
+
flags.IntVar(&o.XrfChannelSize, "xfr-channel-size", o.XrfChannelSize, "The size of the channel for transferring data between the proxy server and the agent.")
139
141
140
142
flags.Bool("warn-on-channel-limit", true, "This behavior is now thread safe and always on. This flag will be removed in a future release.")
141
143
flags.MarkDeprecated("warn-on-channel-limit", "This behavior is now thread safe and always on. This flag will be removed in a future release.")
@@ -175,6 +177,7 @@ func (o *ProxyRunOptions) Print() {
175
177
klog.V(1).Infof("KubeconfigBurst set to %d.\n", o.KubeconfigBurst)
176
178
klog.V(1).Infof("ProxyStrategies set to %q.\n", o.ProxyStrategies)
177
179
klog.V(1).Infof("CipherSuites set to %q.\n", o.CipherSuites)
180
+
klog.V(1).Infof("XrfChannelSize set to %d.\n", o.XrfChannelSize)
178
181
}
179
182
180
183
func (o*ProxyRunOptions) Validate() error {
@@ -297,7 +300,9 @@ func (o *ProxyRunOptions) Validate() error {
0 commit comments