private boolean canHonorRequest(RestRequest restRequest, RestResponseChannel restResponseChannel) {
    if (restRequest == null || restResponseChannel == null) {
      throw new IllegalArgumentException("One of the arguments was null");
    } else if (!serviceRunning) {
      handleResponse(restRequest, restResponseChannel, null,
          new RestServiceException("RestRequestService not running", RestServiceErrorCode.ServiceUnavailable));
    }
    return serviceRunning;
  }
Performs null pre checks and checks that the service is running.
@param restRequest the {@link RestRequest} that needs to be handled.
@param restResponseChannel the {@link RestResponseChannel} that can be used to set headers.
@throws IllegalArgumentException if either of {@code restRequest} or {@code restResponseChannel}is null.
@return {@code true} if the the service has the right arguments and is in a state to honor the request. Otherwise
         {@code false}.
ambry-api/src/test/java/com/github/ambry/rest/MockRestRequestService.java