I’m using the
Ping api in my healthcheck process and it seems that it always returns
ok for every node even if the node has become unavailable. This happens only when
SslConnection is used then the unavailable node returned with
Error state in the ping report.
Could someone please help to determine if it’s a misconfiguration on my side or probably this is a known issue?
MultiplexingConnection never throws (
HandleDisconnect just logs the exception), but
Ping sets state of the endpoint in response to the exception occurred.
Does someone have any thoughts? Seems to me like we can’t rely on the
Ping in the 2.7 .net SDK
It should work; which specific version are you using? If not the latest (2.7.26), can you try the latest? Can you provide a simple example and we will try to recreate?
Hello @jmorris , thank you for your reply.
I’m using the latest version (2.7.26). Here is an example what I’m doing and what steps I do to reproduce it:
(1) IBucket bucket = _factory.GetBucket(_bucketType);
IPingReport report = bucket.Ping(ServiceType.KeyValue);
foreach (var serviceName in report.Services.Keys)
(2) var servicePingResults = report.Services[serviceName].ToList();
(3) foreach (IEndpointDiagnostics servicePingResult in servicePingResults)
if (servicePingResult.State != ServiceState.Ok)
// Never gets here
Note: list items below are related to (1), (2) and (3) labels in the code
- Allow the SDK to bootstrap (under the hood the factory just calls
- Then before really pinging the cb nodes I simulate response timeout by blocking connections to the nodes
- After some time the execution continues in point (3) and