Chapter 11. Implementing conversations

You've tried the examples in previous chapters and stored and loaded objects inside transactions. Very likely you've noticed that code examples of five lines are excellent to help you understand a particular issue and learn an API and how objects change their state. If you take the next step and try to apply what you've learned in your own application, you'll probably soon realize that you're missing two important concepts.

The first concept we'll show you in this chapter—persistence context propagation—is useful when you have to call several classes to complete a particular action in your application and they all need database access. So far, we had only a single method that opened and closed a persistence ...

Get Java Persistence with Hibernate now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.