anchor.diff:  include::{websocketdoc-test-dir}WebSocketConfig.java[tags=class]
   ----
   
  -To hook in the Spring Session support, we need to ensure
  +To hook in the Spring Session support we only need to change two things:
  +
  +<1> Instead of extending `AbstractWebSocketMessageBrokerConfigurer` we extend `AbstractSessionWebSocketMessageBrokerConfigurer`
  +<2> We rename the `registerStompEndpoints` method to `configureStompEndpoints`
  +
  +For example:
  +
  +.src/main/java/samples/config/WebSocketConfig.java
  +[source,java]
  +----
  +include::{samples-dir}websocket/src/main/java/sample/config/WebSocketConfig.java[tags=class]
  +----
  +
  +If interested in more details, here are the things the base class does:
   
   * `WebSocketConnectHandlerDecoratorFactory` is added as a `WebSocketHandlerDecoratorFactory` to `WebSocketTransportRegistration`.
   This ensures a custom `SessionConnectEvent` is fired that contains the `WebSocketSession`.
  
positive.code: 
  NOTE: Only messages sent from a user keep the session alive.
  This is because only messages coming from a user imply user activity.
  Messages received do not imply activity and thus do not renew the session expiration.
negative.code: This ensures that we have a mapping of all of the Session id to the corresponding WebSocket connections.
  By maintaining this mapping, we can close all the WebSocket connections when a Spring Session (HttpSession) is terminated.
  
  
  // end::config[]
  
  