This content has been marked as final.
Show 3 replies
-
1. Re: DatabaseInitialization after Component creation
joaobmonteiro Jun 23, 2008 3:06 PM (in response to mika)Hi,
If you need a dao instance in initDatabase(), you have to create it first using @In(create=true) DAO dao
I hope it helps
-
2. Re: DatabaseInitialization after Component creation
mika Jun 23, 2008 8:39 PM (in response to mika)The dao is null even if I add @In(create=true).
-
3. Re: DatabaseInitialization after Component creation
stefanotravelli Jun 24, 2008 12:34 AM (in response to mika)Your initialization method should listen to the
org.jboss.seam.postInitialization
in order to have other components injected. Try with this:@Transactional @Observer("org.jboss.seam.postInitialization") public void initDatabase { dao.initDatabase(); }