Leon,

On Mon, Apr 29, 2013 at 11:02 AM, Leon Rosenberg
<rosenberg.l...@gmail.com>wrote:

> Hello Howard,
> the sniffer thing has nothing to do with original topic, I was just
> wandering that some requests were having session marked as new, which
> actually shouldn't be the case. Or in other word, the naive understanding
> of session.isNew method is that it should only return true once. But it did
> to it multiple times. The was strange, and christopher and myself were
> talking about investigating it further.
>
>
Okay/understood.

Back to your question, filter is ok, too many filters are making stack
> traces fuller than needed, and the order of the filter could be a problem.
> Listener is asked _before_ anything happens.
>

Good point(s).

About how many filters are you trying to consolidate by using this approach?

I have seen recommendations of adding filters for file types, filters for
login/session-management, etc... I have taken those concepts and put those
in one filter which I have implemented and maintain and have done my best
to ensure that it is 'thread-safe' as well. Some months ago, I reported an
issue to tomcat JIRA/issue list, and those guys shot down my filter and
said that it is not thread-safe. Since then, I have made some code changes
in the filter and related sources (referenced by the filter), and did my
best to make sure it is more threadsafe, even did some research on
thread-safe filters (when injecting via CDI), etc...

also, I am using OmniFaces gzip filter. To my knowledge, that is 2 filters
in my app, that I see in stacktrace, when I have issues to
troubleshoot/debug. When I am debugging, I often wonder why 'filter' show
up all the time in stacktrace, but then of course, I have to remember that
every user/HTTP request has to pass through the filter. So, okay, moving
forward, ignore the fact that the (only) filter(s i have in my app) showed
up in the stacktrace.



> regards
> Leon
>
>
> On Mon, Apr 29, 2013 at 4:59 PM, Howard W. Smith, Jr. <
> smithh032...@gmail.com> wrote:
>
> > On Mon, Apr 29, 2013 at 10:54 AM, Christopher Schultz <
> > ch...@christopherschultz.net> wrote:
> >
> > > -----BEGIN PGP SIGNED MESSAGE-----
> > > Hash: SHA256
> > >  >
> > > >> Even, the requests are keepalived they look to me as if they were
> > > >> executed parallel. At least from the chrome timeline. But its
> > > >> hard to tell without further investigation.
> > >
> > > Yeah, you might have to use a packet-sniffer.
> > >
> > >
> > definitely sounds like overkill. how much code you need to write for
> such a
> > thing, all because one would want to avoid using a filter???
> >
>

Reply via email to