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 Docker

Types and Identifiers

Duration: 1h 45m

  • JPA and Hibernate Types
  • Custom Hibernate Types
  • The hibernate-types 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...

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.

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!

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!

Vasile Mihali

Vasile Mihali

Software Architect - AROBS

I actually feel that I had a great opportunity to have Vlad and his experience on-premise for an intensive training (covered with clear examples and explanations) of what Java Persistence is now.

A couple of years ago was, it was simple, few tables and hundred thousand rows. Now persistence metrics (counts) are represented with 10^6+.

The training provided and following Vlad's blog is truly a gold vein in our mining activity of providing effective, efficient, and maintainable applications.

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.

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 an on-site training session,

you should email me at vlad@vladmihalcea.com

and discuss it in more detail.