Reputation: 21
on ELB, what are the recommended values for the following:
Port 80 Stickiness Expiration Period:
Current: 120s
Recommended: ?
Port 443 Stickiness Expiration Period:
Current: 130s
Recommended: ?
Idle Timeout:
Current: 90s
Recommended: ?
Connection Draining:
Current: 120s
Recommended: ?
Not sure if I have correct settings. I have currently two web server instances. The issue is most of the users switch from one server to another server often times. This let the users leave their $_SESSION's from one server and can't carry out to the another server. And does the long execution of scripts on the web app could be one of the possible cause of this issue? And should I recode my scripts to have a session cookies so even the users switch to another server, so they can carry out the sessions they have from the other one?
Upvotes: 2
Views: 949
Reputation: 24643
It's hard to give specifics as it depends on your use case. However, a few comments:
port stickiness is an antipattern; it's an indication that you are using local state. Typically application servers should be stateless, with the state kept in a database instead. (redis or memcached (not a DB) are very fast for session management)
connection draining should be as short as possible, roughly speaking no longer than an expected request. It's only useful if your deployment system understands how to deal with it.
idle timeout: it depends. Are you using async requests?
Both connection draining and idle timeouts are new features for AWS ELB- they didn't exist a year ago.
Upvotes: 1