[JBoss Seam] - Embedded Jboss in Tomcat with latest cvs build
by wesleyhales
After going through the instructions here for tomcat 6.x, I am trying to get a simple SSB to run (that previously worked in Embedded EJB RC9) with no luck.
Here it is installed through the Tomcat console:
[Initialization] Installing components...
| [Component] Component: TestAction, scope: STATELESS, type: STATELESS_SESSION_BEAN, class: com.mycompany.TestActionBean, JNDI: Test
But when I hit the page that references this bean (or any page in the webapp) I get the following stack:
INFO: Server startup in 18992 ms
| 18:06:07,530 INFO [Contexts] starting up: org.jboss.seam.security.identity
| 18:06:07,530 INFO [Contexts] starting up: org.jboss.seam.web.session
| 18:06:07,560 ERROR [SeamPhaseListener] uncaught exception
| java.lang.IllegalStateException: Could not start transaction
| at org.jboss.seam.jsf.SeamPhaseListener.begin(SeamPhaseListener.java:569)
| at org.jboss.seam.jsf.SeamPhaseListener.handleTransactionsBeforePhase(SeamPhaseListener.java:308)
| at org.jboss.seam.jsf.SeamPhaseListener.beforeServletPhase(SeamPhaseListener.java:143)
| at org.jboss.seam.jsf.SeamPhaseListener.beforePhase(SeamPhaseListener.java:116)
| at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:249)
| at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:132)
| at javax.faces.webapp.FacesServlet.service(FacesServlet.java:244)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
| at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:70)
| at org.jboss.seam.debug.hot.HotDeployFilter.doFilter(HotDeployFilter.java:63)
| at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:56)
| at org.jboss.seam.web.MultipartFilter.doFilter(MultipartFilter.java:80)
| at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:56)
| at org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:62)
| at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:56)
| at org.ajax4jsf.framework.ajax.xmlfilter.BaseXMLFilter.doXmlFilter(BaseXMLFilter.java:127)
| at org.ajax4jsf.framework.ajax.xmlfilter.BaseFilter.doFilter(BaseFilter.java:277)
| at org.jboss.seam.web.Ajax4jsfFilter.doFilter(Ajax4jsfFilter.java:34)
| at org.jboss.seam.web.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:56)
| at org.jboss.seam.web.SeamFilter.doFilter(SeamFilter.java:127)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
| at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
| at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
| at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
| at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
| at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
| at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:261)
| at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
| at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:581)
| at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
| at java.lang.Thread.run(Thread.java:595)
| Caused by: java.lang.RuntimeException: exception invoking: getTransaction
| at org.jboss.seam.util.Reflections.invokeAndWrap(Reflections.java:134)
| at org.jboss.seam.Component.callComponentMethod(Component.java:1978)
| at org.jboss.seam.Component.unwrap(Component.java:2004)
| at org.jboss.seam.Component.getInstance(Component.java:1791)
| at org.jboss.seam.Component.getInstance(Component.java:1756)
| at org.jboss.seam.Component.getInstance(Component.java:1733)
| at org.jboss.seam.Component.getInstance(Component.java:1728)
| at org.jboss.seam.transaction.Transaction.instance(Transaction.java:58)
| at org.jboss.seam.jsf.SeamPhaseListener.begin(SeamPhaseListener.java:561)
| ... 32 more
| Caused by: javax.naming.NamingException: Local server is not initialized
| at org.jnp.interfaces.LocalOnlyContextFactory.getInitialContext(LocalOnlyContextFactory.java:45)
| at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:667)
| at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:247)
| at javax.naming.InitialContext.init(InitialContext.java:223)
| at javax.naming.InitialContext.<init>(InitialContext.java:197)
| at org.jboss.seam.util.Naming.getInitialContext(Naming.java:35)
| at org.jboss.seam.util.Naming.getInitialContext(Naming.java:47)
| at org.jboss.seam.transaction.Transaction.getUserTransaction(Transaction.java:100)
| at org.jboss.seam.transaction.Transaction.createUTTransaction(Transaction.java:93)
| at org.jboss.seam.transaction.Transaction.getTransaction(Transaction.java:66)
| 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.seam.util.Reflections.invoke(Reflections.java:21)
| at org.jboss.seam.util.Reflections.invokeAndWrap(Reflections.java:124)
| ... 40 more
| 18:06:07,790 ERROR [DebugPageHandler] redirecting to debug page
It loops through this for a while, so is this a getTransaction/dataSource error? I tried to remove everything that had to do with persistence (i.e a bare components.xml, etc...)
<core:ejb installed="true"/>
|
| <core:init debug="true" jndi-pattern="#{ejbName}/local"/>
|
| <core:manager concurrent-request-timeout="500"
| conversation-timeout="120000" />
|
Any ideas?
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4056680#4056680
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4056680
18Â years, 10Â months
[JBoss Seam] - Complex Search Results - return object identifiers instead o
by jfrankman
In general, when you have a session bean that performs a search is it sometimes better to return object identifiers instead of the entire objects themselves?
I have a search page where a user can enter various criteria to get a search results. Once the search results are returned, the user can click on a record to go to a detail page. In most seam examples I have seen, this is done with a session bean that returns a list of objects and loads them on the search results page and subsequently gets injected into the detail page when the user selects a row in the search results.
However, in the case of a complex/expensive query does it ever make sense to merely return a list of object identifiers rather than the objects themselves? What this would mean is that after the results were returned, and the user selected a record, the object identifier would be injected into a lookup method on a session bean that would then retreive the entire object rather than having the object being injected directly from the search results page. (I hope I am makes sense with this)
(I can supply more code and examples, but I didn't want to get into the nitty gritty unless I had to. )
I understand that for simple searches returning objects and then injecting the objects directly into the the detail page would be better, but in the cases of complex queries or cases where you need to pre fetch a fairly large object graph on the detail page, it makes sense to me just to return an object identifier rather than the objects themselves. But I am still quite new at all of this, so I am looking for feedback from more experienced (or smarter) persons.
Any feedback is appreciated. Thanks.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4056677#4056677
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4056677
18Â years, 10Â months
[Beginners Corner] - Oracle ADF server faces on JBoss 4.2 GA
by Nephthys76
I have been trying to fix/find info on this error for a very long time with no luck. I even posted here already with no replies... thought maybe titled better I might have more luck.
If anybody has any GUESSES or ANYTHING, please please help.
I have been given a war file from a co-worker. She developed the code for ADF server faces on JBoss 4.0, and on that server version it works.
However... there is some kind of conflict between the server faces support native to JBoss 4.2 GA and my war file. I get this error on deploy:
...
| Exception thrown by attributes event listener
| java.lang.ClassCastException: com.sun.faces.application.ApplicationAssociate
| at com.sun.faces.application.ApplicationAssociate.getInstance(ApplicationAssociate.java:180)
| at com.sun.faces.application.WebappLifecycleListener.getAssociate(WebappLifecycleListener.java:289)
| ...
I am TRULY stuck... any direction or help would be appreciated.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4056672#4056672
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4056672
18Â years, 10Â months