Unwanted error responses coming in springfox 2.8.0
See original GitHub issueI have used below configuration for @ApiResponses but when i checked the swagger info unwanted 403 and 404 error response are coming even though i haven’t added. springfox-swagger2 : 2.8.0 springfox-swagger-ui : 2.8.0
@ApiResponses(value = {
@ApiResponse(code = 401, message = "List of supported error codes:\r\n" + "- 40: Missing credentials\r\n"
+ "- 41: Invalid credentials", response = Error.class),
@ApiResponse(code = 400, message = "List of supported error codes:\r\n" + "- 25: Missing header\r\n"
+ "- 26: Invalid header value", response = Error.class),
@ApiResponse(code = 503, message = "List of supported error codes:\r\n"
+ "- 5: The service is temporarily unavailable", response = Error.class),
@ApiResponse(code = 500, message = "List of supported error codes:\r\n"
+ "- 1: Internal error", response = Error.class) })
Method : Get operation
Issue Analytics
- State:
- Created 6 years ago
- Comments:12 (3 by maintainers)
Top Results From Across the Web
java - Swagger 2 Issue - Spring Boot - Stack Overflow
Searching about I tried to change versions to 2.8.0, 2.7.0, 3.0.0... also returns error. The application is an apirest with task list ...
Read more >docs/release-notes.md · serv/springfox - Gitee.com
BUILD-SNAPSHOT @varghgeorge (#1186) Unwanted class with map of map attribute @cbornet (#1174) Doc: includePatterns does not exist (anymore?)
Read more >Springfox Reference Documentation - GitHub Pages
12, Allows globally overriding response messages for different http methods. In this example we override the 500 error code for all GET ...
Read more >Remove Basic Error Controller In SpringFox Swagger-UI
Learn multiple ways to configure Swagger in a Spring Boot application to hide paths exposed by the BasicErrorController.
Read more >Spring Boot RESTful API Documentation with Swagger 2
For best practices on documentation, I suggest going through this ... io.springfox. springfox-swagger2. 2.8.0. compile. com.h2database.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@dilipkrish thanks ,below one worked
@jtviegas would you mind creating a new issue for that so we dont miss it when working on 3.0