Cache-based rate limiting done. refactored request/response handling