DNG 6.0: How to fetch requirements from a folder using OSLC
![]()
i am doing GET on the following url using OSLC and Java but getting
"Exceptionjava.lang.IllegalArgumentException". Url: https://myserver.com/rm/views=oslc.prefix=oslc=<http://open-services.net/ns/core%23>,dcterms=<http://purl.org/dc/terms/>,nav=<http://com.ibm.rdm/navigation%23>&oslc.select=dcterms:title,dcterms:description,oslc:instanceShape&oslc.where=nav:parent=https://myserver.com/rm/folders/_zqHJMVeOEeWrg6L82g9mcQ I have tried to user query capability but returning null value in result. Query parameters: OslcQueryParameters queryParams = new OslcQueryParameters(); queryParams.setPrefix("nav=<http://com.ibm.rdm/navigation#>,rdf=<http://www.w3.org/1999/02/22-rdf-syntaxns#>"); queryParams.setWhere("rdf:type=<http://open-services.net/ns/rm#Requirement> and nav:parent=<" + TargetFolderUri + ">"); OslcQuery query = new OslcQuery(client, queryCapability, 5, queryParams); OslcQueryResult result = query.submit(); can anybody let me know the correct Url and whether should in do a GET or use Query capability ? Thanks!!!! |
Accepted answer
![]()
Hi, the information is project specific, that is the reason you need to grab it from the service provider document. It must be something like :
&projectURL=https://grarrc.ibm.com:9443/jts/process/project-areas/_C7NVcttZEeG_kKBmAlkUvA Naveen Tyagi selected this answer as the correct answer
Comments Hi Gabriel, Thanks for your help.
Hi, have you tried adding another condition to the where clause ?
|
One other answer
![]()
Hi,
From your sample query I think that project context information is not being specified. RDNG OSLC provider need a parameter that specify the project context where the query will be executed. The project context is automatically provided if you get the query url from the project service document. Pls checl following article https://jazz.net/library/article/1197 in the section Using the query capabilities. Best Regards. Comments Hey Gabriel, could you please correct in the above query and post in response. i have been trying from last week but still not able to do. Thanking in advance. and also please tell me what is the correct way using GET or query.submit(). Since i have tried both but still not figured out the correct way. Hi, the information is project specific, that is the reason you need to grab it from the service provider document. It must be something like :
&projectURL=https://grarrc.ibm.com:9443/jts/process/project-areas/_C7NVcttZEeG_kKBmAlkUvA i am giving service provide url. i didn't post the complete URL in previous comment. here is the first two line i have missed in my question.
queryParams.setWhere("rdf:type=<http: open-services.net="" ns="" rm#Requirement=""> and nav:parent=<;" + TargetFolderUri + ">");
you are using Eclipse Lyo, have you seen the RCFormSample in https://wiki.eclipse.org/Lyo/BuildClient
showing 5 of 6
show 1 more comments
|
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.