Depending on command line options and server capabilities, nbdinfo has
legitimate reasons to either be in opt mode or fully connected at the
time a handle is ready to close. Previously, to avoid unwanted error
messages, we had to manually check state to call the correct function
out of
When nbd_set_opt_mode() was introduced, we did not adjust the behavior
of nbd_shutdown(), so as a result it fails if attempted after the
initial connection but before nbd_opt_abort() or nbd_opt_go(). To
avoid spurious error messages, at least nbdinfo has to perform
special-casing on whether it is
When we added nbd_set_opt_mode (v1.4), we did not do anything special
to nbd_shutdown(). As a result, clients that use opt mode when
available, but which want to gracefully close a socket rather than
just forcefully disconnect via nbd_close(), have to take care to check
the current state and then
While working on a larger set of patches to make nbdinfo favor
NBD_OPT_INFO over NBD_OPT_GO where possible (which requires use of
nbd_set_opt_mode(,true) in more cases), I noticed that it got unwieldy
to have to pick the correct shutdown function in all code paths. So I
propose making the API
On Sat, Aug 26, 2023 at 11:29:58AM +, Tage Johansson wrote:
> Add a couple of integration tests as rust/tests/test_async_*.rs. They
> are very similar to the tests for the synchronous API.
> ---
> rust/tests/test_async_460_block_status.rs | 98
>
On Wed, Jul 19, 2023 at 09:09:51AM +, Tage Johansson wrote:
> A couple of integration tests are added in rust/tests. They are mostly
> ported from the OCaml tests.
> ---
> rust/tests/test_210_opt_abort.rs | 39 +
> rust/tests/test_220_opt_list.rs | 85
On Tue, Aug 29, 2023 at 09:09:02AM +0100, Richard W.M. Jones wrote:
>
> Thanks, I pushed this series now.
>
> There are some CI failures, see:
> https://gitlab.com/nbdkit/libnbd/-/pipelines/984910205
>
> Can you suggest some fixes for these, or otherwise we can go through
> them on the call
Pipeline #984910205 has failed!
Project: libnbd ( https://gitlab.com/nbdkit/libnbd )
Branch: master ( https://gitlab.com/nbdkit/libnbd/-/commits/master )
Commit: 9afb980d (
https://gitlab.com/nbdkit/libnbd/-/commit/9afb980d05d6144129c899285e44779757a380e8
)
Commit Message: rust: Check that
Thanks, I pushed this series now.
There are some CI failures, see:
https://gitlab.com/nbdkit/libnbd/-/pipelines/984910205
Can you suggest some fixes for these, or otherwise we can go through
them on the call today.
Rich.
--
Richard Jones, Virtualization Group, Red Hat