velocity-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Geir Magnusson Jr." <ge...@optonline.net>
Subject Re: A call to correct the Velocity servlet_example1...pretty pretty please?
Date Thu, 03 Jan 2002 20:24:14 GMT
On 1/3/02 3:17 PM, "Steven Caswell" <stevencaswell@yahoo.com> wrote:

> Geir, I don't think servlet_example1 should be removed.  Yes, fix it if
> getRealPath() is a problem.  Or explain that the servlet engine needs to
> support getRealPath().  Documentation can always be improved.  But don't
> remove the example.  It is the simplest thing to set up and is a great
> starting place for understanding Velocity without the complexity of loaders
> and property files and such.

Ok.  Good feedback.

I thought servlet example 2 was simple too, but we'll keep #1.

It would be good for David to verify that getRealPath() was the problem as
it was a SWAG...

> 
> -----Original Message-----
> From: Geir Magnusson Jr. [mailto:geirm@optonline.net]
> Sent: Thursday, January 03, 2002 3:02 PM
> To: velocity-user@jakarta.apache.org
> Subject: Re: A call to correct the Velocity servlet_example1...pretty
> pretty please?
> 
> 
> On 1/3/02 2:52 PM, "David Tonhofer, m-plify S.A." <d.tonhofer@m-plify.com>
> wrote:
> 
>> Right!
>> 
>> Pox on whosoever set up the Velocity distribution's "servlet example 1" !
> 
> That was me.
> 
>> 
>> In retrospect I should have known better but I'm just back from
>> nearly punching holes into walls because I couldn't get the Velocity
>> servlet example 1 to work (yes, the most stupid & simple one).
> 
> Oh, I just punch the walls.  Make it a hard one, because repairing plaster
> tends to make one feel dumb.
> 
>> 
>> Well, it turns out that one needs something called a
>> "velocity.properties" file which should be adequately filled in,
>> like so:
>> 
>> ----
>> file.resource.loader.path = <path-to-whatever-the-webapp-dir-is>
>> runtime.log = velocity.log
>> ----
>> 
>> And it should reside in the webapp directory, otherwise there is *no
>> way* the fileloader is ever going to stumble upon the humble file
>> called "sample.vm" which supposedly has only to be copied to the
>> webapp directory. Yeah, right.
>> 
>> So, I suggest to at least put a sample "velocity.properties" file
>> into the distribution AND make add a note regarding this to the
>> f***ing README.
>> 
>> Still fuming,
> 
> Actually, for servlet example 1, I am not sure that it is needed.  I will
> admit its a lousy example, but that's why there is #2.  We should remove #1.
> 
> #1 was meant to be self configuring, but I suspect you are using a servlet
> engine that doesn't support getRealPath() ?
> 
> I have a fix for that, as I am worried that we will be touched by it more
> and more.
> 
> Thanks for the heads up - it will be fixed...
> 
>> -- David
>> 
>> 
>> --
>> To unsubscribe, e-mail:
>> <mailto:velocity-user-unsubscribe@jakarta.apache.org>
>> For additional commands, e-mail:
>> <mailto:velocity-user-help@jakarta.apache.org>
>> 
> 
> --
> Geir Magnusson Jr.                                     geirm@optonline.net
> System and Software Consulting
> "He who throws mud only loses ground." - Fat Albert
> 
> 
> --
> To unsubscribe, e-mail:
> <mailto:velocity-user-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail:
> <mailto:velocity-user-help@jakarta.apache.org>
> 
> 
> 
> 
> _________________________________________________________
> 
> Do You Yahoo!?
> 
> Get your free @yahoo.com address at http://mail.yahoo.com
> 
> 
> 
> 
> --
> To unsubscribe, e-mail:
> <mailto:velocity-user-unsubscribe@jakarta.apache.org>
> For additional commands, e-mail:
> <mailto:velocity-user-help@jakarta.apache.org>
> 

-- 
Geir Magnusson Jr.     geirm@optonline.net
System and Software Consulting
"Whoever would overthrow the liberty of a nation must begin by subduing the
freeness of speech." - Benjamin Franklin



--
To unsubscribe, e-mail:   <mailto:velocity-user-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:velocity-user-help@jakarta.apache.org>


Mime
View raw message