Using hibernate to continue writing code to deal with the association is very complicated. Considering using association ing.
The first use is the notorious lazyinitializationexception, so refer to hibernate's best practice to use the open-session-in-view method.
Http://www.jroller.com/cardsharp/entry/open_session_in_view_pattern
This article is true: it seems inappropriate to expose the back-end processing mechanism in the presentation layer, but it is so transparent and easy to use.
As for performance, there are many discussions online. Theoretically, there is an impact. However, to what extent? What kind of pressure threshold will be reached?
For internal enterprise applications, no more than 10,000 users should be the bottleneck.
After all, the current application software development is more challenging in terms of development speed and code maintainability.
PS:
Configuring:
Org. springframework. Orm. hibernate. Support. opensessioninviewfilter
~~~~~~~
To be modified
Org. springframework. Orm. hibernate3.support. opensessioninviewfilter
When there are several configurations, the class not found will be caused by the missing 3.