High-Performance Java Persistence

High-Performance Java Persistence

Training


Get the most out of your data access layer

Want to run your data access layer at high speeds?

  • 1
    Database Essentials
    Do you know how a relational database systems works behind the scenes?
  • 2
    JDBC®
    Do you know how the JDBC® Driver executes statements and how you can configure it to boost application performance?
  • 3
    JPA and Hibernate®
    Adding JPA and Hibernate® annotations is fairly easy. But, do you know the performance implications of each JPA or Hibernate feature your application makes heavy use of?

Curriculum

The High-Performance Java® Persistence training is aimed to level up your team's data access skills, covering JDBC®, Hibernate®, and many database essential topics for Oracle®, SQL Server®, MySQL® or PostgreSQL®.

Day 1

Introduction

Duration: 1h 45m

  • O/R Mismatch
  • JPA vs. Hibernate
  • Logging SQL Statements 
  • Schema Management 
  • Integration Testing with Testcontainers

Types and Identifiers

Duration: 1h 45m

  • JPA and Hibernate Types
  • Custom Hibernate Types
  • The Hypersistence Utils project
  • JPA and Hibernate Identifiers
  • Hibernate Identifier Optimizers (e.g. hilo, pooled, pooled-lo)

Connection Management

Duration: 1h 45m

  • Connection Management and Hibernate Connection Providers
  • Hibernate Connection Lifecycle
  • Connection Monitoring
  • Hibernate Statistics

Relationships

Duration: 1h 45m

  • JPA and Hibernate Relationships
  • Equals and Hashcode
  • ManyToOne
  • OneToMany
  • OneToOne
  • ManyToMany

Day 2

Inheritance

Duration: 1h 45m

  • JPA Inheritance Basics
  • Single Table Inheritance 
  • Discriminator Column
  • Joined Inheritance
  • TablePerClass Inheritance

Batching and Statement Caching

Duration: 1h 45m

  • Statement Lifecycle and Execution Plans
  • Statement Caching
  • Statement Batching and Cascade Operations
  • Batching Update Operations
  • SQL Injection

Persistence Context

Duration: 1h 45m

  • Persistence Context and Flushing Basics
  • Action Queue
  • The AUTO FlushModeType
  • Dirty Checking Mechanism
  • Bytecode Enhancement Dirty Checking

Fetching

Duration: 1h 45m

  • Direct and Natural id fetching
  • DTO projections vs Entity queries
  • LAZY vs. EAGER
  • Query-time fetching
  • Pagination queries

Day 3

Transactions and Concurrency Control

Duration: 3h 30m

  • ACID
  • Phenomena
    • Dirty Write,
    • Dirty Read,
    • Non-Repeatable Read,
    • Phantom Read,
    • Read Skew,
    • Write Skew,
    • Lost Updates
  • 2PL (Two-Phase Locking)
  • MVCC (Multi-Version Concurrency Control)
  • Isolation levels and database concurrency control
  • Logical vs. physical clock optimistic locking:
    • OPTIMISTIC,
    • OPTIMISTIC FORCE INCREMENT,
    • PESSIMISTIC FORCE INCREMENT,
    • PESSIMISTIC READ,
    • PESSIMISTIC WRITE
  • Versionless optimistic locking
  • JPA physical and optimistic lock types
  • Skip locked and queuing access
  • Preventing lost updates in long conversations

Database, Application and Hibernate Caching

Duration: 3h 30m

  • Database caching
  • Application-level caching
  • Second-level caching
  • Cache synchronization strategies
  • Cache concurrency strategies
    • READ ONLY,
    • NONSTRICT READ WRITE,
    • READ WRITE,
    • TRANSACTIONAL
  • Collection Cache
  • Query Cache

What People Are Saying...

CGM Software Romania

IT Services and IT Consulting

