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

Added TLS backend selection features & Default, removed get_/Get prefixes #25

Merged
merged 15 commits into from
Apr 19, 2024
Merged

Conversation

virtualritz
Copy link
Contributor

@virtualritz virtualritz commented Feb 14, 2024

The main reason is that request's default TLS dependency pulls in openssl which wraps the OpenSSL C-lib via openssl-sys.
This not only adds a noticable hiccup to build times, it also requires a resp. C compiler toolchain which can be a PITA when cross-compilation for other platform targets is needed (e.g. Android or iOS).

reqwest offers a bunch of alternative TLS backends, exposed by feature flags.

With this PR they're all also available in the infobip_sdk crate.

This PR also puts some code behind #[cfg(feature=...)] gates to get rid of some warnings and further decrease build time.

@virtualritz
Copy link
Contributor Author

That spellcheck will never succeed btw. for obvious reasons.

* Simplified `new()` where possible.
* Renamed `enum` variants to `PascalCase` (Rust naming guidelines).
* Removed `get_` prefix from all getters/everywhere (Rust naming guidelines).
* Simplified some places.
@virtualritz
Copy link
Contributor Author

virtualritz commented Mar 15, 2024

This now also fixes #13 and #16. There are some minor changes for developer UX too. I.e. releasing this requires at least a bump to v0.6.

@virtualritz virtualritz changed the title Added TLS backend selection features Added TLS backend selection features & Default, removed get_ prefixes Mar 15, 2024
@virtualritz virtualritz changed the title Added TLS backend selection features & Default, removed get_ prefixes Added TLS backend selection features & Default, removed get_/Get prefixes Apr 16, 2024
Cargo.toml Show resolved Hide resolved
@ukmadlz ukmadlz merged commit d07807c into infobip-community:main Apr 19, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants