Adrian Crum wrote: > "Public service announcement: Object pooling is now a serious > performance loss for all but the most heavyweight of objects, and even > then it is tricky to get right without introducing concurrency > bottlenecks." > > http://www.ibm.com/developerworks/java/library/j-jtp09275.html?ca=dgr-jw22JavaUrbanLegends
What's cute about this, is that that article is from *before* the factory stuff was added to conditions. > -Adrian > > On 6/9/2010 11:19 AM, Adam Heath wrote: >> Why does EntityCondition create objects from a factory? This means >> that any condition that needs to be created will end up storing the >> object into the global heap, with all the requisite locks and >> contention that occur from that. If a new object was just created, >> however, java1.6 has the ability to allocate it on the stack, when >> then means freeing said object is much more efficient. >> >> I'm suggesting that the global factories for conditions be removed, >> but the actual factory methods themselves should remain. >>