„𝑇ℎ𝑒 𝑡𝑟𝑖𝑐𝑘𝑦 𝑝𝑎𝑟𝑡 𝑤𝑖𝑡ℎ 𝐽𝑃𝐴/𝐻𝑖𝑏𝑒𝑟𝑛𝑎𝑡𝑒 𝑖𝑠 𝑖𝑡 𝑖𝑠 𝑣𝑒𝑟𝑦 𝑒𝑎𝑠𝑦 𝑡𝑜 𝑔𝑒𝑡 𝑠𝑡𝑎𝑟𝑡𝑒𝑑 𝑏𝑢𝑡 𝑣𝑒𝑟𝑦 𝑣𝑒𝑟𝑦 ℎ𝑎𝑟𝑑 𝑡𝑜 𝑚𝑎𝑠𝑡𝑒𝑟. 𝑇ℎ𝑖𝑠 𝑖𝑠 𝑤ℎ𝑒𝑟𝑒 𝑉𝑙𝑎𝑑 𝑀𝑖ℎ𝑎𝑙𝑐𝑒𝑎‘𝑠 𝑤𝑜𝑟𝑘𝑠ℎ𝑜𝑝 𝑐𝑜𝑚𝑒𝑠 𝑖𝑛. 𝑉𝑙𝑎𝑑 𝑖𝑠 𝑎 𝑚𝑎𝑠𝑡𝑒𝑟 𝑜𝑓 𝐻𝑖𝑏𝑒𝑟𝑛𝑎𝑡𝑒 𝑎𝑛𝑑, 𝑖𝑛 ℎ𝑖𝑠 𝑤𝑜𝑟𝑘𝑠ℎ𝑜𝑝, ℎ𝑒 𝑐𝑜𝑣𝑒𝑟𝑒𝑑 𝑖𝑛 𝑎 𝑣𝑒𝑟𝑦 𝑑𝑒𝑡𝑎𝑖𝑙𝑒𝑑 𝑤𝑎𝑦 ℎ𝑜𝑤 𝑡ℎ𝑖𝑛𝑔𝑠 𝑤𝑜𝑟𝑘 𝑖𝑛 𝑑𝑎𝑡𝑎𝑏𝑎𝑠𝑒𝑠 𝑎𝑛𝑑 𝐽𝐷𝐵𝐶. 𝐵𝑒 𝑖𝑡 𝐽𝑃𝐴 𝑚𝑎𝑝𝑝𝑖𝑛𝑔𝑠, 𝐼𝑑𝑒𝑛𝑡𝑖𝑓𝑖𝑒𝑟 𝑔𝑒𝑛𝑒𝑟𝑎𝑡𝑖𝑜𝑛 𝑠𝑡𝑟𝑎𝑡𝑒𝑔𝑖𝑒𝑠, 𝑟𝑒𝑙𝑎𝑡𝑖𝑜𝑛𝑠ℎ𝑖𝑝 𝑐𝑜𝑛𝑓𝑖𝑔𝑢𝑟𝑎𝑡𝑖𝑜𝑛𝑠, 𝑏𝑎𝑡𝑐ℎ 𝑜𝑝𝑒𝑟𝑎𝑡𝑖𝑜𝑛𝑠, 𝑓𝑒𝑡𝑐ℎ𝑖𝑛𝑔/𝑝𝑟𝑜𝑗𝑒𝑐𝑡𝑖𝑜𝑛𝑠, 𝑙𝑎𝑧𝑦 𝑙𝑜𝑎𝑑𝑖𝑛𝑔, 𝑐𝑎𝑐ℎ𝑖𝑛𝑔 𝑒𝑡𝑐... 𝑒𝑣𝑒𝑟𝑦𝑡ℎ𝑖𝑛𝑔 𝑤𝑖𝑡ℎ 𝑙𝑜𝑡 𝑜𝑓 𝑐𝑜𝑑𝑒 𝑒𝑥𝑎𝑚𝑝𝑙𝑒𝑠. 𝐹𝑜𝑟 𝑚𝑎𝑛𝑦 𝑜𝑓 𝑢𝑠 𝑖𝑡 𝑖𝑠 𝑎 𝑏𝑖𝑡 𝑜𝑣𝑒𝑟𝑤ℎ𝑒𝑙𝑚𝑖𝑛𝑔 𝑡𝑜 𝑢𝑛𝑑𝑒𝑟𝑠𝑡𝑎𝑛𝑑 𝑖𝑡 𝑖𝑛 𝑜𝑛𝑒 𝑔𝑜, 𝑏𝑢𝑡 ℎ𝑖𝑠 𝑡ℎ𝑜𝑟𝑜𝑢𝑔ℎ 𝑎𝑛𝑑 𝑚𝑒𝑡ℎ𝑜𝑑𝑖𝑐 𝑤𝑎𝑦 𝑜𝑓 𝑒𝑥𝑝𝑙𝑎𝑖𝑛𝑖𝑛𝑔 ℎ𝑒𝑙𝑝𝑒𝑑 𝑢𝑠 𝑢𝑛𝑑𝑒𝑟𝑠𝑡𝑎𝑛𝑑 ℎ𝑜𝑤 𝑡𝑜 𝑡𝑎𝑐𝑘𝑙𝑒 𝑑𝑖𝑓𝑓𝑖𝑐𝑢𝑙𝑡 𝑠𝑖𝑡𝑢𝑎𝑡𝑖𝑜𝑛𝑠 𝑖𝑛 𝑡ℎ𝑒 𝑓𝑢𝑡𝑢𝑟𝑒. 𝑊𝑒 𝑔𝑎𝑖𝑛𝑒𝑑 𝑛𝑜𝑡 𝑜𝑛𝑙𝑦 𝑎 𝑣𝑎𝑠𝑡 𝑎𝑚𝑜𝑢𝑛𝑡 𝑜𝑓 𝑘𝑛𝑜𝑤𝑙𝑒𝑑𝑔𝑒, 𝑏𝑢𝑡 𝑎𝑙𝑠𝑜 𝑎 𝑓𝑟𝑖𝑒𝑛𝑑”, says Catalin Feidi, Senior Software Developer, Team Lead of CLICKDOC Rework team & BackEnd Functional Lead.

