Skip to content

Commit

Permalink
ci: Improve rocksdb build speed by link dynamic libs (#1502)
Browse files Browse the repository at this point in the history
* ci: Improve rocksdb build speed by link dynamic libs

Signed-off-by: Xuanwo <[email protected]>

* Fix typo

Signed-off-by: Xuanwo <[email protected]>

* Not for test

Signed-off-by: Xuanwo <[email protected]>

* Add note for rocksdb

Signed-off-by: Xuanwo <[email protected]>

* Allow using system lib

Signed-off-by: Xuanwo <[email protected]>

* cover docs

Signed-off-by: Xuanwo <[email protected]>

* lower version

Signed-off-by: Xuanwo <[email protected]>

---------

Signed-off-by: Xuanwo <[email protected]>
  • Loading branch information
Xuanwo authored Mar 8, 2023
1 parent 3e70d58 commit 289006c
Show file tree
Hide file tree
Showing 7 changed files with 188 additions and 94 deletions.
11 changes: 11 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,15 +51,22 @@ jobs:
with:
hdfs-version: "3.3.2"

- name: Install rocksdb
run: sudo apt install librocksdb-dev

- uses: Swatinem/rust-cache@v2

- name: Check license headers
uses: korandoru/hawkeye@v1
- name: Cargo format
run: cargo fmt --all -- --check
- name: Cargo clippy
env:
ROCKSDB_LIB_DIR: /usr/lib
run: cargo clippy --all-targets --all-features --workspace -- -D warnings
- name: Cargo doc
env:
ROCKSDB_LIB_DIR: /usr/lib
run: cargo doc --lib --no-deps --all-features

msrv_check:
Expand Down Expand Up @@ -126,9 +133,13 @@ jobs:
uses: beyondstorage/setup-hdfs@master
with:
hdfs-version: "3.3.2"
- name: Install rocksdb
run: sudo apt install librocksdb-dev

- uses: Swatinem/rust-cache@v2
- name: Build
env:
ROCKSDB_LIB_DIR: /usr/lib
run: cargo build --all-features

unit:
Expand Down
6 changes: 6 additions & 0 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,18 @@ jobs:
distribution: temurin
java-version: '11'

- name: Install rocksdb
run: sudo apt install librocksdb-dev

- uses: Swatinem/rust-cache@v2

- uses: actions-rs/cargo@v1
with:
command: doc
args: --lib --no-deps --all-features -p opendal
env:
LD_LIBRARY_PATH: ${{ env.JAVA_HOME }}/lib/server:${{ env.LD_LIBRARY_PATH }}
ROCKSDB_LIB_DIR: /usr/lib

- name: Copy vercel.json
run: cp ./vercel.json ./target/doc
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/service_test_rocksdb.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,14 @@ jobs:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Install rocksdb
run: sudo apt install librocksdb-dev
- uses: Swatinem/rust-cache@v2
- name: Test
shell: bash
run: cargo test rocksdb --features services-rocksdb -- --show-output --test-threads=1
env:
ROCKSDB_LIB_DIR: /usr/lib
RUST_BACKTRACE: full
RUST_LOG: debug
OPENDAL_ROCKSDB_TEST: on
Expand Down
Loading

1 comment on commit 289006c

@github-actions
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Deploy preview for opendal ready!

✅ Preview
https://opendal-cjf93zz90-databend.vercel.app

Built with commit 289006c.
This pull request is being automatically deployed with vercel-action

Please sign in to comment.