Added some logs for recording behaviour state change