@Injection is not working for CDI bean
问题 I have a CDI bean where I'm using @ConversationScoped. When I try to do an @Inject for the Conversation object, I get a NPE. @ConversationScoped @Named("customerbean") public class CustomerBean implements Serializable { @Inject private Conversation conversation; private static final EntityManagerFactory emf = Persistence.createEntityManagerFactory("ba"); private EntityManager em; private Customer customer; boolean disabled; public CustomerBean() { beginConversation(); customer = new Customer(