Introduction to Spring MVC for Web development

Introduction

What is MVC?

Spring MVC Workflow

Fig. Spring MVC request response Workflow.

Why use Spring MVC over other frameworks?

Annotations In Spring MVC

package com.example;
import
org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
@Controller
public class ExampleController {
// request mappings
}
package com.example;
import
org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
@Controller
public class ExampleController {
@RequestMapping
public String helloWorld() {
return "hello.jsp";
}
}

Conclusion

--

--

Software Engineer

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store