I'd like to follow clean/hexagonal architecture and therefore I'd like to keep my services/interactors clean of any spring dependencies.
Is it possible to replace the @Component
annotation with a custom annotation and register it with spring, so my new annotation does the same as the built-in @Component
annotation?
An alternative might be to use XML configuration. But I'd like to refrain from that if possible.