• 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 all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Liutauras Vilda
  • Junilu Lacar
  • Jeanne Boyarsky
  • Bear Bibeault
Sheriffs:
  • Knute Snortum
  • Devaka Cooray
  • Tim Cooke
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Ron McLeod
  • Carey Brown
Bartenders:
  • Paweł Baczyński
  • Piet Souris
  • Vijitha Kumara

Struts2.1.8 in weblogic 10.3

 
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I am using struts 2.1.8 in weblogic portal and i am getting this error
my web.xml and portlet.xml are given below

The portlet "HelloWorld" is not available. The portlet class org.apache.struts2.portlet.dispatcher.Jsr168Dispatcher is not found.
javax.portlet.UnavailableException: The portlet "HelloWorld" is not available. The portlet class org.apache.struts2.portlet.dispatcher.Jsr168Dispatcher is not found.

at com.bea.portlet.container.PortletStub.createPortletInstance(PortletStub.java:744)

at com.bea.portlet.container.PortletStub.getPortletInstance(PortletStub.java:677)

at com.bea.portlet.container.PortletStub.init(PortletStub.java:215)

at com.bea.portlet.container.AppContainer.invokeRender(AppContainer.java:803)

at com.bea.netuix.servlets.controls.content.JavaPortletContent.fireRender(JavaPortletContent.java:264)

at com.bea.netuix.servlets.controls.content.JavaPortletContent.renderInternal(JavaPortletContent.java:159)

at com.bea.netuix.servlets.controls.content.JavaPortletContent.beginRender(JavaPortletContent.java:106)

at com.bea.netuix.servlets.controls.application.laf.ContentControlRenderer.beginRender(ContentControlRenderer.java:48)

at com.bea.netuix.nf.ControlLifecycle$7.visit(ControlLifecycle.java:481)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:518)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walk(ControlTreeWalker.java:220)

at com.bea.netuix.nf.Lifecycle.processLifecycles(Lifecycle.java:395)

at com.bea.netuix.nf.Lifecycle.processLifecycles(Lifecycle.java:361)

at com.bea.netuix.nf.Lifecycle.processLifecycles(Lifecycle.java:352)

at com.bea.netuix.nf.Lifecycle.run(Lifecycle.java:326)

at com.bea.netuix.nf.UIControl.render(UIControl.java:582)

at com.bea.netuix.servlets.controls.PresentationContext.render(PresentationContext.java:486)

at com.bea.netuix.servlets.util.RenderToolkit.renderChild(RenderToolkit.java:146)

at com.bea.netuix.servlets.jsp.taglib.RenderChild.doStartTag(RenderChild.java:62)

at jsp_servlet._framework._skeletons._default.__flowlayout._jspService(__flowlayout.java:271)

at weblogic.servlet.jsp.JspBase.service(JspBase.java:34)

at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)

at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)

at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:292)

at weblogic.servlet.internal.ServletStubImpl.onAddToMapException(ServletStubImpl.java:408)

at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:318)

at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:175)

at weblogic.servlet.internal.RequestDispatcherImpl.invokeServlet(RequestDispatcherImpl.java:505)

at weblogic.servlet.internal.RequestDispatcherImpl.include(RequestDispatcherImpl.java:432)

at com.bea.netuix.servlets.controls.application.laf.JspTools.renderJsp(JspTools.java:130)

at com.bea.netuix.servlets.controls.application.laf.JspControlRenderer.beginRender(JspControlRenderer.java:72)

at com.bea.netuix.servlets.controls.application.laf.PresentationControlRenderer.beginRender(PresentationControlRenderer.java:65)

at com.bea.netuix.nf.ControlLifecycle$7.visit(ControlLifecycle.java:481)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:518)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walkRecursiveRender(ControlTreeWalker.java:529)

at com.bea.netuix.nf.ControlTreeWalker.walk(ControlTreeWalker.java:220)

at com.bea.netuix.nf.Lifecycle.processLifecycles(Lifecycle.java:395)

at com.bea.netuix.nf.Lifecycle.processLifecycles(Lifecycle.java:361)

at com.bea.netuix.nf.Lifecycle.runOutbound(Lifecycle.java:208)

at com.bea.netuix.nf.Lifecycle.run(Lifecycle.java:168)

at com.bea.netuix.servlets.manager.UIServlet.runLifecycle(UIServlet.java:388)

at com.bea.netuix.servlets.manager.UIServlet.processControlTree(UIServlet.java:301)

at com.bea.netuix.servlets.manager.PortalServlet.service(PortalServlet.java:927)

at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)

at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)

at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)

at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:292)

at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26)

at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:42)

at com.bea.portal.tools.servlet.http.HttpContextFilter.doFilter(HttpContextFilter.java:60)

at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:42)

at com.bea.p13n.servlets.PortalServletFilter.doFilter(PortalServletFilter.java:336)

at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:42)

at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3502)

at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)

at weblogic.security.service.SecurityManager.runAs(Unknown Source)

at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2186)

at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2092)

at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1406)

at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)

at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)


