[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: [PATCH v3] doc: Define a standard URI syntax for NBD URIs.



On Tue, Jun 11, 2019 at 07:40:38PM +0200, Wouter Verhelst wrote:
> [1] theoretically it should be possible to detect the oldstyle magic
>     number and fall back to oldstyle if supported, but that's a bit ugly
>     and I don't want to write that in stone for clients/libraries that
>     support it.

This is in fact what libnbd does :-)

https://github.com/libguestfs/libnbd/blob/4026742c751ed42b5f96c12a5ae7bdb4a6c82b1e/generator/states-magic.c#L45-L53

However I totally take your more general points that (a) newstyle
should be preferred in all circumstances and (b) we shouldn't require
clients to implement oldstyle.  Hopefully nothing in the URI document
should imply that.

But I don't think we need to add the protocol version to the URI
because it can be easily detected in clients that support that, and
other clients will just error out when they see a non-supported
version.

Rich.

-- 
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
Read my programming and virtualization blog: http://rwmj.wordpress.com
virt-builder quickly builds VMs from scratch
http://libguestfs.org/virt-builder.1.html


Reply to: