@@ -168,7 +168,7 @@ public TimeSpan ConnectTimeout
168
168
{
169
169
if ( value < TimeSpan . Zero )
170
170
{
171
- throw new ArgumentOutOfRangeException ( "value" , "ConnectTimeout must be larger than or equal to zero." ) ;
171
+ throw new ArgumentOutOfRangeException ( "value" , "ConnectTimeout must be greater than or equal to zero." ) ;
172
172
}
173
173
_connectTimeout = value ;
174
174
base [ "connectTimeout" ] = MongoUrlBuilder . FormatTimeSpan ( value ) ;
@@ -271,7 +271,7 @@ public TimeSpan MaxConnectionIdleTime
271
271
{
272
272
if ( value < TimeSpan . Zero )
273
273
{
274
- throw new ArgumentOutOfRangeException ( "value" , "MaxConnectionIdleTime must be larger than or equal to zero." ) ;
274
+ throw new ArgumentOutOfRangeException ( "value" , "MaxConnectionIdleTime must be greater than or equal to zero." ) ;
275
275
}
276
276
_maxConnectionIdleTime = value ;
277
277
base [ "maxIdleTime" ] = MongoUrlBuilder . FormatTimeSpan ( value ) ;
@@ -288,7 +288,7 @@ public TimeSpan MaxConnectionLifeTime
288
288
{
289
289
if ( value < TimeSpan . Zero )
290
290
{
291
- throw new ArgumentOutOfRangeException ( "value" , "MaxConnectionLifeTime must be larger than or equal to zero." ) ;
291
+ throw new ArgumentOutOfRangeException ( "value" , "MaxConnectionLifeTime must be greater than or equal to zero." ) ;
292
292
}
293
293
_maxConnectionLifeTime = value ;
294
294
base [ "maxLifeTime" ] = MongoUrlBuilder . FormatTimeSpan ( value ) ;
@@ -305,7 +305,7 @@ public int MaxConnectionPoolSize
305
305
{
306
306
if ( value <= 0 )
307
307
{
308
- throw new ArgumentOutOfRangeException ( "value" , "MaxConnectionPoolSize must be larger than zero." ) ;
308
+ throw new ArgumentOutOfRangeException ( "value" , "MaxConnectionPoolSize must be greater than zero." ) ;
309
309
}
310
310
_maxConnectionPoolSize = value ;
311
311
base [ "maxPoolSize" ] = XmlConvert . ToString ( value ) ;
@@ -320,9 +320,9 @@ public int MinConnectionPoolSize
320
320
get { return _minConnectionPoolSize ; }
321
321
set
322
322
{
323
- if ( value <= 0 )
323
+ if ( value < 0 )
324
324
{
325
- throw new ArgumentOutOfRangeException ( "value" , "MinConnectionPoolSize must be larger than zero." ) ;
325
+ throw new ArgumentOutOfRangeException ( "value" , "MinConnectionPoolSize must be greater than or equal to zero." ) ;
326
326
}
327
327
_minConnectionPoolSize = value ;
328
328
base [ "minPoolSize" ] = XmlConvert . ToString ( value ) ;
@@ -476,7 +476,7 @@ public TimeSpan SecondaryAcceptableLatency
476
476
{
477
477
if ( value < TimeSpan . Zero )
478
478
{
479
- throw new ArgumentOutOfRangeException ( "value" , "SecondaryAcceptableLatency must be larger than zero." ) ;
479
+ throw new ArgumentOutOfRangeException ( "value" , "SecondaryAcceptableLatency must be greater than or equal to zero." ) ;
480
480
}
481
481
_secondaryAcceptableLatency = value ;
482
482
base [ "secondaryAcceptableLatency" ] = MongoUrlBuilder . FormatTimeSpan ( value ) ;
@@ -547,7 +547,7 @@ public TimeSpan SocketTimeout
547
547
{
548
548
if ( value < TimeSpan . Zero )
549
549
{
550
- throw new ArgumentOutOfRangeException ( "value" , "SocketTimeout must be larger than or equal to zero." ) ;
550
+ throw new ArgumentOutOfRangeException ( "value" , "SocketTimeout must be greater than or equal to zero." ) ;
551
551
}
552
552
_socketTimeout = value ;
553
553
base [ "socketTimeout" ] = MongoUrlBuilder . FormatTimeSpan ( value ) ;
@@ -616,7 +616,7 @@ public double WaitQueueMultiple
616
616
{
617
617
if ( value <= 0.0 )
618
618
{
619
- throw new ArgumentOutOfRangeException ( "value" , "WaitQueueMultiple must be larger than zero." ) ;
619
+ throw new ArgumentOutOfRangeException ( "value" , "WaitQueueMultiple must be greater than zero." ) ;
620
620
}
621
621
_waitQueueMultiple = value ;
622
622
_waitQueueSize = 0 ;
@@ -635,7 +635,7 @@ public int WaitQueueSize
635
635
{
636
636
if ( value <= 0 )
637
637
{
638
- throw new ArgumentOutOfRangeException ( "value" , "WaitQueueSize must be larger than 0 ." ) ;
638
+ throw new ArgumentOutOfRangeException ( "value" , "WaitQueueSize must be greater than zero ." ) ;
639
639
}
640
640
_waitQueueSize = value ;
641
641
_waitQueueMultiple = 0.0 ;
@@ -654,7 +654,7 @@ public TimeSpan WaitQueueTimeout
654
654
{
655
655
if ( value < TimeSpan . Zero )
656
656
{
657
- throw new ArgumentOutOfRangeException ( "value" , "WaitQueueTimeout must be larger than or equal to zero." ) ;
657
+ throw new ArgumentOutOfRangeException ( "value" , "WaitQueueTimeout must be greater than or equal to zero." ) ;
658
658
}
659
659
_waitQueueTimeout = value ;
660
660
base [ "waitQueueTimeout" ] = MongoUrlBuilder . FormatTimeSpan ( value ) ;
@@ -672,7 +672,7 @@ public TimeSpan? WTimeout
672
672
if ( value != null ) { EnsureFireAndForgetIsNotTrue ( "WTimeout" ) ; }
673
673
if ( value != null && value . Value < TimeSpan . Zero )
674
674
{
675
- throw new ArgumentOutOfRangeException ( "value" , "WTimeout must be larger than or equal to zero." ) ;
675
+ throw new ArgumentOutOfRangeException ( "value" , "WTimeout must be greater than or equal to zero." ) ;
676
676
}
677
677
_wTimeout = value ;
678
678
base [ "wtimeout" ] = ( value == null ) ? null : MongoUrlBuilder . FormatTimeSpan ( value . Value ) ;
0 commit comments