Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

init() method invocation

0 views
Skip to first unread message

vamsi

unread,
Mar 16, 2001, 1:43:49 AM3/16/01
to

hi all

iam using weblogic5.1 servicepack 7 as my servlet container.
if i get an error in the init() method of the servlet and the servlet
throws
a ServletException,
then according to the spec, the server may put that servlet into
service
after some time (this may be when another request
comes for the same servlet) by again calling it's init() method.

but in weblogic server, if a servlet throws a ServletException
in the init()
method and if another request comes to it
it gives the following exception and gives an internal error 500:

weblogic.utils.AssertionError: ***** ASSERTION FAILED *****[ getServlet()
returned null!
! ]
at java.lang.Throwable.fillInStackTrace(Native Method)
at java.lang.Throwable.<init>(Throwable.java:94)
at java.lang.Error.<init>(Error.java:50)
at weblogic.utils.NestedError.<init>(NestedError.java:15)
at weblogic.utils.AssertionError.<init>(AssertionError.java:49)
at weblogic.utils.Debug.assert(Debug.java:73)
at
weblogic.servlet.internal.ServletStubImpl.invokeServlet(ServletStubImpl.java
:
104)
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
M
anager.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:120)

the spec is as follows:

During initialization, the servlet instance can signal that it
is not to be
placed into active service by
throwing an UnavailableException or ServletException. If a servlet
instance
throws
an exception of this type, it must not be placed into active service
and the
instance must be
immediately released by the servlet container. The destroy method
is not
called in this case as
initialization was not considered to be successful.

After the instance of the failed servlet is released, a new instance
may be
instantiated and initialized
by the container at any time. The only exception to this rule is
if the
UnavailableException
thrown by the failed servlet which indicates the minimum time of
unavailability. In this case, the
container must wait for the minimum time of unavailability to pass
before
creating and initializing a
new servlet instance.

is there any property to be set in weblogic property files or am
i missing
something.
vamsi


Tom Mitchell

unread,
Mar 28, 2001, 8:31:43 AM3/28/01
to
Vamsi,

You will probably get a response by posting this question to
weblogic.developer.interest.servlet.

HTH.

vamsi wrote:

--
Tom Mitchell
t...@tom.org
Very Current Stoneham, MA Weather
http://www.tom.org


0 new messages