[closed] OSLC query for getting requirements from a requirement collection
Hi,
I'm using DOORS NG (V5.0.2) and I'm trying to get requirements referenced by a RequirementCollection using OSLC.
I tried the query given on:
https://jazz.net/library/article/1197
which is:
So, is the query correct?
PS: Thanks Sudarshan for your answer on DOORS forum. In fact, I put the wrong query.
I'm using DOORS NG (V5.0.2) and I'm trying to get requirements referenced by a RequirementCollection using OSLC.
I tried the query given on:
https://jazz.net/library/article/1197
which is:
&oslc.prefix=oslc_rm=<http://open-services.net/ns/rm%23>,dcterms=<http://purl.org/dc/terms/>&oslc.select=oslc_rm:uses&oslc.where=dcterms:identifier=1But this query only returns the RequirementCollection itself.
So, is the query correct?
PS: Thanks Sudarshan for your answer on DOORS forum. In fact, I put the wrong query.
The question has been closed for the following reason: "The question is answered, right answer was accepted" by davidhoney Jan 31 '23, 4:20 a.m.
Accepted answer
The result is correct and expected. The parameter "oslc.where=dcterms:identifier=1" dictates that you will get zero or one item in the response. To my knowledge, when using an OSLC query, it does not "expand" the items with more details such as links, and only includes "basic" properties.
In the response, you will get the <oslc_rm:RequirementCollection> attribute (hopefully) which is the OSLC URL to the collection itself. Accessing to the URL will expose the "oslc_rm:uses" attributes that you are looking for.
If you want to get the details of the contained artifacts at the same time, it's better to use the Reportable REST API (not OSLC).
https://<server>:<port>/rm/publish/resources?collectionURI=<collection UUID>
In the response, you will get the <oslc_rm:RequirementCollection> attribute (hopefully) which is the OSLC URL to the collection itself. Accessing to the URL will expose the "oslc_rm:uses" attributes that you are looking for.
If you want to get the details of the contained artifacts at the same time, it's better to use the Reportable REST API (not OSLC).
https://<server>:<port>/rm/publish/resources?collectionURI=<collection UUID>
2 other answers
Hi,
That query should return all artifact URL's that are member of the collection with id = 1. If you ar enot gettign the expected results try by URL encoding the"," char,
That query should return all artifact URL's that are member of the collection with id = 1. If you ar enot gettign the expected results try by URL encoding the"," char,
Comments
Yes, therefore the query proposed on https://jazz.net/library/article/1197 is wrong.
I know this is old but adding this comment for others:
The article isn't wrong, you just need to replace the value '1' with your own requirement ID, or use something like oslc.where=dcterms:title="My module name"