ICslQueryProvider.ExecuteQuery 线程安全吗?

Is ICslQueryProvider.ExecuteQuery thread safe?

我想让多个线程在同一个 kusto ICslQueryProvider 上查询 kusto。这个线程安全吗?

我目前锁定资源,但希望异步处理

var client = Kusto.Data.Net.Client.KustoClientFactory.CreateCslQueryProvider("https://help.kusto.windows.net/Samples;Fed=true");
var reader = client.ExecuteQuery("MyTable | count");

The docs 状态:

More concretely, to create an ADO.NET-like client allowing queries against Kusto, one uses static methods on the Kusto.Data.Net.Client.KustoClientFactory class. These take the connection string and create a thread-safe, disposable, client object. (It is strongly recommended that client code refrains from creating "too many" instances of this object, and instead create an object per connection string and hold on to it for as long as it is needed.) This allows the client object to efficiently cache resources.

In general, all methods on the clients are thread-safe with two exceptions: Dispose, and setter properties. For consistent results, one should not invoke either methods concurrently.

所以,是的,你的 client 是 thread-safe。