openwebbeans-user mailing list archives

UnsatisfiedResolutionException Api type is not found with the qualifiers

Date

Wed, 27 Jun 2012 11:13:20 GMT

Hi everyone,
im facing an issue with OWB(works with weld) that i cant inject a field and i want to know
if im doing something wrong, the stacktrace can be found here: http://pastebin.com/Uq5ujzWC
Ill try to explain what im doing:
Here is the implementation of the class which is failing to be injected.
public class UsuarioServiceImpl extends CustomHibernateService<Usuario, Long> implements
UsuarioService {code here:https://github.com/rmpestano/conventions-issuetracker/blob/master/src/br/com/triadworks/issuetracker/service/impl/IssueServiceImpl.java}
here is the interface:
public interface UsuarioService extends BaseService<Usuario, Long>{ }
here is the superclass:
@Named
@CustomService
public class CustomHibernateService<T,K extends Serializable> extends BaseCustomServiceImpl<T,
K> implements BaseService<T, K> {code and related classes here:http://code.google.com/p/jsf-conventions-framework/source/browse/ConventionsCore/src/main/java/com/jsf/conventions/service/impl/CustomHibernateService.java
}
the qualifier:
@Qualifier
@Retention(RUNTIME)
@Target({METHOD, FIELD, PARAMETER, TYPE})
public @interface CustomService {
@Nonbinding
Class entity() default byte.class;
}
and finally the injection point:
@Inject @CustomService(entity=Usuario.class)
private BaseService usuarioService;
@Inject @CustomService(entity=Projeto.class)
private BaseService projetoService;
Do you have any idea? if you need more information just tell me.
here is the project where this injection works(weld as cdi impl): https://github.com/rpestano/conventions-issuetracker/blob/master/issuetracker/src/br/com/triadworks/issuetracker/controller/ComboBean.java
also in this project i have no problems with this approach: http://code.google.com/p/jsf-conventions-framework/source/browse/ConventionsShowcase/src/main/java/com/jsf/conventions/showcase/controller/ComboMBean.java
and here is the project where it is failing: https://github.com/rmpestano/conventions-issuetracker/blob/master/src/br/com/triadworks/issuetracker/controller/ComboBean.java (note
that im 'workaround' the exception by injecting specific services)
thanks in advance.
Att,
Rafael M. Pestano
Desenvolvedor Java Cia. de Processamento de Dados do Rio Grande do Sul
Graduando em Ciência da Computação UFRGS
http://code.google.com/p/jsf-conventions-framework/
http://rpestano.wordpress.com
http://twitter.com/realpestano