[concurrency-interest] question on concurrent HashMap

Tim Peierls tim at peierls.net
Fri Nov 3 08:42:54 EST 2006

And see section 9.4 of Java Concurrency in Practice for more on "push" and
thread-safe data models.


On 11/3/06, Joe Bowbeer <joe.bowbeer at gmail.com> wrote:
> On 11/2/06, David Holmes <dcholmes at optusnet.com.au> wrote:
> >
> > I think what Joe was suggesting was a "push" style approach whereby
> > the timer task, after getting updates from the database, posts an event
> > to the Swing event thread that then has each component update itself
> > with the latest data from the map. That way there is no need for the UI
> > updates to wait for fresh data.
> >
> Yes.
> One way to implement this while still preserving the beneficial
> separation of UI from data model would be to add support for listeners
> to the manager.
> Then the UI could register a special "relaying" listener that, when
> notified, would schedule (i.e., invokeLater) the appropriate update
> task on the event thread.
> --Joe
> _______________________________________________
> Concurrency-interest mailing list
> Concurrency-interest at altair.cs.oswego.edu
> http://altair.cs.oswego.edu/mailman/listinfo/concurrency-interest
-------------- next part --------------
An HTML attachment was scrubbed...
URL: /pipermail/attachments/20061103/5e76d02f/attachment.html 

More information about the Concurrency-interest mailing list