Re: GenericPK and EntityCache

2015-03-21 Thread Adrian Crum
Okay, #2 is not a problem. When the GenericPK instance is created it only contains pk fields. I still need to fix #1. Adrian Crum Sandglass Software www.sandglass-software.com On 3/20/2015 6:09 PM, Adrian Crum wrote: I just discovered a serious flaw in the PK cache (EntityCache.java): GenericP

GenericPK and EntityCache

2015-03-20 Thread Adrian Crum
I just discovered a serious flaw in the PK cache (EntityCache.java): GenericPK is used as a cache key. This is bad for two reasons: 1. GenericPK is mutable and its hash code changes over time. It can be made immutable before adding it to the cache. 2. The equals method is implemented by the Gen