jmeter-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sebb <seb...@gmail.com>
Subject Re: How to connect to Database from JMeter at the start of the test and use the connection in the post processor to insert some data?
Date Thu, 21 Jun 2012 16:03:39 GMT
On 21 June 2012 16:27, Roderick Parks <roderick.parks@triometric.net> wrote:
> I've recently developed a prototype JDBC Data Set component that is
> analogous to the CSV Data Set except that the values come from the
> columns in the select or prepared select statement. It uses JDBC
> Connection Configuration just like the JDBC sampler, pre-processor and
> post-processor.

It would be likely more efficient to extract the variables into a CSV
file just before running the test.
Of course that may not be quite as convenient, and would not work if
the values are dynamic.

> Early on I thought that keep alive and connection age could be
> significant parameters affecting the performance and efficiency of my
> component but when I looked in the source code for the JDBC Connection
> (src/protocol/jdbc/org/apache/jmeter/protocol/jdbc/config/DataSourceElem
> ent.java) I found not only that "Keep-Alive", "Max Connection Age" and
> "Validation Query" have set/get methods but are otherwise not used
> (presumably an aspirational addition to the component and its beaninfo)
> but also that it uses the now defunct Apache Excalibur as its actual
> JDBC interface: it's only a wrapper.  Rather than dig into another
> source project, and a dead and static one at that, I decided to trust
> JMeter's JDBC Connection Configuration's encapsulation of Excalibur and
> hope that the eventually inevitable migration to something else remains
> equally encapsulated and won't break my component.
>
> So that's the long answer. The short answer is that you have no control
> over the status of a given connection and will have to tolerate the
> default behaviour.


> -----Original Message-----
> From: Dzmitry_Kashlach [mailto:dzmitrykashlach@gmail.com]
> Sent: 21 June 2012 15:08
> To: jmeter-user@jakarta.apache.org
> Subject: Re: How to connect to Database from JMeter at the start of the
> test and use the connection in the post processor to insert some data?
>
>  When I had task that was similar to yours, I opened connection to
> database
> via JDBC Connection Configuration once per Thread Group. After that I
> used
> this connection through the whole test. While creating
> JMeter test-plan, I used
> http://community.blazemeter.com/knowledgebase/articles/65143-using-jdbc-
> sampler-in-jmeter-2-6
> How to use JDBC Sampler in JMeter
>
> --
> View this message in context:
> http://jmeter.512774.n5.nabble.com/How-to-connect-to-Database-from-JMete
> r-at-the-start-of-the-test-and-use-the-connection-in-the-post-p-tp567638
> 8p5713661.html
> Sent from the JMeter - User mailing list archive at Nabble.com.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscribe@jmeter.apache.org
> For additional commands, e-mail: user-help@jmeter.apache.org
>

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@jmeter.apache.org
For additional commands, e-mail: user-help@jmeter.apache.org


Mime
View raw message