[redirected to zope-dev]
John Ziniti wrote:
Back in June 2004, I had the following problem:
http://mail.zope.org/pipermail/zope/2004-June/151436.html
http://mail.zope.org/pipermail/zope/2004-June/151492.html
http://mail.zope.org/pipermail/zope/2004-June/151497.html
http://mail.zope.org/pipermail/zope/2004-June/151498.html
which came about because HTTPRequest.py was hard-coded
to assume that any request with a Content-type of "text/xml"
is an xmplrpc call and handles the request as such.
I resolved this issue with the help of [EMAIL PROTECTED], who
gave me the XmlFix product, which monkey-patches the
HTTPRequest.processInputs method to respond a bit more
appropriately. We noted in the thread that although Zope's
behavior is broken, it is unlikely to change for
historical reasons. I am fine with this and felt comfortable
with the simplicity and supportability of the monkey-patch.
This monkey-patch was no longer effective recently when I
upgraded our Zope instances to 2.8.1.
Zope-2.8.1 now additionally has the zope.app.publication.
HTTPPublicationRequestFactory class, which also assumes
that "text/xml" means xmlrpc (in fact, it assumes that
anything that startswith('text/xml') is an xmlrpc call).
Not fixing old code which acts in strange hard-coded ways is
something I understand, but adding new code that also
acts that way seems like it is getting further away
from "good" :)
Can anything be done to change the behavior in the
HTTPPublicationRequestFactory so that it is not so
obtuse? My monkey-patch now has to munge two methods
to make xml uploads work and I am less happy with it
than I was before.
This could be turned into a "disable-xmlrpc" config option. Could you
provide your updated monkey-patch?
Florent
--
Florent Guillaume, Nuxeo (Paris, France) Director of R&D
+33 1 40 33 71 59 http://nuxeo.com [EMAIL PROTECTED]
_______________________________________________
Zope-Dev maillist - Zope-Dev@zope.org
http://mail.zope.org/mailman/listinfo/zope-dev
** No cross posts or HTML encoding! **
(Related lists -
http://mail.zope.org/mailman/listinfo/zope-announce
http://mail.zope.org/mailman/listinfo/zope )