Executing a JMeter testplan from Rational Quality manager

About this time last year I wrote a couple of posts on using JMeter against  a Jazz server. A few days ago Gary posted a comment about “making it possible to kick off JMeter tests from RQM and get results sent back so that they can be managed inside RQM” and it stuck in my head, so here’s how it can be done.

RQM allows arbitrary tools to be executed as “test tools” via one facility : the Command Line Adapter. It’s pretty well documented in the Infocentre and Article 809 on Jazz.net . So it ended up being a (mostly:-) straightforward exercise. My requirements were simple: execute a JMeter testplan from RQM and get the appropriate result (PASSED, FAILED,…) to be set for the RQM Test Result. The result would depend on the result of executing a HTTP Request and I’d consider it a bonus if I could set a Custom Property on the RQM result with the value of the HTTP Response Message.

Continue reading “Executing a JMeter testplan from Rational Quality manager”

(J)Metering a Jazz server – Part II

Continuing my journey on the JMeter road, I found Jmeter has a number of other features that help to make Test Plans more generic and useful.

Continue reading “(J)Metering a Jazz server – Part II”

Jazzing up my TV

My TV blew up.

We rarely watch TV anyway (except for any All Blacks games, The Game of Thrones, Dexter, Sherlock Holmes, Modern Family and House of course:-) so we got rid of the Foxtel cable box and haven’t had a TV for a couple of months now. Seriously, no TV. Haven’t missed it. Well, until my wife and I were in the living room last week, with the fire going and she says “Would have been nice to flick through the channels to see what’s on, wouldn’t it?”.  So I set out to buy one, did a bit of research on what was out there and  settled on a Samsung Smart TV. No, not the really big, really cool one with the motion/voice control, facial recognition.

My main requirement is simplicity. I have an Airport Express, an Apple TV, a T-Box, DVD player, a USB drive full of home videos and copies of my DVDs, a  HD PVR that I use to get the content out of the T-Box onto the USB drive so I can watch it on my 27″ iMac in the other room and a HMDI switch as the TV only had one HDMI input. Yeah, a lot of messy cables and messy moving,copying stuff around just so I can kind of watch/listen to any of my content anywhere. Part of the problem was my old TV, it had neither USB nor network connectivity.

The new Samsung that’s coming over in a couple of days does everything I need, it does 3D and is about a fifth the thickness and weight of my old one. I was rubbing my hands in glee at the thought of hooking it all up when my wife took the glee out of it when she pointed out that all I need to do is hook up 3 HDMI cables and one Ethernet cable to it. Bummer! I’ve had to put all those extra cables, adapters, connectors etc in the garage.
What on earth does this have to do with Jazz? Not much, except that (if I’m allowed!) I can have a 40″ full HD external display on which to put all those Eclipse, browser, Notes, RDP windows when I’m working:-) And still watch in one corner the All Blacks thrash whichever team happens to get past the Haka.

Apparently all this multi-tasking, context switching isn’t so good for productivity, but I digress.

My brain made some vague connections between my new TV and Jazz (RTC specifically) when I was reading Robin’s post on finding files and re-reading Jean-Michel’s Christmas Gift post. As I said to the good members of the NSW South Coast chapter of the ACS last week: the word for the day is “integration“. What about “integration”? Well, it doesn’t exist in RTC’s vocbulary. Oh, sure it does when you want to connect it to all sorts of other systems and tools. But when talking about providing all the capabilities that make development teams effective and productive – version control, task tracking, development planning, build management, process execution, in-context collaboration, real-time status updates- the word “integration” isn’t one I’d use with RTC. Because all of this stuff is “just there”. I don’t need that extra “cable” or “adapter”  or “connector” just to get what I see as fundamental capabilites that every development team should have.

On the other hand this missing word was also a problem for me. Just as I enjoyed working out how connect all these different audio/visual components together, I also used to enjoy integrating different tools together and making them sing. Didn’t matter whether these were custom built integrations (like one I built between FoxPro and Quattro Pro way back in 1991) or “out-of-the-box” integrations (your pick of your favourite combination of ClearQuest, ClearCase, Bamboo, Crucible, Subversion, Cruise Control, Jira, Git, Bugzilla ad nauseum). What takes the glee out of this was that all the time and effort I was spending in integrating stuff meant less time and effort devoted to actually using the things that were being integrated.

In other words: the half hour I spent fiddling with stuff was a half hour of a House episode missed.

Clusters of CLM applications without a GUI

I haven’t had much time to write much over the past few weeks as I’ve spent most of my time writing up https://jazz.net/wiki/bin/view/Main/DeployingCLMClusterWithWASND and a week with customers in Seoul. A bit cold in Seoul, especially going from a warm though wet Sydney, but I love the food in Seoul and managed to keep warm.

