Hi Tibor, Tibor Mlynarik a écrit : > Hi, > > I have noticed code in JSONEntityState that seems suspicious for me. > > In method JSONEntityState#cloneStateIfGlobalStateLoaded > if parts are swapped. > > I suppose that by global state is meant copy taken from cache that is shared > across UoWs. > And before first entity change own copy for UoW should be cloned. > > But as it is now, cloning is not done at first change and redundantly > executed with each entity change. > Also maybe whole cloning could be avoided if cache is not used. > > Or am I wrong in understanding of purpose of this state clone ? IIRC this is the sole purpose of this state clone. As you pointed out there may be room for improvements here.
Niclas, WDYT? /Paul
