Estoy intentando hacer algo al inicio usando un ejb de arranque. Pero mi bean nunca se llama.Startup ejb bean no funciona
Este es mi café en grano:
import javax.annotation.PostConstruct;
import javax.ejb.Startup;
import javax.inject.Singleton;
@Singleton
@Startup
public class StartupBean {
@PostConstruct
public void doSomething(){
System.out.println("why??");
}
}
estoy usando JBoss 7.1.1.
¿Qué estoy haciendo mal? Puede encontrar mi código fuente en bitbucket: https://bitbucket.org/cremersstijn/jee/src/9e22ed2b798a/simple-startup-bean