Sudhanshi
Uploaded by
8 SLIDES
119 VUES
80LIKES

Spring Framework Tutorial for Beginners – Learn Spring

DESCRIPTION

https://data-flair.training/blogs/spring-framework-tutorial/

Télécharger la présentation

Spring Framework Tutorial for Beginners – Learn Spring

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Spring Framework Tutorial for Beginners – Learn Spring In this Spring Framework Tutorial, you will be getting to know an introduction to Spring Framework. Moreover, we are going to study Prerequisites & Audience and History of Spring Framework. At last, we will learn some Pros and Cons of the Spring Framework. So, let’s start the Spring Framework Tutorial. 1. What is Spring Framework? Spring Framework is one of the most popular Java-based application frameworks and it was developed by Rod Johnson back in 2003. Spring

  2. Framework is an open source framework that we use to develop Java applications with very ease and with a rapid pace. It is a very lightweight framework which provides well-defined infrastructure support for developing Java application. In other words, you can say that Spring handles the infrastructure so, that you can focus more on developing your application. Also, Spring is modular in nature which means that you can use the parts that you need instead of using the whole of it. Using Spring Framework, you can build Java applications as well as Web applications (by using extensions). The above diagram is about the Spring Framework. Spring uses Plain Old Java Project that is POJO and applies enterprise services to it. Spring aims to make J2EE development easier and faster. 2. Learn Spring Framework – Prerequisites & Audience

  3. This Spring Framework tutorial is for Java programmers with the need to understand and work with Spring Framework. Before starting with Spring, one should have good knowledge of Java and should be comfortable in writing Java code. Also, the basic working and understanding of Eclipse or Java Netbeans should be there. 3. Spring Framework Tutorial – Versions/History Now, in Spring Framework Tutorial, we will discuss the history of Spring framework. Since the introduction of Spring Framework in 2003 by Rod Johnson, there are several developments that have taken place in the framework. In June 2003 Spring was released under Apache2.0 license. The first milestone release 1.0 was in March 2004 with further milestones releases in September 2004 and March 2005. The Spring 2.0 was released in October 2006, Spring 2.5 in November 2007 and Spring 3.0 in December 2009. In December 2013 the Spring 4.0 was released which included support for Java SE8, Groovy2, some aspects of Java EE7 and WebSocket. The extensions of 4th versions that are Spring 4.2.0 and Spring 4.2.1 were released in July 2015 and September 2015 respectively. The 4.2.1 version focuses on core refinements and the latest web capabilities. The latest version 4.3 has been released on 10 June 2016 which will be supported till 2020 and will be the final generation of the 4th version. Version 5 is said to be built upon Reactive Streams.

  4. The below diagram will tell the important dates and milestones which achieve during the development of Spring Framework since its launch in 2003. 4. Spring Framework Modules In this Java Spring Framework Tutorial, we are going to study important modules of Spring Framework:

  5. a. Dependency Injection and Inversion of Control These are design patterns that use discard dependencies from the code which makes the code easy to maintain and test. Consider the following example code: – class Student { Address address; Student() { address=new Address(); } } The above example code shows the dependency between the Student and the Address. You can say that Student and Address are tightly coupled. The Ioc makes the code loosely coupled. We can also type the above example as follow: – class Student { Address address; Student(Address address)

  6. { this.address=address; } } In Spring Framework, the IoC container is use for injecting dependencies. Using XML files or annotations you can provide metadata to the IoC container. b. Aspect Oriented Programming Aspect Oriented Programming(AOP) is an important part of the Spring Framework. The Aspect Oriented Programming is used for separating cross-cutting concerns (for example logging, security, etc.) from the business logic of the application. c. Model-View-Controller (MVC) It is an HTTP and servlet-based framework which provides customization for web applications. d. Transaction Management TM is use to unify several transaction management APIs and use to coordinate transactions for Java objects.

  7. 5. Advantages & Disadvantages of Spring In this Spring Framework tutorial, we are going to explore the limitations/benefits of the Spring Framework. a. Advantages of Spring Framework After the brief introduction to you will be getting to know the benefits of Spring framework which are as follow: – ● It is lightweight in nature due to its POJO implementation which doesn’t force to inherit any class or implement any interfaces. ● Spring Framework supports other frameworks and its integration makes Spring easier to develop. ● The Spring application is loosely coupled due to Dependency Injection. ● The Spring Framework is easier to test and it doesn’t require any server to run the application. ● It provides a powerful abstraction to JavaEE Specifications like JDBC, JTA, etc. ● Spring can remove the creation of the singleton and factory classes. ● Spring framework takes the best practices in all applications and formalizes them as design patterns. b. Disadvantages of Spring Framework These are some limitations of Spring Framework, let’s discuss them: ● The learning curve for Spring Framework is very high as most developers find it hard to understand and apply.

  8. ● The nature of Spring Framework keeps changing over the course of time which makes it harder to grasp. For example, the annotation-based Spring is not everybody’s cup of tea. ● For many its a time-consuming process as Spring Framework has lots of integration with other frameworks due to which it is hard to know all the options which are available. Read More about the Advantages & Disadvantages of the Spring Framework So, this was all about Spring Framework Tutorial. Hope you like our explanation. 6. Summary In this Spring Framework Tutorial, you learned what is Spring Framework is and what are the important components of the Java Spring Framework. You also got to know how important Spring is and what are advantages of Spring Framework over other Java-based frameworks. Also, you got to know about the shortcomings of Spring and the versions of it since its initial release.

More Related
SlideServe
Audio
Live Player
Audio Wave
Play slide audio to activate visualizer