Re: grinder JDBC parallel threads test

olivier merlin <[email protected]> Tue, 25 Nov 2014 12:57:34 +0100
Newsgroups gmane.comp.java.grinder.user
Message-ID <CAFjxuZMuD6+wmZ65xKOEggo45_6drMBzsp=qn9PRz5PwddV5FQ@mail.gmail.com>
http://grinder.sourceforge.net/g3/script-gallery.html#parallel.py
cheers

2014-11-25 3:48 GMT+01:00 Gang Yan <[email protected]>:

> Hi  Olivier
>
>
>
> Can you give sample ? Thanks!
>
>
>
>
>
> *From:* Olivier [mailto:[email protected]]
> *Sent:* 2014年11月25日 2:48
> *To:* grinder-use
> *Subject:* Re: [Grinder-use] grinder JDBC parallel threads test
>
>
>
> Hi,
> Use a modulo 25 on grinder.threadNumber to spread treatment
> Olivier
> ------------------------------
>
> *De : *Gang Yan <[email protected]>
> *Envoyé : *‎24/‎11/‎2014 11:18
> *À : *grinder-use <[email protected]>
> *Objet : *[Grinder-use] grinder JDBC parallel threads test
>
> Hi All:
>
> I have question about parallel threads test JDBC driver. Such as:
>
> I set 50 threads for parallel threads test JDBC driver. 25 threads run
> Database query, 25 threads run Database insert.
>
> Such as:
>
> class TestRunner:
>     def __call__(self):
>         connection = None
>         insertStatement = None
>         queryStatement = None
>
>         try:
>             connection = getConnection()
>             insertStatement = connection.createStatement()
>
>             test1.record(insertStatement)
>             insertStatement.execute("insert into grinder_fun values(%d,
> %d)" %
>                                     (grinder.threadNumber,
> grinder.runNumber))
>
>             test2.record(queryStatement)
>             queryStatement.execute("select * from grinder_fun where
> thread=%d" %
>                                    grinder.threadNumber)
>
>
> Thanks!
>
>
> ------------------------------------------------------------------------------
> Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
> from Actuate! Instantly Supercharge Your Business Reports and Dashboards
> with Interactivity, Sharing, Native Excel Exports, App Integration & more
> Get technology previously reserved for billion-dollar corporations, FREE
>
> http://pubads.g.doubleclick.net/gampad/clk?id=157005751&iu=/4140/ostg.clktrk
> _______________________________________________
> grinder-use mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/grinder-use
>
>
> ------------------------------------------------------------------------------
> Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
> from Actuate! Instantly Supercharge Your Business Reports and Dashboards
> with Interactivity, Sharing, Native Excel Exports, App Integration & more
> Get technology previously reserved for billion-dollar corporations, FREE
>
> http://pubads.g.doubleclick.net/gampad/clk?id=157005751&iu=/4140/ostg.clktrk
> _______________________________________________
> grinder-use mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/grinder-use
>
>

------------------------------------------------------------------------------
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE
http://pubads.g.doubleclick.net/gampad/clk?id=157005751&iu=/4140/ostg.clktrk

_______________________________________________
grinder-use mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/grinder-use