Hi Aleks,

On Fri, Jun 05, 2015 at 12:15:42AM +0200, Aleksandar Lazic wrote:
(...)
> I'm proud that this part survived for so long time.

You can!

> As before with the hash table handling I have the product point of view 
> and if there is a better solution for the same use case im fine with the 
> decision to remove legacy config options.
>
> We talked in the past to be able to share the session across n processes 
> or servers and the peers framework offers this now.

Yes, that's the idea here.

> >I have identified that it can match a cookie name prefix (not sure
> >anyone has ever needed this after 2005 or so), and the ability to
> >match the cookie name in the path split on semi-colons (something
> >we could easily do by providing a new fetch method).
> 
> It would be nice if we can add in the documentation a replacement 
> example.
> It could also be a example in the test or in the example directory for a 
> this use case.
> 
> Due to the fact that I don't use haproxy any more in the intensity as 
> before I try a first shot for a pseudo config example.
> 
> --------
> appsession <cookie> len <length> timeout <holdtime> [request-learn] 
> [prefix] [mode <path-parameters|query-string>]
> --------
> 
> I think this could be the statements which can be used to replace the 
> "appsession".
> 
> https://cbonte.github.io/haproxy-dconv/configuration-1.5.html#4.2-stick%20store-response
> https://cbonte.github.io/haproxy-dconv/configuration-1.5.html#4.2-stick%20store-request
> https://cbonte.github.io/haproxy-dconv/configuration-1.5.html#4.2-stick-table%20type
> https://cbonte.github.io/haproxy-dconv/configuration-1.5.html#7.3.6-cookie
> https://cbonte.github.io/haproxy-dconv/configuration-1.5.html#7.3.6-set-cookie
> https://cbonte.github.io/haproxy-dconv/configuration-1.5.html#7.3.6-path
> https://cbonte.github.io/haproxy-dconv/configuration-1.5.html#stick%20match
> 
> 
> fronted session_sticky
> ....
>   stick on path_sub OR url_sub ??? (JSESSIONID,;)
>   stick on cookie(JSESSIONID)
> 
> backend http
> ...
> 
>   # init the appsession table
>   stick-table type string len 52 size 10m expire 3h ...
>   appsession              ^^^^^similar    ^^^timeout 3h
> 
>   # save the Set-Cookie or Set-Cookie2 sessionID from the server
>   stick store-response cookie(JSESSIONID) ....
>   appsession           ^^^^^ first param
> 
>   # save the URL param sessionID from the server
>   stick store-response path_sub OR url_sub ??? (JSESSIONID,;)
>   appsession [mode <path-parameters|query-string> ]
> 
>   # save the URL param sessionID from the server
>   stick store-request cookie(JSESSIONID)
>   stick store-request path_sub OR url_sub ??? (JSESSIONID,;)
>   appsession [request-learn]

That's a good idea. We could indeed keep the keyword in the doc in 1.6
with such mappings.

> What could be the solution for this arguments?
>  [prefix]

No solution at the moment, it will require some modifications to the
cookie sample fetch function to match against a prefix. But I'm not
too much worried, as at the moment I'm not sure it's needed anymore
at all. It used to be needed for ASPSESSIONXXX. If it was still in
use, I suspect we would also have received requests to support this
for the regular "cookie prefix" mode.

Thanks,
Willy


Reply via email to