Slight bug in the documentation for the LoginHandler example, specifically with the getRedirect() function. There is a chance of returning the Uri object instead of a string.
The final return statement return $redirect; should be cast to string,return (string)$redirect; to ensure a string is returned and not the actual Uri object.
When a user is authenticated both her/his identity and roles are stored in the session. Subsequent requests will check for any active session first, so, even if the user was deleted or updated with more restricted roles, as long as the session stays active, the user can operate with old permissions (the user snapshot at login time) (Think of a rude forum member)
Sessions can also survive browser close/reopen operation if the browser is configured to remember session cookies when the session lifetime is not set to be very short.
I have always used a different approach: I store just the identity (id/username/email) of the user in the session and reload the user details/permission from the storage (db) on every request.
I'm not sure how to present an alternative workflow in the documentation therefor I'm starting this discussion to figure out the how's and where's. If you want take the code and incorporate it into the documentation yourselves then that's fine too, I'm not much of a documentation guy ๐