users@glassfish.java.net

Re: RE: Basic auth not working in Glassfish 2.1

From: <glassfish_at_javadesktop.org>
Date: Fri, 21 Aug 2009 06:05:06 PDT

Hi Martin,

This is a REST type "web service" for uploading potentially fairly large (multi megabyte) files to a server, hence the PUT. The upload is triggered directly from a client's system, not through a web page, therefore there is not form being posted or anything like that.

Regarding CURL, yes it both reads and writes HTTP headers. That is f.ex. what the

          -H "Content type: application/xml"

is for, it adds the content type header to the request. I think the -T part of the CURL command causes the request to be a PUT rather than a GET or POST, as can be seen in the CURL output, the request is logged as:

          PUT /rest/tpos/incoming/ab/GoodFile.xml HTTP/1.1

Cheers,

Hordur
[Message sent by forum member 'hordurth' (hordurth)]

http://forums.java.net/jive/thread.jspa?messageID=361597