Course Spring Boot Masterclass
-
LSP: jdtls
- Install on neovim through :Mason
- config: https://github.com/pavva91/dotfiles/blob/main/.config/nvim/lua/custom/plugins/nvim-jdtls.lua
- Update the "path_to_jar" with locally installed version name: https://github.com/pavva91/dotfiles/blob/main/.config/nvim/lua/custom/plugins/nvim-jdtls.lua#L20
-
DAP: java-debug-adapter
-
Gradle:
- Needs Java 17
sudo pacman -S jre17-openjdk archlinux-java set java-17-openjdk
-
./gradlew bootRun
-
./gradlew bootRun --args='--app.useFakeCustomerRepo=true'
There are 2 servers:
- Tomcat (default)
- Jetty (change pom.xml)
This architecture is structure in layers as follows:
- Client
- REST Layer (POST, GET, PUT, DELETE) (Controllers)
- Service Layer (business logic)
- DAO (Data Abstracion Object) Layer
@Component - Is a singleton (one instance instead of creating multiple instances). Creates one instance that we can then inject @RestController - Is like @Component, but more specific annotation @Service - Is like @Component, but more specific annotation @Repository - Is like @Component, but more specific annotation @GetMapping @PutMapping @PostMapping @Primary @Autowired @Qualifier @Bean - Add configuration steps before a class is initialized @Configuration