Last week, for 4 days, the BackEnd Community within CGM participated in a very intense and interactive hybrid workshop with the Java Champion Vlad Mihalcea, called 𝐇𝐢𝐠𝐡 𝐏𝐞𝐫𝐟𝐨𝐫𝐦𝐚𝐧𝐜𝐞 𝐉𝐚𝐯𝐚 𝐏𝐞𝐫𝐬𝐢𝐬𝐭𝐞𝐧𝐜𝐞.


It was an amazing experience and it clearly must be done again on the next level. So, Vlad, thank you for everything that you gave to us in these 4 days, from shared knowledge to good vibes. And, as you already know, our doors are always open for you when you get to Iași.

Cloudflight

Cloudflight

B2B digital transformation

What better way to strengthen one's Hibernate skills than with a course in High-Performance Java Persistence with none other than the world-renowned expert, Vlad Mihalcea!

In a 4-part series, each 4 hours long, densely packed with everything from "best practices" to "biggest pitfalls", developers all around Cloudflight got nothing less than wisdom from the best.

We thank Vlad for this great experience and wholeheartedly recommend him to anyone else willing to dig into the nooks and crannies of High-Performance Java Persistence.

Andrei Rosu-Cojocaru

Andrei Roșu-Cojocaru

Software Developer - ABS Laundry Business Solutions

Our company has been delivering an ERP solution for laundries for more than 25 years. Our application uses Oracle, Java, Spring, and JDBC as its backbone.

Most of the performance problems reported by our customers find their root cause in the persistence layer. During his course, Vlad showed us how we should tackle these kinds of issues, breaking up the execution time of a statement into atomic bits and improving the performance for each of them. We found that optimizing the persistence layer is much more than just writing an SQL query as efficiently as possible. The framework allows for a lot of configuration we were not aware of, even in our case, where we are using plain JDBC. There are also some other architectural decisions that might have an amazing impact on the speed, such as caching, batching, or fetching options.

