#ldap #pool #async #ldap3 #deadpool

deadpool-ldap

LDAP support for the deadpool connection pool

5 releases

0.1.4 Sep 3, 2021
0.1.3 Nov 13, 2020
0.1.2 Nov 13, 2020
0.1.1 Nov 13, 2020
0.1.0 Nov 13, 2020

#4 in #ldap

MIT/Apache

7KB

Deadpool for LDAP

Deadpool is a dead simple async pool for connections and objects of any type.

This crate implements a deadpool manager for ldap3

Features

Feature Description Default
tls-native Enable support for TLS connections using tokio-native-tls no
tls-rustls Enable support for TLS connections using tokio-rustls no

Basic usage

use deadpool_ldap::{Manager, Pool};

#[tokio::main]
async fn main() {
    let manager = Manager("ldap://example.org");
    let pool = Pool::new(manager, 5);
        
    let mut client = pool.get().await.unwrap();
    result = client.simple_bind("uid=user,dc=example,dc=org", "password").await;
    assert!(result.is_ok());
}

License

Licensed under either of

Choose at your option!

Dependencies

~6–10MB
~215K SLoC