SPONSORS:






User Tag List

Thanks Thanks:  0
Likes Likes:  0
Dislikes Dislikes:  0
Results 1 to 8 of 8
  1. #1
    Junior Member
    Join Date
    Sep 2010
    Posts
    8
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    parameterization and vuser_init

    I want to read a unique row for each vuser in the vuser_init. I tried parameterizing using "update on each occurence" as I understand that "update on each iteration" only applies to the Action iteself.

    Comments?

    Thanks
    John



    =======
    LR 9.50
    Windows 2003 Server

  2. #2
    Apprentice
    Join Date
    Jun 2008
    Location
    Chennai, India
    Posts
    45
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: parameterization and vuser_init

    By definition, the init and end sections are set to run only when the user enters/exits his actions. If you want a parameter in these sections to be updated for every iteration, you have two options.
    <ul type="square">1. Set the iteration count to 1 in Run-time settings. This way, the user will log on and off for each iteration and the init and end sections will be called each time.
    2. Move the code containing the parameters into the action section. [/list]
    On the other hand, if you have multiple instances of the same parameter in the init section and want to assign different values only when logging in for the first time, I think what you are doing will accomplish that.

    Scimitar

  3. #3
    Advanced Member
    Join Date
    Jun 2006
    Location
    USA
    Posts
    785
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: parameterization and vuser_init

    [ QUOTE ]

    <ul type="square">1. Set the iteration count to 1 in Run-time settings. This way, the user will log on and off for each iteration and the init and end sections will be called each time.
    [/list]

    [/ QUOTE ]

    Only in VuGen. When the Script moves to the Controller, and scenario duration is set for duration, it wont work as it should.

  4. #4
    Apprentice
    Join Date
    Jun 2008
    Location
    Chennai, India
    Posts
    45
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: parameterization and vuser_init

    duh! Stupid me!

    Thanks for pointing it out, Chid.

    Scimitar

  5. #5
    Senior Member
    Join Date
    Apr 2009
    Location
    Canada
    Posts
    123
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: parameterization and vuser_init

    To do what you want, can't you use?

    Select Next Row: Unique
    Update: Once

    That way, you'll get one unique "row" of parameters per VUser (you'll need as many rows as VUsers).

    Regards,

  6. #6
    Junior Member
    Join Date
    Sep 2010
    Posts
    8
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: parameterization and vuser_init

    The users are tied to the test data. Here's an exmaple:
    Allocation (log in once, iterate over n rows, then logout)
    User TruckID Allocate
    1 1 SKU1
    1 1 SKU2
    ...
    Ship (log in once, iterate over n rows, then logout)
    User TruckID Ship
    3 3 SKU1
    4 4 SKU2
    ...
    so if I use Unique I don't think it will read in sequential order (or will it).

  7. #7
    Moderator
    Join Date
    Feb 2010
    Location
    Europe
    Posts
    944
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: parameterization and vuser_init

    what exactly are you trying to do here?

    are you trying to get user 1 to allocate SKU1 and then get user 3 to ship SKU1?

    or doesn't it matter?

    if the order is important then there are a number of approaches

    you could log in to the application as 2 seperate users using the same sku in the same script, however this then dictates how you can structure your scenario, so not ideal

    another way is to seed the database, before you test, with the allocation script adding enough data for your shipping script to run, at least until a decent amount of data is coming into the system, this is a very common way of getting around this issue

    probably the most complicated is to use a database to pass the data at run time - however, if you want to go down this route it's not that difficult or time consumming, I had everything I needed downloaded, installed and working in about a day or so

    for load runner mysql integration code google "richard bishop loadrunner mysql" or "jds australia loadrunner mysql"

    i think the big issue here is what happens in real life? does user 1 enter sku1 in the system and then physically tell user 3 that they should ship sku1 and they ship it? or does the system tell user 3? and if so why user 3 and not user 79? or does a user do a general search and pick the first one to work on

    for example, if your script for shipping does a search on a particular field and your actual user just searches with no criteria and takes the first one, then your test may not be as useful as it could be

    it's always a balance really, between how much time you have, how accurate your test needs to be, the amount of effort you have to put in and potentially how you and your customers deal with you performance testing their application and maybe finding performance issues in a heavily used, in production, function that you didn't test because that's not how the walkthrough was written

  8. #8
    Senior Member
    Join Date
    Apr 2009
    Location
    Canada
    Posts
    123
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: parameterization and vuser_init

    And to answer your question about Unique, yes it will pull them in "sequential" order.

    You need to see the "unique" like this; Pretend all your parameter rows constitute a set. Everytime your scripts (It's not a set per script but a set per group of scripts referecing that param file) call for one of these rows, that row is removed from the set. This effectively means the second VUser will grab the second row and remove it from the set and so forth.

    So in the end, the effect is "sequential" but it requires you to have, at least, as many param rows as you'll have VUsers that reference them.

    Hope this makes sense.

 

 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Search Engine Optimisation provided by DragonByte SEO v2.0.36 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Resources saved on this page: MySQL 9.38%
vBulletin Optimisation provided by vB Optimise v2.6.4 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
User Alert System provided by Advanced User Tagging v3.2.8 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
vBNominate (Lite) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Feedback Buttons provided by Advanced Post Thanks / Like (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Username Changing provided by Username Change (Free) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
BetaSoft Inc.
Digital Point modules: Sphinx-based search
All times are GMT -8. The time now is 06:14 PM.

Copyright BetaSoft Inc.