If you use @ToString on Entities you may face the problem that some fields were
lazily loaded and if the (Hibernate-)Session is already closed you get an
org.hibernate.LazyInitializationException in the toString()-Method.
We could exclude all lazy loaded fields, but I think it would be better if the
generated toString()-Method catches all exceptions while accessing the fields
and if some exception happens it outputs <Not loadable> ore something like this
for the failed field. A @ToString Method should not throw any exception ;)
Original issue reported on code.google.com by witte...@gmail.com on 9 Oct 2013 at 10:28
Original issue reported on code.google.com by
witte...@gmail.com
on 9 Oct 2013 at 10:28