Releases: kobylynskyi/graphql-java-codegen
Releases · kobylynskyi/graphql-java-codegen
4.1.0
- Support custom serialization of parameters in GraphQLOperationRequest #464 #472 #473
- Support interfaces to extend other interfaces (graphql/graphql-spec#373) #468 #469
- Support message for
@deprecated
directive #445 #471
- Kotlin support (via
generatedLanguage = KOTLIN
) - Scala support (via
generatedLanguage = SCALA
)
Kudos to @jxnu-liguobin for Kotlin and Scala support!
4.0.1
- Fix GraphQLRequest serialization with null input #412 #413
- Consider a case when both
Optional
&apiReturnType
is used #410 #414 - Consider primitive types in
ParametrizedInput
classes #421 #423 - Scala: Refactor
toString()
andequals()
, add examples #406 #411 - Scala: Optimizations and reformatting of generated classes #416 #417
- Refactor the library for multi-language support #407 #418
- Bump jackson-databind from 2.11.3 to 2.12.0 #409
4.0.0
New features and bugfixes
- Support Scala code generation #401 #402
- Via a new codegen config:
generatedLanguage
(for now accepts onlyJAVA
andSCALA
. More JVM languages might be supported in the future)
- Via a new codegen config:
- Support multiple queries in a single request #340 #350
- Example can be found here
- Generate primitive types for non-null GraphQL types #305 #386
- Breaking change. Migration is described below.
- Introduce config for specifying custom-serializable fields #260 #392
- Now it is possible to specify a list of fields that should be serialized in the way you want. Example
- Ability to skip "throws Exception" in api method signature #339 #375
- Via a new codegen config:
generateApisWithThrowsException
(by default =true
)
- Via a new codegen config:
- Maven plugin: Support parallel builds #325 #376
- To support Parallel builds in Maven 3
- Maven plugin: fix parameters parsing: customAnnotationsMapping/directiveAnnotationsMapping #389 #391
Breaking changes
This release has the following breaking change:
- Generate primitive types for non-null GraphQL types #305 #386
- Follow migration guide to update your GraphQLResolver implementation classes.
3.1.1
3.1.0
- Relay support (introduced new config) #295 #304
- Support code generation based on introspection query response #165 #297
- Ability to specify fieldsWithResolvers via directives #296 #299
- Ability to select "all" in client response projection #300 #302
- Add suffix after the default value of the base type (long) #292
3.0.0
New features and bugfixes
- Support multiple annotations #248 #273
- Affects
customAnnotationsMapping
anddirectiveAnnotationsMapping
- Affects
- Support for Optional when returning nullable types #269 #274
- Introduced new config:
useOptionalForNullableReturnTypes
. See codegen options. Also removedgenerateAsyncApi
and renamedapiAsyncReturnType
/apiAsyncReturnListType
.
- Introduced new config:
- Ability to generate only root interface with all APIs #270 #275
- Introduced new config:
apiInterfaceStrategy
. See codegen options
- Introduced new config:
- Support descriptions in Javadoc rather than comments #267 #268
- Taking into account GraphQL descriptions when generating classes with Javadoc. If the description for GraphQL type is not provided, then fetch GraphQL comments.
- Fix request serialization if null input was supplied #271 #272
Migration guide
Breaking changes
This release has the following breaking changes:
- Remove
generateAsyncApi
#269 #274 - Rename
apiAsyncReturnType
->apiReturnType
#269 #274 - Rename
apiAsyncReturnListType
->apiReturnListType
#269 #274 - Change type of
customAnnotationsMapping
: Map<String, String> -> Map<String, String[]> #248 #273 - Change type of
directiveAnnotationsMapping
: Map<String, String> -> Map<String, String[]> #248 #273
2.4.1
2.4.0
2.3.0
- Possibility to add
__typename
to response projection of GraphQL interfaces #230 #233 #229 - Support custom types for async Query/Mutation generation #228 #236 #229
- Support custom class-level annotations via
customAnnotationsMapping
#231 #234 - Handle java-reserved names in client generated classes #237 #238
2.2.1
- Support Response Projection for GraphQL interfaces #226 #227 by @kobylynskyi
Note: If you are migrating from version 1.x.x, please follow Migration Guide