magro/memcached-session-manager — pull request #22 by amcnair (2013-02-15 20:34:40+00:00)
Title: Fixed problem with detecting session ID if response contains multiple Set-Cookie headers.

This patch is very similar to https://github.com/magro/memcached-session-manager/pull/21

The difference is that this patch works with both Tomcat6 and 7. If you look at org.apache.catalina.connector.Response, the getHeaderValues() method was replaced with getHeaders() in Tomcat7.

The reason for the patch is the same. Quoting from the other pull request:
>One of our customers ran into a problem when using memcached-session-manager in their application. After some debugging, we saw that one of our filters added a Set-Cookie header for our own cookie before Tomcat could add its Set-Cookie header for JSESSIONID.

>We think that memcached-session-manager should check all Set-Cookie response headers instead of only the first one in method RequestTrackingHostValve::getSessionIdFromResponseSessionCookie.