Hi Robert
Thanks 4 the help!!!
Yes, the application/xml solved it !!! And in fact 415 should have been
the correct error.
Nevertheless, the POST firefox addon was sending:
application/vnd.taverna.t2flow+xml
IMHO, Taverna server should be a bit more flexible with mimetypes, and
also accept this mimetype ?!
Thanks
Jorge
On 11/08/11 13:31, Robert Haines wrote:
> Hi Jorge,
>
>> I need some help with Taverna server 2.2, and I must say that I'm
>> totally new to REST requests
>
> <snip GET working>
>
>> If I try to POST a file (I'm using Firefox add-on Poster) and I get 404
>> Not Found.
>>
>> If I send a OPTIONS the server replies:
>>
>> Allow: POST,GET,OPTIONS,HEAD
>>
>> Meaning that POST should be working, I am confused with a 404 Error
>> for POST
>
> This version of Taverna Server does have confusing/wrong HTTP response
> codes in certain places. It clearly shouldn't be returning 404 here
> (and this has been fixed for the next release) but it does add
> confusion unnecessarily, sorry.
>
> The problem is outlined below:
>
>> I've tried also with wget and catalina.out has the following:
>> ID: 37
>> Address: /taverna-server/rest/runs
>> Encoding: ISO-8859-1
>> Content-Type: application/x-www-form-urlencoded
>
> Your Content-Type for POSTing a workflow should be application/xml.
> The next version of the Server will return a 415 error here which
> would give some clue as to the actual error!
>
>> Headers: {content-type=[application/x-www-form-urlencoded],
>> connection=[Keep-Alive], host=[localhost:8080], Content-Length=[34828],
>> user-agent=[Wget/1.12 (linux-gnu)],
>> Content-Type=[application/x-www-form-urlencoded], Accept=[*/*]}
>> Payload: <?xml version="1.0" encoding="UTF-8"?>
>> <t2s:workflow t2s:xmlns="http://ns.taverna.org.uk/2010/xml/server/">
>> <workflow xmlns="http://taverna.sf.net/2008/xml/t2flow" version="1" ...
>
> <snip tomcat logs>
>
>> It seems that there is some problem with the Target method ?!!?
>>
>> I am doing something wrong ?! Bug, RTFM ?!
>
> Yes, a bug. 404 is clearly wrong here and, as I said, it's fixed in
> the next release.
>
> If you are a ruby programmer there is a gem, which hides all the low
> level HTTP unpleasantness, available here:
> https://rubygems.org/gems/t2-server
>
> I hope this helps, please let me know if you're still having problems.
>
> Best wishes,
> Rob
>
--------------------------------------------------------------------------------
Plymouth Marine Laboratory
Registered Office:
Prospect Place
The Hoe
Plymouth PL1 3DH
Website: www.pml.ac.uk
Click here for PML Annual Review
Registered Charity No. 1091222
PML is a company limited by guarantee
registered in England & Wales
company number 4178503
Please think before you print
--------------------------------------------------------------------------------
This e-mail, its content and any file attachments are confidential.
If you have received this e-mail in error please do not copy, disclose it to
any third party or use the contents or attachments in any way. Please notify
the sender by replying to this e-mail or e-mail [email protected] and then
delete the email without making any copies or using it in any other way.
The content of this message may contain personal views which are not the views
of Plymouth Marine Laboratory unless specifically stated.
You are reminded that e-mail communications are not secure and may contain
viruses. Plymouth Marine Laboratory accepts no liability for any loss or damage
which may be caused by viruses.
--------------------------------------------------------------------------------
------------------------------------------------------------------------------
Get a FREE DOWNLOAD! and learn more about uberSVN rich system,
user administration capabilities and model configuration. Take
the hassle out of deploying and managing Subversion and the
tools developers use with it.
http://p.sf.net/sfu/wandisco-dev2dev
_______________________________________________
taverna-users mailing list
[email protected]
[email protected]
Web site: http://www.taverna.org.uk
Mailing lists: http://www.taverna.org.uk/about/contact-us/