• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Does doView() calls service() method?

 
Ranch Hand
Posts: 3852
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I got the following exception when viewing the portlet first time:

Could not invoke the service() method on servlet LoginPortlet. Exception thrown : javax.servlet.ServletException

doView() method is getting called for sure. Why its not rendering the JSP included in doView()?

Why it's trying to call service() method of servlet LoginPortlet?

Thanks.
 
author and cow tipper
Posts: 5009
1
Hibernate Spring Tomcat Server
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Which API are you using? Are you using the JetSpeed API or the JRS168 API for portlet development?

Which portal server are you using? Pluto? Liferay? WebSphere Portal Server? JetSpeed? BEA?

Which development environment are you using?

-Cameron McKenzie
 
ankur rathi
Ranch Hand
Posts: 3852
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Cameron McKenzie:
Which API are you using? Are you using the JetSpeed API or the JRS168 API for portlet development?

Which portal server are you using? Pluto? Liferay? WebSphere Portal Server? JetSpeed? BEA?

Which development environment are you using?

-Cameron McKenzie



Thanks Cameron.

API - ? (I guess Websphere Portal API which follows JSR 168 specificaitons, right?)
Server - Websphere Portal Server 6.0
IDE - RAD
 
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I also get similar error when deploying a simple portlet

API - jsr168
Server - Websphere Portal Server 6.0.1.1
IDE - RAD 7.0 (7.0.0.3)

I created a Basic Portlet based on JSR168 API and published on the portal server. when i open the portal, it throws this exception.

The stack trace is as follows :-
SRVE0068E: Could not invoke the service() method on servlet /_MyPortlet/jsp/html/MyPortletView.jsp. Exception thrown : java.lang.NullPointerException
at com.ibm._jsp._MyPortletView._jspService(_MyPortletView.java:111)
at com.ibm.ws.jsp.runtime.HttpJspBase.service(HttpJspBase.java:91)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1572)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:762)
at com.ibm.wsspi.webcontainer.servlet.GenericServletWrapper.handleRequest(GenericServletWrapper.java:121)
at com.ibm.ws.jsp.webcontainerext.JSPExtensionServletWrapper.handleRequest(JSPExtensionServletWrapper.java:204)
at com.ibm.ws.jsp.webcontainerext.JSPExtensionProcessor.handleRequest(JSPExtensionProcessor.java:254)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.include(WebAppRequestDispatcher.java:633)
at org.apache.pluto.core.impl.PortletRequestDispatcherImpl.include(PortletRequestDispatcherImpl.java:112)
at dai.itpde.rap.myportlet.MyPortlet.doView(MyPortlet.java:44)
at javax.portlet.GenericPortlet.doDispatch(GenericPortlet.java:235)
....
Could not invoke the service() method on servlet MyPortlet. Exception thrown : javax.servlet.ServletException
at com.ibm.wps.pe.pc.std.invoker.impl.PortletServlet.convertException(PortletServlet.java:230)
at com.ibm.wps.pe.pc.std.invoker.impl.PortletServlet.dispatch(PortletServlet.java:208)
at com.ibm.wps.pe.pc.std.invoker.impl.PortletServlet.doGet(PortletServlet.java:69)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:743)
at com.ibm.wps.pe.pc.std.cache.CacheablePortlet.service(CacheablePortlet.java:393)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1572)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:762)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.include(WebAppRequestDispatcher.java:633)
at com.ibm.wps.pe.om.definition.impl.ServletDefinitionImpl$RDWrapper.include(ServletDefinitionImpl.java:419)
at com.ibm.wps.pe.pc.std.invoker.impl.PortletInvokerImpl.invoke(PortletInvokerImpl.java:206)
at com.ibm.wps.pe.pc.std.invoker.impl.PortletInvokerImpl.invoke(PortletInvokerImpl.java:168)
at com.ibm.wps.pe.pc.std.invoker.impl.PortletInvokerImpl.render(PortletInvokerImpl.java:97)
at com.ibm.wps.pe.pc.std.PortletContainerImpl.renderPortlet(PortletContainerImpl.java:110)
at com.ibm.wps.pe.pc.PortletContainerImpl.doRenderPortlet(PortletContainerImpl.java:587)
at com.ibm.wps.pe.ext.render.AbstractRenderManager.performService(AbstractRenderManager.java:247)
at com.ibm.wps.pe.pc.PortletContainerImpl.renderPortlet(PortletContainerImpl.java:115)
at com.ibm.wps.engine.tags.PortletRenderTag.doStartTag(PortletRenderTag.java:161)
at com.ibm._jsp._Control._jspx_meth_portal$1skin_portletRender_0(_Control.java:953)
at com.ibm._jsp._Control._jspx_meth_portal$1logic_if_4(_Control.java:985)
at com.ibm._jsp._Control._jspService(_Control.java:582)
at com.ibm.ws.jsp.runtime.HttpJspBase.service(HttpJspBase.java:91)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1572)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1521)



