#1864 - L2 cache miss for natural key property of type UUID

This commit is contained in:
rob bygrave
2019-11-17 17:06:38 +13:00
parent 9b0dd2b0c4
commit c2a30f786f
6 changed files with 122 additions and 14 deletions
@@ -66,11 +66,7 @@ public class BeanNaturalKey {
*
* @param map The bind values for the properties.
*/
public Object calculateKey(Map<String, Object> map) {
if (naturalKey.length == 1) {
return map.get(naturalKey[0]);
}
public String calculateKey(Map<String, Object> map) {
StringBuilder sb = new StringBuilder();
for (BeanProperty prop : props) {
sb.append(prop.naturalKeyVal(map)).append(";");