[jboss-user] [JBoss Portal] - Error from JSF app deployed as portlet

arnieAustin do-not-reply at jboss.com
Tue Jan 9 09:47:25 EST 2007


I have a working two-page JSF application which I'm trying to deploy as a portlet. The various XML files are built and being deployed, the new tab shows up when /portal/ is accessed. I have to tweak security a bit, but otherwise, the portlet seems to be auto-configuring correctly. The first page is a user login page only. The second page is where the inquiry is done. The top of the page has fields and a search and cancel buttons. If records are found, the form is repainted and the first 10 records (paged, up to a 100) are shown below the form. 

I've tried debugging to the first line of the method that is supposed be being called, but it is never invoked. The error seems to be coming from the JSF libraries.

It works fine as a JSF app. I get the following error when I hit the "search" button in the portlet:

  | 2007-01-09 08:27:04,812 ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[localhost].[/DpsLicenseInquiry]] Error calling action method of component with id jbpfe08a106_id6:cmdSubmit
  | javax.faces.FacesException: Error calling action method of component with id jbpfe08a106_id6:cmdSubmit
  | 	at org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:74)
  | 	at javax.faces.component.UICommand.broadcast(UICommand.java:106)
  | 	at javax.faces.component.UIViewRoot._broadcastForPhase(UIViewRoot.java:90)
  | 	at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:164)
  | 
  | ...
  | 
  | Caused by: javax.faces.el.EvaluationException: Exception while invoking expression #{driverSearchBean.doSearch}
  | 	at org.apache.myfaces.el.MethodBindingImpl.invoke(MethodBindingImpl.java:153)
  | 	at org.apache.myfaces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:63)
  | 	... 226 more
  | Caused by: java.lang.ClassCastException: org.jboss.portal.portlet.impl.jsr168.PortletSessionImpl
  | 	at us.tx.state.oag.DpsLicenseInquiry.DriverSearchBean.doSearch(DriverSearchBean.java:356)
  | 
  | 
  | and the error repeats a few times. I've googled around and this error doesn't show up.
  | 
  | JBoss XML Portal Files:
  | 
  | 
  |   | <?xml version="1.0" encoding="UTF-8"?>
  |   | <portlet-app xmlns="http://java.sun.com/xml/ns/portlet/portlet-app_1_1.xsd"
  |   | 	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  |   | 	xsi:schemaLocation="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd"
  |   | 	version="1.0">
  |   | 
  |   | 	<portlet>
  |   | 		<portlet-name>DpsLicenseInquiryPortlet</portlet-name>
  |   | 		<display-name>DPS License Inquiry Portlet</display-name>
  |   | 		
  |   | 		<header-content>
  |   | 			<link href="/resources/stylesheet.css" rel="stylesheet" type="text/css"/>
  |   | 			<script type="text/javascript" src="/resources/toggleLayers.js"></script>
  |   | 		</header-content>
  |   | 
  |   | 		<portlet-class>org.apache.myfaces.portlet.MyFacesGenericPortlet</portlet-class>
  |   | 
  |   | 		<init-param>
  |   | 			<name>default-view</name>
  |   | 			<value>/userLogin.jsp</value>
  |   | 		</init-param>
  |   | 	
  |   | 		<supports>
  |   | 			<mime-type>text/html</mime-type>
  |   | 			<portlet-mode>VIEW</portlet-mode>
  |   | 		</supports>
  |   | 	
  |   | 		<portlet-info>
  |   | 			<title>DPS License Inquiry</title>
  |   | 		</portlet-info>
  |   | 
  |   | 	</portlet>
  |   | 
  |   | </portlet-app>
  |   | 
  |   | <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
  |   | <deployments>
  |   | 	<deployment>
  |   | 		<instance>
  |   | 			<instance-id>DpsLicenseInquiryInstance</instance-id>
  |   | 			<portlet-ref>DpsLicenseInquiryPortlet</portlet-ref>
  |   | 			<security-constraint>
  |   | 				<unchecked/>
  |   | 			</security-constraint>
  |   | 		</instance>
  |   | 	</deployment>
  |   | </deployments>
  |   | 
  |   | <?xml version="1.0" encoding="UTF-8"?>
  |   | <deployments>
  |   | 	<deployment>
  |   | 		<if-exists>overwrite</if-exists>
  |   | 		<parent-ref>default.OAG Intranet</parent-ref>
  |   | 		<window>
  |   | 			<window-name>DpsLicenseInquiryWindow</window-name>
  |   | 			<instance-ref>DpsLicenseInquiryInstance</instance-ref>
  |   | 			<region>center</region>
  |   | 			<height>1</height>
  |   | 		</window>
  |   | 	</deployment>
  |   | </deployments>
  |   | 
  | 

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3999476#3999476

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3999476



More information about the jboss-user mailing list