开发者

Hibernate cascade debug options

开发者 https://www.devze.com 2023-01-01 17:19 出处:网络
I have run into various StackOverflowErrors which occur during cascading. These have been 开发者_如何学Cextremely time consuming in debugging because I don\'t know which properties are being cascaded

I have run into various StackOverflowErrors which occur during cascading. These have been 开发者_如何学Cextremely time consuming in debugging because I don't know which properties are being cascaded to cause this recursive behavior. Does anyone know of a log setting or some other form of debugging which could tell me specifically what properties are being cascaded?


In the "log4j.properties" file set the "log4j.logger.org.hibernate" property to "trace":

"log4j.logger.org.hibernate=trace"

This provides TRACE output for Hibernate Cascade.cascade() calls.


It's Depending on the way you have defined the hibernate mapping.

  • If you've defined the mapping via xxx.hbm.xml, then, in the

  • If you've defined the mapping via Java Annotation, you should check the location of your @Cascade annotation and on which field you have this.

0

精彩评论

暂无评论...
验证码 换一张
取 消