Is that true? Does MyFaces really require JSP 2.0? Does JSF itself require it?

 


From: Storm Spire [mailto:[EMAIL PROTECTED]
Sent: Tuesday, July 18, 2006 7:03 AM
To: users@myfaces.apache.org
Subject: Re: deploy MyFaces as portlet into Websphere Portal 5.1

 

I can deploy my application to pluto 1.0.1 without a problem
I suspect the reason is due to JSP version, as websphere portal 5.1.0.1 is using JSP 1.3, and myFaces needs JSP 2.0.
Is there any way to hack the portal to JSP 2.0?

On 7/18/06, Storm Spire <[EMAIL PROTECTED]> wrote:

Hi Wynn,

   Do you have a simple WAR that can be run inside websphere portal?
   Or I mail you my WAR file to check whether mine is workable?

Best Regards,


Bruce

On 7/18/06, Ryan Wynn <[EMAIL PROTECTED]> wrote:

On 7/18/06, Storm Spire <[EMAIL PROTECTED]> wrote:
> Hi Ryan,
>
>   I have added the parameters into the portlet.xml like following:
>
>         <init-param>
>             <name>default-view</name>
>             <value>/Jsr168_2View.jsp</value>
>         </init-param>
>
>         <init-param>
>             <name>ViewPage</name>
>             <value>/Jsr168_2View.jsp</value>
>         </init-param>

Did that fix your problem or are you still seeing a blank portlet page?

>
>    I think it may be required by tomcat.
>
>
> Regards,
> Bruce
>
> On 7/18/06, Ryan Wynn < [EMAIL PROTECTED]> wrote:
> > On 7/17/06, Storm Spire < [EMAIL PROTECTED]> wrote:
> > > Hi Ryan,
> > >     Your information is really helpful!
> > >     Just found I didn't have jsp-api.jar inside my lib, after I placed
> the
> > > jar inside my WAR lib, it could be deployed without a problem.
> > >   However I met another problem, my first page for the portlet is simply
> a
> > > plain HTML content, like "<P>Place content here 2.</P>".  But after I
> > > deployed it successfully, I can't see anything inside my deployed
> portlet, I
> > > can only see the portlet title, no content at all.
> >
> > Try adding this parameter to your portlet.xml and see if the page gets
> displayed
> >
> > <init-param>
> > <name>ViewPage</name>
> > <value>/test.jsp</value>
> > </init-param>
> >
> >
> > >
> > >   By the way, you mentioned about commons-logging, I am not clear about
> it,
> > > did you place it inside the lib or not?  I didn't put commons-logging
> into
> > > the lib folder.
> >
> > Initially I tested my app in both tomcat and Portal Server.  One of
> > which I can't remember required that commons-logging to be located in
> > the webapp to work properly.  It looks like it wasn't required in
> > portal since the names I sent you did not include it.
> >
> > >
> > >   Here is the files inside my lib:
> > >    commons-beanutils-1.7.0.jar
> > >   commons-collections-3.1.jar
> > >   commons-digester-1.6.jar
> > >   commons-el-1.0.jar
> > >   commons-lang-2.1.jar
> > >   jsp-api.jar
> > >   myfaces-api-1.1.3.jar
> > >   myfaces-impl-1.1.3.jar
> > >
> > >  Regards,
> > > Bruce
> > >
> > > On 7/18/06, Ryan Wynn < [EMAIL PROTECTED]> wrote:
> > > > Storm,
> > > >
> > > > Are you running the app on the Portal Server 5.1 Test Environment or
> > > > the full blown Portal 5.1 Server? Have you packaged the myfaces
> > > > dependencies in your portlet war or do you have them at a higher
> > > > classloader level?
> > > >
> > > > If you are running from within Rational Application Developer what do
> > > > you see in the console when you right click on the Server and
> > > > Restart->Project?  Also you may want to check the Problems window.  I
> > > > have found seemingly benign reported problems that make PS unable to
> > > > load the app (disregard these questions if you are deploying with
> > > > xmlaccess or through the portal admin interface).
> > > >
> > > > Let's see it could be missing dependencies or maybe you left ibm jars
> > > > in the war from a RAD wizard (if you have any ibm related jars in your
> > > > WAR you should remove them).
> > > >
> > > > Did you use a RAD wizard to create you project?
> > > >
> > > > Sorry if I can't give you any easy answer.  I did get Myfaces working
> > > > with portal 5.1.0.3 and I have seen obscure error messages previously
> > > > like the ones you are seeing.
> > > >
> > > > One problem I had was that my the context-root in my web app
> > > > (.websettings) and enterprise app ( application.xml ) did not match.
> > > > Another problem I had was that I was missing commons-logging.
> > > > Unfortunately both these problems result in the same obscure error
> > > > message that you are seeing.
> > > >
> > > > You portlet.xml and web.xml look okay to me.
> > > >
> > > > These are the jars I have in my lib directory.
> > > >
> > > > commons-beanutils.jar
> > > > commons-codec.jar
> > > > commons-collections.jar
> > > > commons-digester.jar
> > > > commons-el.jar
> > > > commons-fileupload.jar
> > > > commons-lang.jar
> > > > commons-validator.jar
> > > > jsp-api.jar
> > > > myfaces-api.jar
> > > > myfaces-impl.jar
> > > > tomahawk.jar
> > > >
> > > >
> > > >
> > > >
> > > > On 7/17/06, CD < [EMAIL PROTECTED] > wrote:
> > > > >
> > > > > Bruce,
> > > > >
> > > > > Have you selected the box in your server config in RAD that allows
> the
> > > > > portal to pipe it's output to the console?
> > > > >
> > > > > Also, one thing I noticed when attempting to use myfaces with
> JSR-168 is
> > > > > that a problem occurs due to the faces-config.xml being included in
> the
> > > jar
> > > > > file.
> > > > >
> > > > >
> > > > > On 7/17/06, Matthias Wessendorf < [EMAIL PROTECTED]> wrote:
> > > > > > mmm strange,
> > > > > >
> > > > > > but there is a user here in this list (Ryan) he has AFAIK
> experiences
> > > > > > with MyFaces_Portlets and Websphere.
> > > > > >
> > > > > > I guess you should wait abit.
> > > > > > Any update on the wiki regarding problems you solved are *warmly*
> > > welcome
> > > > > :)
> > > > > >
> > > > > > -Matthias
> > > > > >
> > > > > > On 7/17/06, Storm Spire < [EMAIL PROTECTED] > wrote:
> > > > > > > Hi Stephan,
> > > > > > >   Thanks for your reply! but I can't find enough info from the
> > > website.
> > > > > I
> > > > > > > think my problem is specific to websphere only, as I can deploy
> my
> > > > > > > application to pluto without any problem.
> > > > > > >
> > > > > > >   I have turned on the trace level to all for websphere_portal
> > > server
> > > > > > > setting, and can't find enough debug information as well.
> > > > > > >
> > > > > > >   The only error I found from the huge log file is the
> following:
> > > > > > > java.io.FileNotFoundException: D:\Program
> > > > > > >
> > > > >
> > >
> Files\WebSphere\AppServer\config\cells\ibm-server\nodes\ibm-server\servers\variables.xml
> > > > > > > &
> > > > > > >  [06-7-18 1:58:57:578 CST] 567da6db ConfigInfoBui d
> > > > > > > initConfiguredBindingInfo: Absorb FileNotFoundException,
> > > > > > > java.io.FileNotFoundException : d:\Program
> > > > > > >
> > > > >
> > >
> Files\WebSphere\AppServer\config\cells\ibm-server\nodes\ibm-server\namebindings.xml
> > > > > > >
> > > > > > >   Will these two files affect the program?
> > > > > > >
> > > > > > > Regards,
> > > > > > > Bruce
> > > > > > >
> > > > > > >
> > > > > > > On 7/17/06, Strittmatter, Stephan <
> > > > > > > [EMAIL PROTECTED] > wrote:
> > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > > Hi Storm,
> > > > > > > >
> > > > > > > > I am not familar with WebShere, but I know, that there are
> some
> > > things
> > > > > to
> > > > > > > do before MyFaces is working within portlet environment.
> > > > > > > > Have a look at
> > > > > > > http://wiki.apache.org/myfaces/Using_Portlets I
> > > started
> > > > > > > there a section about portlets. Probably this could help you.
> > > > > > > > You are welcome tho share your knowledge there also! Porlets &
> > > MyFaces
> > > > > are
> > > > > > > still a seldom combination, I learned.
> > > > > > > >
> > > > > > > > Regards,
> > > > > > > >
> > > > > > > > Stephan
> > > > > > > >
> > > > > > > >
> > > > > > > > ________________________________
> > > > > > >  From: Storm Spire [mailto: [EMAIL PROTECTED]]
> > > > > > > > Sent: Saturday, July 15, 2006 9:13 AM
> > > > > > > > To: users@myfaces.apache.org
> > > > > > > > Subject: deploy MyFaces as portlet into Websphere Portal 5.1
> > > > > > > >
> > > > > > > >
> > > > > > > >
> > > > > > > > Hi,
> > > > > > > >   I am suffering on running myfaces app as portlet into
> websphere
> > > > > portal
> > > > > > > 5.1 these days.
> > > > > > > >   I am really not sure what I have done wrong.
> > > > > > > >   I can deploy the myfaces war file without a problem, but
> when I
> > > run
> > > > > the
> > > > > > > portlet, I will see an error " This portlet is unavailable".
> > > > > > > >   The log from PortalServer\log folder will only give this
> > > message:
> > > > > > > >
> > > > > > > > 2006.07.15 14:28:44.140 E
> > > > > > > com.ibm.wps.engine.tags.PortletRenderTag
> doStartTag
> > > > > > > >   javax.portlet.UnavailableException:
> > > WebApplication
> > > > > is
> > > > > > > stopped
> > > > > > > >
> > > > > > > >
> > > > > > > >   My environment:
> > > > > > > >   websphere portal 5.1.0.2
> > > > > > > >   myfaces 1.1.3
> > > > > > > >   windows XP
> > > > > > > >
> > > > > > > >   Here is my 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>testPortal</display-name>
> > > > > > > >     <context-param>
> > > > > > > >         <param-name> javax.faces.CONFIG_FILES </param-name>
> > > > > > > >         <param-value>
> > > > > > > >             /WEB-INF/faces- config.xml
> > > > > > > >         </param-value>
> > > > > > > >     </context-param>
> > > > > > > >     <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>
> > > > > > > >     <servlet-mapping>
> > > > > > > >         <servlet-name>Faces Servlet</servlet-name>
> > > > > > > >         <url-pattern>*.jsf</url-pattern>
> > > > > > > >     </servlet-mapping>
> > > > > > > >     <welcome-file-list>
> > > > > > > >         <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>
> > > > > > > > </web-app>
> > > > > > > >
> ------------------------------------------------
> > > > > > > >
> > > > > > > > my portlet.xml:
> > > > > > > >
> ------------------------------------------------
> > > > > > > > <?xml version=" 1.0" encoding="UTF-8"?>
> > > > > > > > <portlet-app xmlns="
> > > > > > >
> > > http://java.sun.com/xml/ns/portlet/portlet-app_1_0.xsd
> "
> > > > > > > version=" 1.0" 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
> > > > > "
> > > > > > > id=" testPortal.8ba3a7c6c0">
> > > > > > > >     <portlet>
> > > > > > > >         <portlet-name>csc</portlet-name>
> > > > > > > >         <display-name>csc portlet</display-name>
> > > > > > > >         <display-name xml:lang="zh">csc portlet</display-name>
> > > > > > > >         <portlet-class>
> > > > > > > >
> > > > > > >
> org.apache.myfaces.portlet.MyFacesGenericPortlet
> > > > > > > >         </portlet-class>
> > > > > > > >         <init-param>
> > > > > > > >             <name>default-view</name>
> > > > > > > >             <value>/test.jsp</value>
> > > > > > > >         </init-param>
> > > > > > > >         <supports>
> > > > > > > >             <mime-type>text/html</mime-type>
> > > > > > > >             <portlet-mode>view</portlet-mode>
> > > > > > > >         </supports>
> > > > > > > >         <portlet-info>
> > > > > > > >             <title>csc portlet</title>
> > > > > > > >         </portlet-info>
> > > > > > > >     </portlet>
> > > > > > > > </portlet-app>
> > > > > > > >
> ------------------------------------------------
> > > > > > > > My faces-config.xml is empty, as I want to test the plain jsf
> > > only,
> > > > > didn't
> > > > > > > use any managed bean.
> > > > > > > >
> > > > > > >
> > > > > > >
> > > > > >
> > > > > >
> > > > > > --
> > > > > > Matthias Wessendorf
> > > > > >
> > > > > > further stuff:
> > > > > > blog: http://jroller.com/page/mwessendorf
> > > > > > mail: mwessendorf-at-gmail-dot-com
> > > > > >
> > > > >
> > > > >
> > > >
> > >
> > >
> >
>
>



 

Reply via email to