spring-bootaspectjspring-initializr

AspectJ dependency missing in spring boot 2.1.1


I was trying to create a new Spring Boot project using start.spring.io. Searching for dependencies, I found that there was no AspectJ starter available. Has this dependency removed/deprecated from Spring Boot starters? Here is a screen shot: Spring boot starter does not show AspectJ dependency

I, however, was able to find the dependency on maven repositories website:

Spring boot starter AOP on maven repository


Solution

  • It was removed indeed. @jwenting explained in a nutshell why. This starer is required if you want to create your own aspect or if you want to use some advanced AOP mode.

    Most users don't need it and whenever a library requires it, its starter brings it automatically. Having a dedicated entry was confusing as we saw a very large amount of users picking this up for no good reason.

    Also, please keep in mind that start.spring.io is not an exhaustive list of what you can do with Spring. We're focusing on the getting started experience only and avoiding cases that could lead to confusion. This one is a good example of the latter.