13 Commits

Author SHA1 Message Date
William Cheng
2168851e8a
Better array handling in 3.1 spec (#18313)
* better array detection in 3.1 spec

* fix
2024-04-07 15:48:19 +08:00
William Cheng
3d2e38e347
add tests for query parameter (array of enum) in 3.1 spec (#18310) 2024-04-06 14:36:41 +08:00
William Cheng
6d10e80916
[normalizer] fix schemas incorrectly skipped (#18297)
* fix circular reference check in normalizer

* add new files

* fix
2024-04-05 13:55:22 +08:00
Flemming Nørnberg Larsen
a4508f6817
#18058 Fix the Java generator to generate valid @RequestMappings where the produce field takes list of string parameters instead of a single comma-separated string (#18092)
* #18058 Fix AbstractJavaCodegen.getAccepts() so it returns a String array instead of a comma-separated string, and fixed api.mustache so the @RequestMapping annotation generated produces for x-accepts as a parameter list instead of a (single) string.

* #18058 Updated test case to accept a string array instead of a comma-separated list.

* #18058 Reverted changes on imported compared to the main branch.

* #18058 getAccepts() is now hybrid, and can return both a single String or a String[].

* #18058 Rolled back the hybrid getAccepts(), so it only returns a String array.

* #18058 Updated mustache files to cope with vendorExtensions.x-accepts being a string array instead of a comma-separated string.

* #18058 Generated new sample files with by running `./bin/generate-samples.sh ./bin/configs/*.yaml`

* #18058 Optimization of getAccepts()

* #18058 Regenerated scripts that got broken after resolving conflicts on GitHub

* #18058 Fixed introduced issue with api.mustache causing a redundant accept with @HttpExchange with the PetApi.java, StoreApi.java, and UserApi.java.
2024-03-21 17:53:18 +08:00
William Cheng
51ef501c02
fix npe by prefixItems in normalizer 3.1 spec (#17955) 2024-02-26 15:24:55 +08:00
William Cheng
64c763b87a
[OAS 3.1] Fix null type check in normalizer (#17609)
* fix null type check in normalizer

* add back ref check

* add files
2024-01-14 00:49:35 +08:00
William Cheng
c6efe8810d better npe handling when processing openapi 3.1 spec 2024-01-13 11:21:08 +08:00
William Cheng
75ef9e0b02 update java samples 2024-01-12 12:51:33 +08:00
William Cheng
dc047b4e91
fix missing array description in 3.1 spec (#17427) 2023-12-19 11:35:46 +08:00
William Cheng
367301de22
deref parameter in normalizer for 3.1 spec (#17406) 2023-12-15 12:18:07 +08:00
William Cheng
d4d5196907
Better handling of any type in v3.1 spec (#17370)
* fix NPE in the example generator

* fix any type in 3.1 spec

* use log error instead
2023-12-11 17:13:55 +08:00
William Cheng
de8599906e
Better handling of API response in 3.1 spec (#16986)
* better handling of API response in 3.1 spec

* update PR template

* add tests
2023-11-05 15:24:02 +08:00
William Cheng
4b7a808a9f
[openapi-normalizer] add a rule to better handle openapi 3.1 spec (#16495)
* add samples

* update samples

* openapi 3.1 beta support

* update .gitignore

* fix composed schema, add oneof, allof tests in opeanpi 3.1 spec

* add allof tests, more fixes

* add null check

* update artifact id

* better null check
2023-09-05 23:27:00 +08:00