-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

To whom it may concern,

On 6/4/2009 4:13 PM, universeprojects.com wrote:
> Caldarale, Charles R wrote:
>> 3) What <Connector> flavor are you using?
>
> 3. Catalina? (Does that make sense? I'm a little newbish) Whatever defaults
> with tomcat

The default would be a non-APR HTTP connector on port 8080. You could
just look in conf/server.xml for all <Connector> elements that haven't
been commented-out and post them, here.

Regarding "APR"... have you installed any kind of native library into
your Tomcat instance? If not, then you are probably not using APR.

> One thing, I think I may have been using 6.0.7. I've since re-installed to
> 6.0.14 and will be watching to see if it has any effect. (I was getting
> conflicting version numbers so perhaps it was just the windows service
> description that had the old version number on it. We'll see...)

Both of these versions should be performing equally well.

Something interesting to do would be to install a filter that watches
your AJAX requests and reports which session is being referenced.
Something like this would work:

public class SessionIdReporterFilter
    implements javax.servlet.Filter
{
    private ServletContext _app;

    public void init(FilterConfig config)
    {
        _app = config.getServletContext();
    }

    public void doFilter(ServletRequest req,
                         ServletResponse rsp,
                         FilterChain chain)
        throws IOException, ServletException
    {
        if(req instanceof HttpServletRequest)
        {
           HttpServletRequest request = (HttpServletRequest)req;

            _app.log("Got a request for " + request.getRequestURL()
                     "; using sessionid="
                     + request.getRequestedSessionId()
                     "; session=" + request.getSession(false));
        }

        chain.doFilter(req, rsp);
    }
}

Enable this in your webapp's web.xml like this:

<filter>
   <filter-name>sessionIdReporter</filter-name>
   <filter-class>fully.qualified.SessionIdReporterFilter<filter-class>
   <description>
      Reports the requested session id and resulting session used
      to handle a request. Logs to the application's context log.
   </description>
</filter>

<filter-mapping>
   <filter-name>sessionIdReporter</filter-name>
   <url-pattern>/whatever/matches/your/ajax/requests</url-pattern>
</filter-mapping>

The <filter> and <filter-mapping> elements go in web.xml before any
<servlet> or <listener> declarations.

Hope that helps,
- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAkooOEMACgkQ9CaO5/Lv0PDihwCfdEsm9cOAM64PFtz7VWy7m0ry
xfIAoL1mKtEd3GCVlgUbq2lU0bzOuROP
=WX0T
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to