Task Tracker Successful Completion - How to get stream uri after its created.
I am using the oslc rm apis on my java backend. I have a baseline and wanting to create a stream from it. I send the request to oslc client create a stream and get back a 202 response as expected. Now I am taking that location header for the task tracker. I am polling the task tracker just fine and finally when I get the progress 100 and confirmation that state is COMPLETE/PASS I am now trying to get the url of the stream that was created in that task. In order to do that I am getting 'references' (http://purl.org/dc/terms/references) and successfully getting back the following references string:
"1443a0fa-b8cc-41fa-8a21-df307274a26d"
I am confused now how I can get the url of the stream with that provided string above.
One answer
oslc_config:Activity
has the following description for
dcterms:references
. That should be the URI of the created resource. If an application is returning a string rather than a URI, that application is not conformant with the OSLC Configuration Management specification.
A reference to a resource providing more details about the progress or result of the activity. For successful or partially successful operations, thedcterms:references
property MUST be present, providing a link to the primary resource created or affected by the operation [CONFIG-RES-161]. For completely unsuccessful activities, this property may be missing. For activities still in progress, this MAY be a reference to a resource providing further information; which MAY be provided inline [CONFIG-RES-162].
Comments
Im confused because im making this call to the DNG oslc api. Im getting a succesful response for the task tracker that it is complete and getting that string back in the references. So are you saying this is an issue with the oslc api for dng?
-
Getting the local stream and getting the streams LDPC (Linked Data Platform Container) URI from its RDF. See the OSLC Configuration Management spec.
- POST new RDF content to that streams LDPC URI.
-
On getting 202 Accepted, gets the URI of the
oslc_config:Activity
resource from the Location header of the response -
Polls that activity resource until it completes. If successful, it gets the URI of the stream that was created from the
dcterms:references
in theoslc_config:Activity
resource.
I am understanding that and everything 1-4 is happening accordingly except at the end im not getting a URI of the created stream but rather getting "1443a0fa-b8cc-41fa-8a21-df307274a26d" for dcterms:references
Sounds like you are not using the above OSLC defined mechanism but something else. Is the resource you see of RDF type
oslc_config:Activity
?
If not, then you are not using an OSLC defined mechanism. Please read the OSLC Configuration Management specification.