You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Darryl Nortje <Da...@astrolabegroup.com> on 2001/12/03 09:12:16 UTC

RE: problems getting struts example to run

Hi Jon, I changed the two lines to what you said. I did not make any
difference still got the error
java.lang.IllegalArgumentException: cant remove Attributes from request
scope.

There is something wrong with the Constants.BEAN_KEY. it is either not being
set which I was trying to trace in the FormTag.doStartTag() at the last line
--> pageContext.setAttribute(Constants.BEAN_KEY, bean);

I can't see anything wrong with the way it is setting the attribute, so the
way it is removing the attribute should not be a problem. Any more ideas you
might have would be welcome. I'll keep going on? Thanks again for the
replies.

cheers
Darryl

-----Original Message-----
From: Jon.Ridgway [mailto:Jon.Ridgway@upco.co.uk]
Sent: Friday, November 30, 2001 2:35 PM
To: 'Struts Users Mailing List'
Subject: RE: problems getting struts example to run


Hi,

Change the two lines of code in FormTag.doEndTag that remove attributes from
the request to read:

    pageContext.getRequest().removeAttribute(Constants.BEAN_KEY);
    pageContext.getRequest().removeAttribute(Constants.FORM_KEY);
    
Jon Ridgway
www.upco.co.uk

-----Original Message-----
From: Darryl Nortje [mailto:DarrylN@astrolabegroup.com] 
Sent: 30 November 2001 11:36
To: 'Struts Users Mailing List'
Subject: problems getting struts example to run

I have done my homework. I just cannot get the Struts example to run in
VAJ4.0 using WTE (not WAS). Please can someone help me. the following are
the symptoms.

I type in the url http:/localhost:8080/strutsexample/index.jsp	I then get
to the main page. When I click on the logon url, the following error msg
appears. (-*********)

now I managed to trace this down to the doEndTag() method in
org.apache.struts.taglib.FormTag class. When it executes the line
"pageContext.removeAttribute(Constants.BEAN_KEY);" IT CHUCKS THE EXCEPTION.

Thanking you in advance for your help with this. *cos i don't have a clue.

regards
Darryl

-********* Error 500
An error has occured while processing
request:http://localhost:8080/strutsexample/logon.jsp
Message: Server caught unhandled exception from servlet [jsp]: cant remove
Attributes from request scope

Target Servlet: jsp
StackTrace: 
----------------------------------------------------------------------------
----
Root Error-1: cant remove Attributes from request scope

java.lang.IllegalArgumentException: cant remove Attributes from request
scope
	java.lang.Throwable(java.lang.String)
	java.lang.Exception(java.lang.String)
	java.lang.RuntimeException(java.lang.String)
	java.lang.IllegalArgumentException(java.lang.String)
	void
org.apache.jasper.runtime.PageContextImpl.removeAttribute(java.lang.String,
int)
	int org.apache.struts.taglib.html.FormTag.doEndTag()
	void _logon_xjsp._jspService(javax.servlet.http.HttpServletRequest,
javax.servlet.http.HttpServletResponse)
	void
org.apache.jasper.runtime.HttpJspBase.service(javax.servlet.http.HttpServlet
Request, javax.servlet.http.HttpServletResponse)
	void
javax.servlet.http.HttpServlet.service(javax.servlet.ServletRequest,
javax.servlet.ServletResponse)
	void
org.apache.jasper.runtime.JspServlet$JspServletWrapper.service(javax.servlet
.http.HttpServletRequest, javax.servlet.http.HttpServletResponse, boolean)
	void
org.apache.jasper.runtime.JspServlet.serviceJspFile(javax.servlet.http.HttpS
ervletRequest, javax.servlet.http.HttpServletResponse, java.lang.String,
java.lang.Throwable, boolean)
	void
org.apache.jasper.runtime.JspServlet.service(javax.servlet.http.HttpServletR
equest, javax.servlet.http.HttpServletResponse)
	void
javax.servlet.http.HttpServlet.service(javax.servlet.ServletRequest,
javax.servlet.ServletResponse)
	void
com.ibm.servlet.engine.webapp.StrictServletInstance.doService(javax.servlet.
ServletRequest, javax.servlet.ServletResponse)
	void
com.ibm.servlet.engine.webapp.StrictLifecycleServlet._service(javax.servlet.
ServletRequest, javax.servlet.ServletResponse)
	void
com.ibm.servlet.engine.webapp.IdleServletState.service(com.ibm.servlet.engin
e.webapp.StrictLifecycleServlet, javax.servlet.ServletRequest,
javax.servlet.ServletResponse)
	void
com.ibm.servlet.engine.webapp.StrictLifecycleServlet.service(javax.servlet.S
ervletRequest, javax.servlet.ServletResponse)
	void
com.ibm.servlet.engine.webapp.ServletInstance.service(javax.servlet.ServletR
equest, javax.servlet.ServletResponse,
com.ibm.servlet.engine.webapp.WebAppServletInvocationEvent)
	void
com.ibm.servlet.engine.webapp.ValidServletReferenceState.dispatch(com.ibm.se
rvlet.engine.webapp.ServletInstanceReference, javax.servlet.ServletRequest,
javax.servlet.ServletResponse,
com.ibm.servlet.engine.webapp.WebAppServletInvocationEvent)
	void
com.ibm.servlet.engine.webapp.ServletInstanceReference.dispatch(javax.servle
t.ServletRequest, javax.servlet.ServletResponse,
com.ibm.servlet.engine.webapp.WebAppServletInvocationEvent)
	void
com.ibm.servlet.engine.webapp.WebAppRequestDispatcher.handleWebAppDispatch(c
om.ibm.servlet.engine.webapp.WebAppRequest,
javax.servlet.http.HttpServletResponse, boolean)
	void
com.ibm.servlet.engine.webapp.WebAppRequestDispatcher.dispatch(javax.servlet
.ServletRequest, javax.servlet.ServletResponse, boolean)
	void
com.ibm.servlet.engine.webapp.WebAppRequestDispatcher.forward(javax.servlet.
ServletRequest, javax.servlet.ServletResponse)
	void
com.ibm.servlet.engine.srt.WebAppInvoker.handleInvocationHook(java.lang.Obje
ct)
	void
com.ibm.servlet.engine.invocation.CachedInvocation.handleInvocation(java.lan
g.Object)
	void
com.ibm.servlet.engine.srp.ServletRequestProcessor.dispatchByURI(java.lang.S
tring, com.ibm.servlet.engine.srp.ISRPConnection)
	void
com.ibm.servlet.engine.oselistener.OSEListenerDispatcher.service(com.ibm.ser
vlet.engine.oselistener.api.IOSEConnection)
	void
com.ibm.servlet.engine.http_transport.HttpTransportHandler.handleConnection(
java.net.Socket)
	void
com.ibm.servlet.engine.http_transport.HttpTransportHandler.run()
	void java.lang.Thread.run()


--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>

--
To unsubscribe, e-mail:
<ma...@jakarta.apache.org>
For additional commands, e-mail:
<ma...@jakarta.apache.org>

--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>