 |
|
 |
|
|
 |
WPS 5.1.0.4 Upgrade causes JSF Portlet not working |
 |
 |
|
|
03-27-07 12:17 PM
Dear All,
I successfully managed my WPS 5.1.0.1 to WPS 5.1.0.4 and also WAS 5.1.1.3 to
WPS 5.1.1.13. Basically, all applications run very well. But I encountered
an error in JSF Portlet.
My JSP page has something like:
<h:form id="myForm">
<h:commandButton id="btnId" value="#{bundle.save}" action="#{backi
ngBean.doSave}" type="submit" />
</h:form>
When I click on that button, the Portal seems unable to response. It does no
t throw any error message, but my Portlet is not rendered.
However I found a message:
2007.03.27 16:34:32.501 E com.ibm.wps.pe.pc.legacy.impl.PortletContextImpl i
nclude
EJPPG1009E: Resource could not be found.
When I analysed further, I notice that the <h:form> generates an invalid URL
.
Has anyone found any similar case?
Any help will be much appreciated since we are in production mode.
Regards,
Fernando Karnagi
[ Post a follow-up to this message ]
|
|
|
 |
|
 |
|
 |
|
|
 |
Re: WPS 5.1.0.4 Upgrade causes JSF Portlet not working |
 |
 |
|
|
03-27-07 12:17 PM
My first guess would be to look at the resource bundle used for bundle.save
and backingBean.doSave - do they still exist after the update. Is it perhaps
a global resource-file that got overwritten...
/Jonas V
[ Post a follow-up to this message ]
|
|
|
 |
|
 |
|
 |
|
|
 |
Re: WPS 5.1.0.4 Upgrade causes JSF Portlet not working |
 |
 |
|
|
03-27-07 12:17 PM
Well, I have removed all resource bundled, and it is still not working.
FYI, I developed that Portlet using IBM JSF Portlet framework initially and
using RAD6, and my Portal Test Environment is still 5.1.0.1. But now, the se
rver gets upgraded into 5.1.0.4.
The other things is that when I deploy another JSR 168 Portlet, it does not
have any problem. Does it mean that I have to get the latest version of jsf-
portlet and jsf-wp jars, as told by:
http://www-128.ibm.com/developerwor...um=168#13885369
If yes, do you know where to get those jars?
Thank you in advanced for your help.
Regards,
Fernando Karnagi
[ Post a follow-up to this message ]
|
|
|
 |
|
 |
|
 |
|
|
 |
Re: WPS 5.1.0.4 Upgrade causes JSF Portlet not working |
 |
 |
|
|
03-27-07 12:17 PM
No, afaik you still use the same jars in 5.1.0.1 as in 5.1.0.4. If the weren
't you'd get a classexception error for version mismatch instead.
>Well, I have removed all resource bundled, and it is still not working.
Umm, well that was the exact opposite what I meant. It will throw errors and
not render as it should if it don't find the resource-bundles, so you're ge
tting the correct response in a way...
What I meant was that if your resource-keys were packed together with global
bundles (reside in PORTAL_HOME/shared/app) they could've been overwritten w
hen upgrading thus not find your specific key.
It implies that you need to put them back, not take them away.
/Jonas V
[ Post a follow-up to this message ]
|
|
|
 |
|
 |
|
 |
|
|
 |
Re: WPS 5.1.0.4 Upgrade causes JSF Portlet not working |
 |
 |
