[dev] WG: Re: Proposal for change to Horde's XML-RPC service

Jan Schneider jan at horde.org
Fri Jun 23 08:01:50 PDT 2006



----- Weitergeleitete Nachricht von ben at alkaloid.net -----
      Datum: Fri, 23 Jun 2006 10:39:22 -0400
        Von: Ben Klang <ben at alkaloid.net>
    Betreff: Re: [dev] Proposal for change to Horde's XML-RPC service
         An: Jan Schneider <jan at horde.org>

On Fri, 2006-06-23 at 09:42 +0200, Jan Schneider wrote:
> Zitat von Ben Klang <ben at alkaloid.net>:
>
> > 1) Create a reserved variable name that is recognized by the XML-RPC
> > driver as a file upload.  The variable would be a struct and have some
> > kind of reserved name like "_fileupload" or similar to avoid conflicts
> > with application variable names.  This has the disadvantage of being a
> > "one-off" in the sense that the XML-RPC driver today does not do any
> > processing on the contents of the POSTed data.  It instead immediately
> > hands it off to the called method for processing.
>
> I don't see how this is much different from handling the file data
> inside the API methods, beside that you do the base64 decoding in the
> RPC driver, not in the api.
The only difference would be that the work would be done once in the
XML-RPC driver rather than in each API method accepting file uploads.


> > 2) Modify the XML-RPC spec to recognize a special file upload tag.
> > Unless we can get the buy-in of the XML-RPC community I would prefer to
> > avoid this route as I'm not usually one to go breaking accepted
> > standards.  It does, however, have the benefit of being the "cleanest"
> > approach in my mind as it would be unambiguous to the receiving
> > application what should be done with the data (in Horde's/PHP's case
> > that means decoding the Base64 data and writing it to a temp file to be
> > passed to higher level methods as HTTP form processing does now).
>
> The XMLRPC spec is pretty set in stone, don't expect any changes in
> the future. And even if there were some, they would have to be
> implemented in the php extension.
Yeah that was my impression as well.  I don't think extending XML-RPC
itself is the way to go.

> I think you have two options. Either handle the base64 decoding in the
> API methods. This really isn't a bad choice because this is not much
> work or overhead, and adding a new method or paramter is a matter of
> minutes.

> Or use SOAP. SOAP already supports attachments, though we don't use
> them in Horde's RPC server yet. But at least there is a well defined
> standard you could build on.
I had not considered SOAP.  This may be the best answer for me.  I'll
investigate it.  Thanks for pointing it out to me.

/BAK/
--
Ben Klang
Alkaloid Networks
404.475.4850
ben at alkaloid.net
http://projects.alkaloid.net



----- Ende der weitergeleiteten Nachricht -----


Jan.

-- 
Do you need professional PHP or Horde consulting?
http://horde.org/consulting/
-------------- next part --------------
An embedded message was scrubbed...
From: Ben Klang <ben at alkaloid.net>
Subject: Re: [dev] Proposal for change to Horde's XML-RPC service
Date: Fri, 23 Jun 2006 10:39:22 -0400
Size: 5211
Url: http://lists.horde.org/archives/dev/attachments/20060623/a6a49bdc/attachment-0001.mht


More information about the dev mailing list