The SamplingStatCalculator.addSample() method is definitely called
from multiple threads, but I think the rest of the class is probably
only called from a single thread.

addSample() synchronises on calculator, but if another thread accesses
calculator, it will also need to synch.

The easiest would probably be to replace ArrayList by Vector in
StatCalculator, and then synch any transactions using it.

S.
On 07/09/05, Peter Lin <[EMAIL PROTECTED]> wrote:
> I supppose we could. I should have time this weekend to take a look if no
> one else gets around to it.
> 
> peter
> 
> 
> 
> On 9/7/05, sebb <[EMAIL PROTECTED]> wrote:
> > 
> > Also, the StatCalculator class is documented as being not thread-safe,
> > yet access is not always synchronised. Perhaps it needs to be?
> > 
> > S.
> > On 07/09/05, sebb <[EMAIL PROTECTED] > wrote:
> > > Not quite sure why you changed ArrayList to Vector in
> > > SamplingStatCalculator.java.
> > >
> > > Was it to avoid some additional synchronisation, e.g. in methods such
> > > as getSample() ? 
> > >
> > > S.
> > > On 07/09/05, studdugie <[EMAIL PROTECTED]> wrote:
> > > > I've posted the patch as promised but I'm unsubscribing from the list.
> If
> > > > anyone has any questions, comments, or concerns about the patches
> please 
> > > > email me directly at this email address.
> > > >
> > > > Thank you.
> > > >
> > > > Dane
> > > >
> > > > On 9/7/05, Michael Stover <[EMAIL PROTECTED] > wrote:
> > > > >
> > > > > 2.1.1 : +1
> > > > >
> > > > > On Tue, 2005-09-06 at 17:56 -0400, Peter Lin wrote:
> > > > > > I vote for 2.1.1
> > > > > >
> > > > > > 
> > > > > > peter
> > > > > >
> > > > > >
> > > > > > On 9/6/05, sebb <[EMAIL PROTECTED]> wrote:
> > > > > > >
> > > > > > > I would think within a week or so, depends on what else would be
> worth 
> > > > > > > fixing, plus finding time to do the build, collect votes etc.
> > > > > > >
> > > > > > > By the way, what should it be called?
> > > > > > >
> > > > > > > 2.1.1 or 2.2 or ?
> > > > > > >
> > > > > > > It would be useful to decide that so Bugzilla can be updated in
> > > > > > > advance - should probably get the next version added at the same
> time. 
> > > > > > >
> > > > > > > S.
> > > > > > > On 06/09/05, Peter Lin <[EMAIL PROTECTED]> wrote:
> > > > > > > > I need to write some graph classes to produce the charts and
> graphs, 
> > > > > so
> > > > > > > I
> > > > > > > > thought I might as well extend the aggregate listener. When do
> we
> > > > > plan
> > > > > > > on
> > > > > > > > releasing a new version of 2.1?
> > > > > > > >
> > > > > > > > peter
> > > > > > > >
> > > > > > > >
> > > > > > >
> > > > > > >
> ---------------------------------------------------------------------
> > > > > > > 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]

Reply via email to