How to start learning Struts and Hibernate? [closed]

Is it necessary to study Java servlets before studying Struts and Hibernate? Where t begin for Learning Struts and Hibernate. I am just aware with core java.What is required more for it?…………………………………… Hibernate has nothing to do with servlets, so you’re find there. It …

via Java Application Development Tutorial » Search Results » ajax:

How to start learning Struts and Hibernate? [closed]

Is it necessary to study Java servlets before studying Struts and Hibernate? Where t begin for Learning Struts and Hibernate. I am just aware with core java.What is required more for it?
……………………………………

Hibernate has nothing to do with servlets, so you’re find there. It does presume a good knowledge of JDBC, so if you fall short in that space I’d recommend putting off Hibernate until JDBC was comfortable.
I would recommend getting a reading knowledge of servlets before you begin. The information will never hurt you, and it won’t take long. Does that mean you’re ignorant of JSP, too? What about JSTL? That’s a problem.
I’d question learning Struts more. I think it’s a technology on the decline. You’d be better off learning servlets well and sticking with HTML, CSS, JavaScript, and AJAX.
……………………………………

To create a struts 2 and hibernate 4 application you require the following libraries of struts 2 and hibernate 4.
Struts 2 libraries
commons-fileupload-1.2.2.jar commons-lang-2.4.jar commons-lang-3-3.1.jar freemarker-2.3.19.jar ognl-3.0.5.jar struts2-core-2.3.4.1.jar xwork-core-2.3.4.1.jar
Hibernate 4.1.8 libraries
antlr-2.7.7.jar
dom4j-1.6.1.jar
hibernate-commons-annotations-4.0.1.Final.jar
hibernate-core-4.1.8.Final.jar
hibernate-jpa-2.0-api-1.0.1.Final.jar
javassist-3.15.0-GA.jar
jboss-logging-3.1.0.GA.jar
jboss-transaction-api_1.1_spec-1.0.0.Final.jarCreate a web application in Netbeans.
Go to File >New Project>Java Web>Web Application>fill name and location field>Next>Select Server>finish
Now your project is created and display in project tab.
Structure of Project
Now follow these steps……
Step 2: Add all the above jar files in Libraries folder . Step 3: Create a hibernate.cfg.xml file in Source Packages. Step 4: Enter the following code in hibernate.cfg.xml.

“-//Hibernate/Hibernate Configuration DTD//EN”
“http://www.hibernate.org/dtd/hibernate-configuration-3.0.dtd”>


org.hibernate.dialect.MySQLDialect com.mysql.jdbc.Driver jdbc:mysql://localhost:3306/test root root

Please take a look for the following link for more information this is a simple and best way to integrate Struts2 with hibernate 4.1.8
Simple way to implement Struts 2 with Hibernate 4.1.8
……………………………………

It is better to learn Hibernate first. Use it with core Java since you are familiar with it. If you have learned Swing, write a Swing CRUD application in order to see how things work and understand the basic aspects.
Then start with Struts 2. Avoid Struts it still being used but slowly becoming obsolete.
GWT is a nice platform to learn!
……………………………………

Struts is a web application framework using the MVC architecture and Hibernate, a ORM framework. Knowing servlets would be an added benefit in understanding the intricacies. However, it is not a road block for learning Struts or Hibernate. Struts In Action is a good book and following it would give you a good understanding of the framework even if you skip the servlet knowldge.

For more info: How to start learning Struts and Hibernate? [closed]

Java Application Development Tutorial » Search Results » ajax

How to start learning Struts and Hibernate? [closed]

Share this post:

Related Posts

Leave a Comment