|
|
03-27-07 12:17 PM
Hi, thank you for your quick reply.
I am using Global Resource Bundle, by the way.
Here is my configuration:
Web.Xml:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3
//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
<web-app id="WebApp_ID">
<display-name>TestJSFPortlet</display-name>
<context-param id="ContextParam_1174897044563">
<param-name>com.ibm.ws.jsf.JSP_UPDATE_CHECK</param-name>
<param-value>true</param-value>
<description>Monitors Faces JSP files for modifications and synchronizes a r
unning server with
the changes without restarting the server. If this parameter is set to fals
e or
removed from the deployment descriptor, any changes made to Faces JSP files
may
not be seen by the server until it is restarted. This parameter is usually
set
to true while the Faces JSP files are being developed and debugged in order
to
improve the performance of the development environment.</description>
</context-param>
<context-param id="ContextParam_1174897044564">
<param-name>com.ibm.ws.jsf.LOAD_FACES_CONFIG_AT_STARTUP</param-name>
<param-value>true</param-value>
<description></description>
</context-param>
<listener id="Listener_1174897044563">
<listener-class>com.sun.faces.config.ConfigureListener</listener-class>
</listener>
<servlet id="Servlet_1174896774390">
<servlet-name>JS Resource Servlet</servlet-name>
<servlet-class>com.ibm.faces.webapp.JSResourceServlet</servlet-class>
<load-on-startup>-1</load-on-startup>
</servlet>
<servlet id="Servlet_1174896776421">
<servlet-name>testjsfportlet.TestJSFPortletPortlet</servlet-name>
<display-name>testjsfportlet.TestJSFPortletPortlet</display-name>
<servlet-class>com.ibm.faces.webapp.WPFacesGenericPortlet</servlet-class>
</servlet>
<servlet-mapping id="ServletMapping_1174897044563">
<servlet-name>JS Resource Servlet</servlet-name>
<url-pattern>/.ibmjsfres/*</url-pattern>
</servlet-mapping>
<servlet-mapping id="ServletMapping_1174897044564">
<servlet-name>testjsfportlet.TestJSFPortletPortlet</servlet-name>
<url-pattern>/testjsfportlet.TestJSFPortletPortlet/*</url-pattern>
</servlet-mapping>
<welcome-file-list id="WelcomeFileList_1174897044563">
<welcome-file>index.html</welcome-file>
<welcome-file>index.htm</welcome-file>
<welcome-file>index.jsp</welcome-file>
<welcome-file>default.html</welcome-file>
<welcome-file>default.htm</welcome-file>
<welcome-file>default.jsp</welcome-file>
</welcome-file-list>
<taglib id="TagLibRef_1174897044563">
<taglib-uri>http://jakarta.apache.org/taglibs/datetime-1.0</taglib-uri>
<taglib-location>/WEB-INF/lib/taglibs-datetime.jar</taglib-location>
</taglib>
<taglib id="TagLibRef_1174897044564">
<taglib-uri>http://jakarta.apache.org/taglibs/string-1.0.1</taglib-uri>
<taglib-location>/WEB-INF/lib/taglibs-string.jar</taglib-location>
</taglib>
<taglib id="TagLibRef_1174897044565">
<taglib-uri>http://jakarta.apache.org/taglibs/utility</taglib-uri>
<taglib-location>/WEB-INF/lib/utility.jar</taglib-location>
</taglib>
<taglib id="TagLibRef_1174897044566">
<taglib-uri>http://jakarta.apache.org/taglibs/mailer-1.1</taglib-uri>
<taglib-location>/WEB-INF/lib/taglibs-mailer.jar</taglib-location>
</taglib>
</web-app>
Portlet.XML:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE portlet-app-def PUBLIC "-//IBM//DTD Portlet Application 1.1//EN" "
portlet_1.1.dtd">
<portlet-app-def>
<portlet-app uid="testjsfportlet.TestJSFPortletPortlet.0c80e4d811" major-ver
sion="1" minor-version="0">
<portlet-app-name>TestJSFPortlet application</portlet-app-name>
<portlet id="testjsfportlet.TestJSFPortletPortlet" href="WEB-INF/web.xml#Ser
vlet_1174896776421" major-version="1" minor-version="0">
<portlet-name>TestJSFPortlet portlet</portlet-name>
<cache>
<expires>0</expires>
<shared>no</shared>
</cache>
<allows>
<maximized />
<minimized />
</allows>
<supports>
<markup name="html">
<view />
</markup>
</supports>
</portlet>
</portlet-app>
<concrete-portlet-app uid="testjsfportlet.TestJSFPortletPortlet.d0bbd4d811.1
">
<portlet-app-name>TestJSFPortlet application</portlet-app-name>
<concrete-portlet href="#testjsfportlet.TestJSFPortletPortlet">
<portlet-name>TestJSFPortlet portlet</portlet-name>
<default-locale>en</default-locale>
<language locale="en">
<title>TestJSFPortlet portlet</title>
<title-short></title-short>
<description></description>
<keywords></keywords>
</language>
<config-param>
<param-name>com.ibm.faces.portlet.page.view</param-name>
<param-value>/TestJSFPortletView.jsp</param-value>
</config-param>
</concrete-portlet>
</concrete-portlet-app>
</portlet-app-def>
FacesConfig.xml:
<?xml version="1.0"?>
<!--
Copyright 2003 Sun Microsystems, Inc. All rights reserved.
SUN PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
-->
<!DOCTYPE faces-config PUBLIC
"-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.0//EN"
"http://java.sun.com/dtd/web-facesconfig_1_0.dtd">
<!-- =========== FULL CONFIGURATION FILE ==================================
-->
<faces-config>
<factory>
<faces-context-factory>
com.ibm.faces.context.WPPortletFacesContextFactoryImpl</faces-context-factor
y>
</factory>
<managed-bean>
<managed-bean-name>pc_TestJSFPortletView</managed-bean-name>
<managed-bean-class>pagecode.TestJSFPortletView</managed-bean-class>
<managed-bean-scope>request</managed-bean-scope>
</managed-bean>
<lifecycle>
<phase-listener>com.ibm.faces.webapp.ValueResourcePhaseListener</phase-liste
ner>
</lifecycle>
<!-- variable/property resolver registration -->
<application>
<variable-resolver>com.ibm.faces.databind.SelectItemsVarResolver</variable-r
esolver>
<variable-resolver>
com.ibm.faces.application.WPPortletVariableResolver</variable-resolver>
<property-resolver>com.ibm.faces.databind.SelectItemsPropResolver</property-
resolver>
</application>
</faces-config>
/WEB-INF/lib:
commons-beanutils.jar
commons-collections.jar
commons-digester.jar
jaxen-full.jar
jsf-api.jar
jsf-ibm.jar
jsf-impl.jar
jsf-portlet.jar
jsf-wp.jar
jstl.jar
jstl_el.jar
saxpath.jar
standard.jar
taglibs-datetime.jar
taglibs-mailer.jar
taglibs-string.jar
utility.jar
my JSP file:
<%-- jsf:pagecode language="java" location="/JavaSource/pagecode/TestJSFPort
letView.java" --%><%-- /jsf:pagecode --%>
<%@ taglib uri="http://java.sun.com/jsf/core" prefix="f"%>
<%@taglib uri="http://www.ibm.com/jsf/html_extended" prefix="hx"%>
<%@taglib uri="http://java.sun.com/jsf/html" prefix="h"%>
<%@taglib uri="http://java.sun.com/jstl/core" prefix="c"%>
<%@ page language="java" contentType="text/html; charset=windows-1252"
pageEncoding="windows-1252" session="false"%>
<portletAPI:init />
<f:view>
<P>Place content here.</P>
<h:form styleClass="form" id="taskListForm" >
<h:commandButton id="showButton" actionListener="#{pc_TestJSFPortletVie
w.doShow}" value="Show" type="submit"/>
</h:form>
</f:view>
------------------------------------------------------------
When I click on the Show button, my portlet does not get renderred, and the
action listener does not get invoked either.
[ Post a follow-up to this message ]
|
|
|
 |
|
 |
|
 |
|
|
 |
Re: WPS 5.1.0.4 Upgrade causes JSF Portlet not working |
 |
 |
|
|
03-27-07 06:20 PM
I do not have the details available here, so I just throw out what I know.
When attending the WP 6.0 Dev. course we had to remove the JSF jar-file from
shared/app due to some problems in it. The problem caused JSF-pages not wor
king, and the url created was _strange_ . Sounds like your problem as well?
I will look back tomorrow and see if anyone else have responded to this, if
not I will try to look up the details, have to run now :-)
R.
****************************************
**********
Rune Hellem http://hellem.org
[ Post a follow-up to this message ]
|
|
|
 |
|
 |
|
 |
|
|
 |
Re: WPS 5.1.0.4 Upgrade causes JSF Portlet not working |
 |
 |
|
|
03-27-07 06:20 PM
Hmm, I must say "ummm" again.
Ok, after looking at your testcode there are a couple of things I not quite
sure about.
1. You're using IBM legacy portlet API. That's not exactly my ballpark since
I'm into JSR168.
2. Do you really get the same error when trying this code?
4. Do TestJSFPortletView.java implements the actual actionlistener? It would
be nice to see that java-class...
5. Using windows-1252 as page encoding. *shudders*
Besides that it looks as it should. Though it don't contain any references t
o a resource bundle.
/Jonas V
[ Post a follow-up to this message ]
|
|
|
 |
|
 |
|
 |
|
|
 |
Re: WPS 5.1.0.4 Upgrade causes JSF Portlet not working |
 |
 |
|
|
03-28-07 06:21 AM
Hi, thank you again getting quick reply from you.
==== TestJSFPortletView.java ====
/*
* Created on Mar 26, 2007
*
* TODO To change the template for this generated file go to
* Window - Preferences - Java - Code Style - Code Templates
*/
package pagecode;
import javax.faces.event.ActionEvent;
import javax.faces.component.html.HtmlCommandButton;
/**
* @author Fernando
*
* TODO To change the template for this generated type comment go to
* Window - Preferences - Java - Code Style - Code Templates
*/
public class TestJSFPortletView extends PageCodeBase {
protected HtmlCommandButton showButton;
public void doShow(ActionEvent e) {
System.out.println("--> doShow");
}
public void deleteItem(ActionEvent e) {
System.out.println("--> deleteItem");
}
protected HtmlCommandButton getShowButton() {
if (showButton == null) {
showButton = (HtmlCommandButton) findComponentInRoot("showButton");
}
return showButton;
}
}
========================================
========
When I deployed another JSR 168 Faces Portlet, it did not have any problem,
so the same thing as MyTask Portlet (WPS built-in portlet), since it uses JS
R 168 Faces Portlet and it does not have any problem.
Is there any upgrade on the jsf-related Jars that RAD6 puts into /WEB-INF/li
b folder of my IBM JSF Portlet project.
I think there is some bugs in IBM JSF Portlet Framework after upgrading from
5.1.0.1 into 5.1.0.4
[ Post a follow-up to this message ]
|
|
|
 |
