Jazz Forum Welcome to the Jazz Community Forum Connect and collaborate with IBM Engineering experts and users

Export specific testresources from RQM with it's ID using REST API.

Hi,

I am trying to export a single testcase using rest api.

When i gave the following URL it gave a feed containing all the Testcase details:

https://my-server:port-number/qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/My-Project-area/testcase?fields=feed/entry/content/testcase/

But when i gave

https://my-server:port/qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/My-Project/testcase/urn:com.ibm.rqm:testcase:846?fields=feed/entry/content/testcase/*

It is not giving me the feed kind of output. it is navigating me to the view testcase screen in RQM.

Note: If i am getting a feed that contains only one testcase, i could save it as an XML doc.

0 votes


Accepted answer

Permanent link
I am out of ideas; you could contact IBM Rational Client Support for further assistance on this.
this will give you an opportunity to discuss the specifics of this issue and the solution required..

Best Regards, Sunil
Sreenisha S selected this answer as the correct answer

0 votes

Comments

Hi,
I got it working. There were some network issue. After resolving that, i tried with the above code. Now it's working fine. Thanks for the answer.

1 vote


3 other answers

Permanent link
 Hello Sreenisha, you could simply download the artifacts using the RQM URL Utility (available for all versions of RQM)..

Here is a sample command  to download TestCase with id 209 to XML..

java -jar RQMUrlUtility.jar -command GET -user admin -password admin -filepath C:\\testCase_209.xml -url https://clm:9443/qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/testProjectofCLM403+%28Quality+Management%29/testcase/urn:com.ibm.rqm:testcase:209

Best Regards, Sunil

0 votes

Comments

I have tried with the above approach.

But it is not creating the xml file in the path specified. Instead it is giving the following error:...RQMUrlUtility: Connected to https://My-server:Port using project"xxxxx"
Oct 30, 2013 2:11:39 PM org.apache.commons.httpclient.HttpMethodDirector execute WithRetry...INFO: I/O exception (java.net.ConnectException) caught when processing request:Connection timed out: connect
Oct 30, 2013 2:11:39 PM org.apache.commons.httpclient.HttpMethodDirector execute WithRetry..INFO: Retrying request Oct 30, 2013 2:12:00 PM org.apache.commons.httpclient.HttpMethodDirector execute WithRetry
INFO: Retrying request...Oct 30, 2013 2:12:21 PM org.apache.commons.httpclient.HttpMethodDirector execute WithRetry..INFO: I/O exception (java.net.ConnectException) caught when processing request: Connection timed out: connect...Oct 30, 2013 2:12:21 PM org.apache.commons.httpclient.HttpMethodDirector execute WithRetry INFO: Retrying request...RQMUrlUtility: Cannot authenticate to server java.net.ConnectException: Connection timed out: connect
Can anybody help me to resolve this?


Permanent link
Hello Sreenisha, what the error means is that the arguments which you have passed is wrong..
I am able to replicate the error with wrong user id and password, ofcourse with a different exception.
The error that you see could be indicating connection issues from the RQMUrlUtility machine to the RQM server..

Best Regards, Sunil

0 votes

Comments

Hi,

This is the command i am using:

java -jar RQMUrlUtility.jar -command GET -user abc -password xyz -filepath d:\\RQMAssetsFolder\\testcasesree1.xml -url https://My-server:port/qm/secure/service/com.ibm.rqm.integration.service.IIntegrationService/resources/Project-alias/testcase/urn:com.ibm.rqm:testcase:846

Note:

1. Using the username and password, i am able to login.

2. Using the URL, i could navigate to the particular testcase

Really clueless.

The username


Permanent link
Hello Sreenisha, Your url has extra string "secure"
https://My-server:port/qm/secure/service/com.ibm.rqm.integration.service.IIntegrationService/resources/Project-alias/testcase/urn:com.ibm.rqm:testcase:846

That is not a part of the REST URL!

Best Regards, Sunil

0 votes

Comments

Hi,

Thanks for the response.This is also not working.

D:\RQM\RQM-Extras-RQMUrlUtil-3.0.1>java -jar RQMUrlUtility.jar -command GET -user abc -password password -filepath d:\\RQMAssetsFolder\\testcasesree1.xml -url https://Myserver:9443/qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/Project-alias/testcase/urn:com.ibm.rqm:testcase:846 

INFO:I/O exception (java.net.ConnectException) caught when processing request:Connection timed out: connect Oct 31,20139:10:44AMorg.apache.commons.httpclient.HttpMethodDirectorexecute WithRetry
INFO:Retrying request

INFO:I/O exception (java.net.ConnectException) caught when processing request:Connection timed out: connect Oct 31,20139:11:27AM org.apache.commons.httpclient.HttpMethodDirector execute WithRetry
INFO:Retrying request
RQMUrlUtility:Cannot authenticate to server java.net.ConnectException: Connection timed out:connect

Your answer

Register or log in 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.

Search context
Follow this question

By Email: 

Once you sign in you will be able to subscribe for any updates here.

By RSS:

Answers
Answers and Comments
Question details
× 10,948

Question asked: Oct 29 '13, 9:04 a.m.

Question was seen: 7,086 times

Last updated: Nov 06 '13, 5:17 a.m.

Confirmation Cancel Confirm