jmeter-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Shmuel Krakower <shmul...@gmail.com>
Subject Re: Creating a Shared context between threads
Date Thu, 11 Oct 2012 07:00:13 GMT
How about the existing bsh.shared name space? I use it like this to even
share objects between thread groups in beanshell:

MyClass UI = new MyClass();
// Saving object to allow using it later for cleanup in tearDown phase.
bsh.shared.UI = UI;


Best,
Shmuel.

On Wed, Oct 10, 2012 at 11:57 PM, Philippe Mouawad <
philippe.mouawad@gmail.com> wrote:

> I agree with you.
>
> I was thinking of something like:
>
>    - Loading a file in a setup Thread group which would contain a
>    Map<String, List<String>> (ID to List of IDs map), groupID <=> IDs
> children
>    of group in a parent/child hierarchy
>    - And then in regular thread group access map by ID to get List of other
>    ID and use them in a Loop Controller
>
>
> Use case emerged from here, but I am not saying it's the best solution to
> the case presented there:
>
>    -
>
> http://stackoverflow.com/questions/12827079/read-a-string-from-a-file-with-a-dynamic-name-in-jmeter
>
>
> Regards
> Philippe
>
> On Wed, Oct 10, 2012 at 11:45 PM, sebb <sebbaz@gmail.com> wrote:
>
> > On 10 October 2012 22:38, Philippe Mouawad <philippe.mouawad@gmail.com>
> > wrote:
> > > Hello,
> > > I was wondering if there is in JMeter a way to put an Object in a
> context
> > > shared by all threads ?
> > >
> > > Something like JMeterUtils.setProperty() but which would accept an
> Object
> > > as value.
> > >
> > > Wouldn't be interesting to have that ?
> >
> > The synchronisation issues would certainly be interesting ... what is
> > the use case?
> >
> > > --
> > > Cordialement.
> > > Philippe Mouawad.
> >
>
>
>
> --
> Cordialement.
> Philippe Mouawad.
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message