Working on the clustering stuff has meant I’ve done very little on the Jazz side and a lot ( and I mean a LOT:-) on the Websphere side. Which reminded me of a conversation I had with Alex (http://alexetestelle.almandra.com/) around simplicity. Alex and Estelle had just completed a cycling tour of New Zealand and were visiting us in Sydney on their way back to France. Life on the road was pretty simple for them: not much more than the clothes on their back, their bicycles and panniers, and an iPhone. Alex is also pretty handy with computers and after overhearing a long conversation I had about troubleshooting an RTC installation on WAS, he shook his head and said “Ziz ees too complex no?” (No, he doesn’t really speak like that but is my rendition of his Gallic accented English.) We went on to talk about whether the IT world is guilty of making things unnecessarily complicated, Websphere being a case in point. I’m all in favor of simplicity or at least a facade of simplicity, taking a cue from what I see in nature: simple and beautiful patterns everywhere hiding incredibly complex systems, which funnily enough, are usually the result of fairly simple interactions. After the last few weeks, I’m craving even more simplicity,  though I’ve learnt a ton more about WAS.

Continue reading “Clusters of CLM applications without a GUI”

Digging out RRC custom attributes with RRDI

I seem to do a lot of “follow-up” posts: something I’m writing triggers something else and things start to multiply. Oh well…

This one is essentially the RRC version of  Digging out RTC custom attributes with RRDI (and Reporting on data with custom attributes).  As part of the workshop I needed to show a simple example of extracting and using a couple of attributes defined for an RRC requirement type. So I first assume that there are two attributes of type Integer named Cost and Multiplier defined for the Features in my RRC project.

I’ve modified a couple of Features to add values for these new attributes so I can get some meaningful data in RRDI.

The RRDI report I would like to generate should show these Features in a format similar to that in the graphic above, with an extra column that is the result of multiplying Cost by Multiplier.

Instead of starting with Query Studio as I did last time round, I’ll go straight to Report Studio and start with an empty List report.

The guts of the report lies in the following 5 queries/joins:

1. Requirements: Extracts the “Requirements ID” and “Name” columns from the Requirements query subject.

 

 

 

 

 

2. CostValues: Extracts the “Requirements ID”, “Extension Type Name” and “Value” columns from the Requirement Integer Extension query subject, with a Detail Filter [Extension Type Name]=’Cost’.

3. ReqsWithCost: A join on Requirements ID between the Requirements and CostValues queries, with the Requirements to CostValues cardinality set to 0..n (outer join). The outer join is important as without it the query will only show those requirements that have a value in the Cost attribute.

 

 

 

 

4. MultiplierValues: Extracts  the “Requirements ID”, “Extension Type Name” and “Value” columns from the Requirement Integer Extension query subject, with a Detail Filter [Extension Type Name]=’Multiplier’.

5. RequirementsCostMultipliers: A join on Requirements ID between the ReqWithCosts and MultiplierValues queries, with the Requirements to MultiplierValues cardinality set to 0..n (outer join). The outer join is important as without it the query will only show those requirements that have a value in the Multiplier attribute.

 

 

 

 

 

Once I’ve made sure I’ve added the Value attributes from both the Cost and Multiplier Extension query subjects to the final RequirementsCostMultipliers join, running the query should give a list of all requirements with values for Cost and Multiplier where available. I’ve sneaked in a Detail Filter on the Requirements query ([Requirement Type]=’Feature’) so only Features are shown.

Now that I have the correct data I add a calculated data item to RequirementsCostMultipliers that multiplies the Cost and Multiplier values.

Running the query shows the result of the calculation where available.

Now all that remains is to clean up the list on the report page to display the required results. I’ve also added a conditional style to the calculated column values to highlight null values and values above and  below a threshold in different colours.

Felt a little complicated but the only slightly complicated bit was working out how to put the queries together.

Digging out RTC custom attributes with RRDI

The canned data model in Rational Reporting for Development Intelligence (RRDI) pulls in most custom attributes added to Rational Team Concert, Rational Quality Manager or Rational Requirements Composer projects in the Operational Data Stores “Extension” query subjects. Here is an example documented in the CLM Infocenter that shows how to extract a custom attribute defined for a Test Case in Rational Quality Manager. While running the CLM 2011 reporting workshop I got asked to show how this can be applied to a custom attribute added to an RTC work item and a custom attribute added to an RRC requirement type. As the workshop is also an exploration of the tools RRDI provides report authors –  Query Studio and Report Studio – I showed two different ways of getting at these custom attributes, at the same time showing off how to use these two tools in concert (pun intended:-).

One easy way to get to those custom attributes in RTC work items is to start with Query Studio, setup a query that extracts the attributes of interest and then use the query in Report Studio to present it with bells and whistles if required. To begin I assume that my RTC “Defect” work item type has a custom string attribute with ID “com.ibm.team.apt.attribute.mystring“.

I’ve also created one or two sample Defects with some text in the custom attribute so I have something to show when creating reports:

I now launch the RRDI interface (aka “Cognos Connection”)from the RTC Reports menu on the web:

Then I start Query Studio from the Launch menu. I just want to create a simple list report that shows the values of the Id, Summary, Status and  “My String Attribute” attributes. First I insert the “Request ID“, “Name” and “Request Status” attributes of the Request query subject and sort by Request ID in descending order (not required, but sorting it this way lets me see my new work items at the top of the list) :

 

 

Next I navigate down to the “Request String Extension” query subject and insert the “Name” and “Value” attributes:

While we’re there, notice the other query subjects ending in “Extension”: there are subjects for most other custom attribute types, including Integer, Long and Large String. The CCM Data dictionary is a valuable resource that shows how custom attributes (and other attributes) are surfaced in RRDI.

Now that I have a simple list I open it in Report Studio for further editing and formatting.

First I’ll make a cosmetic edit and change the “Name2” column heading to “Custom Attribute Name“.

Now (the important bit) I need to filter out all custom attributes except my custom string attribute. Report Studio makes it a breeze to do this. Open the “Query” query for editing and drag the “Custom Attribute Name” data item to the “Detail Filters” pane to display the “Detail Filter Expression” dialog.

Next I place the cursor to the right of [Custom Attribute Name] and double-click the “=” operator (or you could just type it in:-) from the Functions tab.

 

 

 

 

 

 

 

 

 

Let’s say I haven’t the best short term  memory in the world and I’ve forgotten exactly how to spell the id of my custom attribute. Report Studio allows me to be forgetful: I just go to the Data Items tab in the expression editor, select “Custom Attribute Name” and click the “Select Value” icon to have Report Studio show all available custom attribute names and double-click “com.ibm.team.apt.attribute.mystring” to add it to the filter expression which now reads “[Custom Attribute Name]=’com.ibm.team.apt.attribute.mystring'”.

I click OK to add the new expression to the Detail Filter, run the report and presto I have a  (yes, very simple) report that shows my custom attribute.

Obviously both Query Studio and Report Studio can do way more than what I’ve shown here but the object of this exercise was to show one way of getting to custom attributes in RTC.

Next up: a slightly more complex example showing how to dig custom attributes out of RRC.

Disambiguation: Requirements Management Project template vs Requirements Management Process template

I seem to be stuck on this topic a little, but perusing the Jazz.net forums shows I’m not the only one confused!

To recap from my last post , relevant bit copied here to save a mouse click or two (I wonder if that saves any trees?):

“Note that through a quirky inconsistency in Project creation between the three CLM applications, you actually need to log in to the Requirements Project URL (/rm/web)  to be able to use the  predefined RM project templates as described in Creating Requirement projects. Attempting Create Project Area from the RM application’s admin page (as you would with the QM and CCM applications) will only show a “Rational Requirements Server Template” which is a process template as opposed to the out-of-the-box  RM-specific project templates.”

So let me dive a little deeper into Requirements Managements (RM) templates and how Rational Requirements Composer (RRC) uses them.

There are actually two types of templates that I can use with RRC :

  1. a process template:
    This is the Jazz process template wherein are specified things like process roles and permissions. I can administer this using the Web UI by navigating to the Jazz Team Server Home Page and then following the “Manage Project Areas” link in the Requirements Management Section of the Application Administration section.

    RM administration links
    RM Jazz process administration

    I can also get to the same page when already in an RM project (/rm/web) using the Administration menu drop down menu icon:

    RM Administration from RM project
  2. a project template:
    This is an RM-specific template mechanism wherein are specified things like  RM artifact templates, RM artifact types, attributes and data types. I can administer this by using the Administration menu  and selecting Manage Project Properties.
    ManageProject Properties 

So to modify an RRC “project template” and create my own modified version of it, I do the following:

a) create a new RM Project Area based on any of the predefined RM project templates.
b) Customize the RM project as required (create new artifact templatescustomise artifact types, attributes and data types and create new link types).
c) Create a new template from the customised project.

Create New RM Project Template

On the other hand to modify the *process* template (roles, permissions etc.) and create my own version of it I do the following:
a) Export the “Rational Requirements Server Template” from the Templates page of the RM Application Administration.

Export RM Process Template

b)Import the exported template with the Eclipse client into a CCM project area.

Import RM Template in Eclipse Client

c)Modify and save the new Project area’s Jazz process configuration – roles, permissions etc .
c) Export the modified template to an archive file

Export RM template in Eclipse Client

d) Import it from the Templates page of the RM Application Administration Web UI.

Import RM Process Template in Web UI

Now come the tricky bits!

Note that when I use the Administration -> Create Project Area action from the /rm/web page, this action *always* uses the “Rational Requirements Server Template” *process* template, but gives me a choice of *project* templates.

Then note that when I use the “Create Project Area” from the RM application’s Project Area Administration page (*not* the /rm/web one), this action *always* uses the “Base”  *project* template, but gives me a choice of *process* templates (if you used the process above to create your own).

So how can I get to choose *both* process and project templates when creating an RM project?

It appears that the only way to allow a choice of both an RM *process* template AND an RM *project* template is to use a Lifecycle Project Template, which I’ve written about previously. Ignore the Quality Management (and the Change and Configuration Management) part if it isn’t in scope and just use the concepts and procedures described in the other sections.

Happy templating:-)