anchor.diff:      credentials = Auth,
       validity_checkup_timer = OldTimer
   } = State) ->
  -    cancel_validity_checkup_timer(OldTimer),
  +    cancel_auth_validity_checkup(OldTimer),
  +
       case check_auth_validity(Auth, Identity) of
  -        {true, NewTimer} ->
  -            NewState = State#state{validity_checkup_timer = NewTimer},
  +        {true, TokenTTL} ->
  +            NewState = State#state{
  +                validity_checkup_timer = schedule_auth_validity_checkup(TokenTTL)
  +            },
               {noreply, NewState, hibernate};
           false ->
  -            mark_inactive(SessionId),
  +            mark_session_as_inactive(SessionId),
               schedule_session_removal(0),
               {noreply, State}
       end;
   
   handle_info({'EXIT', _, shutdown}, #state{session_id = SessionId} = State) ->
  -    spawn(fun() ->
  -        session_manager:terminate_session(SessionId)
  -    end),
  +    async_terminate_session(SessionId),
       {noreply, State, hibernate};
   
   handle_info(Info, State) ->
  
positive.code:     session_id = SessionId,
      session_grace_period = GracePeriod
  } = State) ->
      IsSessionInactive = case session:get(SessionId) of
          {ok, #document{value = #session{status = inactive}}} ->
              true;
          {ok, #document{value = #session{connections = [_ | _]}}} ->
              {false, GracePeriod};
          {ok, #document{value = #session{status = active}}} ->
              mark_inactive_if_grace_period_has_passed(SessionId, GracePeriod);
          {error, _} = Error ->
              {false, Error}
      end,
  
      case IsSessionInactive of
          true ->
              schedule_session_removal(0),
              {noreply, State};
  
negative.code: %%--------------------------------------------------------------------
  -spec handle_info(Info :: timeout() | term(), State :: state()) ->
      {noreply, NewState :: state()} |
      {noreply, NewState :: state(), timeout() | hibernate}.
  handle_info(?REMOVE_SESSION, #state{session_id = SessionId} = State) ->
      async_terminate_session(SessionId),
      schedule_session_removal(?SESSION_REMOVAL_RETRY_DELAY),
      {noreply, State, hibernate};
  
  