REP-1283 DeRP Filter

I'm not sure if system level tests will be necessary for this story? Since I can actually test the Java filter API doFilter method, my unit tests are fairly comprehensive and can be expanded to cover more cases. Actually, I suppose we need a test for the response messaging service, at least.

Note: The tests won't pass on this branch until we cut a release of http-delegation. We should also probably update the version api-checker uses.
Shouldn't it be using the repose message service? So that whatever template is applied is used? 

On December 2, 2014 6:03:22 PM CST, Damien Johnson <notifications@github.com> wrote:
>> +    delegationValues.flatMap { value =>
>> +      parseDelegationHeader(value) match {
>> +        case Success(value) => Some(value)
>> +        case Failure(e) =>
>> +          LOG.warn("Failed to parse a delegation header: " +
>e.getMessage)
>> +          None
>> +      }
>> +    }
>> +  }
>> +
>> +  def sendError(httpServletResponse: HttpServletResponse,
>statusCode: Int, responseBody: String, responseContentType: String):
>Unit = {
>> +    httpServletResponse.setContentLength(responseBody.length)
>> +    httpServletResponse.setContentType(MediaType.TEXT_PLAIN)
>> +    httpServletResponse.getWriter.write(responseBody)
>> +    httpServletResponse.sendError(statusCode)
>> +  }
>
>I just want to get eyes on this since I'm not sure this is the "right"
>way to send a response with a body. Do we want to set the content type
>to `text/plain`?
>
>---
>Reply to this email directly or view it on GitHub:
>https://github.com/rackerlabs/repose/pull/1184/files#r21203150

-- 
Sent from my Android device with K-9 Mail. Please excuse my brevity.