I have this following code:
@Stateless
public class Service {
....
@Inject
private Translator <Customer> translator;
....
}
@Default
@ApplicationScoped
public class TheTranslator extends Translator <Customer> {...}
If I remove @ApplicationScoped
I get this error:
java.io.IOException: com.sun.enterprise.admin.remote.RemoteFailureException: Error occurred during deployment: Exception while loading the app : CDI deployment failure:WELD-001408: Unsatisfied dependencies for type Translator with qualifiers @Default at injection point [BackedAnnotatedField] @Inject @Default private com.company.translator at com.companyService.translator(Service.java:0)