-
Bug
-
Resolution: Obsolete
-
Major
-
None
-
1.1.0.CR3
-
-
-
Medium
Here is the problem.
I've got @Typed class becouse I wanted to limit the set of proxies generated by weld becouse it's ancestors would not be proxyable. That's why I tried @Typed. And halfway it works. But just halfway. The problem I notice is here in Validator (lines 142-145)
if (normalScoped && !Beans.isBeanProxyable(bean))
{ throw Proxies.getUnproxyableTypesException(bean.getTypes()); }My @Typed class which is annotated like this:
@Named("catalogEntityHome")
@ConversationScoped
@Typed(CatalogEntityHome.class)
public class CatalogEntityHome extends BasicDAO<CatalogEntity, ObjectId> implements Serializable {
..
The problem I observe is that Beans.isBeanProxyable checks Proxies.getUnproxyableTypesException(bean) which somehow produces non-null result. However a moment later it checks Proxies.getUnprox....(bean.getTypes()), which turns to be null. And that's what it tries to throw, like here:
09:32:58,035 ERROR [org.jboss.kernel.plugins.dependency.AbstractKernelController] Error installing to Start: name=vfs:///C:/servers/jboss-6.0.0.Final/server/default/deploy/test.war_WeldBootstrapBean state=Create: java.lang.NullPointerException
at org.jboss.weld.bootstrap.Validator.validateBean(Validator.java:144) [:6.0.0.Final]
at org.jboss.weld.bootstrap.Validator.validateRIBean(Validator.java:162) [:6.0.0.Final]
at org.jboss.weld.bootstrap.Validator.validateBeans(Validator.java:377) [:6.0.0.Final]
at org.jboss.weld.bootstrap.Validator.validateDeployment(Validator.java:363) [:6.0.0.Final]
at org.jboss.weld.bootstrap.WeldBootstrap.validateBeans(WeldBootstrap.java:388) [:6.0.0.Final]
at org.jboss.weld.integration.deployer.env.helpers.BootstrapBean.boot(BootstrapBean.java:92) [:6.0.0.Final]
- relates to
-
WELD-1192 NPE in Validator.validateBean() when bean annotated with @Typed
- Resolved