-
Notifications
You must be signed in to change notification settings - Fork 8
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add rust extension lib alluxiocommon to the repo (#39)
* Port changes from https://github.com/lucyge2022/alluxiofs/tree/multithread 5f80059 small fixes for REST and metrics 1c426c2 add access debug logs for all fsspec ops & add quick sanity unit tests for read 7dcb833 checkin multi process http benchmark for worker http server 4b4ebce use alluxiocommon pyo3 package to try to do multithread http req 523f748 add rust pyo3 extension 8979d2b remove first 0367659 add related files 4d0eebe small fixes a0519b3 if any error on any thread running result, raise exception back to python directly * missing changes from port * fix the bug of inpage_read_len calculation * make ondemand pool default and enable it by flag during instantiation * cleanup fixes * WIP add fixture to test with alluxio client with alluxiocommon lib enabled * for read pages if we got any data just return without throwing any following exception * add _all_page_generator with alluxiocommon * 1. add pytest fixture for alluxiocommon enabled to use in test_docker_alluxio_fsspec.py 2. make tests/client/test_read_range_docker.py (now named as test_read_docker.py to handle full read as well add alluxiocommon fixture in it too * remove unnecessary files * try adding a ci yaml file with alluxiocommon enabled as dependency * cleanup fixes * add to ci.yml of alluxiocommon dependency * add rust/alluxiocommon/tests/ * fixes * remove changes in ci.yml as it wont run * try add alluxiocommon pyo3 build * fix pyo3 related * pre-commit style changes + manually install openssl * chanegs * try to use rustls instead of rust-native-tls as reqwest dependency as rust-native-tls requires dynamic link of tls in runtime env * enable run alluxiocommon tests job in ci.yml * reorder to have alluxiocommon install after alluxiocommon wheel building * try fix pip install alluxiocommon from dist/ * add --no-index * add ls dist/ to debug * add pyo3 with python version when buildoing * merge pytest for alluxiocommon and alluxiofs together * syntax fix * syntax fix * try reorder * name change * modify rust/alluxiocommon/README.md and cleanup ci.yml * remove comments for debugging purpose before
- Loading branch information
1 parent
8c6dc03
commit 08429c4
Showing
16 changed files
with
2,050 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
## A PyO3 based common native extension lib for alluxio python client | ||
|
||
### Developer Prerequisites: | ||
- Install Rust: | ||
https://www.rust-lang.org/tools/install | ||
- Install maturin: | ||
https://www.maturin.rs/installation | ||
|
||
|
||
### To build developer version locally and play: | ||
|
||
1) create virtualenv, (a tool used to create isolated Python environments): | ||
|
||
|
||
python3 -m venv .env | ||
source .env/bin/activate | ||
maturin develop | ||
|
||
2) then can start using: | ||
|
||
|
||
python3 | ||
>>> from alluxiocommon import _DataManager | ||
>>> dm = _DataManager(4) | ||
>>> # do something with dm... | ||
### To build wheel package and install with pip: | ||
|
||
#in rust/alluxiocommon dir: | ||
$ maturin build --out <alluxiofs_home>/dist -m <alluxiofs_home>/rust/alluxiocommon/Cargo.toml -i python<x.y> (python version such as 3.8) | ||
#then find .whl package in <alluxiofs_home>/dist: | ||
[root@ip-XXX-XX-XX-XX alluxiofs]# ls -l dist/ | ||
total 21848 | ||
-rw-r--r--. 1 root root 22318133 Apr 28 05:31 alluxiocommon-0.1.0-cp38-cp38-linux_x86_64.whl | ||
#install with pip | ||
$ pip install dist/alluxiocommon-0.1.0-cp38-cp38-linux_x86_64.whl --force-reinstall |
Oops, something went wrong.