web.xml :-
<?xml version="1.0" encoding="UTF-8"?>
<web-app id="WebApp_ID" 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">
<display-name>StrutsSample</display-name>
<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>
<filter>
<filter-name>struts2</filter-name>
<filter-class>org.apache.struts2.dispatcher.FilterDispatcher</filter-class>
</filter>

<filter-mapping>
<filter-name>struts2</filter-name>
<url-pattern>*.action</url-pattern>
</filter-mapping>
<filter>
<filter-name>PageFlowJspFilter</filter-name>
<filter-class>org.apache.beehive.netui.pageflow.PageFlowJspFilter</filter-class>
</filter>
<filter>
<filter-name>PageFlowForbiddenFilter</filter-name>
<filter-class>org.apache.beehive.netui.pageflow.PageFlowForbiddenFilter</filter-class>
<init-param>
<param-name>response-code</param-name>
<param-value>404</param-value>
</init-param>
</filter>
<filter-mapping>
<filter-name>PageFlowJspFilter</filter-name>
<url-pattern>*.jsp</url-pattern>
<dispatcher>FORWARD</dispatcher>
<dispatcher>REQUEST</dispatcher>
<dispatcher>INCLUDE</dispatcher>
</filter-mapping>
<filter-mapping>
<filter-name>PageFlowJspFilter</filter-name>
<url-pattern>*.jspx</url-pattern>
<dispatcher>FORWARD</dispatcher>
<dispatcher>REQUEST</dispatcher>
<dispatcher>INCLUDE</dispatcher>
</filter-mapping>
<filter-mapping>
<filter-name>PageFlowForbiddenFilter</filter-name>
<url-pattern>*.java</url-pattern>
<dispatcher>REQUEST</dispatcher>
</filter-mapping>
<filter-mapping>
<filter-name>PageFlowForbiddenFilter</filter-name>
<url-pattern>*.jsfb</url-pattern>
<dispatcher>REQUEST</dispatcher>
</filter-mapping>
<filter-mapping>
<filter-name>PageFlowForbiddenFilter</filter-name>
<url-pattern>*.jpfs</url-pattern>
<dispatcher>REQUEST</dispatcher>
</filter-mapping>
<listener>
<listener-class>org.apache.beehive.netui.pageflow.PageFlowContextListener</listener-class>
</listener>
<listener>
<listener-class>org.apache.beehive.netui.pageflow.HttpSessionMutexListener</listener-class>
</listener>
<servlet>
<servlet-name>action</servlet-name>
<servlet-class>org.apache.beehive.netui.pageflow.PageFlowActionServlet</servlet-class>
<init-param>
<param-name>config</param-name>
<param-value>/_pageflow/struts-config.xml</param-value>
</init-param>
<init-param>
<param-name>debug</param-name>
<param-value>2</param-value>
</init-param>
<init-param>
<param-name>detail</param-name>
<param-value>2</param-value>
</init-param>
<load-on-startup>2</load-on-startup>
</servlet>
<servlet>
<servlet-name>XmlHttpRequestServlet</servlet-name>
<servlet-class>org.apache.beehive.netui.pageflow.xmlhttprequest.XmlHttpRequestServlet</servlet-class>
</servlet>


<servlet id="Struts2PortletDispatcherServlet">
<servlet-name>Struts2PortletDispatcherServlet</servlet-name>
<servlet-class>org.apache.struts2.portlet.dispatcher.DispatcherServlet</servlet-class>
</servlet>
<servlet-mapping>
<servlet-name>action</servlet-name>
<url-pattern>*.jpf</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>action</servlet-name>
<url-pattern>*.do</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>XmlHttpRequestServlet</servlet-name>
<url-pattern>*.xhr</url-pattern>
</servlet-mapping>
<servlet-mapping>
<servlet-name>XmlHttpRequestServlet</servlet-name>
<url-pattern>*.render</url-pattern>
</servlet-mapping>

</web-app>


Portlet.xml :-

<?xml version="1.0" encoding="UTF-8"?>
<portlet-app version="1.0"
xmlns="http://java.sun.com/xml/ns/portlet/portlet-app_1_0.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"
id="my-portlet-app">

<portlet>
<description>Hello World </description>
<portlet-name>HelloWorld</portlet-name>
<display-name> hello world </display-name>
<portlet-class>org.apache.struts2.portlet.dispatcher.Jsr168Dispatcher</portlet-class>
<init-param>
<!-- Portlet namespace -->
<name>portletNamespace</name>
<value>/portletA</value>
</init-param>
<init-param>
<!-- The base namespace of the view portlet mode -->
<name>viewNamespace</name>
<value>/view</value>
</init-param>
<init-param>
<!-- The default action to invoke in view mode -->
<name>defaultViewAction</name>
<value>index</value>
</init-param>

<supports>
<mime-type>text/html</mime-type>
<portlet-mode>view</portlet-mode>
</supports>
<portlet-info>
<title>HelloWorld</title>
</portlet-info>
</portlet>
</portlet-app>


Can anyone please tell me what should i do...?
 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please check whether you have "struts2-portlet-plugin-2.1.8.1.jar" in your runtime classpath.

Bijesh
 
Because those who mind don't matter and those who matter don't mind - Seuss. Tiny ad:
Java file APIs (DOC, XLS, PDF, and many more)
https://products.aspose.com/total/java
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!