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

Re: [Nbd] [PATCH v3 1/2] doc: Use dedicated reply types for NBD_OPT_INFO/GO



On Thu, Apr 14, 2016 at 04:31:00PM +0100, Alex Bligh wrote:
> On 14 Apr 2016, at 14:59, Eric Blake <eblake@...696...> wrote:
> > Okay. And thinking about it more, a server may indeed want to advertise
> > all names by which an export is known, so NBD_INFO_NAME could even be
> > given more than once (but then the wording needs to no longer call out
> > that it is a 'canonical' name).
> 
> Mmmm ... maybe. I'm not actually quite sure what the purpose of
> sending the canonical name is, but if there is a purpose may be
> we should set a 'canonical' flag on that one.

The reason I originally said "canonical" was that the protocol defines a
"default" name, which I was planning to implement in nbd-server by way
of a boolean flag (or maybe a global option). If you then ask for
NBD_OPT_INFO on the default name (i.e., the empty string), the server
would reply with the name of that export as it is specified in the
config file, rather than the empty name.

What a server defines as "canonical" is up to the server, obviously, and
it need not even be consistent across implementations. The point is that
the reply may just have a different name from the original request.

-- 
< ron> I mean, the main *practical* problem with C++, is there's like a dozen
       people in the world who think they really understand all of its rules,
       and pretty much all of them are just lying to themselves too.
 -- #debian-devel, OFTC, 2016-02-12



Reply to: