hdfs-client 0.2.0

hdfs rust native client
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
use std::io::Write;

use hdfs_client::HDFS;

fn main() {
    tracing_subscriber::fmt()
        .with_max_level(tracing::Level::INFO)
        .pretty()
        .init();
    let mut fs = HDFS::connect("localhost:9000", "root".to_string()).unwrap();

    let mut fd = fs.append("/test/hello.txt").unwrap();
    fd.write_all(b"hello").unwrap();
}