and it goes on and on....

I am very new to portal development.

any kinda help is appreciated.

Thanks in advance
 
Cameron Wallace McKenzie
author and cow tipper
Posts: 5009
1
Hibernate Spring Tomcat Server
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
A JSR168 portlet shouldn't be throwing a ServletException.

I'm guessing, but I think your environment, when they deploy, is treating your resources as Servlets/JSPs. As a result, the environment is looking for a service method, and throwing a ServletException.

Check your server configuration, or how your project is associated with the server. There is a portlet.xml file in the WEB-INF folder, right?

-Cameron McKenzie
 
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

Am just facing the same problem. My project do have portlet.xml How it be resolved?
 
Cameron Wallace McKenzie
author and cow tipper
Posts: 5009
1
Hibernate Spring Tomcat Server
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
How are you configuring WebSphere authorization. Are you trying to do a custom authentication against LDAP or a custom user registry?

This is a pretty old thread. If your situation or environment is unique, you might want to start a new thread, and reference this thread in it.

-Cameron McKEnzie
 
Neil And
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
At this moment I didnot configure any authorisation and at a latter stage I will be using the the Users and Groups in Websphere Portal to give access to different users. Am getting the same exception as below:

API - JSR 168
Server - Websphere Portal Server 6.0.1.3
IDE - RAD 7.0.0.8


SRVE0068E: Could not invoke the service() method on servlet /_LHNavigation/jsp/html/LHNavPortletView.jsp. Exception thrown : java.util.NoSuchElementException
at java.util.LinkedList$ListItr.next(LinkedList.java(Compiled Code))
at com.ibm._jsp._LHNavPortletView._jspService(_LHNavPortletView.java:129)
at com.ibm.ws.jsp.runtime.HttpJspBase.service(HttpJspBase.java:93)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1697)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java(Compiled Code))
at com.ibm.wsspi.webcontainer.servlet.GenericServletWrapper.handleRequest(GenericServletWrapper.java:121)
at com.ibm.ws.jsp.webcontainerext.JSPExtensionServletWrapper.handleRequest(JSPExtensionServletWrapper.java:221)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.include(WebAppRequestDispatcher.java:670)
at org.apache.pluto.core.impl.PortletRequestDispatcherImpl.include(PortletRequestDispatcherImpl.java:112)
at uk.ui.LHNavPortlet.doView(LHNavPortlet.java:118)
at javax.portlet.GenericPortlet.doDispatch(GenericPortlet.java:235)
at javax.portlet.GenericPortlet.render(GenericPortlet.java:163)
at com.ibm.wps.pe.pc.std.cmpf.impl.PortletFilterChainImpl.render(PortletFilterChainImpl.java:144)
at com.ibm.wps.pe.pc.std.invoker.impl.PortletServlet.dispatch(PortletServlet.java:130)
at com.ibm.wps.pe.pc.std.invoker.impl.PortletServlet.doGet(PortletServlet.java:69)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:743)
 
Bartender
Posts: 2856
10
Firefox Browser Fedora Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
"Neil And " welcome to Javaranch
please check your private messages for an important administrative matter. You can check them by clicking the My Private Messages link above.
reply
    Bookmark Topic Watch Topic
  • New Topic