How can you configure a Spring Boot project to use a different version of a specific dependency than the one provided by the Spring Boot Starter?
- By directly modifying the Spring Boot Starter.
- By adding an exclusion for the specific dependency in the project's build file.
- By creating a custom Spring Boot Starter.
- By deleting the existing Spring Boot Starter.
To use a different version of a specific dependency than the one provided by the Spring Boot Starter, you can add an exclusion for that dependency in the project's build file (build.gradle for Gradle or pom.xml for Maven). This allows you to specify your desired version while still benefiting from the other dependencies provided by the Spring Boot Starter. The other options are not the recommended approaches for version management.
Loading...
Related Quiz
- In what scenario would you use the @Modifying annotation in a Spring Data JPA repository method?
- In a Spring Boot application, the _____ annotation is used to demarcate transaction boundaries.
- How can you enable transaction management in a Spring Boot application?
- In Spring Boot, which annotation is typically used to enable caching in an application?
- What is the significance of the spring-boot-starter-parent in a Spring Boot project's POM file?