Cookies and load balancer stickiness

There are few load balancer that use cookie to maintain the target node that the client show work with (stickiness) while other use IP or other approach

When you write code to access some web service or WCF end point make sure that you enable the cookies (or cookies container) so that if the target address is using load balancer that uses cookies to support stickiness you will not lose it.

Failing to do so might cause you session lost / problems in authentication

If you do simple manual webrequest than you need to create new cookiecontainer and assign to the webrequest

and if you use WCF than in the configuration simply set AllowCookies to true

This should save you half a day of debugging customer site Smile

Cookies and load balancer stickiness Cookies and load balancer stickiness Reviewed by Ran Davidovitz on 3:35 AM Rating: 5

No comments:

Powered by Blogger.