Thanks, Scott. Would you give out a snapshot and I will do some stress
test on it.

-Wesley

2010/11/30 Scott Ferguson <f...@caucho.com>:
> Thanks. I've fixed it for the next release (changing to ConcurrentHashMap)
>
> - Scott
>
> Wesley Wu wrote:
>> Or this method sync the wrong map?
>>
>> private Set<Bean<?>> resolveAllBeans()
>>   {
>>     synchronized (_beanMap) {
>>       LinkedHashSet<Bean<?>> beans = new LinkedHashSet<Bean<?>>();
>>
>>       for (ArrayList<TypedBean> comp : _selfBeanMap.values()) {
>>         for (TypedBean typedBean : comp) {
>>           beans.add(typedBean.getBean());
>>         }
>>       }
>>
>>       return beans;
>>     }
>>   }
>>
>> maybe should synchronized (_selfBeanMap) instead.
>>
>> -Wesley
>>
>>
>> 2010/11/30 Wesley Wu <wumen...@gmail.com>:
>>
>>> 2010-11-30 02:35:13.697 ERROR [Thread-48]
>>> c.b.c.j.MessageReceiverDaemon -
>>> java.util.ConcurrentModificationException
>>>        at java.util.HashMap$HashIterator.nextEntry(HashMap.java:977)
>>>        at java.util.HashMap$KeyIterator.next(HashMap.java:1012)
>>>        at java.util.HashMap.buildCache(HashMap.java:590)
>>>        at java.util.HashMap.resize(HashMap.java:576)
>>>        at java.util.HashMap.addEntry(HashMap.java:939)
>>>        at java.util.HashMap.put(HashMap.java:477)
>>>        at 
>>> com.caucho.config.inject.InjectManager.addBeanByType(InjectManager.java:720)
>>>        at 
>>> com.caucho.config.inject.InjectManager.addBeanByType(InjectManager.java:697)
>>>        at 
>>> com.caucho.config.inject.InjectManager.addBeanImpl(InjectManager.java:1205)
>>>        at 
>>> com.caucho.config.inject.InjectManager.addBean(InjectManager.java:1163)
>>>        at 
>>> com.caucho.config.inject.InjectManager.addBean(InjectManager.java:1133)
>>>        at 
>>> com.caucho.config.inject.InjectManager.addDiscoveredBean(InjectManager.java:3156)
>>>        at 
>>> com.caucho.config.inject.InjectManager.discoverBeanImpl(InjectManager.java:3128)
>>>        at 
>>> com.caucho.config.inject.InjectManager.processPendingAnnotatedTypes(InjectManager.java:2868)
>>>        at 
>>> com.caucho.config.inject.InjectManager.fillByType(InjectManager.java:1540)
>>>        at 
>>> com.caucho.config.inject.InjectManager.access$200(InjectManager.java:158)
>>>        at 
>>> com.caucho.config.inject.InjectManager$FillByType.apply(InjectManager.java:3929)
>>>        at 
>>> com.caucho.loader.EnvironmentClassLoader.applyVisibleModules(EnvironmentClassLoader.java:703)
>>>        at 
>>> com.caucho.config.inject.InjectManager.getWebComponent(InjectManager.java:1505)
>>>        at 
>>> com.caucho.config.inject.InjectManager.resolveRec(InjectManager.java:1369)
>>>        at 
>>> com.caucho.config.inject.InjectManager.resolve(InjectManager.java:1360)
>>>        at 
>>> com.caucho.config.inject.InjectManager.getBeans(InjectManager.java:1308)
>>>        at 
>>> mdi.java.factory.MDIObjectFactory.buildBean(MDIObjectFactory.java:121)
>>>        at 
>>> com.buysou.cms.jms.MessageDestinationStore$DefaultMessageReceivedCallback.onReceive(MessageDestinationStore.java:168)
>>>        at 
>>> com.buysou.cms.jms.MessageReceiverDaemon.start(MessageReceiverDaemon.java:61)
>>>        at 
>>> com.buysou.cms.jms.MessageReceiverDaemon.run(MessageReceiverDaemon.java:42)
>>>        at java.lang.Thread.run(Thread.java:619)
>>>
>>>
>>
>>
>> _______________________________________________
>> resin-interest mailing list
>> resin-interest@caucho.com
>> http://maillist.caucho.com/mailman/listinfo/resin-interest
>>
>>
>
>
>
> _______________________________________________
> resin-interest mailing list
> resin-interest@caucho.com
> http://maillist.caucho.com/mailman/listinfo/resin-interest
>


_______________________________________________
resin-interest mailing list
resin-interest@caucho.com
http://maillist.caucho.com/mailman/listinfo/resin-interest

Reply via email to