Skip to content

Commit 6b69273

Browse files
authored
[Rust] Add support for native-tls and rustls-tls Cargo features for the reqwest library (#21925)
* feat(rust): add the native-tls (default) and rustls Cargo features for `reqwest` * refactor(rust): rename the `rustls` Cargo feature to follow the ecosystem naming convention
1 parent ee4cb9a commit 6b69273

File tree

19 files changed

+664
-5
lines changed

19 files changed

+664
-5
lines changed

modules/openapi-generator/src/main/resources/rust/Cargo.mustache

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -86,6 +86,11 @@ async-trait = "^0.1"
8686
google-cloud-token = "^0.1"
8787
{{/supportTokenSource}}
8888
{{/supportAsync}}
89+
90+
[features]
91+
default = ["native-tls"]
92+
native-tls = ["reqwest/native-tls"]
93+
rustls-tls = ["reqwest/rustls-tls"]
8994
{{/reqwest}}
9095
{{#reqwestTrait}}
9196
async-trait = "^0.1"
@@ -106,7 +111,7 @@ bon = { version = "2.3", optional = true }
106111
[features]
107112
default = ["native-tls"]
108113
native-tls = ["reqwest/native-tls"]
109-
rustls = ["reqwest/rustls-tls"]
114+
rustls-tls = ["reqwest/rustls-tls"]
110115
{{#mockall}}
111116
mockall = ["dep:mockall"]
112117
{{/mockall}}

0 commit comments

Comments
 (0)