Training

Hibernate performance tuning

Hibernate is one of the most popular enterprise frameworks today and is used on almost every project. Unfortunately, though, using the framework incorrectly or inefficiently leads to performance problems. And because Hibernate sits in front of the database, these problems are among the most critical. This training will teach you how to measure performance and introduce you to various ways to optimize it. Having used Hibernate on various projects, I’ve come across the common mistakes developers make. I’ll show you how to fix them effectively with real-world examples. Rather than dry theory, the training is built on practical examples that show the nuances, bugs, and pitfalls you may run into in your day-to-day work. You’ll also learn how Hibernate works under the hood. There will be live coding and exercises, so you can practice and reinforce what you’ve learned.

Who this training is for:

This is not an introductory training: if you’re only planning to start working with Hibernate or have only recently started, this training isn’t for you. It centers on examples drawn from my own experience. The focus is on the pitfalls and problems you may run into, not on theory. This training is for you if:

  1. You work with Hibernate, feel that you don’t understand how the framework behaves, and are tired of feeling that way.
  2. You want to learn how to use Hibernate effectively.
  3. You want to learn how to optimize performance.
  4. You want to find out how the framework works under the hood.

Technical prerequisites: a basic knowledge of JPA/Hibernate (an understanding of what ORM is and what problems Hibernate solves; what SessionFactory, Session, EAGER, LAZY, LazyInitializationException, HQL, and SQL are; and basic familiarity with @Entity, @Column, and other annotations).

It’s a good idea to watch the following videos:

  1. Hibernate, how the magic is really done? (Mikalai Alimenkou and Igor Dmitriev)
  2. Hibernate performance tuning (Igor Dmitriev and Mikalai Alimenkou)
Target audience
Java developers, tech leads
Price
$350per participant
Date and time
16 hours / 2 days

Book for your company

Detailed program

  1. Efficient entity mapping (useful annotations, sequences, lazy vs. eager loading, proxies, advanced entity mappings)
  2. Different ways to measure performance (StatementInspector, P6Spy, etc.)
  3. Performance problems and their solutions (the N+1 problem, Cartesian products, fetching strategies, etc.)
  4. Processing large volumes of data (batch processing, fetching, scrolling, stateless sessions, bulk operations)
  5. Read-only operations (dirty checking, bytecode enhancement, projections, read-only queries and transactions, result transformers)
  6. Querying (HQL or native queries, criteria queries, doWork, views, advanced query options, customizing SQL)
  7. Caching (first-level cache, second-level cache, query cache)
  8. Transactions and concurrency control
  9. Migrating to Hibernate 6+ (benefits, migration pitfalls)

Past runs

  • July 21-22, 2017Kyiv, Ukraine