Hello Sebb .. i was reading this because i want to do the same than Ori, but for a different reason .. I want to test a DB using the JDBC Sampler .. but it seems is not possible to connect each thread with different user/password ... am i right?
"No olvides, no traiciones, lo que llevas bien dentro de ti. No olvides, no traiciones, lo que siempre te ha hecho vivir." On Sun, Jan 27, 2008 at 12:52 PM, sebb <[EMAIL PROTECTED]> wrote: > On 27/01/2008, Ori Marco <[EMAIL PROTECTED]> wrote: > > In database connection configuration there are username,password and url > > I want to be able to get those parameters from Main DB so I can run > > using same JMX tests on several DBs/Configurations. > > > > Ah, now it becomes clear. > > > It seems that this can't be done except sending in command-line. > > > > The JDBC Config element is only processed at test startup, so it is > not possible to change the values once a test has started - i.e. you > could not change the values for different loops of the test plan. The > test plan has to know the JDBC settings near the start. > > You may be able to use the StringFromFile or CSVRead functions as > input to JDBC config; I've not tried. > > But the simplest is going to be using properties on the command-line. > > > Ori Marko > > Quality Assurance Engineer > > Praxell Inc. > > http://www.praxell.com > > > > -----Original Message----- > > From: sebb [mailto:[EMAIL PROTECTED] > > Sent: Sunday, January 27, 2008 5:19 PM > > To: JMeter Users List > > Subject: Re: Dynamic JDBC configuration (user&pass) > > > > On 27/01/2008, Ori Marco <[EMAIL PROTECTED]> wrote: > > > Hi > > > > > > The problem remains, I want to change user/pass variables according to > > > values in DB. > > > > Which user / password are you talking about here? > > > > I assume that you need a user and pass to connect to the DB in the > > first place ... > > > > > But JDBC Config element is setting its variables at the start of the > > > test. > > > > It does not set variables, but it does read the values (which may be > > variables) that define the connection quite early in the test. > > > > > So I must send user/pass in command-line as properties or define in > > JMX, > > > right? > > > > Depends which user/pass you are referring to. > > > > Please clarify exactly what you are trying to do. > > > > > Ori Marko > > > Quality Assurance Engineer > > > Praxell Inc. > > > http://www.praxell.com > > > > > > -----Original Message----- > > > From: sebb [mailto:[EMAIL PROTECTED] > > > Sent: Sunday, January 27, 2008 4:49 PM > > > To: JMeter Users List > > > Subject: Re: Dynamic JDBC configuration (user&pass) > > > > > > On 27/01/2008, Ori Marco <[EMAIL PROTECTED]> wrote: > > > > The problem is that I need to get dynamically the user/pass > > > > If it's defined in Test Plan it's not dynamic > > > > > > Not strictly true - you can define variables as property references, > > > and pass in the properties via the command line. > > > > > > > It seems that what was defined in Test Plan can't be override after > > > test > > > > has started > > > > (changing variable value in runtime doesn't change user/pass of JDBC > > > > connection) > > > > > > That's not true - variables defined on the test plan can be changed; > > > however if they are changed after the JDBC Config element has used > > > them, the change will have no effect. That's what happens with the CSV > > > Dataset. > > > > > > > Ori Marko > > > > Quality Assurance Engineer > > > > Praxell Inc. > > > > http://www.praxell.com > > > > > > > > -----Original Message----- > > > > From: sebb [mailto:[EMAIL PROTECTED] > > > > Sent: Sunday, January 27, 2008 4:17 PM > > > > To: JMeter Users List > > > > Subject: Re: Dynamic JDBC configuration (user&pass) > > > > > > > > On 27/01/2008, Ori Marco <[EMAIL PROTECTED]> wrote: > > > > > Hi > > > > > > > > > > > > > > > > > > > > How can I use dynamic username and password in JDBC connection > > > > > configuration? > > > > > > > > As normal, just use the variable references. > > > > > > > > > If it's possible can database URL be dynamic? > > > > > > > > > > > > > Have you tried? > > > > > > > > Note that the JDBC config element is processed early on, so CSV > > > > Dataset variables cannot be used, see the note here: > > > > > > > > > > > > > http://jakarta.apache.org/jmeter/usermanual/component_reference.html#CSV > > > > _Data_Set_Config > > > > > > > > I suggest you try replacing the fixed strings with variables defined > > > > on the Test Plan. You can then try other methods of defining the > > > > variables. > > > > > > > > > > > > > > Thanks > > > > > > > > > > > > > > > > > > > > Ori Marko > > > > > Quality Assurance Engineer > > > > > Praxell Inc. > > > > > http://www.praxell.com <http://www.praxell.com> > > > > > > > > > > > > > > > > > > > > --------------------------------------------------------------------- > > > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > > > > > > > > > --------------------------------------------------------------------- > > > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > > > > > > > > > --------------------------------------------------------------------- > > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > > > > --------------------------------------------------------------------- > > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > --------------------------------------------------------------------- > > To unsubscribe, e-mail: [EMAIL PROTECTED] > > For additional commands, e-mail: [EMAIL PROTECTED] > > > > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [EMAIL PROTECTED] > For additional commands, e-mail: [EMAIL PROTECTED] > >

