Shell error

Hi Turian/All

I am creating a new thread to discuss on shell topic for everyones convenience.

The steps that I followed to create a shell is this::
1)created the portlets for header, footer and left navigation panel and created the aliases for the same.
2)created a shell ‘drytest’ by configuring the aliases that I created for header, footer and leftnav. please find the screen attached.
3)created one user ‘jyotiranjan’.
4)created a shell rule ‘invtest’ with user ‘jyotiranjan’ and the shell.
5)I logged out of MWS and tried logging in with user ‘jyotiranjan’ and password. But I am getting java.lang.ClassCastException.

Am I following the correct steps or missing out on something?
Quick help is really appreciated.

Regards
jyoti


The error is resolved as I put the user into ‘Admin Role’.
But how can I be able to see the header, footer and leftnav that I created for a portlet?

Regards
Jyoti

Hi Jyoti,

Do you have other shell rules defined?

If yes, please make sure that your rule is the one that get’s triggered. An idea is to move it first in the list of rules as they are interpreted in the order from the list.

Please let us know if this is the problem. If not, we can dig further.

Regards,
Vlad Turian

yes Turian.
I moved my shell rule to the top on the evaluation order and checked.
Even I tried with the webMethods pre-defined headers and footers and it was working. So I created my header in the Folder–Systems–Shell Section and tested, but no result. I was getting the same error java.lang.ClassCastException.

Regards
Jyoti

Hi Jyoti,

Please share with us the full stack trace of the exception and the MWS fix pack you have installed.
We will try to reproduce the erroneous behavior ourselves.

Thank you.
Vlad Turian

Hi Turian,

We are using MWS::

Version: 8.0.3.0.97
Build Date: 2010-06-02

We created portlets for header, footer and left navigation and created aliases for the same. While using them we are getting the below error::

2015-08-05 16:25:22 IST (Framework:FATAL) [RID:1535] - [POP.001.0002] A “java.lang.ClassCastException” occurred with the Message “com.webMethods.portal.framework.portletcontainer.mech.PortletApplicationMechanics cannot be cast to com.webMethods.portal.mech.storage.IFolderMechanics”
java.lang.ClassCastException: com.webMethods.portal.framework.portletcontainer.mech.PortletApplicationMechanics cannot be cast to com.webMethods.portal.mech.storage.IFolderMechanics
at com.webMethods.portal.framework.presentation.renderers.PortalPageSubRenderer.getPageData(PortalPageSubRenderer.java:884)
at com.webMethods.portal.framework.presentation.renderers.ShellSubRenderer.subrender(ShellSubRenderer.java:75)
at com.webMethods.portal.framework.presentation.renderers.DefaultRenderer.renderPageStart(DefaultRenderer.java:311)
at com.webMethods.portal.framework.presentation.renderers.DefaultRenderer.render(DefaultRenderer.java:265)
at com.webMethods.portal.framework.presentation.PresentationManager.handlePres(PresentationManager.java:389)
at com.webMethods.portal.framework.dispatch.DispatchManager.pres(DispatchManager.java:640)
at com.webMethods.portal.framework.dispatch.DispatchManager.handle(DispatchManager.java:470)
at com.webMethods.portal.framework.dispatch.DispatchManager.handleDispatch(DispatchManager.java:381)
at com.webMethods.portal.framework.impl.PortalServlet.service(PortalServlet.java:308)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:511)
at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1221)
at com.webMethods.portal.framework.impl.NTLMV1Filter.doFilter(NTLMV1Filter.java:50)
at com.webMethods.portal.framework.impl.NTLMFilter.doFilter(NTLMFilter.java:28)
at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1212)
at com.webMethods.caf.faces.servlet.GZIPFilter.doFilter(GZIPFilter.java:47)
at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1212)
at com.webMethods.portal.framework.impl.RequestFilter.doFilter(RequestFilter.java:56)
at org.mortbay.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1212)
at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:399)
at org.mortbay.jetty.security.SecurityHandler.handle(SecurityHandler.java:216)
at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182)
at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:767)
at org.mortbay.jetty.webapp.WebAppContext.handle(WebAppContext.java:450)
at org.mortbay.jetty.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:230)
at org.mortbay.jetty.handler.HandlerCollection.handle(HandlerCollection.java:114)
at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
at org.mortbay.jetty.Server.handle(Server.java:326)
at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:542)
at org.mortbay.jetty.HttpConnection$RequestHandler.headerComplete(HttpConnection.java:928)
at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:549)
at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:212)
at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:410)
at org.mortbay.thread.BoundedThreadPool$PoolThread.run(BoundedThreadPool.java:451

And while we set the folder level alias, the portlets are not getting evaluated.

Regards
Jyoti

Hi Jyoti,

Is there anyway in which you can share what me the artefacts that you have made.

I want to install them on my wm installation and check if I have the same problem.

Thank you.
Vlad Turian

Hello Turian/All,

It worked.
I am explaining the full steps below.

1)create a new shell and select the parent shell as any one of the existing shell.
2)In the Header, Footer Leftnav and Rightnav section, click on ‘Clone from Parent’.
3)Go to Folders–Systems–Shell Section. There you can see the folders created for which you selected Clone from Parent.
4)Then go inside every folder and delete whatever components you don’t require and drag and drop your custom portlets that you want to use as Header, Footer, Leftnav etc. by clicking ‘Edit Page’ on the folder level.
5)Create a new user and a new role and add that user to the role.
6)Create a shell rule with the Role that you have defined.
7)put your shell rule on the top in the evaluation order.
8)Logout and login with the user you have created in the step 5. and check if its working.

Regards
Jyoti