-
1. Re: @Logger - usage question
gavin.king Jun 16, 2006 1:37 AM (in response to jazir1979)stateless session beans do not support @Create and @Destroy methods.
I probably need to document this. -
2. Re: @Logger - usage question
jazir1979 Jun 18, 2006 5:49 PM (in response to jazir1979)That's strange, because my @Create create() method is being called. The stateless session bean in question is being used as a scheduled task (has an @Timeout method), and I'm setting up the timer in the @Create method to fire every second. And it's working... just that the @Logger is not being injected.
thanks for yr response though, I'll do it another way,
Daniel. -
3. Re: @Logger - usage question
jschuetter Jul 25, 2006 1:20 PM (in response to jazir1979)Hi,
logger is not injected on a stateful bean either. Somehow I feel Seam annotations are not correctly processed for @Startup components.
Would like to know as well if anyone has an idea why @Create works on stateless beans?
Thanks a lot
Jens
[Btw, if anyone from Jboss listens, org.jboss.seam.remoting.wrapper.DateWrapper is not registered for remoting in 1.0.1GA --> dates cannot be passed from Javascript] -
4. Re: @Logger - usage question
gavin.king Jul 25, 2006 3:20 PM (in response to jazir1979)OK, you guys are doing something very wrong here. A stateless session bean is supposed to be bound to the STATELESS scope. Hence it cannot have an @Startup annotation, since @Startup applies only to APPLICATION and SESSION scoped components.
-
5. Re: @Logger - usage question
gavin.king Jul 25, 2006 3:21 PM (in response to jazir1979)Btw, if anyone from Jboss listens, org.jboss.seam.remoting.wrapper.DateWrapper is not registered for remoting in 1.0.1GA --> dates cannot be passed from Javascript
Please report this in JIRA. -
6. Re: @Logger - usage question
gavin.king Jul 25, 2006 3:30 PM (in response to jazir1979)Note also that @Startup components are instantiated outside of the context of JSF, so not all functionality is available from the @Create method.
-
7. Re: @Logger - usage question
jschuetter Jul 26, 2006 5:46 AM (in response to jazir1979)Thanks for the quick answer.
I'll post the remoting bug on JIRA once I figured out where to find that.
Maybe it wasn't clear but I do use a stateful session bean not stateless.
@PersistenceContext is injected, @Logger is not.
Jens@Startup @Name("dbCache") @Stateful @Scope(ScopeType.APPLICATION) @Interceptors(SeamInterceptor.class) public class DBCacheBean implements DBCache { @Logger private Log log; @PersistenceContext private EntityManager entityManager;
-
8. Re: @Logger - usage question
gavin.king Jul 26, 2006 1:20 PM (in response to jazir1979)I'll post the remoting bug on JIRA once I figured out where to find that.
http://jira.jboss.com/jira/browse/JBSEAM -
9. Re: @Logger - usage question
gavin.king Jul 26, 2006 1:21 PM (in response to jazir1979)Note that yesterday I committed some changes to CVS so that injection works during the startup phase.
You guys were right, there was a bug there.