Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.
mysql_async for WebAssembly
Tokio based asynchronous MySql client library for The Rust Programming Language. This is a fork from the original mysql_async with support for WebAssembly compilation target. That allows async MySql apps to run inside the WasmEdge Runtime as a lightweight and secure alternative to natively compiled apps in Linux container.
For more details and usage examples, please see the upstream mysql_async source and this example.
Note: We do not yet support SSL / TLS connections to databases in this WebAssembly client.
Installation
[]
= "<desired version>"
Crate Features
Default feature set is wide – it includes all default mysql_common
features
as well as native-tls
-based TLS support.
List Of Features
-
minimal
– enables only necessary features (at the moment the only necessary feature isflate2
backend). Enables:- `flate2/zlib"
Example:
[] = { = "*", = false, = ["minimal"]}
*Note: it is possible to use another
flate2
backend by directly choosing it:[] = { = "*", = false } = { = "*", = false, = ["rust_backend"] }
-
default
– enables the following set of crate's and dependencies' features:native-tls-tls
- `flate2/zlib"
mysql_common/bigdecimal03
mysql_common/rust_decimal
mysql_common/time03
mysql_common/uuid
mysql_common/frunk
-
default-rustls
– same as default but withrustls-tls
instead ofnative-tls-tls
.Example:
[] = { = "*", = false, = ["default-rustls"] }
-
native-tls-tls
– enablesnative-tls
-based TLS support (conflicts withrustls-tls
)Example:
[] = { = "*", = false, = ["native-tls-tls"] }
-
rustls-tls
– enablesnative-tls
-based TLS support (conflicts withnative-tls-tls
)Example:
[] = { = "*", = false, = ["rustls-tls"] }
TLS/SSL Support
SSL support comes in two flavors:
-
Based on native-tls – this is the default option, that usually works without pitfalls (see the
native-tls-tls
crate feature). -
Based on rustls – TLS backend written in Rust (see the
rustls-tls
crate feature).Please also note a few things about rustls:
- it will fail if you'll try to connect to the server by its IP address, hostname is required;
- it, most likely, won't work on windows, at least with default server certs, generated by the MySql installer.
Example
use *;
async
License
Licensed under either of
- Apache License, Version 2.0, (LICENSE-APACHE or https://www.apache.org/licenses/LICENSE-2.0)
- MIT license (LICENSE-MIT or https://opensource.org/licenses/MIT)
at your option.
Contribution
Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in the work by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.