OperationTimeout setting seems to be ignored by the .NET SDK 2.0.2


#1

Hello,

I am using .NET SDK 2.0.2 and I noticed that the PoolConfiguration.OperationTimeout setting is ignored by the client and the default value is always used.

I did the following test:

var config = new ClientConfiguration
{
    Servers = new List<Uri>
    {
        new Uri("http://127.0.0.1:8091/pools"),
    },
    BucketConfigs = new Dictionary<string, BucketConfiguration>
    {
        { 
            "samples",
            new BucketConfiguration
            {
                BucketName = "samples",
            }
        }
    },
    PoolConfiguration = new PoolConfiguration
    {
        MinSize = 10,
        MaxSize = 10,
        OperationTimeout = (int)TimeSpan.FromSeconds(15).TotalMilliseconds,
    },
};

var cluster = new Cluster(config);
var bucket = cluster.OpenBucket(c.Configuration.BucketConfigs.Single().Value.BucketName);
var result = bucket.Get<string>("some_key");

After debugging into the source code, I noticed that the Couchbase.IO.Operations.Get<string> operation that gets instantiated during the operation has the default Timeout property of 2500 instead of 15000 as I would expect in this case.


#2

@dimitrod -

This is a known issue and will be resolved in 2.0.3/2.1.0. There are two tickets associated with it:

  1. ConnectionTimeout should be SendTimeout in Configuration: NCBC-802
  2. Make operation lifespan configurable: NCBC-811

The first one changes the naming to align with the behavior of the property; the latter fixes the issue you mentioned here. Note that “send timeout” and “operation timeout” are two completely different concepts!

Thanks!

-Jeff