[Spice-devel] [PATCH spice-common] RFC: spice.proto: add webdav channel
Jonathon Jongsma
jjongsma at redhat.com
Wed Feb 26 14:00:13 PST 2014
There's also the option of using a 'temporary' name (e.g.
DraftWebDAVChannel or something) until we're convinced that it's the
right approach and then rename it to a more official name and advertise
it as stable...
Just an idea.
Jonathon
On Wed, 2014-02-26 at 17:47 +0100, Marc-André Lureau wrote:
> Hey,
>
> ping! still looking for review/ack,
>
> I would like this webdav channel to be part of the specified protocol.
> I could do without, and just name a port channel with my own data, but
> I prefer to have a proper registered channel, so it is documented
> officially as part of Spice.
>
> Although some channels are optionnal, some are mandatory, some must be
> unique, there is something that we haven't exploited so far. We could
> deprecate channels and replace them with newer versions or different
> channels (while keeping same protocol version). Example, if we come to
> the conclusion that multiplexing requests in one channel isn't a good
> idea, we could deprecate WebDAVChannel and make WebDAVChannel2 appears
> (instead or both available for compatibility). In the same vein,
> WebDAV could be replaced by SFTP or anything else. Even more, they
> could coexist, so a client could be free to choose (this is very much
> hypothetical, I don't think that should ever happen).
>
> This is all to say that adding a channel, such as webdav, shouldn't
> limit our future development, if somehow it doesn't work as expected
> or other reasons.
>
> cheers
>
>
> On Sun, Jan 12, 2014 at 6:29 PM, Marc-André Lureau
> <marcandre.lureau at gmail.com> wrote:
> > This channel provides a webdav server (rfc4918). This allows various
> > guest or remote system that support webdav to access a folder shared by
> > the client (some agent can be used to proxy the requests on a local port
> > for example). The webdav server may also be accessed by an hypervisor as
> > a remote filesystem interface, which can then be accessed by the guest
> > via other means (fs/fat emulation, mtp device, etc)
> >
> > Due to the usage of a single channel stream and the need for concurrent
> > requests, webdav clients streams are multiplexed. Each client stream is
> > framed within 64k max messages (in little-endian)
> >
> > int64 client_id
> > uint16 size
> > char data[size]
> >
> > A new client_id indicates a new connection. A new communication stream
> > with the webdav server should be started. A client stream message of
> > size 0 indicates a disconnection of client_id. This multiplexed
> > communication happens over the channel "data" message.
> >
> > Only when the port is opened may the communication be started.
> > A closed port event should close all currently known multiplexed
> > connections.
> >
> > Why WebDAV?
> >
> > webdav is supported natively by various OS for a long time (circa
> > Windows XP). It has several open-source implementations and a variety of
> > tools exist. A webdav implementation can be tested and used without a
> > Spice server or any virtualization (this also permit sharing the
> > implementation with other projects in the future, such as GNOME). It is
> > an IETF open standard and thus thoroughly specified.
> >
> > The basic requirements for an efficient remote filesystem are provided
> > by the standard (pipelining, concurrency, caching, copy/move, partial
> > io, compression, locking ...) While other features are easily possible
> > via extensions to the protocol (common ones are executable attributes,
> > or searching for example).
> >
> > Given the requirements, and the popularity of http/webdav, I believe it
> > is the best candidate for Spice remote filesystem support.
> >
> > Other alternatives (adhoc, p9, smb2, sftp) have been studied and
> > discarded so far since they do not match in term of features or
> > requirements.
> > ---
> > spice.proto | 4 ++++
> > 1 file changed, 4 insertions(+)
> >
> > diff --git a/spice.proto b/spice.proto
> > index 67b3803..316d287 100644
> > --- a/spice.proto
> > +++ b/spice.proto
> > @@ -1352,6 +1352,9 @@ channel PortChannel : SpicevmcChannel {
> > } event;
> > };
> >
> > +channel WebDAVChannel : PortChannel {
> > +};
> > +
> > protocol Spice {
> > MainChannel main = 1;
> > DisplayChannel display;
> > @@ -1363,4 +1366,5 @@ protocol Spice {
> > SmartcardChannel smartcard;
> > UsbredirChannel usbredir;
> > PortChannel port;
> > + WebDAVChannel webdav;
> > };
> > --
> > 1.8.4.2
> >
>
>
>
More information about the Spice-devel
mailing list