All,

I need to get the context's session-tracking URI parameter name from
within a Valve, and it looks like this is the right (static) call:

o.a.c.util.SessionConfig.getSessionUriParamName(request.getContext());

=2E.. but a quick reading of the code in there seems to reveal a
copy/paste error:

Starting on line SessionConfig.java:49

    public static String getSessionUriParamName(Context context) {

        String result =3D getConfiguredSessionCookieName(context);

        if (result =3D=3D null) {
            result =3D DEFAULT_SESSION_PARAMETER_NAME;
        }

        return result;
    }

At first, I would have imagined that there was some breakage in the
trunk due to some refactoring, but it appears that the code is the same
all the way back to Tomcat 7.

I haven't tested it (and will), but it looks like if a non-default
cookie name is used, that same name will be used for the URI parameter
as well.

Is that by mistake or by design?

Thanks,
-chris

Attachment: signature.asc
Description: OpenPGP digital signature

Reply via email to