Skip to content
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

[rust]: allow specifying TLS flavour to use #892

Merged
merged 1 commit into from
Apr 18, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion rust/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -25,5 +25,8 @@ serde = "^1.0"
serde_derive = "^1.0"
serde_json = "^1.0"
url = "^2.2"
reqwest = { version = "^0.11", features = ["json", "multipart", "default-tls"], default-features = false }
reqwest = { version = "^0.11", features = ["json", "multipart"], default-features = false }

[features]
default = ["reqwest/default-tls"]
rustls-tls = ["reqwest/rustls-tls"]
12 changes: 12 additions & 0 deletions rust/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,3 +44,15 @@ You can find general usage documentation at <https://docs.svix.com>. For comple

## Usage
Please refer to [the documentation](https://docs.svix.com/) or [the API reference](https://api.svix.com/docs) for more usage instructions.

# Optional Cargo Features

## TLS

By default reqwest uses rust-native-tls, which will use the operating system TLS framework if available, meaning Windows and macOS. On Linux, it will use OpenSSL 1.1.

[rustls-tls](https://github.com/rustls/rustls) can also be choosen, eg.:
```
svix = { version = "N", features = ["rustls-tls"], default-features = false }
```