I enjoyed the fact that Vlad successfully managed to deliver custom training tailored to our needs. He had no problem adjusting the content, as he immediately understood our application’s architecture. Although his course contains a lot of information on various DBMSs, such as SQL Server, PostgreSQL, and MySQL (also comparing their performances) and on frameworks such as Hibernate, he focused on the technologies we are currently using and provided a lot of tips and tricks to help us tune our data access layer. The information was delivered at a pace that could be followed by all participants, and he promptly answered all our questions.

The course was delivered online - given the pandemic situation – and we had a very good interaction, with our colleagues being involved in the discussion through periodical Q&A or hands-on exercises.

Vlad offers a repository with an impressive library of integration tests that illustrate each concept presented throughout the course. Given the level of abstraction they provide and the way they were written, using the latest version of Java, taking gain of the latest additions in the JDK, and abiding by the clean code standards, it would not be an exaggeration to say they provide state of the art in this domain. Every developer writing tests should take a look at them to make sure the application is checked for most hidden vulnerabilities.

I highly recommend the High-Performance SQL and Java Persistence Trainings delivered by Vlad for all companies that want to make sure the data management solution in their application is put to proper use!

Sergiu Oltean

Sergiu Oltean

Senior Software Engineer - Winnow Solutions

Every time I had heard that some app needs to be fast, I would have run away from Hibernate. Well, not anymore! After attending Vlad's High-Performance Java Persistence course, I changed my mind.

It was well structured, focused on performance and day-to-day usage. There were lots of details and small things that can really make a huge difference.

Everything was backed up by code examples. Vlad is a smart guy with lots of patience, and he's passionate about technology.

Learn the power of Hibernate! Use it properly!

Mihai Costin

Mihai Costin

Senior Software Engineer - Moqups

I've been using Hibernate for over 8 years in various projects, and I was thinking "what's more to learn about it?". Well, it turns out I was wrong. I've learned a lot after attending Vlad's training.

It was a very educative and enlightening course, backed up by a lot of code samples, answered questions, do's and don'ts in the Hibernate world. There's a huge difference between using Hibernate and using it right.

Elod Balázs

Elod Balázs

Operations Manager - NTT DATA

As Java developers, we all use JPA and inherently Hibernate at one point in time in our projects. Sometimes it happens that some of us just use and abuse this technology.

The presentation has the right topics, order and proper information to get the beginners and the “lost” intermediate user on the right track. You are a senior, and you wonder if it’s the right thing for you? Well, you can get under the hood and understand the underlying mechanisms and implementations used throughout the framework. Moreover, you will learn about advanced topics like caching, locking mechanisms and concurrency control.

I strongly believe that this is a great all-around training when it comes to ORM concepts.

Fit to your needs

There is no limit of students that can enroll in this training. If you have multiple teams that need to attend it, the cheaper it gets per person.

The full training spans 3 days, but it can be adapted to a 1-day or 2-day workshop as well. We can arrange the agenda so that we cover exactly what you need.

All source code is in a GitHub repository which you set up during the training and later use it as a JPA or Hibernate playing ground.


More Testimonials


Call Trade, Switzerland

Postis, Romania

JDK.io, Danmark

Voxxed Days, Bucharest

Viva Credit, Romania

I've also been doing training and workshops at various software conferences.

Check out the following links for more details.




Contact me

Let me teach you how to run your data access layer at high speeds!


If you want to book a training session,

you should email me at vlad@vladmihalcea.com

and discuss it in more detail.

Oracle®, Java®, MySQL® are registered trademarks of Oracle and/or its affiliates.

Microsoft® SQL Server® – Microsoft and Microsoft SQL Server are either registered trademarks or trademarks of Microsoft Corporation in the United States and/or other countries.

PostgreSQL is a trademark or registered trademark of PostgreSQL Global Development Group.

Hibernate® is a trademark of Red Hat, Inc.

Spring® is a trademark of Broadcom Inc. and/or its subsidiaries.

jOOQ™ is a trademark by Data Geekery™ GmbH.

GitHub is a trademark of GitHub, Inc.