-
1. Re: Logger injection in JBoss 6 Final ?
isonisak Jan 5, 2011 1:33 AM (in response to isonisak)Hai
This problem is not Seam version or platfrom spesific.
Probably the cause is that appropriate class where query is started is not injected by Seam. This is bad architecture for new Seam users and I suggest that seam-gen is changed so, that server methods are called from UI so, that @Logger works.
Why is the class not Seam injected although there is annotation @Name ?
This requires that methods are instantiated from UI with #{bean.method} notation that causes, that Seam catches the call and injects Logger etc.
Am I right ?
-
2. Re: Logger injection in JBoss 6 Final ?
stefanotravelli Jan 5, 2011 3:19 AM (in response to isonisak)Since Seam components are managed components you have to let Seam instantiate them.
Referencing the component in EL is the common way. In some cases you can use Component.getInstance(). -
3. Re: Logger injection in JBoss 6 Final ?
isonisak Jan 5, 2011 3:46 AM (in response to isonisak)OK
I suppose that in Seam documentantion this is not emphasized
enough.Sadly seam-gen produces architecture where @Logger cannot be used everywhere,
so some clarifying is needed.