All Products
Search
Document Center

Function Compute:CookieSessionAffinityConfig

Last Updated:Jan 14, 2026

Parameter

Type

Description

Example

object

Routes requests that have the same cookie information to the same instance.

sessionIdleTimeoutInSeconds

integer

The duration in seconds that a session can remain idle. If a user is inactive for this period, the session is considered idle. The maximum duration is limited by the session's lifecycle. The value must be between 0 and 21,600.

1800

sessionTTLInSeconds

integer

The total lifecycle of a session in seconds, from creation to destruction. After this period, Function Compute automatically destroys the session and no longer guarantees affinity. The value must be an integer from 1 to 21,600.

21600

sessionConcurrencyPerInstance

integer

The maximum number of sessions that a single instance can process at the same time. The value must be an integer from 1 to 200.

20

disableSessionIdReuse

boolean

The default value is `false`. When set to `false`, a request with the same session ID can be sent after the session expires. The system treats this as a new session and attaches it to a new instance. When set to `true`, the session ID cannot be reused after the session expires.