Hi Max,

I tend to think of RuntimeExceptions as application level errors, while
checked exceptions indicate specific conditions that need to be caught.
This seems to be consistent with the way most Java frameworks are going.
(Hibernate 3, Spring, come to mind).

Since the method exceptions (in general) for Velocity plugins don't declare
exceptions, then having the plugin throw a RuntimeException is the way to
go.  I suppose we could change the plugin to declare a generic "Exception",
but that seems pretty pointless.

WILL

On 3/8/06, Nathan Bubna <[EMAIL PROTECTED]> wrote:
>
> On 3/8/06, Max Rydahl Andersen <[EMAIL PROTECTED]> wrote:
> > On Tue, 07 Mar 2006 19:38:33 +0100, Will Glass-Husain <[EMAIL PROTECTED]>
> > wrote:
> >
> > > Hey Max--
> > >
> > > Appreciate the specific feedback.  We've also done a pass at #2.  In
> > > particular, any RuntimeException from a plugin, event handler,
> resource
> > > loader, etc is now passed through to the application.
> > >
> > > Are there other type of exceptions you were thinking of?
> >
> > how about normal exceptions ? :)
>
> that doesn't especially help. :)  we can't throw them without
> declaring them in method signatures and that forces everyone to catch
> them or declare them.  that's a burden either way and something i
> think Velocity already does too much of without good, specific
> justification.  so i'm definitely not into that as a general practice.
> and, of course, we're constrained to backwards compatibility in our
> public API for the current version.
>
> but seriously, if there are events that were logged and not thrown
> that you think should be changed, i'd love to hear some specifics that
> we can look at.  don't feel like you have to dig them up now; next
> time you notice one, just pop us a note.
>
> > /max
> >
> >
> > >
> > > WILL
> > >
> > > On 3/7/06, Max Rydahl Andersen <[EMAIL PROTECTED]> wrote:
> > >>
> > >> On Tue, 07 Mar 2006 18:48:45 +0100, Will Glass-Husain <
> [EMAIL PROTECTED]>
> > >> wrote:
> > >>
> > >> > Or Hibernate.  I haven't checked lately, but I seem to remember
> > >> hundreds
> > >> > if
> > >> > not thousands of DEBUG lines at startup.  Not a big deal.  If we
> move
> > >> > more
> > >> > of Velocity log messages to DEBUG, this seems similarly
> > >> inconsequential.
> > >>
> > >> There are two things wrong with velocity logging:
> > >>
> > >> 1. the level is often wrong (apparently fixed recently)
> > >>
> > >> 2. alot of the logs should default to be exceptions instead of
> ignored.
> > >>
> > >> /max
> > >>
> > >> > cheers,
> > >> > WILL
> > >> >
> > >> > On 3/7/06, Nathan Bubna <[EMAIL PROTECTED]> wrote:
> > >> >>
> > >> >> you think Velocity's output is hard-to-use?  try reading the
> output
> > >> of
> > >> >> commons-digester at debug level. ;-)
> > >> >>
> > >> >> anyway, i've been fiddling with logging extensively in 1.5-dev,
> > >> >> lowering levels, improving the API, etc.  so i would really love
> more
> > >> >> specific feedback if you've got any!
> > >> >>
> > >> >> On 3/7/06, Max Rydahl Andersen <[EMAIL PROTECTED]> wrote:
> > >> >> > On Tue, 07 Mar 2006 01:48:54 +0100, Will Glass-Husain
> > >> >> <[EMAIL PROTECTED]>
> > >> >> > wrote:
> > >> >> >
> > >> >> > > You could auto-init Velocity but log a message stating that
> you
> > >> are
> > >> >> doing
> > >> >> > > that...
> > >> >> >
> > >> >> >
> > >> >> > ...now I understand how velocity's log output has grown to such
> a
> > >> huge
> > >> >> > amount
> > >> >> > of hard-to-use lines. ;)
> > >> >> >
> > >> >> >
> > >> >> > /max
> > >> >> >
> > >> >> > >
> > >> >> > >
> > >> >> > > On 3/6/06, Max Rydahl Andersen <[EMAIL PROTECTED]> wrote:
> > >> >> > >>
> > >> >> > >> On Tue, 07 Mar 2006 01:39:15 +0100, Will Glass-Husain <
> > >> >> [EMAIL PROTECTED]>
> > >> >> > >> wrote:
> > >> >> > >>
> > >> >> > >> > Sure, why not?
> > >> >> > >>
> > >> >> > >> because then users who like to know if a subsystem is
> configured
> > >> >> > >> before using it will not get a warning/exception.
> > >> >> > >>
> > >> >> > >> I would rather say that all the static singleton
> functionallity
> > >> >> > >> should be ripped out of velocity since it is a Bad Thing.
> > >> >> > >>
> > >> >> > >> /max
> > >> >> > >>
> > >> >> > >> >
> > >> >> > >> > On 3/6/06, Nathan Bubna <[EMAIL PROTECTED]> wrote:
> > >> >> > >> >>
> > >> >> > >> >> hey guys,
> > >> >> > >> >>
> > >> >> > >> >> here's another idea i've only half-thought through... :)
> > >> >> > >> >>
> > >> >> > >> >> why do we require users to manually init() Velocity?  are
> our
> > >> >> default
> > >> >> > >> >> settings that useless?
> > >> >> > >> >>
> > >> >> > >> >> i know most users will still want and need to do
> init(props),
> > >> so
> > >> >> it
> > >> >> > >> >> ultimately isn't a big deal either way.  but i think it
> could
> > >> >> be a
> > >> >> > >> >> nice convenience to automatically call init() when someone
> > >> tries
> > >> >> to
> > >> >> > >> >> use Velocity, especially for those using Velocity.evaluate
> ().
> > >> >> as
> > >> >> it
> > >> >> > >> >> is, we (sometimes) throw IllegalStateExceptions if someone
> is
> > >> >> trying
> > >> >> > >> >> to use Velocity and RuntimeInstance.isInitialized()
> returns
> > >> >> false.
> > >> >> > >> >> why not just call init() instead of barking at the user?
> > >> >> > >> >>
> > >> >> > >> >> feedback appreciated. :)
> > >> >> > >> >>
> > >> >> > >> >>
> > >> >>
> ---------------------------------------------------------------------
> > >> >> > >> >> To unsubscribe, e-mail:
> > >> >> [EMAIL PROTECTED]
> > >> >> > >> >> For additional commands, e-mail:
> > >> >> [EMAIL PROTECTED]
> > >> >> > >> >>
> > >> >> > >> >>
> > >> >> > >> >
> > >> >> > >> >
> > >> >> > >> > --
> > >> >> > >> > _______________________________________
> > >> >> > >> > Forio Business Simulations
> > >> >> > >> >
> > >> >> > >> > Will Glass-Husain
> > >> >> > >> > phone (415) 440-7500 x89
> > >> >> > >> > mobile (415) 235-4293
> > >> >> > >> > [EMAIL PROTECTED]
> > >> >> > >> > www.forio.com
> > >> >> > >>
> > >> >> > >>
> > >> >> > >>
> > >> >> > >> --
> > >> >> > >> --
> > >> >> > >> Max Rydahl Andersen
> > >> >> > >> callto://max.rydahl.andersen
> > >> >> > >>
> > >> >> > >> Hibernate
> > >> >> > >> [EMAIL PROTECTED]
> > >> >> > >> http://hibernate.org
> > >> >> > >>
> > >> >> > >> JBoss Inc
> > >> >> > >> [EMAIL PROTECTED]
> > >> >> > >>
> > >> >> > >>
> > >> >>
> ---------------------------------------------------------------------
> > >> >> > >> To unsubscribe, e-mail:
> > >> [EMAIL PROTECTED]
> > >> >> > >> For additional commands, e-mail:
> > >> >> [EMAIL PROTECTED]
> > >> >> > >>
> > >> >> > >>
> > >> >> > >
> > >> >> > >
> > >> >> > > --
> > >> >> > > _______________________________________
> > >> >> > > Forio Business Simulations
> > >> >> > >
> > >> >> > > Will Glass-Husain
> > >> >> > > phone (415) 440-7500 x89
> > >> >> > > mobile (415) 235-4293
> > >> >> > > [EMAIL PROTECTED]
> > >> >> > > www.forio.com
> > >> >> >
> > >> >> >
> > >> >> >
> > >> >> > --
> > >> >> > --
> > >> >> > Max Rydahl Andersen
> > >> >> > callto://max.rydahl.andersen
> > >> >> >
> > >> >> > Hibernate
> > >> >> > [EMAIL PROTECTED]
> > >> >> > http://hibernate.org
> > >> >> >
> > >> >> > JBoss Inc
> > >> >> > [EMAIL PROTECTED]
> > >> >> >
> > >> >> >
> > >> ---------------------------------------------------------------------
> > >> >> > To unsubscribe, e-mail:
> [EMAIL PROTECTED]
> > >> >> > For additional commands, e-mail:
> > >> [EMAIL PROTECTED]
> > >> >> >
> > >> >> >
> > >> >>
> > >> >>
> ---------------------------------------------------------------------
> > >> >> To unsubscribe, e-mail:
> [EMAIL PROTECTED]
> > >> >> For additional commands, e-mail:
> [EMAIL PROTECTED]
> > >> >>
> > >> >>
> > >> >
> > >> >
> > >> > --
> > >> > _______________________________________
> > >> > Forio Business Simulations
> > >> >
> > >> > Will Glass-Husain
> > >> > phone (415) 440-7500 x89
> > >> > mobile (415) 235-4293
> > >> > [EMAIL PROTECTED]
> > >> > www.forio.com
> > >>
> > >>
> > >>
> > >> --
> > >> --
> > >> Max Rydahl Andersen
> > >> callto://max.rydahl.andersen
> > >>
> > >> Hibernate
> > >> [EMAIL PROTECTED]
> > >> http://hibernate.org
> > >>
> > >> JBoss Inc
> > >> [EMAIL PROTECTED]
> > >>
> > >> ---------------------------------------------------------------------
> > >> To unsubscribe, e-mail: [EMAIL PROTECTED]
> > >> For additional commands, e-mail: [EMAIL PROTECTED]
> > >>
> > >>
> > >
> > >
> > > --
> > > _______________________________________
> > > Forio Business Simulations
> > >
> > > Will Glass-Husain
> > > phone (415) 440-7500 x89
> > > mobile (415) 235-4293
> > > [EMAIL PROTECTED]
> > > www.forio.com
> >
> >
> >
> > --
> > --
> > Max Rydahl Andersen
> > callto://max.rydahl.andersen
> >
> > Hibernate
> > [EMAIL PROTECTED]
> > http://hibernate.org
> >
> > JBoss Inc
> > [EMAIL PROTECTED]
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


--
Forio Business Simulations

Will Glass-Husain
[EMAIL PROTECTED]
www.forio.com

Reply via email to