更新时间:2023-12-04 21:02:40
@EJB注释仅适用于应用程序服务器控制的类,如servlets,mdbs,其他ejbs 。
我猜测UsuarioManagedBean是一个pojo,因此NPE是因为资源永远不会被注入。
The @EJB annotation only works with application-server controlled classes like servlets, mdbs, other ejbs. I'm guessing that UsuarioManagedBean is a pojo and hence the NPE because the resource never gets injected.