How eddy16/simple-springboot-webapp works
This small Spring Boot example provides two browser-facing routes: a REST greeting and a Thymeleaf page. Spring Boot configuration starts the application and scans the webapp package; the page controller supplies a model value and returns a view name. The README documents the MVC/Thymeleaf setup, but the template and stylesheet contents were not sampled, so their detailed bindings are not shown.
Main entry points: SpringBootConfig.java Spring Boot config · SimplePageController.java Page controller · HelloWorldController.java Greeting endpoint · simplepage.html Simple page template
Components 8
Application startup
- Spring Boot config
src/main/java/com/edcg/simple/springboot/webapp/config/SpringBootConfig.java - Spring Boot runtime
Web endpoints
- Greeting endpoint
src/main/java/com/edcg/simple/springboot/webapp/controller/HelloWorldController.java - Page controller
src/main/java/com/edcg/simple/springboot/webapp/controller/SimplePageController.java
Page presentation
- Thymeleaf rendering
- Simple page template
src/main/resources/templates/simplepage.html - Page stylesheet
src/main/resources/static/css/styles.css
Other components
- Browser
Connections 7
- Spring Boot config → Spring Boot runtime: starts
src/main/java/com/edcg/simple/springboot/webapp/config/SpringBootConfig.java - Spring Boot config → Greeting endpoint: scans package
src/main/java/com/edcg/simple/springboot/webapp/config/SpringBootConfig.java - Spring Boot config → Page controller: scans package
src/main/java/com/edcg/simple/springboot/webapp/config/SpringBootConfig.java - Browser → Greeting endpoint: GET /hello/{name}
src/main/java/com/edcg/simple/springboot/webapp/controller/HelloWorldController.java - Browser → Page controller: GET /
src/main/java/com/edcg/simple/springboot/webapp/controller/SimplePageController.java - Page controller → Thymeleaf rendering: returns view
README.md - Thymeleaf rendering → Simple page template: renders
README.md