[JBoss Seam] - Re: Problems with application-like behaviour project
by raffaele.camanzo
Waiting for an advice I tried another solution, this does not fail, but does not do what I want:
I modified the conversation generation in order to provide a conversation id as a commandLink parameter (<f:param name="conversationId" value="#{contextTab.token} />), the conversationId value is passed correctly but ignored by Seam.
layout.xhtml:
| <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
| <html xmlns="http://www.w3.org/1999/xhtml"
| xmlns:ui="http://java.sun.com/jsf/facelets"
| xmlns:h="http://java.sun.com/jsf/html"
| xmlns:f="http://java.sun.com/jsf/core"
| xmlns:s="http://jboss.com/products/seam/taglib"
| xmlns:c="http://java.sun.com/jstl/core">
|
| <f:view>
|
| <f:loadBundle basename="main" var="mainmsg" />
| <f:loadBundle basename="messages" var="msgs" />
|
|
| <head>
| <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
| <title><h:outputText value="#{mainmsg.title}" /></title>
| <link href="css/main.css" rel="stylesheet" type="text/css"/>
| </head>
|
| <body>
|
| <div id="document">
| <div id="header">
| <div id="title"></div>
| <div id="status">
| <ui:insert name="status" />
| </div>
| </div>
| <div id="container">
| <div id="leftside">
| </div>
| <div id="rightside">
| <div id="ContextView">
|
| <div id="slidingContext">
| <h:form>
| <ul>
| <c:forEach items="#{sessionHandler.contextTabs}" var="contextTab">
| <li>
| <h:commandLink action="#{provaAction.startConversation}">
| <h:outputText value="label" />
| <f:param name="token" value="#{contextTab.token}" />
| <f:param name="conversationId" value="#{contextTab.token}" />
| </h:commandLink>
| </li>
| </c:forEach>
| </ul>
| </h:form>
| </div>
|
| </div>
| <ui:insert name="contextmanager" />
| </div>
| </div>
| </div>
|
| </body>
|
| </f:view>
| </html>
|
the ProvaAction.java:
| import javax.ejb.Remove;
| import javax.ejb.Stateful;
| import javax.faces.context.FacesContext;
| import javax.faces.event.ActionEvent;
|
| import org.jboss.logging.Logger;
| import org.jboss.seam.annotations.Begin;
| import org.jboss.seam.annotations.Conversational;
| import org.jboss.seam.annotations.Create;
| import org.jboss.seam.annotations.Destroy;
| import org.jboss.seam.annotations.End;
| import org.jboss.seam.annotations.In;
| import org.jboss.seam.annotations.Name;
| import org.jboss.seam.annotations.Out;
| import org.jboss.seam.annotations.RequestParameter;
| import org.jboss.seam.core.Conversation;
| import org.jboss.seam.core.Manager;
|
| @Stateful
| @Name("provaAction")
| @Conversational
| public class ProvaAction implements Prova {
|
| @RequestParameter(value="token")
| private String tok;
|
| @RequestParameter(value="conversationId")
| private String conv;
|
| @Begin(join=true)
| public String startConversation() {
| FacesContext context = FacesContext.getCurrentInstance();
| String tokz = (String) context.getExternalContext().getRequestParameterMap().get("token");
| Logger.getLogger(this.getClass()).info("TOKEN IS: " + tokz);
| Logger.getLogger(this.getClass()).info("TOKEN FROM REQUEST PARAMETER IS: " + tok);
| Logger.getLogger(this.getClass()).info("CONVERSATION ID PARAMETER IS: " + conv);
|
| Logger.getLogger(this.getClass()).info("CONVERSATION IS: " + Conversation.instance().getId());
| return "prova";
| }
|
| @End
| public String endConversation() {
| // TODO Auto-generated method stub
| return null;
| }
|
| @Remove @Destroy
| public void destroy() {
| // TODO Auto-generated method stub
|
| }
| }
|
which produces the following output:
2006-10-31 17:32:46,542 INFO [it.finservice.organizer.modules.dummy.components.ProvaAction] TOKEN IS: token1
2006-10-31 17:32:46,543 INFO [it.finservice.organizer.modules.dummy.components.ProvaAction] TOKEN FROM REQUEST PARAMETER IS: token1
2006-10-31 17:32:46,543 INFO [it.finservice.organizer.modules.dummy.components.ProvaAction] CONVERSATION ID PARAMETER IS: token1
2006-10-31 17:32:46,543 INFO [it.finservice.organizer.modules.dummy.components.ProvaAction] CONVERSATION IS: 4
Help really appreciated.
Regards,
Raffaele
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3982148#3982148
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3982148
19 years, 1 month
[JBoss Seam] - Re: Problems with application-like behaviour project
by gavin.king@jboss.com
(1) I don't understand what your code looked like for the first approach. Please post it.
(2) Seam is throwing an NPE because there is no view id stored in the conversation entry. This is actually a bug in Seam, and I will fix it, but you could probably work around it by specifying page descriptions in pages.xml. However, your solution is still broken, AFAICT, because you are using a constant value as the conversation id in @Begin, which means you could only ever have one conversation at a time.
(3) I have a funny feeling that you could do what you want to do more easily using the Switcher or ConversationList stuff, but I'm not exactly sure, because I don't completely understand usecase. How exactly does it differ from the kind of thing that we do in the issue tracker example? Is it just that you want to display the list of conversations as tabs? Or does the list of tabs come from somewhere else?
(4) If you give me a really simplified, stripped down, easy to build and run copy of your project, along with a really good description of what exactly these tabs represent, where they come from, and how you want the conversations to behave, I will figure out a way to do it in Seam and make whatever fixes/changes are needed. But please take time to make sure that I can understand the problem and your code (I don't usually do this!). Email it to gavin.king(a)jboss.com.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3982144#3982144
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3982144
19 years, 1 month
[JBoss Seam] - Re: JavaScript Error when using sortable <t:dataTable>
by chuckadams
Some interesting messages from catalina.out as well:
| 08:23:55,538 INFO [Initialization] done initializing Seam
| Oct 31, 2006 8:23:55 AM org.apache.coyote.http11.Http11BaseProtocol start
| INFO: Starting Coyote HTTP/1.1 on http-8080
| Oct 31, 2006 8:23:56 AM org.apache.jk.common.ChannelSocket init
| INFO: JK: ajp13 listening on /0.0.0.0:8009
| Oct 31, 2006 8:23:56 AM org.apache.jk.server.JkMain start
| INFO: Jk running ID=0 time=0/32 config=null
| Oct 31, 2006 8:23:56 AM org.apache.catalina.storeconfig.StoreLoader load
| INFO: Find registry server-registry.xml at classpath resource
| Oct 31, 2006 8:23:56 AM org.apache.catalina.startup.Catalina start
| INFO: Server startup in 12518 ms
| 08:24:35,424 INFO [Events] no events.xml file found
| 08:24:35,529 INFO [Pages] no pages.xml file found
| Oct 31, 2006 8:24:35 AM com.sun.facelets.compiler.TagLibraryConfig loadImplicit
| INFO: Added Library from: jar:file:/opt/tomcat/webapps/jboss-seam-registrationtrinidad/WEB-INF/lib/trinidad-impl-incubator-m1-SNAPSHOT.jar!/META-INF/trh.taglib.xml
| Oct 31, 2006 8:24:35 AM com.sun.facelets.compiler.TagLibraryConfig loadImplicit
| INFO: Added Library from: jar:file:/opt/tomcat/webapps/jboss-seam-registrationtrinidad/WEB-INF/lib/jboss-seam-ui.jar!/META-INF/seam.taglib.xml
| Oct 31, 2006 8:24:35 AM com.sun.facelets.compiler.TagLibraryConfig loadImplicit
| INFO: Added Library from: jar:file:/opt/tomcat/webapps/jboss-seam-registrationtrinidad/WEB-INF/lib/jsf-facelets.jar!/META-INF/jstl-core.taglib.xml
| Oct 31, 2006 8:24:35 AM com.sun.facelets.compiler.TagLibraryConfig loadImplicit
| INFO: Added Library from: jar:file:/opt/tomcat/webapps/jboss-seam-registrationtrinidad/WEB-INF/lib/trinidad-impl-incubator-m1-SNAPSHOT.jar!/META-INF/tr.taglib.xml
| Oct 31, 2006 8:24:35 AM com.sun.facelets.compiler.TagLibraryConfig loadImplicit
| INFO: Added Library from: jar:file:/opt/tomcat/webapps/jboss-seam-registrationtrinidad/WEB-INF/lib/jsf-facelets.jar!/META-INF/jstl-fn.taglib.xml
| Oct 31, 2006 8:24:35 AM com.sun.facelets.compiler.TagLibraryConfig loadImplicit
| INFO: Added Library from: jar:file:/opt/tomcat/webapps/jboss-seam-registrationtrinidad/WEB-INF/lib/jsf-facelets.jar!/META-INF/jsf-core.taglib.xml
| Oct 31, 2006 8:24:35 AM com.sun.facelets.compiler.TagLibraryConfig loadImplicit
| INFO: Added Library from: jar:file:/opt/tomcat/webapps/jboss-seam-registrationtrinidad/WEB-INF/lib/jsf-facelets.jar!/META-INF/jsf-ui.taglib.xml
| Oct 31, 2006 8:24:35 AM com.sun.facelets.compiler.TagLibraryConfig loadImplicit
| INFO: Added Library from: jar:file:/opt/tomcat/webapps/jboss-seam-registrationtrinidad/WEB-INF/lib/jsf-facelets.jar!/META-INF/jsf-html.taglib.xml
| Oct 31, 2006 8:24:35 AM com.sun.facelets.tag.jsf.ComponentRule warnAttr
| WARNING: /register.xhtml @36,103 type="submit" Property 'type' is not on type: org.apache.myfaces.trinidad.component.core.nav.CoreCommandButton
| Oct 31, 2006 8:24:36 AM org.apache.myfaces.trinidadinternal.renderkit.RenderKitBase getRenderer
| WARNING: Renderer 'javax.faces.Text' not found for component family 'javax.faces.Input'
| 08:24:36,403 INFO [[/jboss-seam-registrationtrinidad]] No Renderer found for component {Component-Path : [Class: javax.faces.component.UIViewRoot,ViewId: /register.xhtml][Class: org.apache.myfaces.trinidad.component.html.HtmlBody,Id: _id4][Class: org.apache.myfaces.trinidad.component.core.CoreForm,Id: _id5][Class: org.jboss.seam.ui.UIValidateAll,Id: _id7][Class: javax.faces.component.html.HtmlInputText,Id: _id9]} (component-family=javax.faces.Input, renderer-type=javax.faces.Text)
| 08:24:36,403 WARN [UIComponentBase] No Renderer found for component {Component-Path : [Class: javax.faces.component.UIViewRoot,ViewId: /register.xhtml][Class: org.apache.myfaces.trinidad.component.html.HtmlBody,Id: _id4][Class: org.apache.myfaces.trinidad.component.core.CoreForm,Id: _id5][Class: org.jboss.seam.ui.UIValidateAll,Id: _id7][Class: javax.faces.component.html.HtmlInputText,Id: _id9]} (component-family=javax.faces.Input, renderer-type=javax.faces.Text)
| Oct 31, 2006 8:24:36 AM org.apache.myfaces.trinidadinternal.renderkit.RenderKitBase getRenderer
| WARNING: Renderer 'javax.faces.Text' not found for component family 'javax.faces.Input'
| 08:24:36,404 INFO [[/jboss-seam-registrationtrinidad]] No Renderer found for component {Component-Path : [Class: javax.faces.component.UIViewRoot,ViewId: /register.xhtml][Class: org.apache.myfaces.trinidad.component.html.HtmlBody,Id: _id4][Class: org.apache.myfaces.trinidad.component.core.CoreForm,Id: _id5][Class: org.jboss.seam.ui.UIValidateAll,Id: _id7][Class: javax.faces.component.html.HtmlInputText,Id: _id9]} (component-family=javax.faces.Input, renderer-type=javax.faces.Text)
| 08:24:36,404 WARN [UIComponentBase] No Renderer found for component {Component-Path : [Class: javax.faces.component.UIViewRoot,ViewId: /register.xhtml][Class: org.apache.myfaces.trinidad.component.html.HtmlBody,Id: _id4][Class: org.apache.myfaces.trinidad.component.core.CoreForm,Id: _id5][Class: org.jboss.seam.ui.UIValidateAll,Id: _id7][Class: javax.faces.component.html.HtmlInputText,Id: _id9]} (component-family=javax.faces.Input, renderer-type=javax.faces.Text)
| Oct 31, 2006 8:24:36 AM org.apache.myfaces.trinidadinternal.renderkit.RenderKitBase getRenderer
| WARNING: Renderer 'javax.faces.Text' not found for component family 'javax.faces.Input'
| 08:24:36,404 INFO [[/jboss-seam-registrationtrinidad]] No Renderer found for component {Component-Path : [Class: javax.faces.component.UIViewRoot,ViewId: /register.xhtml][Class: org.apache.myfaces.trinidad.component.html.HtmlBody,Id: _id4][Class: org.apache.myfaces.trinidad.component.core.CoreForm,Id: _id5][Class: org.jboss.seam.ui.UIValidateAll,Id: _id7][Class: javax.faces.component.html.HtmlInputText,Id: _id9]} (component-family=javax.faces.Input, renderer-type=javax.faces.Text)
| 08:24:36,404 WARN [UIComponentBase] No Renderer found for component {Component-Path : [Class: javax.faces.component.UIViewRoot,ViewId: /register.xhtml][Class: org.apache.myfaces.trinidad.component.html.HtmlBody,Id: _id4][Class: org.apache.myfaces.trinidad.component.core.CoreForm,Id: _id5][Class: org.jboss.seam.ui.UIValidateAll,Id: _id7][Class: javax.faces.component.html.HtmlInputText,Id: _id9]} (component-family=javax.faces.Input, renderer-type=javax.faces.Text)
|
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3982141#3982141
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3982141
19 years, 1 month
[JBoss Seam] - Re: JavaScript Error when using sortable <t:dataTable>
by chuckadams
web.xml
| <?xml version="1.0" encoding="UTF-8"?>
| <web-app version="2.4"
| xmlns="http://java.sun.com/xml/ns/j2ee"
| xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
| xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
|
| <context-param>
| <param-name>javax.faces.DEFAULT_SUFFIX</param-name>
| <param-value>.xhtml</param-value>
| </context-param>
| <context-param>
| <param-name>facelets.REFRESH_PERIOD</param-name>
| <param-value>2</param-value>
| </context-param>
| <context-param>
| <param-name>facelets.DEVELOPMENT</param-name>
| <param-value>true</param-value>
| </context-param>
| <context-param>
| <param-name>javax.faces.STATE_SAVING_METHOD</param-name>
| <param-value>client</param-value>
| </context-param>
| <context-param>
| <param-name>com.sun.faces.validateXml</param-name>
| <param-value>true</param-value>
| </context-param>
| <context-param>
| <param-name>com.sun.faces.verifyObjects</param-name>
| <param-value>true</param-value>
| </context-param>
| <context-param>
| <param-name>org.apache.myfaces.trinidad.ALTERNATE_VIEW_HANDLER</param-name>
| <param-value>com.sun.facelets.FaceletViewHandler</param-value>
| </context-param>
|
|
| <!-- Seam -->
|
| <listener>
| <listener-class>org.jboss.seam.servlet.SeamListener</listener-class>
| </listener>
|
| <!-- MyFaces -->
|
| <listener>
| <listener-class>org.apache.myfaces.webapp.StartupServletContextListener</listener-class>
| </listener>
|
| <servlet>
| <servlet-name>Faces Servlet</servlet-name>
| <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
| <load-on-startup>1</load-on-startup>
| </servlet>
|
| <!-- resource loader servlet -->
| <servlet>
| <servlet-name>resources</servlet-name>
| <servlet-class>
| org.apache.myfaces.trinidad.webapp.ResourceServlet
| </servlet-class>
| </servlet>
|
| <servlet-mapping>
| <servlet-name>Faces Servlet</servlet-name>
| <url-pattern>*.jsf</url-pattern>
| </servlet-mapping>
| <servlet-mapping>
| <servlet-name>resources</servlet-name>
| <url-pattern>/adf/*</url-pattern>
| </servlet-mapping>
| <!-- Faces Servlet Mapping -->
| <servlet-mapping>
| <servlet-name>Faces Servlet</servlet-name>
| <url-pattern>*.seam</url-pattern>
| </servlet-mapping>
|
| <filter>
| <filter-name>trinidad</filter-name>
| <filter-class>org.apache.myfaces.trinidad.webapp.TrinidadFilter</filter-class>
| </filter>
|
| <filter-mapping>
| <filter-name>trinidad</filter-name>
| <servlet-name>Faces Servlet</servlet-name>
| </filter-mapping>
|
| <welcome-file-list>
| <welcome-file>index.html</welcome-file>
| </welcome-file-list>
|
| </web-app>
|
faces-config.xml
| <?xml version="1.0" encoding="UTF-8"?>
| <!DOCTYPE faces-config
| PUBLIC "-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.0//EN"
| "http://java.sun.com/dtd/web-facesconfig_1_0.dtd">
| <faces-config>
|
|
|
| <application>
| <default-render-kit-id>org.apache.myfaces.trinidad.core</default-render-kit-id>
| </application>
|
| <!-- Phase listener needed for all Seam applications -->
| <lifecycle>
| <phase-listener>org.jboss.seam.jsf.SeamPhaseListener</phase-listener>
| </lifecycle>
|
| </faces-config>
|
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3982140#3982140
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3982140
19 years, 1 month
[Installation, Configuration & Deployment] - JEMS Install Error -
by spitnas
I am attempting to install JBoss - EJB3 using the JEMS installer I downloaded (jems-installer-1.2.0.BETA3.jar). I have successfully installed JBoss on a windows PC, but I am having problems installing on a 2nd PC.
The 2nd PC will display the installer dialog, but the screen is completely blank other than a title on the dialog frame. I also found the following exception in the JEMS install log.
I have not been able to find any information on this error in the JBoss forums or on the internet.
Does anyone know why this exception occurs and what I need to do to prevent its occurrence?
Thanks
---------------------------------
No custom langpack available.
com.izforge.izpack.installer.ResourceNotFoundException: Can not find Resource packsLang.xml for language engcom.izforge.izpack.installer.ResourceNotFoundException: Can not find Resource packsLang.xml for language eng
at com.izforge.izpack.installer.ResourceManager.getLanguageResourceString(ResourceManager.java:137)
at com.izforge.izpack.installer.ResourceManager.getInputStream(ResourceManager.java:154)
at com.izforge.izpack.panels.PacksPanelBase.(PacksPanelBase.java:160)
at com.izforge.izpack.panels.PacksPanel.(PacksPanel.java:59)
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
at java.lang.reflect.Constructor.newInstance(Constructor.java:494)
at com.izforge.izpack.installer.InstallerFrame.loadPanels(InstallerFrame.java:243)
at com.izforge.izpack.installer.InstallerFrame.(InstallerFrame.java:198)
at com.izforge.izpack.installer.GUIInstaller.loadGUI(GUIInstaller.java:427)
at com.izforge.izpack.installer.GUIInstaller.access$100(GUIInstaller.java:79)
at com.izforge.izpack.installer.GUIInstaller$2.run(GUIInstaller.java:148)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:461)
at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:242)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:163)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:157)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:149)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:110)
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3982139#3982139
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3982139
19 years, 1 month