es-rest: HTTP 201 is considered an error

Description

The es-rest forwarder code is treating HTTP 201 Created as an error even though this is a normal HTTP return code.

Acceptance / Success Criteria

None

Lucidchart Diagrams

Activity

Show:

Jesse White March 16, 2017 at 7:19 PM

Markus von Rüden February 7, 2017 at 5:06 AM

Depending on what library you are using, there is sometimes a "result.getFamiliy() == SUCCESS_FAMILY" functionality. Which verifies that the response is >= 200 and < 300

Seth Leger February 1, 2017 at 10:59 AM

Yeah, in the code it performs a strict "== 200" check, we just need to adjust this.

Christian Pape February 1, 2017 at 10:44 AM

Maybe you can just use result.isSucceeded(). At the end this just checks for (httpCode/ 100 == 2) as far as I know.

Seth Leger January 30, 2017 at 2:27 PM

Here's a log message that is created:

Fixed

Details

Assignee

Reporter

Sprint

Fix versions

Affects versions

Priority

PagerDuty

Created January 30, 2017 at 2:26 PM
Updated March 16, 2017 at 11:19 PM
Resolved February 9, 2017 at 10:31 AM