Records feedback from JAX London

Brian Goetz brian.goetz at oracle.com
Thu Apr 12 01:13:01 UTC 2018


> Questions included:
> - why not getXxx
> - what about mutability
> - will setters be generated
> - what about overriding hashCode/equals

Yep, these are the usual questions.


> Concerns did clearly go down the JPA route, where database state is
> stored in additional fields in the object today. But it was more
> general than just that, with the use case of being unable to cache an
> expensive field clearly resonating, as was the question of whether its
> worth converting any existing classes to records in a sourcebase if
> only a few actually are convertible.

Yes, getting this right is going to be the tricky bit.  The obvious 
extremes (unrestricted and completely restricted) are both problematic.

The current point is about as restrictive as we can get; easier to 
loosen up than to tighten up.




More information about the amber-dev mailing list