I believe the annotation code you gave us is slightly wrong, the return type of
value() method should be
Target as in the code I've put above.
This Spring tutorial and
this tutorial very nicely explain how you can implement this. The name of the bean can be anything, you need to apply your custom qualifier annotation to the bean too, something like this should work: