private void setResponseHeaders(String location) throws RestServiceException {
    restResponseChannel.setStatus(ResponseStatus.Created);
    restResponseChannel.setHeader(RestUtils.Headers.LOCATION, location);
    restResponseChannel.setHeader(RestUtils.Headers.CONTENT_LENGTH, 0);
    restResponseChannel.setHeader(RestUtils.Headers.CREATION_TIME, new Date(blobProperties.getCreationTimeInMs()));
  }
Sets the required headers in the response.
@param location the location of the created resource.
@throws RestServiceException if there was any problem setting the headers.
ambry-api/src/test/java/com/github/ambry/rest/MockRestRequestService.java