[Dart] Investigating addition of HTTP PUT submission support
Zachary Mark
zmark at cleversafe.com
Mon Jun 19 18:04:13 EDT 2006
This is a followup to the e-mail thread referenced at
http://public.kitware.com/pipermail/dart/2006-June/001557.html
I am investigating the near-term feasibility (as in, beginning very
soon) about contributing support for submissions via HTTP PUT into the
DartServer. This functionality is very highly desired and as such I
would be willing to implement it myself and contribute it into the Dart
code base.
I've spent some of the afternoon reading through the Dart source code
and trying to make heads and tails of it, and I think I have a basic
design overview, and I'm looking for some of the Dart core devs to take
a look at my proposal and evaluate what changes could be made to my
idea. I am not 100% familiar with the Dart code so this is a guess
based on what I have gleaned so far.
What I propose is that a void doPut method be added to the
java.server.servlet.CommandServlet class with the following signature:
public void doPut( HttpServletRequest request,
HttpServletResponse response ) throws
ServletException, IOException
I would make the assumption that all commands received via PUT are
submission requests, rather than the much broader functionality offered
by xmlrpc. The doPut method would contain a submission command object
(dart.server.command.Submit) and call the Submit.put method directly.
It seems that the Submit.put method should handle all the functionality
that I'm looking for, but there is one issue that I potentially have.
How can I use HTTP PUT and differentiate between different projects?
IIRC, HTTP PUT allows only one submission field which obviously should
contain the full XML submission data. Is there a "default project"
setting in the Dart server that I could leverage to direct all PUT
requests? Could the XML format be extended so that clients can specify
which project to submit the results to in the XML? Maybe this could be
incorporated into the <DartSubmission> tag, in the following form:
<DartSubmission version="2.0" createdby="ReSTInstaller"
project="SampleProject">
Since the client has to specify which project to submit the result to in
the first place, I don't see a reason not to potentially include it in
the XML, unless there are some issues that I am not considering.
Sorry I got to the point of rambling, but I'm interested to hear some
thoughts on this issue and my PUT proposal.
-- Zach
More information about the Dart
mailing list