102 个版本
0.19.8 | 2024 年 7 月 22 日 |
---|---|
0.19.7 | 2023 年 8 月 25 日 |
0.19.5 | 2023 年 3 月 27 日 |
0.19.4 | 2022 年 8 月 21 日 |
0.1.2 | 2014 年 11 月 28 日 |
#77 在 数据库接口 中
每月 125,106 次下载
用于 298 个 crates (235 直接)
385KB
8K SLoC
Rust-Postgres
为 Rust 提供的 PostgreSQL 支持。
postgres 
本机、同步的 PostgreSQL 客户端。
tokio-postgres 
本机、异步的 PostgreSQL 客户端。
postgres-types 
Rust 和 Postgres 类型之间的转换。
postgres-native-tls 
通过 native-tls 为 postgres 和 tokio-postgres 提供TLS支持。
postgres-openssl 
通过 openssl 为 postgres 和 tokio-postgres 提供TLS支持。
运行测试套件
测试套件需要以正确的配置运行 postgres。最简单的方法是使用 docker。
- 安装
docker
和docker-compose
。- 在 ubuntu 上:
sudo apt install docker.io docker-compose
。
- 在 ubuntu 上:
- 确保您的用户具有 docker 的权限。
- 在 ubuntu 上:
sudo usermod -aG docker $USER
- 在 ubuntu 上:
- 切换到
rust-postgres
仓库的顶级目录。 - 运行
docker-compose up -d
。 - 运行
cargo test
。 - 运行
docker-compose stop
。
依赖
~6–17MB
~241K SLoC