On Tue, 24 Apr 2001, Bob Jamison wrote:
> Hey, all, I have a minor question about TC4, if anyone knows,
> cool, if not, oh, well. ;-)
>
> (Actually, I am probably just overlooking something obvious)
>
> In the public drafts of 2.3 and in the Tomcat examples, I have
> seen various specifications of Filter. Is the spec going to
> move toward Tomcat (since it is the testbed impl) or will Tomcat's
> impl change?
>
> For example, currently in the examples, it is defined as having 3 methods:
>
> public void init(FilterConfig config);
> public void doFilter(ServletRequest req,ServletResponse resp,FilterChain
> chain);
> public void destroy();
>
>
> While in the final draft it is:
>
> public void FilterConfig getFilterConfig();
> public void setFilterConfig(FilterConfig config);
> public void doFilter(ServletRequest req,ServletResponse resp,FilterChain
> chain);
>
>
> They are identical in function, except for destroy().
> I can see some benefit in keeping destroy(), since the Filter might
> have allocated a lot of resources, (such as an XSLT transformer), but the
> other differences seem to be merely preference.
>
> Just wondering, as I am still becoming acquainted with the new stuff in 2.3.
>
>
>
> Bob
>
>
In "Proposed Final Draft 2" (coming soon) you will see that init() and
destroy() are the final answer. This change was approved by the JSR-053
expert group after the "Proposed Final Draft" version was published, and
Tomcat was changed at that time.
There will be a few more minor changes in Tomcat 4.0 (not API related) to
reflect other clarifications that will be in PFD2.
Craig McClanahan