You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@jmeter.apache.org by bu...@apache.org on 2018/07/18 13:09:37 UTC

[Bug 62553] New: While creating random variable same variable created even options per thread user is set to TRUE

https://bz.apache.org/bugzilla/show_bug.cgi?id=62553

            Bug ID: 62553
           Summary: While creating random variable same variable created
                    even options per thread user is set to TRUE
           Product: JMeter
           Version: 4.0
          Hardware: PC
            Status: NEW
          Severity: major
          Priority: P2
         Component: Main
          Assignee: issues@jmeter.apache.org
          Reporter: ibenikhil@gmail.com
  Target Milestone: ---

Created attachment 36041
  --> https://bz.apache.org/bugzilla/attachment.cgi?id=36041&action=edit
attachment of random variable configuration.

I have created script with some session keys passing. 
In my script i need to have different session keys for each request.
I have configured a random variable in Jmeter and set the option for per thread
user as TRUE(as per my readings/knowledge) if we set a this configuration as
true then it should create different variables for each thread.

But out of my 50 threads 49 different variables have been created and one
variable get repeadted.


I have been attaching the image of random variable configuration.

following are the random variables get created. Here thread 15 and thread 28
having same variables.

Thead1  ,abcdefghijk41128404048       
Thead2  ,abcdefghijk41230939629   
Thead3  ,abcdefghijk41284804475
Thead4  ,abcdefghijk41139561766
Thead5  ,abcdefghijk41018558237
Thead6  ,abcdefghijk41040681298
Thead7  ,abcdefghijk41271915387
Thead8  ,abcdefghijk41247099083
Thead9  ,abcdefghijk41232863374
Thead10 ,abcdefghijk41255755934
Thead11 ,abcdefghijk41155528845
Thead12 ,abcdefghijk41136483774
Thead13 ,abcdefghijk41117631078
Thead14 ,abcdefghijk41199582594
Thead15 ,abcdefghijk41044336413
Thead16 ,abcdefghijk41147641493
Thead17 ,abcdefghijk41185346885
Thead18 ,abcdefghijk41141677885
Thead19 ,abcdefghijk41290960458
Thead20 ,abcdefghijk41180345149
Thead21 ,abcdefghijk41109551351
Thead22 ,abcdefghijk41248060956
Thead23 ,abcdefghijk41166494189
Thead24 ,abcdefghijk41298847810
Thead25 ,abcdefghijk41265759405
Thead26 ,abcdefghijk41028561708
Thead27 ,abcdefghijk41111667470
Thead28 ,abcdefghijk41044336413
Thead29 ,abcdefghijk41034717690
Thead30 ,abcdefghijk41010863259
Thead31 ,abcdefghijk41061457739
Thead32 ,abcdefghijk41120901444
Thead33 ,abcdefghijk41077424818
Thead34 ,abcdefghijk41251716070
Thead35 ,abcdefghijk41068190845
Thead36 ,abcdefghijk41031447325
Thead37 ,abcdefghijk41242097348
Thead38 ,abcdefghijk41158414462
Thead39 ,abcdefghijk41020866730
Thead40 ,abcdefghijk41188617250
Thead41 ,abcdefghijk41259795797
Thead42 ,abcdefghijk41281726484
Thead43 ,abcdefghijk41048376276
Thead44 ,abcdefghijk41171688299
Thead45 ,abcdefghijk41064535730
Thead46 ,abcdefghijk41169572180
Thead47 ,abcdefghijk41152450854
Thead48 ,abcdefghijk41269029771
Thead49 ,abcdefghijk41009324263
Thead50 ,abcdefghijk41103395369

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 62553] Random element might return same value even if property "Per thread user (User)" is set to TRUE

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62553

Philippe Mouawad <p....@ubik-ingenierie.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |NEEDINFO

--- Comment #1 from Philippe Mouawad <p....@ubik-ingenierie.com> ---
I am not sure it's an issue.
As per documentation, since you didn't set a seed, System.currentTimeMillis is
used, so if 2 threads start at same millis, you might get this behaviour.

@Team, should be use new Random() when seed is empty ?

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 62553] Random element might return same value even if property "Per thread user (User)" is set to TRUE

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62553

Nikhil B <ib...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEEDINFO                    |NEW

--- Comment #4 from Nikhil B <ib...@gmail.com> ---
Thanks for your immediate assist. @Vladimir Sitnikov and @Philippe Mouawad.

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 62553] Random element might return same value even if property "Per thread user (User)" is set to TRUE

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62553

--- Comment #2 from Vladimir Sitnikov <si...@gmail.com> ---
+1 for `new Random()` (== different seeds for each thread) when the seed is not
set

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 62553] Random element might return same value even if property "Per thread user (User)" is set to TRUE

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62553

Philippe Mouawad <p....@ubik-ingenierie.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|While creating random       |Random element might return
                   |variable same variable      |same value even if property
                   |created even options per    |"Per thread user (User)" is
                   |thread user is set to TRUE  |set to TRUE
                 OS|                            |All
                 CC|                            |p.mouawad@ubik-ingenierie.c
                   |                            |om

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 62553] Random element might return same value even if property "Per thread user (User)" is set to TRUE

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62553

Philippe Mouawad <p....@ubik-ingenierie.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
   Target Milestone|---                         |JMETER_4.1
           Keywords|                            |FixedInTrunk
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED

--- Comment #5 from Philippe Mouawad <p....@ubik-ingenierie.com> ---
Author: pmouawad
Date: Thu Jul 19 19:17:36 2018
New Revision: 1836293

URL: http://svn.apache.org/viewvc?rev=1836293&view=rev
Log:
Bug 62553 - Random element might return same value even if property "Per thread
user (User)" is set to TRUE
Bugzilla Id: 62553

Modified:
   
jmeter/trunk/src/components/org/apache/jmeter/config/RandomVariableConfig.java
    jmeter/trunk/xdocs/changes.xml
    jmeter/trunk/xdocs/usermanual/component_reference.xml

-- 
You are receiving this mail because:
You are the assignee for the bug.

[Bug 62553] Random element might return same value even if property "Per thread user (User)" is set to TRUE

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=62553

--- Comment #3 from Nikhil B <ib...@gmail.com> ---
Hi I have not given any seed configuration. 
So I am making change in my configuration for seed configuration i am giving
${__Random(MIN,MAX)} as value. Will it solve my problem. 

But my question is with default seed configurations it should work properly?

-- 
You are receiving this mail because:
You are the assignee for the bug.