I have found this question: What is the difference between @Inject and @EJB but I did not get any wiser. I have not done Java EE before nor do I have experience with dependency injection so I do not understand what I should use?
Is @EJB
an old way of injecting? Is the injection done by the EJB container when using this annotation while using @Inject
use the new CDI framework? Is that the difference and should I be using @Inject
instead of @EJB
if this is the case?