Wednesday, August 19, 2009

Siebel SWECount

This post refers to the usage of the Siebel_SWECount variable in LoadRunner scripts.
It is very easy to identify that loadrunner scripts for Siebel-Web are composed mainly for submit calls followed by a web_url call. The behavior of the Siebel-SWECount is adding 1 before the submit, substracting 1 after the submit, and then adding 2 after the url.

Simulation:

Siebel_SWECount += 1;
web_submit(...);
Siebel_SWECount -= 2;
web_url(...);
Siebel_SWECount -= 3;

This will provide the increment for the following submit without having to add it again.
This behavior is not always used in loadrunner. Which means that is not a rule, as some urls dont require the substraction of the Siebel_SWECount.

Does anybody have found an answer for this?

Regards!

Wednesday, January 21, 2009

Loadrunner Siebel-Web Scripts

After a lifetime doing Loadrunner Siebel scripts I have come across with this blog to share and receive comments from people around the globe that have struggle with the same technologies I have used.

I am trying this blog as my first blog in life because I really want to share and get other people experiences in this area and I want to check if I am the only one that really wants to understand the secrets of the SISNAPI protocol and most important thing the format of the responses so I can better understand how to automate it.

This blog is intended for people that is interested in share experiences and techniques for Siebel Automated Test scripts with LoadRunner Technology.

If you are a Performance Test Specialist and you are looking for the best tips and tricks that are not available in all the documentation from HP Loadrunner and Siebel Bookshelfs consider this area the approapiate framework to review and go through.

Ok, so now the first things which refer of what are the first steps in the script development for Siebel-Web scripts:

1. Multiple Recordings
One of the first approaches for correlating Siebel-Web scripts is the fact of finding the differences between multiple recordings with different users and different data sets. This approach will help to find different row id positions in the responses comming from SISNAPI

Questions that I have in this area are:
1. Does anyone know what are the values:
- Siebel_SWEVLC
- Siebel_ACn10
As they are automatically correlated but never know what they correlate to in the application

Multiple recordings also help you to find the enigmatic Siebel_SWECount values that Loadrunner since version 8 automatically calculate and adds into your script, instead of adding the correlation of the value directly from the server response as it used to do in the past.

One of my recomendations to go through the correlation process is to record always 2 iterations of the script, one in Action.c and the second iteration in Action1.c (new action created during recording) try also to record without using any correlation, and remember that you don't need to record again with correlation, just use the Generate Script... function with the correlation checks enabled and that will create the script with the appropiate correlations.

2. The Value Arrays
Siebe responses with the Row Ids that you need to create records or drilldown into records are called Row Ids and those are the key for the Siebel-Web scripts.
You will find that value arrays in Siebel come as responses with the following formar `v`and `ValueArray`
Next to that you will find the common StarArray format used in SISNAPI which is

1. A number with the length of the next field
2. Field with previously described length
3. A number of the next field length

Example:
`ValueArray`10*Text with.2*102*221*1*a1*g1*22*Si3*Yes8*1-345678`i`1-345678`

Some of the comments around the correlation of this values is that in LoadRunner regularly it looks for only the value arrays, and in Siebel commonly between iterations this values change a lot in positions, and therefore you have to change the Ord parameter in the web_reg_save_param function, and it make your scripts weak as you run with multiple data sets or with multiple iterations.

My solution is to include more values from the left of the value array to complete the correlation, this regularly includes the number of the Business Component in Siebel rendered for that view, for instance, S_BC11
Try to find something like that in the responses and you will see that the position of the business component never change in the view so there your correlation is more strong and therefore your scripts are also better prepared for various data sets and iterations.

The problem with this approach is always the trade off the new release of new SRFs in the test environment as every time a new SRF file is compiles the fields in the web_submit_data forms change, for instance what use to be

"Name=s_1_1_10_2" change to something like "Name=s_1_2_10_2" because a BusComp is now compiled and positioned in the next value available in the view, and eventually that makes your script to fail, so you need to find out which fields are different between the old SRF and the new SRF.

I think this will be for the first post.
If you have any comments or experiences in this area, are welcomed.

Thanks.