It may be worth noting you can workaround the issue with:
session.merge( book );
This is only applicable starting with Hibernate 5.2 with the merging of Hibernate EntityManager into Core.