fix(mem_wal): prevent cross-generation durability acknowledgements #18427
Workflow file for this run
This file contains hidden or 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
| name: Build and Run Java JNI Tests | |
| on: | |
| push: | |
| branches: | |
| - main | |
| - release/** | |
| pull_request: | |
| branches: | |
| - main | |
| - release/** | |
| paths: | |
| - java/** | |
| - rust/** | |
| - .github/workflows/java.yml | |
| env: | |
| # This env var is used by Swatinem/rust-cache@v2 for the cache | |
| # key, so we set it to make sure it is always consistent. | |
| CARGO_TERM_COLOR: always | |
| RUST_BACKTRACE: "1" | |
| permissions: | |
| contents: read | |
| jobs: | |
| rust-clippy-fmt: | |
| runs-on: ubuntu-24.04 | |
| name: Rust Clippy and Fmt Check | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4 | |
| - uses: Swatinem/rust-cache@779680da715d629ac1d338a641029a2f4372abb5 # v2 | |
| with: | |
| workspaces: | | |
| lance | |
| java/lance-jni -> ../target/rust-maven-plugin/lance-jni | |
| - name: Install dependencies | |
| run: | | |
| sudo apt update | |
| sudo apt install -y protobuf-compiler libssl-dev | |
| - uses: rui314/setup-mold@725a8794d15fc7563f59595bd9556495c0564878 # v1 | |
| - name: Install cargo-llvm-cov | |
| uses: taiki-e/install-action@66068bfca13dcb2ea07c3f613ca2836a37c755d5 # cargo-llvm-cov | |
| - name: Run cargo fmt | |
| working-directory: java/lance-jni | |
| run: cargo fmt --check | |
| - name: Rust Clippy | |
| working-directory: java/lance-jni | |
| run: cargo clippy --all-targets --locked -- -D warnings | |
| build-and-test-java: | |
| runs-on: ubuntu-24.04-4x | |
| timeout-minutes: 60 | |
| strategy: | |
| matrix: | |
| java-version: [11, 17, 21, 25] | |
| name: Build and Test with Java ${{ matrix.java-version }} | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@34e114876b0b11c390a56381ad16ebd13914f8d5 # v4 | |
| - name: Install dependencies | |
| run: | | |
| sudo apt update | |
| sudo apt install -y protobuf-compiler libssl-dev | |
| # pin the toolchain version to avoid surprises | |
| - uses: actions-rust-lang/setup-rust-toolchain@a0b538fa0b742a6aa35d6e2c169b4bd06d225a98 # v1 | |
| with: | |
| toolchain: stable | |
| - uses: rui314/setup-mold@725a8794d15fc7563f59595bd9556495c0564878 # v1 | |
| - name: Install cargo-llvm-cov | |
| uses: taiki-e/install-action@66068bfca13dcb2ea07c3f613ca2836a37c755d5 # cargo-llvm-cov | |
| - uses: Swatinem/rust-cache@779680da715d629ac1d338a641029a2f4372abb5 # v2 | |
| with: | |
| workspaces: java/lance-jni -> ../target/rust-maven-plugin/lance-jni | |
| - name: Set up Java ${{ matrix.java-version }} | |
| uses: actions/setup-java@c1e323688fd81a25caa38c78aa6df2d33d3e20d9 # v4 | |
| with: | |
| distribution: temurin | |
| java-version: ${{ matrix.java-version }} | |
| cache: "maven" | |
| # Skip the format gate on Java 25: google-java-format 1.22.0 (pinned via | |
| # spotless) reaches into com.sun.tools.javac internals and throws | |
| # NoSuchMethodError on JDK 25's javac. No google-java-format release runs | |
| # on JDK 25 without also dropping JDK 11/17 support, so we exclude 25 from | |
| # the (JDK-independent, already-enforced-on-11/17/21) style check instead. | |
| - name: Running code style check with Java ${{ matrix.java-version }} | |
| if: matrix.java-version != '25' | |
| working-directory: java | |
| run: | | |
| mvn spotless:check | |
| - name: Start localstack | |
| run: | | |
| docker compose -f docker-compose.yml up -d --wait | |
| - name: Running tests with Java ${{ matrix.java-version }} | |
| working-directory: java | |
| env: | |
| LANCE_INTEGRATION_TEST: "1" | |
| run: | | |
| # spotless is also bound into the build lifecycle, so on Java 25 the | |
| # format gate must be skipped here too (-Dspotless.skip=true), not just | |
| # in the standalone step above. | |
| mvn install ${{ matrix.java-version == '25' && '-Dspotless.skip=true' || '' }} |