5759 Commits

Author SHA1 Message Date
William Cheng
7649f659c4
add model caching to php generators (#12997) 2022-07-24 09:20:31 +08:00
William Cheng
86882e01ee
add model caching to kotlin generators (#12998) 2022-07-24 09:19:47 +08:00
William Cheng
3ac88e95ed
Add option to customize operationId in R client (#13000)
* add option to customize operationId in r client

* update doc
2022-07-24 09:19:18 +08:00
Thomas Hansen
7c7ac2f0d3
[PHP] double curly braces bugfix (#12999)
* [PHP] Small bugfix: fix punctual double curly bracket usage, to make it consistent with the code around

* [AUTOGENERATED] update samples
2022-07-24 09:18:48 +08:00
Ruben Fiszel
0b31bd4705
[Typescript] Support text/plain by ObjectSerializer.parse (#12888)
* [Typescript] Support text/plain by ObjectSerializer.parse

* generate-samples

* update samples

* clean up spaces

Co-authored-by: William Cheng <wing328hk@gmail.com>
2022-07-23 20:38:36 +08:00
William Cheng
fe8fbaf923
[Rust Server] Generate operations where tags require sanitization (#12996)
* [Rust Server] Render operations for sanitized tags

* [Rust Server] Add test for sanitized tags

* Update samples

Co-authored-by: Richard Whitehouse <richard.whitehouse@metaswitch.com>
2022-07-23 14:25:05 +08:00
William Cheng
a87da6ad3c
update undertow to newer version (#12994) 2022-07-23 14:07:15 +08:00
William Cheng
5cf1ba3841
add additonal dependencies for xml in resttemplate (#12995) 2022-07-23 14:06:09 +08:00
William Cheng
ee8566260c
[JAVA] Generated api client doesn't work for plain text body types (#12993)
Co-authored-by: Ilya Kuchmin <kuchmin@haulmont.com>
2022-07-23 13:07:26 +08:00
Vladimir V. Bychkov
434464c898
dateLibrary java8 does works now with xml (#8444)
Co-authored-by: v.bychkov <v.bychkov@betterbits.de>
2022-07-23 12:39:28 +08:00
eoghanbdoyle
153cfeb7ae
Fix crash in extractBodyContent when using large headers (#10636)
If you send a request with a body and a header greater than 255 characters long there will be an exception. The session->fetch will not return the body in the synchronous way expected.
2022-07-23 12:27:11 +08:00
Tristan Lins
2e6cdb5196
[typescript-fetch] Convert dates only if target type is a Date (#11685) 2022-07-23 11:45:36 +08:00
Mauro Valota
ea7a319a65
[java] fixed pojo template for nullable fields (#12630)
* [java] fixed pojo template for nullable fields

* regenerated samples
2022-07-23 11:19:48 +08:00
Oleh Kurpiak
9f2f36c4fb
[Java][WebClient] return ResponseSpec to manually control response handling (#12843) 2022-07-23 10:20:06 +08:00
William Cheng
6c9cd65e73
add model caching in perl client gen (#12992) 2022-07-23 09:19:24 +08:00
William Cheng
00ef7a8590
add schema mapping support to perl (#12991) 2022-07-23 08:56:47 +08:00
Bruno Coelho
c03cf178c9
[swift][client] reduce unnecessary public api (#12975)
* [swift][client] reduce unnecessary public api

* [swift][client] reduce unnecessary public api
2022-07-23 08:39:34 +08:00
Max K
08c4a35162
[aspnetcore] Added dotnet outdated to READMEs (#12981)
* Added dotnet outdated to READMEs

* Update samples
2022-07-23 08:37:17 +08:00
William Cheng
e4b268613c
[R] fix assignment, better doc (#12979)
* better code format

* fix doc comment, remove blank line

* ignore .lintr in rbuildignore
2022-07-22 13:08:01 +08:00
William Cheng
6e6c2f9a0e
add http basic test in r client (#12978) 2022-07-22 10:01:48 +08:00
William Cheng
f26985c239
add http bearer auth support to R client (#12974) 2022-07-22 09:44:05 +08:00
Justin Black
d1c2230709
v303 unit test spec, adds post json request bodies (#12875)
* Adds post request body routes and test data to spec

* Sample regenerated

* Adds tags and post endpoints

* Uses refs to tests examples in requestBodies

* Stops passing in test_examples into generate_operation

* Adds testCases to MediaType

* Adds refs to test cases in media type

* Adds post request body examples

* Fixes enum 1 ingestion of 1.0

* Only generates test examples when they exist

* Regenerates samples
2022-07-21 15:34:49 -07:00
Ry Bobko
1b6069f984
[Typescript-Angular] Handle runtime-generated injected BASE_PATH in Typescript-Angular services (#12936)
* handle array of strings for basePath

* handle string[] for basePath when generated from APP_INITIALIZER

* updated samples

* updated samples
2022-07-21 16:41:31 +02:00
Paul Hagedorn
298ccfcfd8
[typescript-nestjs] Upgrade to NestJS v8 (#12937)
* feat(typescript-nestjs): upgrade to nestjs v8

Set default nestVersion to 8.0.0

* chore(typescript-nestjs): create typescript-nestjs-v8-provided-in-root.yaml and add it to samples.json

* chore(typescript-nestjs): generate samples

* docs(typescript-nestjs): generate docs

* chore(typescript-nestjs): re-generate samples
2022-07-21 13:41:32 +02:00
William Cheng
eeb1711f9f
Add support for string response deserialization (#12964) 2022-07-21 15:18:59 +08:00
William Cheng
17ba8304b6
Update swashbuckle version to 6.4.0 (#12965)
* update swashbuckle to newer version

* use newer version of swashbuckle for all aspnet versions
2022-07-21 15:10:32 +08:00
William Cheng
c26e19cbc0 Revert "Add support for string response deserialization (#12910)"
This reverts commit b8524bee232a55e28693354ab543b91e3f65629a.
2022-07-21 12:58:46 +08:00
Emanuele Saccomandi
b8524bee23
Add support for string response deserialization (#12910)
* Add support for string response deserialization

* updated samples

* updated samples

* realigned to master

* fix: errors were not getting thrown

* updated samples

* fix: errors were not getting thrown

* updated samples
2022-07-21 12:45:50 +08:00
Martin Delille
cf58ac0583
[cpp-qt-client] Minor fixes (#12951)
* foreach => for

* Fix PetStore.pro

* Whitespace formatting
2022-07-21 12:03:22 +08:00
Max K
17c021df5b
Added support for inheritance in Swashbuckle in ASP.NET Core (#12856)
* Added support for inheritance in Swashbuckle

* Updated to new API
2022-07-21 11:44:46 +08:00
William Cheng
2248baa5ea
add schema mapping support to ruby client generator (#12962) 2022-07-21 11:38:27 +08:00
William Cheng
f898b072ba
add model caching to ruby client generator (#12961) 2022-07-21 11:22:41 +08:00
Yohei Kitamura
9b154bb437
[Ruby] Enhance Faraday middleware support (#12873) 2022-07-21 11:01:14 +08:00
Paul Hagedorn
33ec914e6a
fix(typescript-nestjs): initialize queryParameters in Service if auth uses apikey but has no other query parameters (#12940) 2022-07-20 19:33:09 +02:00
William Cheng
05f4792df7
[csharp-netcore] fix OAuth2 integration when using httpclient library (#12954)
* Update RestSharp to v108

* Add OAuth2 Application (client_credentials) authentication

* Run generators and fix typos

* Undo accidental python and rust changes

* Add documentation, fix authenticator bug, and fix user agent bug

* Fix tests

Missed some changes in the mustache templates.
Also had to update the `netcoreapp2.0` test project to `netcoreapp3.1` for compatibility with RestSharp

* Switch HttpUtility to WebUtility for compatibility

* skip oauth file generation for httpclient

* fix templates

* remove files, regenerate samples

* add reference to system.web

Co-authored-by: Jared Bates <Jared.Bates@sight-sound.com>
2022-07-20 20:30:56 +08:00
Jared Bates
2dcc319e13
[csharp-netcore] Update RestSharp and add client_credentials auth support (#12789)
* Update RestSharp to v108

* Add OAuth2 Application (client_credentials) authentication

* Run generators and fix typos

* Undo accidental python and rust changes

* Add documentation, fix authenticator bug, and fix user agent bug

* Fix tests

Missed some changes in the mustache templates.
Also had to update the `netcoreapp2.0` test project to `netcoreapp3.1` for compatibility with RestSharp

* Switch HttpUtility to WebUtility for compatibility
2022-07-20 19:25:29 +08:00
Cédric Thireau
0a0a8cffd6
Fix spring implicitHeaders w/o annotationLibrary (#12921)
Fix erroneous code generation when `implicitHeaders=true` and `annotationLibrary=none`
2022-07-20 11:42:49 +08:00
William Cheng
322f617d33
add schema mapping to powershell generator (#12934) 2022-07-20 11:10:27 +08:00
William Cheng
e2b1ed3dfc
add schema mapping to r client (#12933) 2022-07-20 11:09:56 +08:00
devhl-labs
92193f7159
Adds isInnerEnum to CodegenProperty (#12860)
* added nonNullableVars

* added return property to operation

* added return property to operation

* build samples

* added inner enum

* build samples

* added a comment
2022-07-20 01:41:17 +08:00
Bruno Coelho
8d62e597ae
[kotlin][client] Kotlinx Serialization code formating (#12922)
* [kotlin][client] Kotlinx Serialization cleanup

* [kotlin][client] Kotlinx Serialization cleanup
2022-07-19 14:05:17 +01:00
Marcus Handte
8fded5c47e
Fix npe when unwrapping optional. (#12882) 2022-07-19 12:11:11 +01:00
stropho
f176716a61
[typescript-axios] avoid stringifying header string values (#12919)
* feat(typescript-axios) don't stringify string headers

* samples
2022-07-19 09:55:34 +02:00
William Cheng
b722fd9063
cache the model name for faster lookup in r client gen (#12918) 2022-07-19 14:12:55 +08:00
William Cheng
d2be711669
powershell: cache model name for faster lookup (#12917) 2022-07-19 14:12:36 +08:00
Akhil Nair
259221ab25
This PR adds memoization to Java **toModelName()** method. (#12909)
### PR checklist

- [x] Read the [contribution guidelines](https://github.com/openapitools/openapi-generator/blob/master/CONTRIBUTING.md).
- [x] Pull Request title clearly describes the work in the pull request and Pull Request description provides details about how to validate the work. Missing information here may result in delayed response from the community.
- [x] Run the following to [build the project](https://github.com/OpenAPITools/openapi-generator#14---build-projects) and update samples:
  ```
  ./mvnw clean package
  ./bin/generate-samples.sh
  ./bin/utils/export_docs_generators.sh
  ```
  Commit all changed files.
  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](https://gitforwindows.org/).
- [x] File the PR against the [correct branch](https://github.com/OpenAPITools/openapi-generator/wiki/Git-Branches): `master` (6.1.0) (minor release - breaking changes with fallbacks), `7.0.x` (breaking changes without fallbacks)
- [x] If your PR is targeting a particular programming language, @mention the [technical committee](https://github.com/openapitools/openapi-generator/#62---openapi-generator-technical-committee) members, so they are more likely to review the pull request.

This PR greatly reduces the time taken for Java code generation.
**toModelName()** method is invoked numerous times and it was accumulating a lot of time.

This has reduced the Java SDK generation time for our rather large open API spec from ~3h30m hours to 4 mins.

The generated code is the same as before.

spec: https://cdn.intersight.com/components/an-apidocs/1.0.11-7546/model/intersight-openapi-v3-1.0.11-7546.yaml

@wing328
2022-07-19 11:48:32 +08:00
William Cheng
b88666b87a
add uuid test, better hyper test (#12916) 2022-07-19 11:22:29 +08:00
Taufik Rama
4ee336a9da
[Rust] Changed 'UUID' handling into 'uuid' crate (#12895)
* [Rust] Changed 'UUID' handling into 'uuid' crate

* [Rust] updated 'samples/'
2022-07-19 11:03:53 +08:00
Jaemin Park
ed4ed3923f
[cpp-ue4] Fix GET request writes body (OpenAPITools#12833) (#12904)
Co-authored-by: nullbus <nullbus@nm-fc.com>
2022-07-18 17:14:18 +08:00
William Cheng
2e0a121205
add decimal support to crystal cilent (#12899) 2022-07-18 17:01:36 +08:00