velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jason van Zyl <>
Subject Re: uhm, it seems like there's a problem
Date Tue, 06 Mar 2001 15:30:12 GMT

Hmm. I saw this problem while testing and noticed the same type of
behaviour when I discovered the tested was initializing the Runtime twice.

The Configuration class when seeing a property once turns it into a
string, when seeing it twice assumes you have a collection of same
named keys and collects them in a vector.

If you send me your code, I will take a look at it. I would like to track
this down.

> When I just ran all of my tests on last night's build, I was only testing
> one of my servlets ... so it ran init() only once ... but I just tried to
> run another servlet and I get a
> javax.servlet.ServletException: Error configuring the loader:
> java.lang.ClassCastException: default.contentType doesn't map to a String
> object
>         at
> org.apache.velocity.servlet.VelocityServlet.init(
>         at org.apache.tomcat.core.ServletWrapper.doInit(
>         at org.apache.tomcat.core.Handler.init(
>         at org.apache.tomcat.core.ServletWrapper.init(
>         at org.apache.tomcat.core.Handler.service(
>         at org.apache.tomcat.core.ServletWrapper.service(
>         at
> org.apache.tomcat.core.ContextManager.internalService(
> 7)
>         at org.apache.tomcat.core.ContextManager.service(
>         at
> org.apache.tomcat.service.http.HttpConnectionHandler.processConnection(HttpC
>         at
> org.apache.tomcat.service.TcpWorkerThread.runIt(
>         at
> org.apache.tomcat.util.ThreadPool$
>         at Source)
> If I stop and restart my JVM, each servlet works fine ... it seems like
> there is something wrong with the way that the first call to init() leaves
> velocity and therefore it crashes on each subsequent call to Velocity's
> init() ...


Jason van Zyl

View raw message