依赖注入问题解决:No bean is eligible for injection to the injection point [JSR-299 §5.2.1]


症状:


Eclipse + JSF(CDI) + JBoss7/WildFly + JPA...

CDI注入时报错.


Eclipse 报错如下:

No bean is eligible for injection to the injection point [JSR-299 §5.2.1]

依赖注入问题解决:No bean is eligible for injection to the injection point [JSR-299 §5.2.1]


问题解决:

将[ JBoss Tools Project Validator ] 关闭:


Eclipse -> [ Window ] -> [ Preferences ] -> [ Validation ] -> [ JBoss Tools Project Validator  ] 右键 disable


依赖注入问题解决:No bean is eligible for injection to the injection point [JSR-299 §5.2.1]


原因:

尚不明确。


参考资料:

https://www.ibm.com/developerworks/community/forums/html/topic?id=77777777-0000-0000-0000-000014642982&ps=100&tags=&query=&filter=