Taverna Server

Attempts to set a new permission on a run result in a 500 error

Details

  • Type: Bug Bug
  • Status: Resolved Resolved
  • Priority: Blocker Blocker
  • Resolution: Fixed
  • Affects Version/s: Taverna 2.3 Server Release 1
  • Component/s: Webapp
  • Labels:
    None

Description

POSTing the following to a run owned by user "taverna":

<t2sr:permissionUpdate>
  <t2sr:userName>test1</t2sr:userName>
  <t2sr:permission>destroy</t2sr:permission>
</t2sr:permissionUpdate>

Produces a 500 error.

Activity

Hide
Donal K Fellows added a comment - 2011-08-30 15:50

Did that message include the xmlns:t2sr="http://ns.taverna.org.uk/2010/xml/server/rest/" pseudo-attribute? If not, the XML deserializer throws a fit.

Exception is:

WARNING: javax.xml.bind.UnmarshalException
 - with linked exception:
[com.ctc.wstx.exc.WstxParsingException: Undeclared namespace prefix "t2sr"
 at [row,col {unknown-source}]: [1,23]]

plus a long stack trace of no interest at all.

Show
Donal K Fellows added a comment - 2011-08-30 15:50 Did that message include the xmlns:t2sr="http://ns.taverna.org.uk/2010/xml/server/rest/" pseudo-attribute? If not, the XML deserializer throws a fit. Exception is:
WARNING: javax.xml.bind.UnmarshalException
 - with linked exception:
[com.ctc.wstx.exc.WstxParsingException: Undeclared namespace prefix "t2sr"
 at [row,col {unknown-source}]: [1,23]]
plus a long stack trace of no interest at all.
Hide
Donal K Fellows added a comment - 2011-09-01 14:24

I believe this to be due to an invalid input message.

Show
Donal K Fellows added a comment - 2011-09-01 14:24 I believe this to be due to an invalid input message.
Hide
Robert Haines added a comment - 2011-09-01 17:01

Good point - I did miss the namespace declaration.

However, retesting with the following XML

<t2sr:permissionUpdate xmlns:t2sr="http://ns.taverna.org.uk/2010/xml/server/rest/">
  <t2sr:userName>test1</t2sr:userName>
  <t2sr:permission>destroy</t2sr:permission>
</t2sr:permissionUpdate>

Still gives a 500 error.

Show
Robert Haines added a comment - 2011-09-01 17:01 Good point - I did miss the namespace declaration. However, retesting with the following XML
<t2sr:permissionUpdate xmlns:t2sr="http://ns.taverna.org.uk/2010/xml/server/rest/">
  <t2sr:userName>test1</t2sr:userName>
  <t2sr:permission>destroy</t2sr:permission>
</t2sr:permissionUpdate>
Still gives a 500 error.
Hide
Donal K Fellows added a comment - 2011-09-02 11:03

OK, that second one was a real bug, and was caused by my fumbling up which result objects should be read-only and which should be writable. (The queried permissions sets were supposed to be read-only, but I had code that assumed they weren't. Oops!)

Show
Donal K Fellows added a comment - 2011-09-02 11:03 OK, that second one was a real bug, and was caused by my fumbling up which result objects should be read-only and which should be writable. (The queried permissions sets were supposed to be read-only, but I had code that assumed they weren't. Oops!)

People

Vote (0)
Watch (0)

Dates

  • Created:
    2011-08-30 15:10
    Updated:
    2011-09-02 11:03
    Resolved:
    2011-09-02 11:03