Automated JSON API documentation for API's built with Spring
APACHE-2.0 License
Bot releases are hidden (Show)
Picture Credit National Geographic
First and foremost a big thank you to the community for keeping me motivated to work on this project. There have been some really amazing contributions in this release in terms of code, comments, bug reports and it is humbling to see people jumping in to solve problems on the issue forum. It sure motivated me to get over the "hump" and start working on in earnest. What better way to lose the COVID blues!
Thank you! 🥳 🍾
Also please welcome the newest maintainer to the springfox team @MaksimOrlov. A lot of the great work you see in the model generation support is due to his efforts, collaborating tirelessly on weekends and not giving up while ensuring the model generation engine is performant 👏
NOTE: This is a breaking change release, I've tried to maintain backwards compatibility with earlier versions of springfox as much as possible. Deprecated APIs prior to 2.9 have been aggressively removed and new APIs that will go away in the near future have been marked. So please look out for those and do report anything that has been missed.
Highlights of this release include
springfox-boot-starter
dependency (Zero Config, Autoconfiguration support)Significant contributions that come to mind (and please remind me of others in this list cos' my memory is weak)
ModelAndView
parameter, an error log appears. (#3380) by @wangxinImplementation-Version
to MANIFEST.MF (#3341) by @seregamorphPublished by dilipkrish over 6 years ago
© JUDITH VRUGT, NATIONAL GEOGRAPHIC YOUR SHOT
Thank you for the patience with this release. More importantly, thank you for your contributions in helping identify bugs and issues and improving the library with your contributions!
duplicate
@gionnduplicate
@andyRokitduplicate
@FossilBladeduplicate
@gionnduplicate
@litttlefisherduplicate
@maraswronaduplicate
@andyRokitduplicate
@stevePublished by dilipkrish over 6 years ago
©️Photograph by Alex Geifman courtesy National Geographic
This is the last release supporting jdk 7 and spring 4.x. The next planned release is 3.0 which will have jdk 8 as a pre-requisite. There was a large effort to ensure a stable release before moving to the next major release. A big thank you again for the numerous feature/bug requests for making this product better and supporting this library.
A special thank you to @kasecato, @MaksimOrlov, @neumaennl, @rgoers and @Fyro-Ing for working on some much requested features.
NOTE: All deprecations will be removed when we move to 3.0
NOTE: This release isnt available via maven central due to issues publishing to maven central. Still working through the issues. It is available via jcenter.
duplicate
@igieonduplicate
@rantunesboreasduplicate
@PascalSchumachernot-reproducable
@thiagolocatellinot-reproducable
@ok11duplicate
@k631583871duplicate
@903452746duplicate
@Mumijava.lang.NoSuchMethodError
duplicate
@salah3xduplicate
@Snina88not-reproducable
@bgiaccioPR
@kasecatoPR
@kasecatoResources
not rendered correctly duplicate
@raffaelschmidPublished by dilipkrish almost 7 years ago
Photograph by Margaret Krzepkowski
Thank you everyone for your contributions.
While this release still doesnt support OpenAPI 1.0 spec, it does bring support for the new swagger-ui look thanks to @kasecato!! 🙇
Apologies for the delayed release schedule of 2.8.0. Much of the work in this release was to shore up the library for significant work in the near future to support in 2.9.0
swagger1
2.9.0 will be the last supported release for Java 6/Java 7. Much of 2.9.0 will focus on Improvements in the model rendering thanks to @MaksimOrlov! 🙇 (support @JsonView, better support for rendering the same models in request/response, inheritance support). Please note the deprecation warnings to prepare for breaking changes in 3.0.0.
(#2178) Change regex in Paths.java to handle expressions/constraints correctly @nobe0716
(#2174) fix fmt maintenanc @silenceshell
(#2169) Swagger ui 3.x suggested improvements feature
@kasecato
(#2160) Fix conversion of byte to integer with max / min bug
@avdv
(#2153) Upgrading Swagger UI to 3.7.0 @kasecato
(#2144) Allow ApiModelProperties on methods to be discovered from superclasses @RoyJacobs
(#2106) Add support for exclusive ranges handling @filiphr
(#2103) Fix some tests under windows @apixandru
(#2101) Fix Remapping issue @apixandru
(#2081) Fix child expansion context creation bug
@gzsombor
(#2069) Optimise HandlerMethodResolver.getMemberMethods maintenance
@simongajdosech
(#2066) Added error handling around "duplicate" request handlers @mate1983
(#2048) Support explicit ordering for Tags @jroweboy
(#2040) Use Guava 20.0 throughout the project maintenance @Thunderforge
(#2014) Fix markdown @koppor
(#2013) Fixed merging headers from the already existing request with the supplied request @pvanassen
(#1988) custom the web page title as swagger.title when had set it @rainplus
(#1974) Add default property support on model properties feature
@matrosovs
(#1956) @ApiModelProperty example string does not escape char "" from JSON example @heapifyman
(#1952) Fix to recognize @Param as query parameter in EntitySearchExtractor know @viruscamp
(#1943) Wrong API resource path in Swagger 1.2 @mathieuales
(#1942) Model classes having names containing integers are not detected as array @mathieuales
(#1917) Consumes / Produces media-types on the document level aren't copied and merged anymore with the operation level consumes / produces media-types. @mzeijen
(#1914) Provide proprty pattern annotation support @simonamc
(#1897) Correct spelling and typos @naXa777
(#1878) Preserve tags order in documentation builder @rainoko
(#1868) Create EntitySaveExtractor.java @jadhavsuhas
(#1838) Fix a mixed up part in the Getting Started guide for Docket @PeterWippermann
(#1837) Minor update of Docket's JavaDoc @PeterWippermann
(#1829) JacksonEnumDeterminer to handle JsonFormat.Shape.Object @yelhouti
(#2177) Paths.sanitizeRequestMappingPattern fix @nobe0716
(#2139) Should support "title" property, set via @ApiModel annotation. @ngbalk
(#2088) @ApiParam(allowableValues = "range(0, infinity)") does not work @filiphr
(#2063) Added support for Pageable resolved parameter @avillev
(#2057) Swagger-ui don't render additionalProperties duplicate
@deblockt
(#2026) Produces/Consumes do not maintain order @jgaribay21
(#2023) Is it possible to disable globalResponseMessage configuration partially. duplicate
@dohoon
(#2021) @ApiModelProperty.allowEmptyValue = true/false does not emit "allowEmptyValue" in swagger.json @bill
(#2000) Upgrade to latest version of Swagger UI (3.1.5) duplicate
@madheshr
(#1960) Upgrade to swagger-ui 3.0 duplicate
@alex
(#1957) springfox doesn't work with spring boot 2.0 and spring data Kay-RC2 duplicate
@shashankitmaster
(#1955) Add support for inclusive and exclusive ranges for allowable values @JohnNiang
(#1946) collectionFormat problem @vitek499
(#1936) configuration for adding dynamic api-key(access token value). duplicate
@akashgupta08
(#1919) Add support to rename ApiModel property name in Model Attributes @peterjurkovic
(#1901) Pattern Bean Validations API (JSR-303) support for Request Parameters help wanted @simonamc
(#1900) Tag custom ordering @rainoko
(#1818) JsonFormat for enum and other cases @yelhouti
(#1729) Status of support for v3.0.2 of Swagger UI duplicate
@JLLeitschuh
(#2161) How to set a default value to a field of a model? in progress @michele
(#2093) swagger-ui.html appears to be empty documentation
@silentsnooc
(#2090) When using AlternateTypeRuleConvention ApiModelProperty annotation does not work @snimavat
(#2031) How to get object in response body in autogenerated swagger.json file documentation
@rajat
(#2029) ApiImplicitParam with empty datatype fails when we try it out documentation
@ljp510016132
(#1995) View APIs from different Spring Cloud Instances registered in Eureka documentation
@s
(#1971) Vavr/Javaslang Jackson module support documentation
@Sir4ur0n
(#1954) Multiple swagger JSON's in swagger-ui.html documentation
@dreambrother
(#1950) Document support customized param using HandlerMethodArgumentResolver documentation
@neil4dong
(#1916) Consumes and produces media-types defined on Docket are incorrectly merged together with consumes/produces media-types that are defined on a resource level @mzeijen
(#1913) Space getting added to oAuth scope while making authorization request documentation
@mojaiq
(#1904) Nondeterministic output for Models used in multiple controllers documentation
@kevinm416
(#1899) Upgrade libraries @dilipkrish
(#1896) Wrong spelling and typos in code @naXa777
(#1882) @RepositoryRestResource -- ApiParam definition for the JPA methods always defines the @Param as "body" type parameter @aniruthmp
(#1875) Tags should be orderable @rainoko
(#1870) The lasted version supported for Swagger UI 3.x? @maliqiang
(#1865) Can't test the configuration 404 not found documentation
@pinkyjain26
(#1833) Different guava versions in dependencies @Dimok74
(#1704) Document springfox oauth2 documentation
duplicate
@kidshg
(#2165) AlternateTypeRules doesn't work as expected @crmky
(#2148) 2.7.1-SNAPSHOT NullPointerException when attempting to view http://localhost:8080/v2/api-docs @beardy247
(#2138) java.util.Optional<java.time.OffsetDateTime> disappears from request params duplicate
@bohdan
(#2135) No qualifying bean error when launching spring 5.0.x application with springfox duplicate
@gauravphoenix
(#2133) Optional @kitsjory
(#2132) @ApiModelProperty has no effect on some variables (name starting with one lowercase) not-reproducable
@bbrenne
(#2118) Request type mapping doesn't work if using both RequestBody and ModelAttribute on the same parameter @andrea
(#2114) @RequestParam and @PathVariable annotated parameters should not be expanded @loxal
(#2111) Application startup failed org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'documentationPluginsBootstrapper' @shobhit921
(#2107) @ApiParam ignores certain properties duplicate
@milosonator
(#2097) Swagger 2 : Getting "type": "ref" when using @RequestPart duplicate
@jrishabh198
(#2096) @ApiParam is ignored on ValueObjects wrapped with @JsonCreator @dkellenb
(#2080) NullPointerException in handlerPackage duplicate
@ejuniorasas
(#2072) Springfox generates Api-Doc for non-exported Repositories @stoetti
(#2053) @PathVariable work with Parameter Converter strangely duplicate
@cxl086
(#2039) Endpoints with the same path and parameters but different headers some times cause java.lang.IllegalArgumentException: Multiple entries with same key @joaoacmota
(#2025) SpringFox-Data-Rest 2.7.0: Missing camelCase with generated Associations operationIds @stoetti
(#2015) Add support for generics not-reproducable
wontfix
@raderio
(#2012) Duplicated swagger.json document not-reproducable
@cesartl
(#2011) OperationBuilder mergeResponseMessages overwrites headers @pvanassen
(#1999) Generated JSON for endpoints with PathVariables converted to non-trivial objects is incorrect duplicate
@joel
(#1998) PathVarible composed of Custom Objects are not parsed correctly duplicate
@frbo42
(#1965) @RequestPart annotation not rendering models correctly @pratapyelugula
(#1963) Spring Data Rest Integration doesn't document repository method parameters correctly @thombergs
(#1961) Springfox - Authorization value didn't update after Authorize confirmed.. @thomasharin
(#1941) swagger-ui does not remove java string escape char "" from @ApiModelProperty example @heapifyman
(#1932) BasePathAwareController docs aren't base path aware @fquinner
(#1926) Can't be filtered by ignoredParameterTypes not-reproducable
@heyuxian
(#1924) Unable to define host in Swagger 1.2 @mathieuales
(#1906) Swagger shows wrong id field using Spring Data Rest duplicate
@drenda
(#1894) @EnableSwagger2 breaking my unit tests not-reproducable
@rawadrifai
(#1890) Can't declare Docket in multiple Configuration classes not-reproducable
@lorenzobenvenuti
(#1887) @ApiResponses tag does not override default responses not-reproducable
@muff1nman
(#1880) Wrong API resource path in Swagger 1.2 @mathieuales
(#1876) NullPointerException with Spring Data Rest integration @drenda
(#1866) 2.7.0 does not list PATCH methods from Spring Data Rest @jadhavsuhas
(#1864) @NotNull not working to mark field as required @sddakoty
(#1860) [Spring boot] @EnableAspectJAutoProxy cause endpoint scanning failed duplicate
@jdupont22
(#1841) Overloaded method does not respect the "tag" option @jackmatt2
(#1839) Primary keys are added to path parameters for Spring Data Rest Entities POST request after upgrading to 2.7.0 @jadhavsuhas
(#1830) CORS headers disappeared after upgrading to 2.7.0 not-reproducable
@gionn
(#1804) Api key input missing in swagger ui after upgrading version to 2.6.1 @prajapatkiran
(#1781) Swagger JSON generated by SpringFox shows 'Consumes' for GET and DELETE operations @dcp65
(#1672) Swagger-UI giving 405 (Method not allowed) when called not-reproducable
@GarrettMosier
Published by dilipkrish over 7 years ago
Photo credit Mark Summers via National Geographic
Thank you for being patient with this release. This is packed with bug fixes (over 40 of them) and over 15 new features.
Many thanks to those contributing with feature requests, questions, bug reports and most importantly helping out with pull requests. With time being such a premium, its getting harder and harder to address without the contributions of the many listed below.
Significant changes in this release
#1806 Update PropertySourcedRequestMappingHandlerMapping.java @OzgaRobert
#1793 [#1770] Remove the requirement for property sources placeholder @dilipkrish
#1782 Model property vendor extension @philippejulien
#1776 Fix Swagger version error in documentation @ersinciftci
#1761 Vendor Extensions for API Info and Documentation @jkgentry
#1758 Use double backtick to prevent miss parsing @naxhh
#1741 1740 @JsonUnwrapped is ignored by schema generation test @StepanLeybo
#1730 Fix a typo at the common-problems documentation file @florianrusch
#1717 Adding vendorExtensions in apiKey class @cfernandezh
#1702 Make ApiResourceController methods public @psyho
#1699 Make Swagger2Controller respect basePath even if a host is not set @asdcdow
#1693 Fix for https://github.com/springfox/springfox/issues/1653 @pjskyboy
#1667 #1666 allowableValues blank for Optional parameter @madgnome
#1660 waffle.io Badge maintenance @waffle
#1617 Updated swagger-ui version to 2.2.8 @acourtiol
#1593 OAuth2 not initialized when clientSecret undefined @gonzalad
#1589 Apply ApiParam hidden attribute to parameters @defshine
#1576 Added support for composed bean validation constraints @jamesbassett
#1371 JSR-303 for Request parameters, Fix Allowable values not displayed in Apidocs, Externalizing Api Descriptions @jfiala
#1759 Support for property vendor extensions @philippejulien
#1707 Removal of "swagger-ui.html" from uri path causes swagger-ui JavaScript error @LukeHackett
#1636 VendorExtension support in ApiKey @mlstocks
#1627 Error with group handling response @marchc
#1592 OAuth2 clientSecret shouldn't be required for implicit flow @gonzalad
#1590 springfox-data-rest : Pageable not supported duplicate @tooms4444
#1544 [Feature request] JDK8 JSR310 types support @cbornet
#1497 springfox-staticdocs : Update to last swagger2markup version @orevial
#1490 Infer alternate type rules using serializers and deserializers @justcoon
#1423 @RequestParam with placeholders syntax like ${x.y} @blelem
#1413 Ability to set VendorExtensions on ApiInfo? @michael-pratt
#1367 Springfox overwrites swagger path entries with the same base path but with different content types @codecounselor
#1299 Feature Request: Upgrade swagger2markup version to v1.0.0 duplicate @fayndee
#1227 Bean Validations API (JSR-303) support for Request Parameters @jfiala
#1169 Add Support For Documenting Services In Grails Projects @dilipkrish
#1008 Models with different packages are not represented uniquely in the generated swagger document @tenstriker
#824 Support vendor extensions in operations @cbornet
#1736 Spring-Data-Rest support for property references
#1701 Make ApiResourceController methods public @psyho
#1694 Fixed the intermittent build failures @dilipkrish
#1675 Why generic method names are being generated for Spring Data Rest? @tahir
#1653 springfox-data-rest: 2.6.1 spring-data-rest: 2.6 RepositoryRestHandlerMapping constructor broken @cbbs
#1644 Update library to support for Spring 5 @binkley
#1628 swagger-ui 2.2.10 @IanSwift
#1621 2.6.1 breaks @Value placeholder replacement @2is10
#1505 Release process fails when updating the documentation @dilipkrish
#1797 How to write a custom ApiListingScannerPlugin? @indrabasak
#1786 StackOverflowError In 2.6.1 @tcsw1221
#1785 @ApiOperation "response" value causing docs to ignore model annotations @bfinleyui
#1780 ConcurrentModificationException on startup with -20170420.041823-43 @gionn
#1778 javax @Valid annotation makes parameter as requestbody-parameter @jmattheis
#1775 Swagger version error in documentation @ersinciftci
#1772 BasePath can't be defined without host @astafev
#1770 SNAPSHOT breaks @Value placeholder replacement @stacysimpson
#1767 Unable to implement and use ApiListingScannerPlugin @stacysimpson
#1749 Error resolving $ref pointer for input DTO @gionn
#1746 How to override API-Documentation of generated endpoints (spring-data-rest) @florianrusch
#1734 swagger ui not showing the default parameter value zero @liudonghua123
#1732 Default value of "supportedSubmitMethods" in springfox.js @thadc23
#1727 Jackson required/optional @raderio
#1726 @Size is not working @raderio
#1725 If you have both Read and Write operation in single Controller readOnly do not work. But if only Write it works. @dzmitryhil
#1724 Swagger methods in multiple groups being renamed @nitin02
#1708 @EnableSwagger2 interfering with application configuration. @rycentious
#1706 X-Forwarded-Port NumberFormatException: For input string: "443,443" looking-for-contributions @sixcorners
#1698 [BUG] custom swagger endpoint returns a 404. Default endpoint works. @ahatzz11
#1697 Problem with direct model substitution @cbornet
#1677 OAuth2 request adds vendorExtension
scope to all auth requests @pmlido
#1676 Invalid attributes that starts with x or y @isolisduran
#1670 Question: how to use @ApiParam annotation on a parameter defined in an interface? @taxone
#1666 AllowableValues blank for Optional parameter @madgnome
#1651 ResponseHeaders do not preserve lexical ordering question @ahatzz11
#1648 Operation ordering is not working @neil
#1632 Invalid response model for class with name "File" @dreambrother
#1623 Swagger annotations like @ApiParam, @ApiOperation annotation work for Spring Data Rest operations @taxone
#1615 api_docs shows content but swagger-ui (2.6.1) is empty @StefanSchubert
#1613 HTML code in API description in ignored using springfox-swagger-ui 2.6.1 @anouarchattouna
#1605 Response with a byte array does not work as expected @maukito
#1603 StackOverflowError on swagger generation @jmattheis
#1597 @ApiParam value is not respected @sta
#1594 IndexOutofBoundException when using unbounded Map models @sac10nikam
#1588 springfox-data-rest : @Param annotation not supported @tooms4444
#1580 Can't expand the operation when I set @Api tags by chinese wontfix @letorn
#1571 2.6.1 Cannot read property of custom enum list @jearton
#1569 When using ApiKey "keyname" is mapped incorrectly in progress @jmattheis
#1507 Broken basePath with AbstractPathProvider in version 2.5.0 of springfox-swagger2 @danielbcorreia
#1435 Setting a Custom basePath Requires Setting a Static Host in 2.5 looking-for-contributions @asdcdow
Published by dilipkrish almost 8 years ago
Photo courtesy National Geographic
A big thank you for reporting bugs and
Published by dilipkrish about 8 years ago
The one where spring data rest support lands!
The one that you've all been waiting for :)
image courtesy @SWildlifepics
This is the initial support, its is still rough would love to have feedback to improve support.
Thank you for all your contributions!
Published by dilipkrish over 8 years ago
Photo courtesy: https://twitter.com/swildlifepics/status/736672399958114304
Not to mention all the questions and suggestions by the community!! 🤘
Published by dilipkrish over 8 years ago
©️ Image courtesy of Richard Spiller@flickr
(#1145) Generated file is not compatible with Swagger specification if method parameter is Object and is used as path parameter @tjuchniewicz
(#1122) Default page served isn't configurable and lacks search / listAll functionality @porcoesphino
(#1087) Change hardcoded "api_key" @JulianaRed
(#1061) Add support @RequestParam of type Map<String, String> @matias2681
(#1046) Control over swagger contact object @smwurster
(#1037) Add support for multiple allowable values @smwurster
(#1023) Provide a method for Model Properties to by sorted by configurable methods @nickpanaiotov
(#969) Support alternate type resolution for @ModelAttribute annotated model fields @ejain
(#937) Add support for @ResponseHeader @MarkVanVenrooij
(#936) Add support for adding global tags to the docket @dilipkrish
(#735) Support for adding additional models for request or response that are not inferred from operationshas-workaround @cabbonizio
(#388) @ApiParam not working on Interface method declarations @charleslieferando
(#356) Support for JSR-303 (Java Bean Validation) @omayevskiy
(#1194) Swagger-ui does not render correctly in safari
@dilipkrish
(#1193) NPE when Feign, Swagger and Spring Security are used - Brixton.BUILD-SNAPSHOT @varghgeorge
(#1186) Unwanted class with map of map attribute @cbornet
(#1174) Doc: includePatterns does not exist (anymore?) can-use-for-docs @vorburger
(#1147) Using parameterized types using Void resulting in invalid Swagger @nigelsim
(#1132) Api operations on abstract superclass not affected by @API tags @gionn
(#1129) Swagger2Controller.getDocumentation get IndexOutOfBoundsException @yqzhan2014
(#1127) Setup base URL after Swagger UI is initialized #1126 @chornyi
(#1126) Race condition and crash on Swagger UI startup @chornyi
(#1125) Service description has no api's as the path regular expression does not match any of the service @irfandawood
(#1051) Customised ObjectMapper not recognized @milanov
(#953) NullPointerException when extending controller classes with multiple parameterized types @woemler
(#902) @ApiImplicitParam: "array" dataType is getting resolved into "type":"ref" @anny-ts
(#1180) Supply the text values for `@ApiOperation, @ApiResponse, @ApiParam, @ApiModelProperty from an external resource file, instead of hardcoding? @joetconcur
(#1168) Changelog not being updated question @jayanderson
(#1161) Update documentation for JSR310 and Joda dates @cbornet
(#1142) Fix the reference document not showing versions correctly in the gh pages @dilipkrish
(#854 ) Rework the ModelRef design to not be a hacky project of the swagger models @dilipkrish
A BIG thank you 🙇 for all the questions/issues/comments and contributions to make this a better product!
(#1189) Allow extension of ApiResourceController by making its methods public @gmarziou
(#1165) ParameterDefaultReader in swagger does not honor other annotations usage of DefaultValue @ctruzzi
(#1163) Updated the Docket XML Configuration Documentation @kellydavid
(#1159) Add basic Bean validation api (JSR-303) support @jfiala
(#1127) Setup base URL after Swagger UI is initialized #1126 @chornyi
Published by dilipkrish almost 9 years ago
spring-hateoas
#1104java.util.Objects
class so that java 6 is still supportedBig thank you to @wxjlibra, @abaile33 for reporting bugs and Thanks @sbuettner and @vmarusic for the PRs!
Published by dilipkrish almost 9 years ago
Full Changelog
As usual thank you for all your PR's, questions and support. Special thanks to @RobWin for also hanging out on the gitter channel and helping answering questions!
Highlights of this release are:
Features:
Pull requests from the community: 🙇
Bug Fixes:
Closed issues:
Published by dilipkrish about 9 years ago
Thank you as usual for everyone who contributed in some for or the other to make this product better!! This release sneaks in some features we're incubating to provide hypermedia support.