At 01:22 19/3/01 -0800, Harmeet Bedi wrote: >A few questions/suggestions >- Would it make sense in the contructor to make a clone of the presmably >unsynchronized <priorityQueue>. Not doing that would impose the burden of >corrent use on the user. I think it is a burden a user can handle as they will mostly do it at the start. CLoning is generally not neccesary at that time and may not be possible for all implementations of PriorityQueue. >- Would it may make sense to sycnhronize the <toString> method. One thread >might do an insert operation and another may grab a snapshot via toString >before the <insert> method finishes. good point - probably would be good ;) >- Does it make sense to use Doug Lea's util.concurrent package for some of >multi threading capabilities or build on that package if there is a need. It >may be a good idea reuse really good libraries if they are avaliable. >util.concurrent does not seem to have any license hangups and has an >excellent reputation. The last time I looked at it, there was some Queue >management facilities >http://g.oswego.edu/dl/classes/EDU/oswego/cs/dl/util/concurrent/intro.html No idea on the license but they are brilliant libraries (have used em before). To be honest the only reason I haven't looked at it for AValon/Phoenix is because most of my servers have simple synchronisation design ;) >- Using JDK 1.3 proxies may provide more general purpose wrapping facility. >Does the avalon/util/ProxyGenerator provide similar facilities ? I don't >think there is a problem in manually writing a few wrappers, but if there >are a lot of wrappers written or likely to be written, it may be better to >generalize that. It could benefit Avalon code and users of Avalon. JDK1.3 proxies add a fair bit of overhead - they were really designed for EJB/CORBA/Other Container implementors etc. ProxyGenerator has less overhead but apparently it has issues on some JVMS (which I have yet to track down). A generic wrapper facility could be usful in the future but probably not required at the moment. At least I don't need it ;) Cheers, Pete *-----------------------------------------------------* | "Faced with the choice between changing one's mind, | | and proving that there is no need to do so - almost | | everyone gets busy on the proof." | | - John Kenneth Galbraith | *-----------------------------------------------------* --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]