|
 |
|
 |
|
|
 |
Re: WPS 5.1.0.4 Upgrade causes JSF Portlet not working |
 |
 |
|
|
03-28-07 06:21 AM
Thank you for your reply.
The problem is that <h:form> does not generate the correct URL.
Here is the URL of WPS 5.1.0.1 for my JSF Portlet
/wps/myportal/!ut/p/kcxml/ 04_Sj9SPykssy0xPLMnMz0vM0Y_QjzKLN4g3MbYE
SYGYxqb6kW
hCjhgixgYhEDFjE0OYmJGTMYY6IydDhJivR35uqr
63foB-QW4oEESUOzoqKgIAAqwMBA!!/delta
/base64xml/ L0lDU0lKQ1RPN29na21DU1Evb0tvUUFBSVFnakZJ
QUFRaENFSVFqR0VKemdBIS80S
kZpQ28wZWgxaWNvblFWR2hkLXNJ
ZDJFQSEhLzdfMF84VkgvMjA1MTEvc2EuY29tLmli
bS5mYWNlcy5wb3J0bGV0LkFDVElPTg!!?PC_
7_0_8VH_javax.servlet.include.path_info=%2fview.jsp#7_0_8VH
Here is the URL of WPS 5.1.0.4 for the same portlet
/wps/myportal/!ut/p/kcxml/ 04_Sj9SPykssy0xPLMnMz0vM0Y_QjzKLN4h3cgXJ
gFjGpvqRqC
KO6AJOFlARN5iIpSu6GksXuIivR35uqn6Qvrd-gH5BbigQRJQ7OioqAgAThOtN/delta/base64x
ml/ L0lDU0lKQ1RPN29na21DU1Evb0tvUUFBSVFnakZJ
QUFRaENFSVFqR0VKemdBIS80SkZpQ28wZ
WgxaWNvblFWR2hkLXNJZDJFQSEh
LzdfMF8xMDIvMTAvc2EuY29tLmlibS5mYWNlcy5w
b3J0bGV0LkFDVElPTg!!?PC_7_0_102_java
x.servlet.include.path_info=#7_0_102
The difference that catch my attention is that the URL 5.1.0.4 does not '%2f
view.jsp' in PC_7_0_102_javax.servlet.include.path_info=#7_0_102
in comparison to
PC_7_0_8VH_javax.servlet.include.path_info=%2fview.jsp#7_0_8VH
in URL 5.1.0.1
So that's why the Portal complaints
2007.03.28 08:01:04.054 E com.ibm.wps.pe.pc.legacy.impl.PortletContextImpl i
nclude
EJPPG1009E: Resource could not be found.
Because it does not know which view (resource) to display.
Back to your suggestion, can you please tell me which Jars I should from sha
red/app ?
Thank you
[ Post a follow-up to this message ]
|
|
|
 |
|
 |
|
 |
|
|
 |
Re: WPS 5.1.0.4 Upgrade causes JSF Portlet not working |
 |
 |
|
|
|
|
|
Sponsored Links |
 |
 |
|
|
 |
All times are GMT. The time now is 08:00 AM. |
 |
|
|
 |
|
 |
|
|
 |
|
Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
|
HTML code is OFF
vB code is ON
Smilies are ON
[IMG] code is OFF
|
|
|
|
Medical and Health forum | Computer Games Reviews | Graphics design forum
|
 |
|
 |
|