@@ -236,6 +236,18 @@ public int MaxReceiveMessageSize
236236
237237 private int _maxReceiveMessageSize ;
238238
239+ public bool DisableServerBalancer
240+ {
241+ get => _disableServerBalancer ;
242+ set
243+ {
244+ _disableServerBalancer = value ;
245+ SaveValue ( nameof ( DisableServerBalancer ) , value ) ;
246+ }
247+ }
248+
249+ private bool _disableServerBalancer ;
250+
239251 public bool DisableDiscovery
240252 {
241253 get => _disableDiscovery ;
@@ -334,7 +346,8 @@ internal async Task<IDriver> BuildDriver()
334346 Password = Password ,
335347 EnableMultipleHttp2Connections = EnableMultipleHttp2Connections ,
336348 MaxSendMessageSize = MaxSendMessageSize ,
337- MaxReceiveMessageSize = MaxReceiveMessageSize
349+ MaxReceiveMessageSize = MaxReceiveMessageSize ,
350+ DisableServerBalancer = DisableServerBalancer
338351 } ;
339352 var loggerFactory = LoggerFactory ?? NullLoggerFactory . Instance ;
340353
@@ -433,6 +446,9 @@ static YdbConnectionOption()
433446 AddOption ( new YdbConnectionOption < int > ( IntExtractor ,
434447 ( builder , createSessionTimeout ) => builder . CreateSessionTimeout = createSessionTimeout ) ,
435448 "CreateSessionTimeout" , "Create Session Timeout" ) ;
449+ AddOption ( new YdbConnectionOption < bool > ( BoolExtractor , ( builder , disableServerBalancer ) =>
450+ builder . DisableServerBalancer = disableServerBalancer ) ,
451+ "DisableServerBalancer" , "Disable Server Balancer" ) ;
436452 }
437453
438454 private static void AddOption ( YdbConnectionOption option , params string [ ] keys )
0 commit comments