cloudbase / wnbd

Windows Ceph RBD NBD driver
GNU Lesser General Public License v2.1
58 stars 26 forks source link

Async requests #6

Closed petrutlucian94 closed 4 years ago

petrutlucian94 commented 4 years ago

At the moment, we're sending one NBD request at a time and wait for it to complete. While simple, this is very inefficient.

This change will send the requests as they arrive, using a separate thread to read the replies from the NBD channel. We'll limit the maximum number of in-flight requests, using a hard-coded value of 255 for the time being.

Signed-off-by: Lucian Petrut lpetrut@cloudbasesolutions.com Signed-off-by: Alin Gabriel Serdean aserdean@cloudbasesolutions.com

aserdean commented 4 years ago

I got some warnings from code analysis can you please fold in the following: https://gist.githubusercontent.com/aserdean/3be22f13cb2340df165cba2029e95f2d/raw/46b3b8bec711c03542f66687750168e3d6367888/gistfile1.txt

aserdean commented 4 years ago

Looks good. I'm running a last batch of testing.

aserdean commented 4 years ago

Testing looks good.