6 Commits

Author SHA1 Message Date
Benoît Courtine
fa72c63b62
[Rust][Client] Unify sync/async client structure (#6753)
* Unify sync/async client structure (configuration as first param instead of a struct).

* Fix: Hyper client requires the client.rs file.

Co-authored-by: Henning Holm <git@henningholm.de>

* Add API method comments (description and/or notes when available).

Co-authored-by: Henning Holm <git@henningholm.de>
2020-07-01 15:24:20 +08:00
Benoît Courtine
93bd8571d3
[Rust][Client] Multiple returns becomes optional (fixes #6650). (#6673)
* fixes #6650. Rust client: multiple returns becomes optional.

* Rename new param "supportMultipleReturns" into "supportMultipleResponses".

* Remove redundant `UnknownList` enum option.

* update doc

Co-authored-by: William Cheng <wing328hk@gmail.com>
2020-06-19 14:57:01 +08:00
Benoît Courtine
8e2bf99ffb
[Rust][Client][Reqwest] Better http error handling (#6481)
* Stronger typing for http errors with Rust client. (#5609).

* Error structure can be parametrized (but is still hardcoded with `serde_json::Value` in generated code).

* Each API method has is own enum of functionnal errors.

* Fix the missing "Debug" derivation for API error enums.

* Generate models for error deserialization.

* Handle several 2xx success models.

* Expose new API objects, required to use the API (params, success, error structs/enums).

Co-authored-by: William Cheng <wing328hk@gmail.com>
2020-06-13 12:28:53 +08:00
William Cheng
db10bba1e3
Update rust config (#6600)
* update rust config

* update rust reqwest async sample
2020-06-10 16:23:15 +08:00
William Cheng
c176bdcb3e
[rust][reqwest] fix broken export (#6586)
* fix broken export

* add tests
2020-06-09 15:56:56 +08:00
William Cheng
bde0d77c8f
[Rust][reqwest] add async support (#6464)
* fix rust sync client

* update doc
2020-05-29 00:45:51 +08:00