generated from wayfair-incubator/oss-template
-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Expose MaxConnsPerNode from AeroSpike to allow easier performance tun…
…ing (#187) Expose MaxConnsPerNode from AeroSpike to allow easier performance tuning.
- Loading branch information
Showing
7 changed files
with
42 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
using System; | ||
using AeroSharp.Enums; | ||
using System; | ||
using System.Diagnostics.CodeAnalysis; | ||
using AeroSharp.Enums; | ||
|
||
namespace AeroSharp.Connection | ||
{ | ||
|
@@ -18,6 +18,12 @@ public ConnectionConfiguration() | |
ConnectionTimeout = TimeSpan.FromSeconds(10); | ||
AsyncMaxCommands = 500; | ||
MaxCommandAction = MaxCommandAction.DELAY; // Recommended by Aerospike Enterprise Support (behavior when asyncMaxCommands is exceeded) | ||
|
||
Check warning on line 21 in src/AeroSharp/Connection/ConnectionConfiguration.cs GitHub Actions / publish
Check warning on line 21 in src/AeroSharp/Connection/ConnectionConfiguration.cs GitHub Actions / unit
Check warning on line 21 in src/AeroSharp/Connection/ConnectionConfiguration.cs GitHub Actions / unit
Check warning on line 21 in src/AeroSharp/Connection/ConnectionConfiguration.cs GitHub Actions / integration
Check warning on line 21 in src/AeroSharp/Connection/ConnectionConfiguration.cs GitHub Actions / integration
|
||
// Leave it as default value from Aerospike Client. | ||
// Note: Aerospike client has updated their default settings, see the change reasons from Aerospike forum: https://discuss.aerospike.com/t/client-1772-client-configurations-changes-reasons/9699 | ||
// We will update AsyncMaxCommands to 100 when we bump up Aerospike version so we align with Aerospike settings. | ||
// Relationship between asyncMaxConnsPerNode and MaxConnsPerNode can be found from here: https://aerospike.com/apidocs/csharp/html/f_aerospike_client_asyncclientpolicy_asyncmaxconnspernode | ||
MaxConnsPerNode = 100; | ||
} | ||
|
||
/// <summary> | ||
|
@@ -34,5 +40,10 @@ public ConnectionConfiguration() | |
/// Defines how to handle cases when the maximum number of concurrent database commands has been exceeded for the async client. | ||
/// </summary> | ||
public MaxCommandAction MaxCommandAction { get; set; } | ||
|
||
/// <summary> | ||
/// The maximum sync connections per node. | ||
/// </summary> | ||
public int MaxConnsPerNode { get; set; } | ||
} | ||
} | ||
} |