[JBoss Seam] - Re: MDB's and EJB Timers
by bsmithjj
after @Naming my MDB's as Seam components:
| 2007-02-07 11:40:03,215 ERROR [org.jboss.jms.asf.StdServerSession] session failed to run; setting rollback only
| java.lang.RuntimeException: java.lang.IllegalStateException: Attempted to invoke a Seam component outside the context of a web application
| at org.jboss.ejb3.interceptor.LifecycleInterceptorHandler.postConstruct(LifecycleInterceptorHandler.java:109)
| at org.jboss.ejb3.EJBContainer.invokePostConstruct(EJBContainer.java:582)
| at org.jboss.ejb3.AbstractPool.create(AbstractPool.java:108)
| at org.jboss.ejb3.ThreadlocalPool.get(ThreadlocalPool.java:48)
| at org.jboss.ejb3.stateless.StatelessInstanceInterceptor.invoke(StatelessInstanceInterceptor.java:54)
| at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
| at org.jboss.ejb3.mdb.MDB.localInvoke(MDB.java:865)
| at org.jboss.ejb3.mdb.MDB.localInvoke(MDB.java:844)
| at org.jboss.ejb3.mdb.MDB$MessageListenerImpl.onMessage(MDB.java:1074)
| at org.jboss.jms.asf.StdServerSession.onMessage(StdServerSession.java:266)
| at progress.message.jimpl.Session.dU_(Unknown Source)
| at progress.message.jimpl.Session.run(Unknown Source)
| at org.jboss.jms.asf.StdServerSession.run(StdServerSession.java:196)
| at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(PooledExecutor.java:743)
| at java.lang.Thread.run(Thread.java:595)
| Caused by: java.lang.IllegalStateException: Attempted to invoke a Seam component outside the context of a web application
| at org.jboss.seam.contexts.Lifecycle.getServletContext(Lifecycle.java:413)
| at org.jboss.seam.contexts.Lifecycle.beginApplication(Lifecycle.java:89)
| at org.jboss.seam.Seam.componentForName(Seam.java:228)
| at org.jboss.seam.intercept.SessionBeanInterceptor.postConstruct(SessionBeanInterceptor.java:101)
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:585)
| at org.jboss.ejb3.interceptor.LifecycleInvocationContextImpl.proceed(LifecycleInvocationContextImpl.java:131)
| at org.jboss.ejb3.interceptor.LifecycleInterceptorHandler.postConstruct(LifecycleInterceptorHandler.java:105)
| ... 14 more
|
I posted a message at http://www.jboss.com/index.html?module=bb&op=viewtopic&t=100946 - hopefully that's a reasonable place to post it.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4012543#4012543
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4012543
19Â years, 2Â months
[JBoss Seam] - Re: Issues moving from Seam 1.1.0 to Seam 1.1.5
by bsmithjj
| log.info("findUserByUserid() : found users -> " + evergreenUsers);
|
here is the whole method:
| public String findUserByUserid() {
| log.info("findUserByUserid() : anumber = " + evergreenUser.getAnumber());
| log.info("findUserByUserid() : lastqry = " + lastQueryText);
|
| if (evergreenUser.getAnumber().trim().length() < 5) {
| facesMessages.add("anumber", "You must enter at least the first 5 characters of the employee id");
| return "";
| }
|
| if (!this.lastQueryText.equalsIgnoreCase(evergreenUser.getAnumber())) {
|
| this.lastQueryText = evergreenUser.getAnumber();
| QueryEPeopleUtil util = new QueryEPeopleUtil(this.lastQueryText);
| boolean pattern = util.isQueryValidUid() & util.getQuery().length() < 7;
| this.evergreenUsers = util.findUsersForUid(pattern);
| if (util.getMessage() != null) {
| this.facesMessages.add("anumber", util.getMessage());
| }
| log.info("findUserByUserid() : found users -> " + evergreenUsers);
| }
| return "search_results";
| }
|
Thanks
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4012540#4012540
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4012540
19Â years, 2Â months
[JBoss Seam] - Seam and granularity
by viniciuscarvalho
Hello there! Just started here, yesterday some folks gave me some help on my first question. Now I have another architectural question: I know I'm free to not use each managed bean as a SLSB, I could use my managed bean as a facade to a remote object and have the SLSB injected inside my managed bean, which would lead me to a coarse grained SLSB. Using each managed bean as a SLSB turns in a very fine grained SLSB. Normally the rule of thumb we use in projects here is to have 1 SLSB per requirement, which groups 3-5 use cases (we have fine grained use cases, we are at sea level according to Cockburn). Now, having so many SLSB wouldn't be a burden for my AS? JBoss has an MBean for each SLSB conteiner right? So in a typical app where I would have some actions/managed beans and few SLSB, I'd change it to a lot of SLSB (maybe not that much) inside my conteiner.
I'm pretty sure, Seam designers worry about performance. I'm just a pretty concerned about this issue. Am I being paranoid?
Best regards
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4012532#4012532
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4012532
19Â years, 2Â months