Package org.springframework.web.server.session

# Interface WebSessionManager

All Known Implementing Classes:
  `DefaultWebSessionManager`

public interface WebSessionManager
Main class for access to the `WebSession` for an HTTP request.

Since:
  5.0
Author:
  Rossen Stoyanchev
See Also:
  - `WebSessionIdResolver`
  - `WebSessionStore`

## Method Summary

Modifier and Type
Method
Description
`reactor.core.publisher.Mono<WebSession>`
`getSession(ServerWebExchange exchange)`
Return the `WebSession` for the given exchange.

## Method Details

### getSession

reactor.core.publisher.Mono<WebSession> getSession(ServerWebExchange exchange)
Return the `WebSession` for the given exchange.

Always guaranteed to return either an instance matching the session id requested by the client, or a new session either because the client did not specify a session id or because the underlying session expired.

Parameters:
  `exchange` - the current exchange
Returns:
  promise for the WebSession