Runtime failure in custom tag
I was curious if you knew what specifically you did to remove the runtime error.
I am also getting the runtime failure. The try/catch that another discussion thread
suggested does not catch the error since the exception is thrown prior to the
doStart and doEnd Tag methods. I know that the exception is thrown immediately
after the constructor is called for the tag and before the setParent method is
called.
Anyway, thank you in advance for any suggestions you might have.
try { // begin instantiate/release try/catch/finally block... //[ /wattage/wtgMainMenu.jsp;
Line: 36]
westerncommon_jsptag_HeaderTag_0 = (western.common.jsptag.HeaderTag)java.beans.Beans.instantiate(getClass().getClassLoader(),
"western.common.jsptag.HeaderTag"); //[ /wattage/wtgMainMenu.jsp; Line: 36]
westerncommon_jsptag_HeaderTag_0.setPageContext(pageContext); //[ /wattage/wtgMainMenu.jsp;
Line: 36]
westerncommon_jsptag_HeaderTag_0.setParent(null); //[ /wattage/wtgMainMenu.jsp;
Line: 36]
westerncommon_jsptag_HeaderTag_0.setNavMenuHREF(weblogic.utils.StringUtils.valueOf("wtgLogout.jsp"));
//[ /wattage/wtgMainMenu.jsp; Line: 36]
westerncommon_jsptag_HeaderTag_0.setNavMenu(weblogic.utils.StringUtils.valueOf("Logout"));
//[ /wattage/wtgMainMenu.jsp; Line: 36]
westerncommon_jsptag_HeaderTag_0.setTitle(weblogic.utils.StringUtils.valueOf("Main
Menu")); //[ /wattage/wtgMainMenu.jsp; Line: 36]
int int0 = westerncommon_jsptag_HeaderTag_0.doStartTag(); //[ /wattage/wtgMainMenu.jsp;
Line: 36]
if (_int_0 == BodyTag.EVAL_BODY_TAG) { //[ /wattage/wtgMainMenu.jsp; Line: 36]
throw new JspTagException("Since tag class western.common.jsptag.HeaderTag does
not implements BodyTag, it cannot return BodyTag.EVAL_BODY_TAG"); //[ /wattage/wtgMainMenu.jsp;
Line: 36]
} //[ /wattage/wtgMainMenu.jsp; Line: 36]
/*** sync AT_BEGIN TagExtra Vars here ***/ //[ /wattage/wtgMainMenu.jsp;
Line: 36]
if (_int_0 != Tag.SKIP_BODY) { // begin !SKIP_BODY... //[ /wattage/wtgMainMenu.jsp;
Line: 36]
//[ /wattage/wtgMainMenu.jsp; Line: 36]
out.print("\r\n");
//[ /wattage/wtgMainMenu.jsp; Line: 37]
} // end !SKIP_BODY //[ /wattage/wtgMainMenu.jsp; Line: 37]
if (_western_common_jsptag_HeaderTag_0.doEndTag() == Tag.SKIP_PAGE) return;
//[ /wattage/wtgMainMenu.jsp; Line: 37]
} catch (java.lang.Exception javalang_Exception_0) { // instantiate/release
try/catch/finally //[ /wattage/wtgMainMenu.jsp; Line: 37]
throw new ServletException("runtime failure in custom tag 'HeaderTag'", javalang_Exception_0);
//[ /wattage/wtgMainMenu.jsp; Line: 37]
} finally { // instantiate/release try/catch/finally block... //[ /wattage/wtgMainMenu.jsp;
Line: 37]
if (_western_common_jsptag_HeaderTag_0 != null) westerncommon_jsptag_HeaderTag_0.release();
//[ /wattage/wtgMainMenu.jsp; Line: 37]
} //[ /wattage/wtgMainMenu.jsp; Line: 37]
----------CONSOLE OUTPUT-------------
Getting Page permissions for page: wtgMainMenu.jsp user: 0
Page Permissions: Insert-1 View-1 Update-1 Delete-1
HeaderTag -- Constructing
Thu Apr 05 11:19:00 CDT 2001:<E> <ServletContext-General> exception raised on
wattage/wtgMainMenu.jsp'
javax.servlet.ServletException: runtime failure in custom tag 'HeaderTag'
at jsp_servlet.wattage.wtgmainmenu._jspService(wtgmainmenu.java:398)
at weblogic.servlet.jsp.JspBase.service(JspBase.java:27)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubIm
pl.java:124)
at weblogic.servlet.internal.ServletContextImpl.invokeServlet(ServletCon
textImpl.java:744)
at weblogic.servlet.internal.ServletContextImpl.invokeServlet(ServletCon
textImpl.java:692)
at weblogic.servlet.internal.ServletContextManager.invokeServlet(Servlet
ContextManager.java:251)
at weblogic.socket.MuxableSocketHTTP.invokeServlet(MuxableSocketHTTP.jav
a:363)
at weblogic.socket.MuxableSocketHTTP.execute(MuxableSocketHTTP.java:263)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)
I just started getting this error after a year in production environment without any problems. Did you every find out what caused this or better yet how to prevent this?
Dan.
Similar Messages
-
Weblogic Commerce Server 3.5 runtime failure in custom tag
An error occurred:
javax.servlet.ServletException: runtime failure in custom tag 'process'
at jsp_compiled._tools._property._propset_create._jspService(_propset_create.java:641)
at weblogic.servlet.jsp.JspBase.service(JspBase.java:27)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:208)
at weblogic.servlet.internal.RequestDispatcherImpl.forward(RequestDispatcherImpl.java:149)
at com.beasys.commerce.foundation.flow.ServletDestinationHandler.handleDestination(ServletDestinationHandler.java:51)
at com.beasys.commerce.foundation.flow.FlowManager.service(FlowManager.java:540)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java:208)
at weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletContext.java:1127)
at weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java:1529)
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:137)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)I just started getting this error after a year in production environment without any problems. Did you every find out what caused this or better yet how to prevent this?
Dan.
-
Javax.servlet.ServletException: runtime failure in custom tag 'content'
Hi When iam trying to click on a link which takes to an another JSP.
iam getting this error after few minutes and that page doesnt display at
all.
can anybody help me out????
==vasan++;
<Jan 9, 2001 11:50:10 AM PST> <Error> <HTTP>
<[WebAppServletContext(627219,console)] exception raised on
'/console/panels/mbean/Server.jsp'
javax.servlet.ServletException: runtime failure in custom tag 'content'
at
weblogic.management.console.pages._panels._mbean._server._jspService(_server
.java:9798)
at weblogic.servlet.jsp.JspBase.service(JspBase.java:27)
at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java
:208)
at
weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletCo
ntext.java:1127)
at
weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java
:1529)
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:137)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)
>
<Jan 9, 2001 11:50:10 AM PST> <Error> <HTTP>
<[WebAppServletContext(627219,console)] Root cause of ServletException
java.net.SocketException: Connection reset by peer: socket write error
at java.net.SocketOutputStream.socketWrite(Native Method)
at java.net.SocketOutputStream.write(SocketOutputStream.java:83)
at
weblogic.servlet.internal.ChunkUtils.writeHeaderChunk(ChunkUtils.java:127)
at
weblogic.servlet.internal.ResponseHeaders.writeHeaders(ResponseHeaders.java:
345)
at
weblogic.servlet.internal.ServletResponseImpl.writeHeaders(ServletResponseIm
pl.java:683)
at
weblogic.servlet.internal.ServletOutputStreamImpl.flush(ServletOutputStreamI
mpl.java:124)
at
weblogic.servlet.internal.ServletOutputStreamImpl.flushWithCheck(ServletOutp
utStreamImpl.java:451)
at
weblogic.servlet.internal.ServletOutputStreamImpl.print(ServletOutputStreamI
mpl.java:243)
at
javax.servlet.ServletOutputStream.println(ServletOutputStream.java:286)
at
weblogic.servlet.jsp.JspWriterImpl.println(JspWriterImpl.java:204)
at
weblogic.management.console.pages._common._requestinfo.print(_requestinfo.ja
va:68)
at
weblogic.management.console.pages._common._requestinfo._jspService(_requesti
nfo.java:224)
at weblogic.servlet.jsp.JspBase.service(JspBase.java:27)
at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java
:208)
at
weblogic.servlet.internal.RequestDispatcherImpl.include(RequestDispatcherImp
l.java:249)
at
weblogic.servlet.internal.RequestDispatcherImpl.include(RequestDispatcherImp
l.java:167)
at
weblogic.servlet.jsp.PageContextImpl.include(PageContextImpl.java:104)
at
weblogic.management.console.pages._common._error._jspService(_error.java:162
at weblogic.servlet.jsp.JspBase.service(JspBase.java:27)
at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java
:208)
at
weblogic.servlet.internal.RequestDispatcherImpl.forward(RequestDispatcherImp
l.java:149)
at
weblogic.servlet.jsp.PageContextImpl.forward(PageContextImpl.java:100)
at
weblogic.management.console.pages._panels._mbean._server._jspService(_server
.java:9830)
at weblogic.servlet.jsp.JspBase.service(JspBase.java:27)
at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java
:208)
at
weblogic.servlet.internal.WebAppServletContext.invokeServlet(WebAppServletCo
ntext.java:1127)
at
weblogic.servlet.internal.ServletRequestImpl.execute(ServletRequestImpl.java
:1529)
at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:137)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)
>
I just started getting this error after a year in production environment without any problems. Did you every find out what caused this or better yet how to prevent this?
Dan.
-
<< runtime failure in custom tag 'process' >>>
Trying to create a simple portlet but it keeps giving the following stack
trace.
Any clues ?
TIA
javax.servlet.ServletException: runtime failure in custom tag 'process'
at
jsp._portals._repository.__user_add_portlets._jspService(__user_add_portlets
.java:871)
at weblogic.servlet.jsp.JspBase.service(JspBase.java:27)
at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java
:106)
at
weblogic.servlet.internal.RequestDispatcherImpl.forward(RequestDispatcherImp
l.java:154)
at
com.beasys.commerce.foundation.flow.ServletDestinationHandler.handleDestinat
ion(ServletDestinationHandler.java:51)
at
com.beasys.commerce.foundation.flow.FlowManager.service(FlowManager.java:448
at javax.servlet.http.HttpServlet.service(HttpServlet.java:865)
at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java
:106)
at
weblogic.servlet.internal.ServletContextImpl.invokeServlet(ServletContextImp
l.java:907)
at
weblogic.servlet.internal.ServletContextImpl.invokeServlet(ServletContextImp
l.java:851)
at
weblogic.servlet.internal.ServletContextManager.invokeServlet(ServletContext
Manager.java:252)
at
weblogic.socket.MuxableSocketHTTP.invokeServlet(MuxableSocketHTTP.java:364)
at weblogic.socket.MuxableSocketHTTP.execute(MuxableSocketHTTP.java:252)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:129)There are a number possible reasons for the error "runtime failure in custom tag
'process'" for WLCS 3.11 and 3.2. You might check the following:
1) Make sure that WebLogic Server 5.10 SP6 is installed correctly and that
weblogic510sp6.jar and weblogic510sp6boot.jar are at the fronts of
weblogic_classpath and java_classpath, respectively.
2) Check to see if weblogic-tags-510.jar from WebLogic Server 5.10 SP6 is copied
to %weblogic_home%\lib\weblogic-tags-510.jar.
3) The WLPS database is corrupted for reason or another. Rerun the appropriate
database script at \weblogiccommerce\db\cloudscape\create-all-cloudscape.bat or
\weblogiccommerce\db\oracle\create-all-oracle.sql.
Ted
aamerG wrote:
<< runtime failure in custom tag 'process' >>>
Trying to create a simple portlet but it keeps giving the following stack
trace.
Any clues ?
TIA
javax.servlet.ServletException: runtime failure in custom tag 'process'
at
jsp._portals._repository.__user_add_portlets._jspService(__user_add_portlets
.java:871)
at weblogic.servlet.jsp.JspBase.service(JspBase.java:27)
at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java
:106)
at
weblogic.servlet.internal.RequestDispatcherImpl.forward(RequestDispatcherImp
l.java:154)
at
com.beasys.commerce.foundation.flow.ServletDestinationHandler.handleDestinat
ion(ServletDestinationHandler.java:51)
at
com.beasys.commerce.foundation.flow.FlowManager.service(FlowManager.java:448
at javax.servlet.http.HttpServlet.service(HttpServlet.java:865)
at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java
:106)
at
weblogic.servlet.internal.ServletContextImpl.invokeServlet(ServletContextImp
l.java:907)
at
weblogic.servlet.internal.ServletContextImpl.invokeServlet(ServletContextImp
l.java:851)
at
weblogic.servlet.internal.ServletContextManager.invokeServlet(ServletContext
Manager.java:252)
at
weblogic.socket.MuxableSocketHTTP.invokeServlet(MuxableSocketHTTP.java:364)
at weblogic.socket.MuxableSocketHTTP.execute(MuxableSocketHTTP.java:252)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:129) -
Runtime exceptions in custom taglib
I am getting errors of the type:
javax.servlet.ServletException: runtime failure in custom tag
The problem is the error is happening in a taglib, but Weblogic is hiding the
original stack trace, and substituting it's own, which is useless in this case. Is
there any way to get the original stack trace?
-Jeff
With custom tags, each interface method needs to be entirely in a try..catch
to support debugging. WL hides the exact exception information. For
example:
public int doEndTag() throws JspException
try
catch (Throwable e)
throw e instanceof JspException ? (JspException) e : new
JspTagException(e.getMessage());
Cameron Purdy
[email protected]
http://www.tangosol.com
WebLogic Consulting Available
"Brian Homrich" <[email protected]> wrote in message
news:[email protected]...
> I'm getting the same type of error in the situation where an error has
occured
> in a page, my client uses "Back" on the browser, then tries another page
> (which uses a custom taglib).
>
> If I stop, then restart WL, all is ok. The page where the runtime
failure
> occured is ok now.
>
> Have you made any progress getting a stack trace, and have you found
anything
> interesting?
>
> Does anyone know why a failure on one page would cause the custom tags
> on another to fail like this? (Both pages use the same tag, but aren't
calls
> to a tag done independently?)
>
> Brian
>
> Jeff Nowakowski wrote:
>
> > I am getting errors of the type:
> >
> > javax.servlet.ServletException: runtime failure in custom tag
> >
> > The problem is the error is happening in a taglib, but Weblogic is
hiding the
> > original stack trace, and substituting it's own, which is useless in
this case. Is
> > there any way to get the original stack trace?
> >
> > -Jeff
>
-
Handling Exceptions in Custom Tags??
Hi,
what is the preferred way to handle an exception that is thrown from jsp
code in the body of a custom tag? The code below obviously causes a null
pointer exception inside of the custom tag. When the code executes, a
ServletException ( javax.servlet.ServletException: runtime failure in custom
tag 'golfPage' ) is thrown back. Is there any way to structure code so that
you get a better idea of what actually went wrong in the body of the custom
tag?
<golf:golfPage navRoot="admin_overview" title="Admin Overview" >
<br>
<%
Hashtable ht = null;
ht.put("test","test null pointer");
%>
</golf:golfPage>
Never mind... got the answer to my question:
http://www.ajug.org/archive/ajug-members/10306/msg00030.html
The encode methods are executed in the JSP which is why the implicit exception object is available... while the decode methods are executed as part of the Faces Servlet lifecycle and hence the exception object must be gotten from the request attribute...
I guess I need to take Servlet 101 all over again... -
Exception Handling with Custom Tags/Exceptions
Hello all --
I'm looking for some guidance in handling Custom errors in my app. I can't
seem to find the message string of my custom exception when trying to call
my JSP Error page. I'm consistently getting:
javax.servlet.jsp.JspTagException: runtime failure in custom tag
'CalendarHandler' .
I am using custom JSP tag libraries to process logic on my EJBs. When I
reach an error in business logic I raise a custom exception and propogate
this back up to doStartTag:
public int doStartTag() throws JspException {
CalendarProcessor cp = new CalendarProcessor();
try {
String eventAction = getEventID();
// pageContext contains information for the JSP;
// Initialize the page with the current context and session
cp.init(pageContext.getServletContext(), pageContext.getSession());
HttpServletRequest req = (HttpServletRequest)pageContext.getRequest();
cp.processRequest(req, eventAction );
} catch (CalendarException ce) {
throw new JspException(ce.getMessage());
return SKIP_BODY;
Then, in my JSP, I am enclosing the TagHandler in a try...catch block; I
can't catch CalendarException because it is Throwable and conflicts with
JspException.
<% try { %>
<gtc:CalendarHandler eventID="updatecal"/>
<% } catch (Exception e) {
throw e instanceof JspException ? (JspException) e : new
JspTagException(e.getMessage());
%>
many thanks in advance!
s.
I could not tell what the problem was that you were describing. Could you
clarify?
Cameron Purdy
[email protected]
http://www.tangosol.com
WebLogic Consulting Available
"Shari" <[email protected]> wrote in message
news:[email protected]...
> Hello all --
>
> I'm looking for some guidance in handling Custom errors in my app. I can't
> seem to find the message string of my custom exception when trying to call
> my JSP Error page. I'm consistently getting:
> javax.servlet.jsp.JspTagException: runtime failure in custom tag
> 'CalendarHandler' .
>
> I am using custom JSP tag libraries to process logic on my EJBs. When I
> reach an error in business logic I raise a custom exception and propogate
> this back up to doStartTag:
>
> public int doStartTag() throws JspException {
>
> CalendarProcessor cp = new CalendarProcessor();
>
> try {
>
> String eventAction = getEventID();
>
> // pageContext contains information for the JSP;
>
> // Initialize the page with the current context and session
>
> cp.init(pageContext.getServletContext(), pageContext.getSession());
>
> HttpServletRequest req = (HttpServletRequest)pageContext.getRequest();
>
> cp.processRequest(req, eventAction );
>
> } catch (CalendarException ce) {
>
> throw new JspException(ce.getMessage());
>
> }
>
> return SKIP_BODY;
>
> }
>
> Then, in my JSP, I am enclosing the TagHandler in a try...catch block; I
> can't catch CalendarException because it is Throwable and conflicts with
> JspException.
>
> <% try { %>
>
> <gtc:CalendarHandler eventID="updatecal"/>
>
> <% } catch (Exception e) {
>
> throw e instanceof JspException ? (JspException) e : new
> JspTagException(e.getMessage());
>
> }
>
> %>
>
> many thanks in advance!
>
> s.
>
>
>
>
>
>
>
-
Exception jsp custom tag in IBM AIX
Hello, this is the scenario.
WebLogic Server 5.1 sp6 on IB AIX
The WLS is standalone; there is a servlet that make a forward to a frameset with
three frame; each frame has a jsp which take data by an http session object.
The log of weblogic give the following message for each servlet class generated
by jsp:
Root cause of ServletException
javax.servlet.ServletException: runtime failure in custom tag 'getProperty' at......
The same application in NT works fine.
there is the execution of a different thread for each jsp in the frameset?
Could you help me?
Thanks and regards
Fabio
Please post the remainder of the stack trace.
Mike
"Fabio Rossi" <[email protected]> wrote:
>
>Hello, this is the scenario.
>WebLogic Server 5.1 sp6 on IB AIX
>The WLS is standalone; there is a servlet that make a forward to a frameset
>with
>three frame; each frame has a jsp which take data by an http session
>object.
>The log of weblogic give the following message for each servlet class
>generated
>by jsp:
>
>Root cause of ServletException
>javax.servlet.ServletException: runtime failure in custom tag 'getProperty'
>at......
>
>The same application in NT works fine.
>there is the execution of a different thread for each jsp in the frameset?
>
>Could you help me?
>
>Thanks and regards
>Fabio
-
Hi there,
Our site is running on Weblogis server 5.0. We are using EJBs, JSPs. We
have several JSP custom tags. but, one of those is raising an exception
quite often:
Tue Jul 25 21:37:19 EDT 2000:<E> <ServletContext-abracat> exception
raised on '/abc/search/animals/index.jsp'
javax.servlet.ServletException: runtime failure in custom tag
'dynamicpage'
at java.lang.Throwable.fillInStackTrace(Native Method)
at java.lang.Throwable.fillInStackTrace(Compiled Code)
at java.lang.Throwable.<init>(Compiled Code)
at java.lang.Exception.<init>(Compiled Code)
at javax.servlet.ServletException.<init>(Compiled Code)
at jsp_servlet._search._animals._index._jspService(Compiled Code)
at weblogic.servlet.jsp.JspBase.service(Compiled Code)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(Compiled
Code)
at weblogic.servlet.internal.ServletContextImpl.invokeServlet(Compiled
Code)
at weblogic.servlet.JSPServlet.service(Compiled Code)
at javax.servlet.http.HttpServlet.service(Compiled Code)
at weblogic.servlet.internal.ServletStubImpl.invokeServlet(Compiled
Code)
at weblogic.servlet.internal.ServletContextImpl.invokeServlet(Compiled
Code)
at weblogic.servlet.internal.ServletContextImpl.invokeServlet(Compiled
Code)
at
weblogic.servlet.internal.ServletContextManager.invokeServlet(Compiled
Code)
at weblogic.socket.MuxableSocketHTTP.invokeServlet(Compiled Code)
at weblogic.socket.MuxableSocketHTTP.execute(Compiled Code)
at weblogic.kernel.ExecuteThread.run(Compiled Code)
Can someone please suggest what must be the reason? And what is the
possible way of solving this problem.
Thanks in advance,
Priya
Oddly, load-on-startup is not mentioned in the text of the servlet-2.2
specification but it is
defined in the web-jar.dtd. I have filed an change request against it and
we will get confirmation
from the specification people that it actually is a feature that should be
included in the
implementation.
Sam
"kevinx" <[email protected]> wrote in message
news:[email protected]...
>
> I'm having same type of exceptions running struts example on weblogic 5.1
with sp 5. I think it has something to do with initialization at server
startup. The web.xml for the application specified one of the servlet as
follows...
>
> <servlet>
> <servlet-name>action</servlet-name>
> <servlet-class>org.apache.struts.action.ActionServlet</servlet-class>
> ......
> <load-on-startup>2</load-on-startup>
> </servlet>
>
> and there were logs showing something was loaded at startup for Tomcat 3.1
but not for Webligic 5.1
>
> Here are the exceptions ...
>
> javax.servlet.ServletException: runtime failure in custom tag 'message'
> at jsp_servlet._index._jspService(_index.java:91)
> at weblogic.servlet.jsp.JspBase.service(JspBase.java:27)
> at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java
:105)
> at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java
:123)
> at
weblogic.servlet.internal.ServletContextImpl.invokeServlet(ServletContextImp
l.java:742)
> at
weblogic.servlet.internal.ServletContextImpl.invokeServlet(ServletContextImp
l.java:686)
> at
weblogic.servlet.internal.ServletContextManager.invokeServlet(ServletContext
Manager.java:247)
> at
weblogic.socket.MuxableSocketHTTP.invokeServlet(MuxableSocketHTTP.java:361)
> at weblogic.socket.MuxableSocketHTTP.execute(MuxableSocketHTTP.java:261)
> at weblogic.kernel.ExecuteThread.run(ExecuteThread.java, Compiled Code)
>
> Fri Sep 08 16:05:19 CDT 2000:<E> <ServletContext-struts> root cause of
ServletException
> java.lang.NullPointerException:
> at
weblogic.servlet.jsp.PageContextImpl.getAttribute(PageContextImpl.java:156)
> at org.apache.struts.taglib.MessageTag.doStartTag(MessageTag.java:358)
> at jsp_servlet._index._jspService(_index.java:83)
> at weblogic.servlet.jsp.JspBase.service(JspBase.java:27)
> at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java
:105)
> at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java
:123)
> at
weblogic.servlet.internal.ServletContextImpl.invokeServlet(ServletContextImp
l.java:742)
> at
weblogic.servlet.internal.ServletContextImpl.invokeServlet(ServletContextImp
l.java:686)
> at
weblogic.servlet.internal.ServletContextManager.invokeServlet(ServletContext
Manager.java:247)
> at
weblogic.socket.MuxableSocketHTTP.invokeServlet(MuxableSocketHTTP.java:361)
> at weblogic.socket.MuxableSocketHTTP.execute(MuxableSocketHTTP.java:261)
> at weblogic.kernel.ExecuteThread.run(ExecuteThread.java, Compiled Code)
>
>
-
Custom Tag using object as an attribute.
I have read up on trying to pass an object as an attribute to a custom tag.
Is it true that the only way to do this is to put the object, using a "key name" in the pageContext
Then in the custom tag, set an attribute equal to the "Key Name"
Then in the TagHandler, to do a lookup using the "Key Name"
We can not just past objects into the attribute?
And what is this about using EL or JSP2.0
sorry sort of new to the whole game.Certainly you can pass objects to tags.
However you need to use a runtime expression to do that.
such as <%= expr %> or (with JSP2.0) ${expr}
If you look at the JSTL library, it uses the EL and passes in objects all the time. However the EL actually accesses the page/request etc attributes as its variable space, so you are still technically using attributes.
Is it true that the only way to do this is to put the object, using a "key name" in the pageContext
then in the custom tag, set an attribute equal to the "Key Name"
then in the TagHandler, to do a lookup using the "Key Name"That is one way of doing it. The struts libraries use this method extensively. It is more suited to JSP1.2.
Sometimes it is easier/neater just to put the value into a scoped attribute, and pass in the name of that attribute. That way you don't need to worrry about the type of the attribute at all in your JSP.
Hope this helps some,
evnafets -
Custom Tag is missing required attribute property
Hello,
Here is my struts config file source;
<global-forwards>
<forward name="mainpage" path="/index.jsp">
</forward>
<forward name="CustomerDetailsForward" path="/GoToCustomerPage.do">
</forward>
</global-forwards>
<!-- Action Mappings -->
<action-mappings>
<action path="/SubmitCustomerForm" type="action.SubmitCustomerForm" name="CustomerForm" scope="request" validate="true" input="/CustomerDetails.jsp">
<forward name="success" path="/Success.jsp">
</forward>
<forward name="failure" path="/Failure.jsp">
</forward>
</action>
<action path="/GoToCustomerPage" type="org.apache.struts.actions.ForwardAction" parameter="/CustomerDetails.jsp">
</action>
</action-mappings>
And my index.jsp source;
<html:html>
<head>
<html:base/>
</head>
<body>
<html:button></html:button>
<html:link forward="CustomerDetailsForward">Go To Customer Form </html:link>
</body>
</html:html>
And here is the error;
Error Message:JSPG0227E: Exception caught while translating /index.jsp: /index.jsp(13,1) --> JSPG0006E: Custom Tag is missing required attribute property
Root Cause:com.ibm.ws.jsp.translator.JspTranslationException: JSPG0227E: Exception caught while translating /index.jsp: /index.jsp(13,1) --> JSPG0006E: Custom Tag is missing required attribute property at com.ibm.ws.jsp.translator.visitor.validator.ValidateVisitor.visitCustomTagStart(ValidateVisitor.java:304) at com.ibm.ws.jsp.translator.visitor.JspVisitor.processJspElement(JspVisitor.java:267) at com.ibm.ws.jsp.translator.visitor.JspVisitor.processChildren(JspVisitor.java:309) at com.ibm.ws.jsp.translator.visitor.JspVisitor.processJspElement(JspVisitor.java:268) at com.ibm.ws.jsp.translator.visitor.JspVisitor.processChildren(JspVisitor.java:309) at com.ibm.ws.jsp.translator.visitor.JspVisitor.processJspElement(JspVisitor.java:139) at com.ibm.ws.jsp.translator.visitor.JspVisitor.visit(JspVisitor.java:121) at com.ibm.ws.jsp.translator.JspTranslator.processVisitors(JspTranslator.java:121) at com.ibm.ws.jsp.translator.utils.JspTranslatorUtil.translateJsp(JspTranslatorUtil.java:181) at com.ibm.ws.jsp.translator.utils.JspTranslatorUtil.translateJspAndCompile(JspTranslatorUtil.java:83) at com.ibm.ws.jsp.webcontainerext.AbstractJSPExtensionServletWrapper.translateJsp(AbstractJSPExtensionServletWrapper.java:349) at com.ibm.ws.jsp.webcontainerext.AbstractJSPExtensionServletWrapper._checkForTranslation(AbstractJSPExtensionServletWrapper.java:317) at com.ibm.ws.jsp.webcontainerext.AbstractJSPExtensionServletWrapper.checkForTranslation(AbstractJSPExtensionServletWrapper.java:226) at com.ibm.ws.jsp.webcontainerext.AbstractJSPExtensionServletWrapper.handleRequest(AbstractJSPExtensionServletWrapper.java:131) at com.ibm.ws.jsp.webcontainerext.AbstractJSPExtensionProcessor.handleRequest(AbstractJSPExtensionProcessor.java:270) at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.forward(WebAppRequestDispatcher.java:308) at com.ibm.ws.webcontainer.extension.DefaultExtensionProcessor.handleRequest(DefaultExtensionProcessor.java:472) at com.ibm.ws.wswebcontainer.extension.DefaultExtensionProcessor.handleRequest(DefaultExtensionProcessor.java:111) at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:3129) at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:238) at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:811) at com.ibm.ws.wswebcontainer.WebContainer.handleRequest(WebContainer.java:1433) at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:93) at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:465) at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:394) at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.ready(HttpInboundLink.java:274) at com.ibm.ws.tcp.channel.impl.NewConnectionInitialReadCallback.sendToDiscriminators(NewConnectionInitialReadCallback.java:214) at com.ibm.ws.tcp.channel.impl.NewConnectionInitialReadCallback.complete(NewConnectionInitialReadCallback.java:113) at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:152) at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:213) at com.ibm.io.async.AbstractAsyncFuture.fireCompletionActions(AbstractAsyncFuture.java:195) at com.ibm.io.async.AsyncFuture.completed(AsyncFuture.java:136) at com.ibm.io.async.ResultHandler.complete(ResultHandler.java:194) at com.ibm.io.async.ResultHandler.runEventProcessingLoop(ResultHandler.java:741) at com.ibm.io.async.ResultHandler$2.run(ResultHandler.java:863) at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1510)volkov wrote:
Error Message:JSPG0227E: Exception caught while translating /index.jsp: /index.jsp(13,1) --> JSPG0006E: Custom Tag is missing required attribute propertyWhich is line 13 then? And check the syntax for that tag. -
Hi folks,
I am trying to create a custom tag that accepts a java.util.Locale as a parameter, and for some reason the container is giving me all kinds of attitude. Here's the detail:
----from the .tld---
<tag>
<name>loadMasthead</name>
<tag-class>uiTagHandlers.LoadMasthead</tag-class>
<body-content>empty</body-content>
<description>Paints the masthead for a given page</description>
<attribute>
<name>locale</name>
<required>false</required>
<rtexprvalue>true</rtexprvalue>
<type>java.util.Locale</type>
</attribute>
</tag> ---end tld--
from the jsp-
<%@ taglib uri="/WEB-INF/simpleUITags.tld" prefix="helper" %>
<%@ page import="java.util.Locale" %>
<helper:loadMasthead locale="<%= Locale.US %>" />---end jsp----
---from the handler-----
public int doTagStart() throws JspTagException{
JspWriter out = pageContext.getOut();
try{
if( locale != null)
out.print( UIHelper.loadMasthead(locale) );
else
out.print( UIHelper.loadMasthead() );
}catch( Exception ex ){
throw new JspTagException( ex.getMessage() );
return SKIP_BODY;
public int doTagEnd() throws JspTagException{
return SKIP_PAGE;
* Sets the locale.
* @param locale The locale to set
public void setLocale(java.util.Locale locale) {
this.locale = locale;
end handler---
Here's the error I'm getting from the container:
[8/5/04 12:14:34:704 EDT] 7abbd628 WebGroup E SRVE0026E: [Servlet Error]-[Unable to convert string '<%= Locale.US %>' to class java.util.Locale for attribute locale: java.lang.IllegalArgumentException: Property Editor not registered with the PropertyEditorManager]: org.apache.jasper.JasperException: Unable to convert string '<%= Locale.US %>' to class java.util.Locale for attribute locale: java.lang.IllegalArgumentException: Property Editor not registered with the PropertyEditorManager
at org.apache.jasper.runtime.JspRuntimeLibrary.getValueFromPropertyEditorManager(JspRuntimeLibrary.java:920)
at org.apache.jsp._index._jspService(_index.java:84)
at com.ibm.ws.webcontainer.jsp.runtime.HttpJspBase.service(HttpJspBase.java:89)
Any ideas what is going on here?
Thanks in advance,
MattThe taglib always passes a string. The container is supposed to change it to the proper object, but some do not, as it wasn't clear in the original specs (I found various bug reports). My container does not do this properly for taglibs, so I ended up using a bean, which it processed correctly.
Your container can't figure out how to change the String it receives to the Locale object it's supposed to set the property to.
I found a similar problem displayed here:
http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=4727371
You'd need to check with your container docs to see if yours is supposed to be able to do the conversion. If not, you'll either need to write it yourself or do what I did and use a bean so it never passes a string to begin with. -
Hi
I have almost migrated an application from jboss to CE 7.1 sp3 maxdb 32 bit
however I am getting the following error on c:out tag of standard jslt.
Runtime error in processing of the JSP file [C:\usr\sap\CE1\J00\j2ee\cluster\apps\<....>\servlet_jsp\<application_context_name>\root\jsp\view\<jsp_name>.jsp].
Line:----
The error is: com.sap.engine.services.servlets_jsp.jspparser_api.exception.JspParseException: Cannot parse custom tag with short name [out].02004C4F4F50001F0000002D000012B000B0688132009833
Line:----
Do anybody have some idea why is it happening.
My guess would be because of jslt version mismatch. but its working fine in jboss. I am not sure what version cE 7.1 support may be 1.2. any idea how to chek the supported version in the server.
The jsp code is something like
Line:----
<code>
<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core" %>
<%@ taglib prefix="c_rt" uri="http://java.sun.com/jstl/core_rt" %>
<c:url var="thumbnailStream" value="/do/<action_tag>">
<c_rt:param name="stream_id" value="<%= <variable1> %>"/>
<c:param name="stream_id_type" value="<variable2>"/>
<c:param name="content_kind" value="<variable3>"/>
</c:url>
<img border="0" src="<c:out value="$"/>">
</code>
Line:----
from the SAP help text its said that jslt is being overrided by server to use from global library rather than local webapplication library. Couls woud explain where is this global library located in the server directory.
Thx.
AshutoshHi are you able to solve this issue.I am getting similar kind of issue.
Logs for the same are ::
Caused by: com.sap.engine.services.servlets_jsp.jspparser_api.exception.JspParseException: Cannot parse custom tag with short name out.
at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.syntax.xmlsyntax.CustomJspTag.action(CustomJspTag.java:183)
at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.syntax.ElementCollection.action(ElementCollection.java:59)
at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.syntax.JspIncludeDirective.action(JspIncludeDirective.java:51)
at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.syntax.ElementCollection.action(ElementCollection.java:59)
at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.syntax.JspElement.customTagAction(JspElement.java:994)
at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.syntax.JspElement.action(JspElement.java:228)
at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.syntax.ElementCollection.action(ElementCollection.java:59)
at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.syntax.ElementCollection.action(ElementCollection.java:69)
at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.GenerateJavaFile.generateJavaFile(GenerateJavaFile.java:72)
at com.sap.engine.services.servlets_jsp.server.jsp.JSPProcessor.parse(JSPProcessor.java:270)
at com.sap.engine.services.servlets_jsp.server.jsp.JSPProcessor.generateJavaFile(JSPProcessor.java:194)
at com.sap.engine.services.servlets_jsp.server.jsp.JSPProcessor.parse(JSPProcessor.java:126)
at com.sap.engine.services.servlets_jsp.jspparser_api.JSPChecker.getClassName(JSPChecker.java:319)
at com.sap.engine.services.servlets_jsp.jspparser_api.JSPChecker.compileAndGetClassName(JSPChecker.java:248)
at com.sap.engine.services.servlets_jsp.jspparser_api.JSPChecker.getClassNameForProduction(JSPChecker.java:178)
at com.sap.engine.services.servlets_jsp.jspparser_api.JSPChecker.processJSPRequest(JSPChecker.java:109)
at com.sap.engine.services.servlets_jsp.jspparser_api.JspParser.generateJspClass(JspParser.java:154)
at com.sap.engine.services.servlets_jsp.server.servlet.JSPServlet.service(JSPServlet.java:193)
... 47 more
Caused by: com.sap.engine.services.servlets_jsp.jspparser_api.exception.JspParseException: Attribute value of <c:out> can accept only static values.
at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.taglib.TagBeginGenerator.calculateAttributeValue(TagBeginGenerator.java:476)
at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.taglib.TagBeginGenerator.generateSetters(TagBeginGenerator.java:394)
at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.taglib.TagBeginGenerator.generateServiceMethodStatements(TagBeginGenerator.java:562)
at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.taglib.TagBeginGenerator.generate(TagBeginGenerator.java:678)
at com.sap.engine.services.servlets_jsp.jspparser_api.jspparser.syntax.xmlsyntax.CustomJspTag.action(CustomJspTag.java:181)
... 64 more -
[Custom Tags] Dynamic Variable Name // Spring MVC
I am having a problem with a tag,
i try to make a dynamic select tag that is reuseable, the problem is that my spring controller generates a model where i can access the list information for a select and that i have to pass this to the dynamic tag, the model could have different name, so it could be ${listitemsa} ${listitemsb} ${listitemsc} and i want to pass this list to my custom tag.
i tried the following, but the problem is that the var is passed as a string and not the list, does anybody know how to do this?
<tag:formfield-selectbox name="listA" path="prototypeForm.selectionA" list="${listitemsa} " />
<tag:formfield-selectbox name="listB" path="prototypeForm.selectionB" list="${listitemsb} " />
<tag:formfield-selectbox name="listC" path="prototypeForm.selectionC" list="${listitemsc} " />
<%@ tag body-content="scriptless" %>
<%@ attribute name="name" required="true" %>
<%@ attribute name="path" required="true" %>
<%@ attribute name="list" required="false" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core_rt" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jstl/fmt" %>
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags" %>
<%@ taglib prefix="form" uri="http://www.springframework.org/tags/form" %>
<spring:bind path="${path}">
<c:if test="${status.error}">
<span class="error">
<c:forEach items="${status.errorMessages}" var="error">
<c:out value="${error}"/>
</c:forEach>
</span><br />
</c:if>
<label for="<c:out value="${status.expression}"/>">${name}: </label>
<form:select path="${path}">
<form:option value="-1" label="--Please Select--" />
<form:options items="${list}" />
</form:select>
</spring:bind>I've sorted it. Here's the solution for anybody experiencing the same problem.
The problem is with switching from Java 1.2.1 to Java 1.3.0_02. Custom tags are (as of the JSP 1.1 spec) JavaBean compnents, and the Introspector appears to work differently in different Java versions.
Consider this example:
public void setAbc(String abc){}
public boolean getAbc(){}Since the setter method takes a String and the finder method returns a boolean, the 1.2 Introspector takes the property type to be String, and returns null as the finder name. Java 1.3 (I haven't tested this explicitely, but this is what seems to be happening), returns null for both the setter name and the finder name (Probably a better way to do it, but breaks old code).
We've rolled back to Java 1.2 and everything works again. It looks to me like the best way to fix the problem for 1.3 is to write custom BeanInfo classes for each JSP custom tag (Can anybody recommend a good JavaBeans book?). I don't yet know what will happen when you have multiple setter methods with different parameter types??? - something I've always found useful in custom tags.
You don't get the problem on some JSP engines that don't use the Introspector (apparently JRun just puts the method name in the code and lets it fail at runtime if it doesn't exist, whereas apache and iPlanet check the methods exist at compile time).
Here's where I got most of the answers from:
http://groups.google.com/groups?hl=en&safe=off&ic=1&th=9330b85b1867cc7,3&seekm=8rnl24%24ef1%241%40nnrp1.deja.com#p
http://groups.google.com/groups?hl=en&safe=off&ic=1&th=edd3053ac670ff5b,8&seekm=D8E32A666B62F7BD0076240185256A16.0073785185256A15%40webforums#p
http://groups.google.com/groups?hl=en&safe=off&ic=1&th=7b5480449150ea26,3&seekm=3B2FA8C3.3F14A9F3%40switzerland.org#p -
All pages that contain a custom tag fail with the following exception: HTTP Status 500 -
description The server encountered an internal error () that prevented it from fulfilling this request.
exception
java.lang.NullPointerException
org.apache.jasper.runtime.TagHandlerPool.get(TagHandlerPool.java:153)
uploadQS1_jsp._jspx_meth_strutshtml_hidden_0(uploadQS1_jsp.java:225)
uploadQS1_jsp._jspService(uploadQS1_jsp.java:100)
org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:133)
javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1069)
org.apache.struts.action.RequestProcessor.processForwardConfig(RequestProcessor.java:455)
org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:279)
org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482)
org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:507)
javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
note The full stack trace of the root cause is available in the Tomcat logs.Even a simple <struts-html: hidden ... /> tag causes this exception. As long as the page has no custom tags, it is served fine. The same web-app works as expected in JBoss3.2.3/Tomcat4.x.
It almost looks as if Tomcat is looking in a object pool for a custom tag object reference and when it fails to find one, throws a null-pointer instead of instantiating a new one to work with. (This is pure speculation on my part).
Did the TLD's req's change, or the setup for Tomcat? It's not my tags, even Struts tags fail. Any ideas why my tags aren't "resolving"?Has anyone had any luck getting this to run or run into this problem? It fails even with a fresh JBoss install using tomcat 5.0.16.
Maybe you are looking for
-
Ipad crashed not recognized by Windows XP
During upgrade of the iPad2 software via iTunes contact with the PC(WindowsXP) was lost which caused the iad2 display to show permanently a white ISB-plug and an arrow pointing to the iTunes icon. However WindowsXP no longer accepts "Apple Mobile Dev
-
have a new HP laptop: HP ENVY 15t-j100 Select Edition CTO Notebook PC (ENERGY STAR) Product Number: E9W31AV Several hours after its first boot the laptop failed to load and I got a message saying it can't load win 8.1 os. (this was two month ago and
-
..I Need Help Putting Music On My iPod..
ok.. For Some Reason.. All Of A Sudden When I Connect My iPod To My Computer To Put Songs On It.. A Message Comes Up Sayin.. "Songs On The iPod "my name iPod" Cannot Be Synced Because All Of The Playlists For Syncing No Longer Exist".. I Have NOOOO I
-
How can I add graphics and other items to the content manager in PSE 10?
I am hoping to add some jpg and png files to my content manager in PSE 10 for easy access, but can't figure out how. Would appreciate any help so I can start scrapbooking with my new software!
-
Upgrade to 8.0.1 with TDM causes crash on startup of app
I just upgraded to 8.0.1, and Logic will not open. I get through most of the start up, and then get a "quit unexpectedly" error. (Don't you love these informative error messages?) I have tried: 1)Installing ProApps updates. ProApp2007 2 had not been