It's all about the answers!

Ask a question

How to make a requirement collection using rest API


helene højrup (231912) | asked Apr 11 '13, 4:53 a.m.
retagged Apr 19 '13, 4:21 p.m. by Douglas Bush (28125)

Hi

How do I make a requirement collection using rest API?

I've tried to follow the workshop notes and am able to get the services.xml. My question is now, if I should use the link under the "Collection Creation Factory"? Should I use the oslc:creation rdf:resource link or the oslc:resourceShape rdf:resource link? When trying to access the oslc:creation rdf:resource link i get the response 404 Not Found.

When these questions are answered... then what should I write to make the collection? I suppose I should use PUT but what else?

Thank you in advance for you help.

One answer



permanent link
Gabriel Ruelas (1.1k13) | answered Apr 11 '13, 9:49 a.m.
Hi,
   Artifact creation in RM Application using OSLC is described in https://jazz.net/library/article/1197.

PLS take a look and add a comment if you have further questions.

Comments
helene højrup commented Apr 16 '13, 7:08 a.m.

Hi Gabriel
Thank you for your answer, it helped me a bit, but now I have a 400 Bad Request problem when I try to PUT my changes (I've just tried to update the title of an existing requirement).


helene højrup commented Apr 16 '13, 7:14 a.m.

PUT <the requirement URI>
OSLC-Core-Version: 2.0
accept: application/xml
If-Match: <the requirement etag>
Content-Type: application/rdf+xml

The response

400 Bad Request
Content-Type: application/rdf+xml; charset=UTF-8
...
the errormessage
https/1.1 400 (more info found at entry [b6027e3840337de9] in the RM application server log)

I can't fint this entry in the RM application server log?


helene højrup commented Apr 16 '13, 8:18 a.m.

Sorry, I was looking at the wrong RM application server log. What it states in the end is:
Error 400: CRJZS5039E The ETag specified for If-Match is not legally formed &#40;see http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html&#41;


Gabriel Ruelas commented Apr 16 '13, 9:54 a.m.

Hi, are you including the complete ETAG in the IF-MATCH header?

Your answer


Register or to post your answer.


Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.