You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
WELD-001409: Ambiguous dependencies for type ClassConverterBean with qualifiers @Default
--
at injection point [BackedAnnotatedField] @Inject private org.eclipse.microprofile.config.tck.ClassConverterTest.classConverterBean
at org.eclipse.microprofile.config.tck.ClassConverterTest.classConverterBean(ClassConverterTest.java:0)
Possible dependencies:
- Managed Bean [class org.eclipse.microprofile.config.tck.ClassConverterTest$ClassConverterBean] with qualifiers [@Any @Default],
- Managed Bean [class org.eclipse.microprofile.config.tck.ClassConverterTest$ClassConverterBean] with qualifiers [@Any @Default]
On both [1] and [2] the usage of static inner bean classes, that are added to WEB-INF/lib (see @Deployment) as well implicitly by arquillian, the TCK tests fail with an exception.
The most simple fix would be to turn these bean classes into regular classes, like in the other tests.
In case of ClassConverterTest, both ClassConverterTest and ClassConverterTest$ClassConverterBean are placed in WEB-INF/classes and WEB-INF/lib/foo.jar (note that this is considered a non-portable behavior - see also 12.1. Bean archives)
As a result Weld registers two beans for ClassConverterTest$ClassConverterBean and both satisfy @Inject ClassConverterBean -> ambiguous error
On both [1] and [2] the usage of static inner bean classes, that are added to
WEB-INF/lib
(see@Deployment
) as well implicitly by arquillian, the TCK tests fail with an exception.The most simple fix would be to turn these bean classes into regular classes, like in the other tests.
[1] https://github.com/eclipse/microprofile-config/blob/master/tck/src/main/java/org/eclipse/microprofile/config/tck/ClassConverterTest.java
[2] https://github.com/eclipse/microprofile-config/blob/master/tck/src/main/java/org/eclipse/microprofile/config/tck/ImplicitConverterTest.java
The text was updated successfully, but these errors were encountered: