-
-
Notifications
You must be signed in to change notification settings - Fork 6.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Spring][server] oneOf Interface for Spring Boot #8091
Conversation
added x-is-one-of-interface extension for oneOf interface in mustache template
fixed name of model from UNKNOWN_BASE_TYPE to right one in api: operationId + OneOf Fix OpenAPITools#5381 parcelableModel is not required
removed not needed methods
catch NPE cases in preprocessOpenAPI updated samples
…rator into spring_fix_5381
fixed generation of oneOf Models
addOneOfInterfaceModel only for cases when useOneOfInterfaces is true and for spring
NPE fix
…rator into spring_fix_5381
…rator into spring_fix_5381 � Conflicts: � modules/openapi-generator/src/main/java/org/openapitools/codegen/DefaultCodegen.java
spring: fixed use of oneOf Models in API
implementing oneOf for spring lib overriding methods with different behavior from default
added x-is-one-of-interface extension for oneOf interface in mustache template
fixed name of model from UNKNOWN_BASE_TYPE to right one in api: operationId + OneOf Fix OpenAPITools#5381 removed not needed methods Fix OpenAPITools#5381 fixed generation of oneOf Models Fix OpenAPITools#5381 addOneOfInterfaceModel only for cases when useOneOfInterfaces is true and for spring Fix OpenAPITools#5381 NPE fix for tests
fixed handing of composed schema with array
fixed NPE in addOneOfInterfaceModel
fixed generation of oneOf models with descriminator
# Conflicts: # modules/openapi-generator/src/main/java/org/openapitools/codegen/DefaultCodegen.java
cc @OpenAPITools/generator-core-team as the change impacts default codegen. |
@wing328 can I get you to re-run the CI? Looks like a transient dependency download error. |
# Conflicts: # modules/openapi-generator/src/test/java/org/openapitools/codegen/java/spring/SpringCodegenTest.java
@wing328, hi. |
any news on this? |
Also would love to have this functionality! |
# Conflicts: # modules/openapi-generator/src/main/java/org/openapitools/codegen/DefaultCodegen.java # modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/SpringCodegen.java
I have resolved the merge conflicts. @wing328 can we get this scheduled for a release? |
@jburgess thanks for your work so far! Really excited for what happens next! |
@jburgess thanks again for the PR and sorry for the delay in reviewing as there're too many PRs. Please resolve the merge conflicts and I'll review later this week. |
FYI. I've resolved the merge conflicts and filed #10392 instead. |
Closed via #11650 |
This implements
OneOf
interfaces for the Java Spring library. Merges #5661 (@alexsuperdev) and #6589 (@rfecher) and refreshes against the main branch.Fixes #5381 and #15 (for Spring)
PR checklist
./bin/generate-samples.sh
to update all Petstore samples related to your fix. This is important, as CI jobs will verify all generator outputs of your HEAD commit as it would merge with master. These must match the expectations made by your contribution. You may regenerate an individual generator by passing the relevant config(s) as an argument to the script, for example./bin/generate-samples.sh bin/configs/java*
. For Windows users, please run the script in Git BASH.master
@bbdouglas @sreeshas @jfiala @lukoyanov @cbornet @jeff9finger @karismann @Zomzog @lwlee2608 @bkabrda