Understanding JPA 2.2

Understanding JPA 2.2
Другая компьютерная литература, Программы
Год: 2018
Добавил: Admin 1 Авг 20
Проверил: Admin 1 Авг 20
Формат:  PDF (9452 Kb)
  • Currently 0/5

Рейтинг: 0/5 (Всего голосов: 0)

Аннотация

Lots of Java applications use an Object-Relational Mapping (ORM) framework, like Hibernate or EclipseLink, to read data from and to write it to a relational database. As a reader of this fascicle, you might already know that both frameworks implement the Java Persistence API (JPA) specif i cation and that the popular Spring Data JPA project integrates them into the Spring ecosystem. But don’t worry if you’ve never heard about the JPA specif i cation. If that’s the case, I want to congratulate you on your decision to learn about it.
JPA is one of the most popular specif i cations in the Java world. It def i nes an easy-to-use way to map database records to Java objects and to update the database records based on the changes you performed on these Java objects. It also specif i es a query language that you can use to def i ne database queries based on your Java classes. All of these powerful features are relatively easy to use if you know the basic concepts of JPA. That’s why Hibernate and other JPA implementations have become so popular and are used in most enterprise Java applications.
So, it should be evident that, as a professional Java developer or somebody who aspires to become one, you should have a solid understanding of JPA’s general concepts and capabilities.
When Antonio asked me to write this foreword, I more than happily agreed to do it. I still remember reading his blog articles at the relative beginning of my career as a Java developer in the mid-2000s. That makes writing this foreword something special. His ability to explain complex features in an easily understandable way still amazes me, and it made me a long-time reader and follower of his work.
I obviously wasn’t the only one who liked his style of teaching and writing. In 2007, he wrote and published his f i rst book about Java EE 5. And that was just the beginning. During the following years, he wrote 3 additional books and recorded 7 video courses teaching Java developers various Java EE specif i cations, like JPA or Bean Validation. He also worked as an expert group member on various Java EE specif i cations and co-created the Devoxx France and the Voxxed Days Microservices conferences. Antonio is clearly a prolif i c member of the Java EE community, and that’s just one of the reasons why he became a Java Champion.
Several years into my career, after I learned as much about JPA and Hibernate as I could, and after I became a freelance consultant and trainer specialised in solving Java persistence problems, I f i nally met Antonio at a speaker’s dinner in Prague. And let me tell you, he not only has an impressive knowledge about Java EE technologies and knows how to share it with other developers, but he is also a great guy who’s fun to hang out with. This was just one of the various reasons why I happily agreed to proofread this fascicle and to write this foreword.
But let’s get back to this fascicle.
The JPA specif i cation def i nes a vast feature set that makes working with a relational database simple and complex at the same time. It only takes a few annotations to implement robust and ef f i cient mappings. You can then focus on your business code, and the JPA implementation takes care of all the nitty-gritty details.
But it only works that way if you’re familiar with the general concepts of the specif i cation. You need to know how the internal life cycle model works, which annotations you need to use and all the defaults that your JPA implementation applies.
Antonio does a great job explaining all of it in this fascicle. He f i rst shows you the necessary conf i guration parameters and mapping annotations that you need in order to start implementing your f i rst persistence layer. After that, Antonio explains the dif f erent query capabilities def i ned by the JPA specif i cation before he dives into its more advanced features, like life cycle events and caching.
And after you’ve learned about all the features specif i ed by the JPA specif i cation, you should pay special attention to Chapter 10. There, Antonio shows you how to use your new knowledge to implement and test a small application so that you are well prepared to use JPA in your own projects.

Похожие книги

Комментарии к книге "Understanding JPA 2.2"

Комментарий не найдено. Будьте первыми!
Чтобы оставить комментарий или поставить оценку книге Вам нужно зайти на сайт или зарегистрироваться