• +91 9723535972
  • info@interviewmaterial.com

Hibernate Interview Questions and Answers

Question - How do you integrate Hibernate with Struts2 or Servlet web applications?

Answer -

You can integrate any Struts application with Hibernate. There are no extra efforts required.

  • Register a custom ServletContextListener.
  • In the ServletContextListener class, first, initialize the Hibernate Session, store it in the servlet context.
  • Action class helps in getting the Hibernate Session from the servlet context, and perform other Hibernate task as normal.

Comment(S)

Show all Coment

Leave a Comment




NCERT Solutions

 

Share your email for latest updates

Name:
Email:

Our partners