inflearn logo

Answering Spring and JPA Backend Interview Questions—and Follow-Ups—with Code

Everyone gives a similar answer to the first question in a technical interview. The difference comes in the follow-up questions. For each of 12 common Spring/JPA interview questions, we map out three levels of follow-up questions in advance and include key test code and expected results to verify each answer.

1 learners are taking this course

Level Basic

Course period Unlimited

Spring Boot
Spring Boot
JPA
JPA
Java
Java
Tech Interview
Tech Interview
Spring Boot
Spring Boot
JPA
JPA
Java
Java
Tech Interview
Tech Interview

What you will gain after the course

  • A 30-second answer to each of the 12 questions, plus brief answers to three levels of follow-up questions.

  • Core test code that asserts figures to cite in an interview, such as query count and inventory levels.

  • How to Answer When You Don’t Know: A Table for Generating Follow-Up Questions from a Single Line on a Résumé

"Use a fetch join." Can you answer the next question?

Everyone gives similar answers to the first question in a technical interview. The difference emerges in the second and third follow-up questions. “What if pagination is involved?” “Why did it roll back even though I caught the exception?” “What about locks when there are multiple servers?” For each of 12 common Spring and JPA interview questions, this course walks you through three levels of follow-up questions in advance, and includes key test code for verification and the expected results with each answer.

Recommended for these people

  • Java·Spring backend entry-level and junior candidates, and bootcamp graduates

  • For those who have memorized the concepts but get stuck when answering follow-up questions.

  • Those who want to explain the 'JPA performance improvements' and 'transaction management' listed on their resumes with supporting evidence.

  • For those who want to quickly review in text rather than watch a video right before an interview.

Structure of Each Lesson

  1. Questions — exactly as they’re commonly asked

  2. 30-second answer — definition → principle → trade-offs → numerical evidence

  3. Three levels of follow-up questions — a short answer for each, ordered by depth

  4. Verify with code — the key test code and expected results that support your answer

  5. Common wrong answers — things you say in an interview that cost you points

Course List (14 Lessons)

Section 1. Getting Started - Lesson 0. How should you structure technical interview answers? — How to use this course

Section 2. JPA and Transaction Basics - Lesson 1. What is the N+1 problem in JPA, and how can you solve it? - Lesson 2. What happens internally when you add @Transactional? - Lesson 3. Does an exception in a @Transactional method always trigger a rollback? - Lesson 4. What is the persistence context, and what are its benefits? - Lesson 5. Why does LazyInitializationException occur, and how can you resolve it?

Section 3. Advanced Transactions - Lesson 6. Why use @Transactional(readOnly = true)? - Lesson 7. When should you use REQUIRES_NEW among the transaction propagation options, and what should you be careful about?

Section 4. Concurrency and Databases - Lesson 8. What problems can occur when orders come in simultaneously for a product with 100 units in stock, and how can you prevent them? - Lesson 9. Explain transaction isolation levels and the problems that can occur at each level. - Lesson 10. How do you decide the column order when creating a composite index? How can you check whether the index is actually being used?

Section 5. Spring Internals and Authentication - Lesson 11. How are Spring AOP proxies created? What is the difference between JDK dynamic proxies and CGLIB? - Lesson 12. What is the difference between session-based and JWT-based authentication, and which would you choose?

Appendix - Appendix. What follow-up questions might come up about a line on my resume? — A follow-up question table and a chance to try it out yourself

What You’ll Take Away After Completing the Course

  • 30-second answers for each of the 12 questions, plus brief answers to three levels of follow-up questions.

  • Core test code that verifies the numbers you can cite in an interview, such as query counts and inventory levels.

  • How to Answer When You Don’t Know: A Table for Generating Follow-Up Questions from a Single Resume Line

Keep in mind.

  • The code is based on Spring Boot 3.x · Java 21 · Hibernate 6 · H2. It’s written for readers who have built a CRUD API with Spring Boot at least once.

  • The main text includes only the key code, and executable project files are not provided. If you want to run it yourself, the appendix explains how to transfer the code from each lesson into a new project.

  • It does not guarantee that you will pass. It does not cover interview questions from specific companies, algorithm or coding tests, or resume editing.

  • The draft was written with the help of AI (Claude Code). The code in the main text was checked against the example project’s source code and program, and a separate AI review before release checked the facts and wording. The numbers in the main text are expected values asserted by tests, not results from actual executions.

Recommended for
these people

Who is this course right for?

  • Entry-level and junior Java/Spring backend applicants, and bootcamp graduates

  • For those who’ve memorized the concepts but get stuck when asked follow-up questions.

  • Those who want to explain the “JPA performance improvements” and “transaction management” listed on their resumes, with supporting evidence.

  • For those who want to quickly review the material in writing instead of watching a video right before an interview.

Need to know before starting?

  • Experience building a CRUD API with Spring Boot (based on Spring Boot 3.x, Java 21, and Hibernate 6)

Hello
This is Hypothesis Lab

I’m a practicing Java and Spring backend developer. I build backtesting and workflow automation tools in Python, and run development task automation with Claude Code. I turn topics you can use right away in interviews and on the job into concise, easy-to-read text lessons with code.

Reviews

Not enough reviews.
Please write a valuable review that helps everyone!

Similar courses

Explore other courses in the same field!

25% off for new members

$15.40

25%

$15.40