Index: [Article Count Order] [Thread]

Date: Tue, 8 Mar 2005 11:42:15 -0800
From: lewisd@f00f.net (Derek Lewis)
Subject: [webricken:145] Re: RequestDispatcher, Filters
To: webricken@notwork.org
Message-Id: <20050308194215.GC30101@f00f.net>
In-Reply-To: <20050224.185312.55839923.gotoyuzo@sawara.priv.tokyo.netlab.jp>
References: <20050215222648.GL23232@f00f.net> <20050224.185312.55839923.gotoyuzo@sawara.priv.tokyo.netlab.jp>
X-Mail-Count: 00145

Sorry to take so long replying, I've been having some email problems.

I've actually taken on a project somewhat more ambitious than just
RequestDispatcher and Filters.  I've mostly finished building something like
SiteMesh and JSP, but build on top of WEBrick.

In a few places, I'm modifying WEBrick classes by (I don't know if there's a
name for this) adding methods to them from my code.  In a few places, I'm
overriding existing methods, and had to copy-paste chunks of code.  What I'd
like to do is identify those, and see if maybe WEBrick could be slightly
refactored to allow me to hook into it in a cleaner fashion.

I don't think what I've been bulding is very suited for inclusion in WEBrick,
because it seems to be that WEBrick aims to be small and fast, and flexible for
building on top of.

So, if I were to point out some methods I wanted hooks added to, or that I
wanted broken out into multiple methods so I can override behaviour, do you
think that would be a suitable way to approach this?

I have a small (very beta, very under construction) demo site of what I've been
working on, which I'm temporarily calling WEBlock.

http://ruby.lewisd.com/

On Thu, Feb 24, 2005 at 06:53:12PM +0900, GOTOU Yuuzou wrote:
> In message <20050215222648.GL23232@f00f.net>,
>  `lewisd@f00f.net (Derek Lewis)' wrote:
> > I notice the author submitted a patch, but it's never been accepted into
> > CVS.  I think the include/forward mechanisms of the request dispatcher,
> > in addition to the ability to create a chain of filters (also like Java)
> > would be incredibly useful for WEBrick, and I know they would make life
> > easier for application builders.
> 
> I understood the necessity of it. But that time I felt some
> problem and didn't add it. However, I cannot remember what
> it was clearly;)
> 
> > I'd like to try my hand at implementing the necessary changes to WEBrick
> > to support filter chains, and an include/forward mechanism, similar to
> > the Java Servlet 2.3 API, as I mentioned.
> > Any tips or guidelines if I want to have these changes accepted into
> > CVS?
> 
> Could you post the new patch? I'd like to reconsider again.
> 
> regards,
> 
> -- 
> gotoyuzo

-- 
Derek Lewis

===================================================================
      Java Web-Application Developer
 
      Email    : email@lewisd.com
      Cellular : 778.898.5825
      Website  : http://www.lewisd.com

 "If you've got a 5000-line JSP page that has "all in one" support
 for three input forms and four follow-up screens, all controlled
 by "if" statements in scriptlets, well ... please don't show it
 to me :-).  Its almost dinner time, and I don't want to lose my
 appetite :-)."
      - Craig R. McClanahan