How to enable devtools in IntelliJ:
- Add the following configuration onto the pom file:
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-devtools</artifactId>
<scope>runtime</scope>
<optional>true</optional>
</dependency>
- Under the section compiler, check the option:
- Finally, under advanced settings/compiler section, check the box:
This is an example of Spring Plugin library applied to an Hexagonal Architecture use case where we're required to introduce another repo implementation that runs in tandem with the existing one.
One of the requirements is to vary the order of execution between implementations, e.g. first db, then http, etc.
One improvement would be to play with the Plugin#supports
method so that some repo implementations can be dynamically
changed based out of a configuration property, although it would required the RepoStrategy#plugins
to be refreshed upon
configuration updates.
This video helped me discover this great library.