velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Yoshia Makino <>
Subject RE: Velocity initialize failure in resin
Date Thu, 12 Dec 2002 04:01:33 GMT
I found the problem.

This was happening because org.apache.commons.collections.ExtendedProperties
is not very nice.

It was using a while(true) loop and using NullPointerExceptions to figure
out the EOF of the file.  So when the
BufferedReader.readLine() was called, it seg faulted when EOF was reached
instead of throwing a NullPointerException.

Althought this must obviously work for most people, it was causing problems
in this case.


-----Original Message-----
From: Yoshia Makino [] 
Sent: Thursday, December 12, 2002 9:57 AM
To: 'Velocity Users List'
Subject: RE: Velocity initialize failure in resin


There is a try catch around the configuration.load() as follows :- 

private  ExtendedProperties configuration = new ExtendedProperties();
	try {
             configuration.load( inputStream );
	} catch ( Exception e ) {

The exception is never reached.  Its crashing inside the ExtendProperties

What I find confusing is that I am using the default VelocityEngine and am
not doing anything funky.

I suppose the next step is to get the source for ExtendedProperties and
trace through that.  I just thought it may be more of a configuration error
rather than a code problem since this setup has been deployed in other
machines before.


-----Original Message-----
From: Geir Magnusson Jr. [] 
Sent: Wednesday, December 11, 2002 10:37 PM
To: Velocity Users List
Subject: Re: Velocity initialize failure in resin

And you have no idea where?

Hm.  Can you put a try around that and catch anything that might get 

On Wednesday, December 11, 2002, at 06:13 AM, Yoshia Makino wrote:

> Hi,
> I am using resin 2.1.6 and velocity 1.3.1 rc-2 and I am experiencing
> difficulties in bringing resin up.
> When I initialize the VelocityEngine, resin crashes quietly. ie 
> without a stacktrace.
> Using the System.out debug method, I found that the crash occurs
> whilst executing
> org.apache.velocity.runtime.RuntimeInstance.setDefaultProperties(){
>             configuration.load( inputStream );
> }
> I have installed the same setup in a 3-4 other machines without a 
> problem.
> Can anyone help me track this problem down or has anyone experienced 
> the same problem?
> Thank you
> Yoshia
Geir Magnusson Jr                                   203-355-2219(w)
Adeptra, Inc.                                       203-247-1713(m)

To unsubscribe, e-mail:
For additional commands, e-mail:

To unsubscribe, e-mail:
For additional commands, e-mail:

To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message