Skip to content

Commit

Permalink
Merge pull request #15554 from phillip-kruger/health-openapi-fix
Browse files Browse the repository at this point in the history
Added descriptions to Health OpenAPI Filter responses
  • Loading branch information
geoand authored Mar 9, 2021
2 parents f7126d0 + 8d33525 commit 7347d9b
Showing 1 changed file with 5 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -125,14 +125,15 @@ private Operation createReadinessOperation() {

private APIResponses createAPIResponses() {
APIResponses responses = new APIResponsesImpl();
responses.addAPIResponse("200", createAPIResponse());
responses.addAPIResponse("503", createAPIResponse());
responses.addAPIResponse("500", createAPIResponse());
responses.addAPIResponse("200", createAPIResponse("OK"));
responses.addAPIResponse("503", createAPIResponse("Service Unavailable"));
responses.addAPIResponse("500", createAPIResponse("Internal Server Error"));
return responses;
}

private APIResponse createAPIResponse() {
private APIResponse createAPIResponse(String description) {
APIResponse response = new APIResponseImpl();
response.setDescription(description);
response.setContent(createContent());
return response;
}
Expand Down

0 comments on commit 7347d9b

Please sign in to comment.