It's all about the answers!

Ask a question

RQM: How can I assign a custom lab resource for an RIT adapter?


Shuhichi Saitoh (20059) | asked Jul 09 '15, 6:04 a.m.
edited Jul 10 '15, 3:31 a.m.
I'm using RQM 4.0.6 with Rational Integration Tester (RIT) 8.6 to automate testing.

At start, it was good working, however, when we need more than 2 adaptors (to run 2 or more tests concurrently), we have problem.

We have "one" server which runs RIT Agent that works as the RQM Adapter.
The server have enough resource (CPU and memory), so, we defined 2 adapters on the RIT Agent, by adding <rqm> elements as described in online help, and it seems fine at first.

However, when we see the those adapters in RQM, those adapters are associated with one same Lab Resource (Test Machine).
And It is the problem, because when test runs on an adapter, another adapter is free for use. However, RQM automatically reserves the "Lab Resource" and prevents another user to use the free adapter, because the Lab resource was locked, even though the another adapter itself is free to use.

So,  I would like to manually assign a custom lab resource to adapter.
 
Does anyone have any suggestion, or solution for it?

Regards,
 

2 answers



permanent link
Subhajit Bhuiya (6222) | answered Jul 09 '15, 7:55 a.m.
JAZZ DEVELOPER
It is recommended not to run 2 adapters on the same machine as they will be mapped into same lab resource and reservation will be a problem.

Comments
Shuhichi Saitoh commented Jul 09 '15, 9:15 p.m.

Thank you very much for your quick response.

What you mentioned is, it is the QM's current design & implementation of adapter & lab resource management behavior, and is designed behavior?

Are there are no way to change the mapped lab resource for an adapter, such as using some public/internal API or something?


I think, restricting "one" adapter per "one" machine is a bad design decision. It is a waste of the resource (i mean CPU/memory or hardware) and I cannot find any practical reason to do so.

From what I see in work items in QM project area (in jazz.net), there are several other users who uses multiple adapters on one machine, such like multiple JUnit adapter or Command Line adapters.



permanent link
Shuhichi Saitoh (20059) | answered Jul 10 '15, 3:30 a.m.
edited Jul 10 '15, 4:32 a.m.
I figured out the procedure myself.
It worked with RQM 4.0.6 (and maybe will work with later version) and worked for RIT Adapter as well as Command Line adapter.

There are 2 ways to do so.

(Option 1) Using RQM Reportable REST API to modify <adapter>.
(https://jazz.net/wiki/bin/view/Main/RqmApi)

1. In RQM Web UI, create a "Machine" type Lab Resource and specify appropriate name.
2. In Hardware section of the lab resource, specify an unique  (but not exist) IP Address  into "IP Address"  field.
It is important to assign unique IP Address, since RQM 4.0.x seems use the IP address for mapping.
3. In Operating System section of the lab resource, specify appropriate Host name, and Full Qualified Domain Name (FQDN), and then save the resource.

For my case, I specified
 Name: Command Line Adapter 1
 IP Address: 10.255.255.1
 Host Name: CLAdapter1
 FQDN: CLAdapter1

4. In test machine, launch adapter using an adapter id to create an <adapter> resource in the RQM.
5. In test machine, stop the adapter.
6. In RQM Web UI, open "Execution" > "Adapter Console" to see the adapter and its ID.
At this moment you will see the "actual" host name and IP address which the adapter running.

7. Using REST API Client (I used the Poster add-in with Firefox 31, but you can use any), get the adapter resource XML.

the URL will be:
https://<host>:<port>/qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/<project area uuid>/adapter/urn:com.ibm.rqm:adapter:<adapter id on Web UI>

Such like:
https://clm406test.localdomain:9443/qm/service/com.ibm.rqm.integration.service.IIntegrationService/resources/_q0uYgKBVEeS6mJDl5KsoeQ/adapter/urn:com.ibm.rqm:adapter:14

8. After copying the XML from 7, change the value of <ns12:ipAddress>. <ns12:hostname> and <ns12:fqdn>  as you specified in step 2 and 3, then "PUT" it to the same URL to update the adapter resource .

<ns12:hostname>CLAdapter1</ns12:hostname>
<ns12:ipaddress>10.255.255.1</ns12:ipaddress>
<ns12:fqdn>CLAdapter1</ns12:fqdn>

9. Now you will see the lab resource is linked to the adapter n Adapter Console view.
10. In test machine, launch adapter with the same adapter id as specified at step 4.
11. In RQM Web UI, you will see the adapter is linked with the custom lab resource and active.


The another option, you do not need to REST API, however you need to delete adapters already exists.

(Option 2) Create/Modify Lab Resource one by one
1. Delete all adapters.
2. Launch an adapter using an adapter id to create an <adapter> resource in the RQM.
3. Open "Execution" > "Adapter Console" to see the adapter and its associated Lab resource.
4. Update the name, IP Address, Hostname and FQDN values of the resource.
Again, it is important to assign a unique "IP Address". You can assign non existing IP address.
5. Open "Execution" > "Adapter Console" to see the resource for the adapter is updated.
6. Repeat step 2 to 5 for all adapters you want to create.


I'm not sure this is supported procedure.
However, considering that, a machine (which the adapter run) can have several IP addresses as well as several host names (such like HTTP servers virtual host), and RQM do not need to see the actual one (because RQM will not connect to adapter, instead adapters do connect to RQM), the trick mentioned above will work eventually.


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.