What's Changed
New Features
- Support
openapi-generator-maven-pluginVersion7.15.0by @Chrimle in #505Official support for Version 7.15.0 of
openapi-generator-maven-plugin. From now on, all changes will also be tested with 7.15.0. - Support
openapi-generator-maven-pluginVersion7.16.0by @Chrimle in #509Official support for version
7.16.0ofopenapi-generator-maven-plugin. NOTE: this dependency update will addimport java.util.Locale;to ALL generatedrecord/enumclasses. - Support
openapi-generator-maven-pluginVersion7.17.0by @Chrimle in #510Official support for version
7.17.0ofopenapi-generator-maven-plugin. This version will also be used during tests. This update does not update generatedrecord/enumclasses.
Bug Fixes
- Remove Extra Indentation on
record-fields by @Chrimle in #515Removes an extra indentation (space) before each field of a
record-class. This is to conform togoogle-java-format. NOTE: This affects ALL generatedrecordclasses. This is only a formatting fix, and does not not affect functionality in any way. - Avoid Instantiating Unused Fallback
List/Set-instances by @Chrimle in #518Fixes an unintended implementation of fallback values for
records withList/Set-fields. A fallback instance (ArrayList/LinkedHashSet) would always be instantiated, despite never being used, due to the usage ofObjects.requireNonNullElse(T,T). The fix is to useObjects.requireNonNullElseGet(T,() -> T)forList/Set-fields. This ensures that these fallback/default objects are not instantiated unless needed. No changes have been made to other field types. NOTE: This is intended as a performance improvement, and should not affect functionality.
Dependency Updates
- Bump com.github.spotbugs:spotbugs-annotations from 4.9.3 to 4.9.8 by @dependabot[bot] in #497
- Bump org.openapitools:jackson-databind-nullable from 0.2.6 to 0.2.7 by @Chrimle in #508
- Bump org.openapitools:jackson-databind-nullable from 0.2.7 to 0.2.8 by @dependabot[bot] in #498
- Bump com.google.code.gson:gson from 2.13.1 to 2.13.2 by @dependabot[bot] in #482
- Bump spring-web.version from 6.2.8 to 6.2.12 by @dependabot[bot] in #495
Summary & Reflection
This release adds official support for newer versions of openapi-generator-maven-plugin, which means that the .mustache template files are compatible with even more versions - verified by the extensive test suite. An implementation bug was discovered in record classes that have List/Set-fields, which was quickly fixed. Similarly, indentations of all fields in record classes were incorrect, but addressed quickly. This is the first MINOR release since 3.0.0, and is also intended as a production-ready release. With that said, a poll has been opened about creating/publishing release candidates. See #520, to better catch issues and potentially establish a more stable/predictable release cadence.
Full Changelog: v3.0.1...v3.1.0