Java EE 8 and Angular
上QQ阅读APP看书,第一时间看更新

The CDI Advantage Combined with JPA

In this chapter, we will go over CDI, which has become a ubiquitous API for dependency injection and context management in Java EE. We will be looking at the new CDI 2.0 features along with the earlier ones, which are shipped with Java EE 8. Having completed the CDI journey, we will move onto the standard persistence solution, Java Persistence API (JPA) for Java applications.

The topics covered will be:

  • The CDI programming model:
    • CDI for Java SE 8
    • RequestContext activation
    • Event enhancements:
      • Asynchronous events
      • Ordered events
    • Annotation Literals
  • JPA:
    • Entities
    • Performing CRUD operations with entities
    • Entity listeners
    • Validations in entities