Hi, You know, when I was putting the balancer app in tomcat proper, I was thinking it'd be great if we had a place for these extra things that don't quite belong in tomcat itself, but are useful accompaniments. We could do this any number of ways, such as sourceforge or a contrib section of the tomcat CVS, but at the time I was too lazy to pursue. Now that I see these filters, I think they belong in the same space, so maybe it's time to think about this a bit further.
Of course this comes up when I'm going on vacation ;) Yoav Shapira Millennium Research Informatics >-----Original Message----- >From: Tim Funk [mailto:[EMAIL PROTECTED] >Sent: Thursday, June 17, 2004 8:13 AM >To: Tomcat Users List >Subject: [ANNOUNCE] Servlet Utilities 0.1 > >I threw together a few filter utilities. Everything (including source) can >be >found here: > >http://funkman.home.comcast.net/ > >Utilities of interest: >*TimerFilter* - A Filter that lets you spew out how long it took to serve a >page. >*ErrorFilter* - Spit or an error code and a file or message. >*NoCacheFilter* - Set all the appropriate no cache headers > >EL Wrapper - Make it easy to use EL expressions in servlets or dynamically >use EL expressions in JSP's. > > >All 3 filters extend a class called ConditionFilter. ConditionFilter allows >you to decide when the Filter will execute. It's default implementation >allows you to use an EL expression. For example: >************ ><filter> > <filter-name>ErrorFilter</filter-name> > <filter-class>net.funkman.servletutil.filter.ErrorFilter</filter-class> > <init-param> > <param-name>errorMessage</param-name> > <param-value> <![CDATA[<b>THBBBBBBBTTTTT!</b>]]> </param-value> > </init-param> > <init-param> > <param-name>errorCode</param-name> > <param-value>400</param-value> > </init-param> ><!-- Show error message from 2 - 4 am --> > <init-param> > <param-name>condition</param-name> > <param-value> > ${now.HOUR_OF_DAY == 2 or now.HOUR_OF_DAY == 3} > </param-value> > </init-param> ></filter> ><filter-mapping> > <filter-name>ErrorFilter</filter-name> > <url-pattern>*.jsp</url-pattern> ></filter-mapping> >************ > >Have fun. > > >-Tim > > >--------------------------------------------------------------------- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] This e-mail, including any attachments, is a confidential business communication, and may contain information that is confidential, proprietary and/or privileged. This e-mail is intended only for the individual(s) to whom it is addressed, and may not be saved, copied, printed, disclosed or used by anyone else. If you are not the(an) intended recipient, please immediately delete this e-mail from your computer system and notify the sender. Thank you. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]