fix: release JDBC sessions before terminal responses #4
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: CI | |
| on: | |
| pull_request: | |
| push: | |
| branches: | |
| - main | |
| permissions: | |
| contents: read | |
| jobs: | |
| rust: | |
| name: Rust | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4.2.2 | |
| - uses: dtolnay/rust-toolchain@4cda84d5c5c54efe2404f9d843567869ab1699d4 | |
| with: | |
| toolchain: stable | |
| components: clippy,rustfmt | |
| - uses: Swatinem/rust-cache@e18b497796c12c097a38f9edb9d0641fb99eee32 # v2.8.1 | |
| - name: Format | |
| run: cargo fmt --all --check | |
| - name: Clippy | |
| run: cargo clippy --workspace --all-targets --all-features --locked -- -D warnings | |
| - name: Test | |
| run: cargo test --workspace --locked | |
| - name: Process supervisor tests | |
| run: cargo test -p chat2db-java-bridge --features test-fixture --test supervisor --locked | |
| rust-msrv: | |
| name: Rust 1.88 | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4.2.2 | |
| - uses: dtolnay/rust-toolchain@4cda84d5c5c54efe2404f9d843567869ab1699d4 | |
| with: | |
| toolchain: 1.88.0 | |
| - uses: Swatinem/rust-cache@e18b497796c12c097a38f9edb9d0641fb99eee32 # v2.8.1 | |
| with: | |
| shared-key: msrv | |
| - name: Check minimum supported Rust version | |
| run: cargo check --workspace --all-targets --all-features --locked | |
| java: | |
| name: Java | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4.2.2 | |
| - uses: actions/setup-java@c1e323688fd81a25caa38c78aa6df2d33d3e20d9 # v4.7.1 | |
| with: | |
| distribution: temurin | |
| java-version: "17" | |
| cache: maven | |
| cache-dependency-path: | | |
| java/pom.xml | |
| java/compat-runtime/pom.xml | |
| - name: Verify tests and driver isolation | |
| working-directory: java | |
| run: ./mvnw -B clean verify | |
| ipc-integration: | |
| name: Rust-Java IPC | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4.2.2 | |
| - uses: dtolnay/rust-toolchain@4cda84d5c5c54efe2404f9d843567869ab1699d4 | |
| with: | |
| toolchain: stable | |
| - uses: Swatinem/rust-cache@e18b497796c12c097a38f9edb9d0641fb99eee32 # v2.8.1 | |
| - uses: actions/setup-java@c1e323688fd81a25caa38c78aa6df2d33d3e20d9 # v4.7.1 | |
| with: | |
| distribution: temurin | |
| java-version: "17" | |
| cache: maven | |
| cache-dependency-path: | | |
| java/pom.xml | |
| java/compat-runtime/pom.xml | |
| - name: Package Java engine | |
| working-directory: java | |
| run: ./mvnw -B -DskipTests package | |
| - name: Verify Rust-Java process protocol | |
| env: | |
| CHAT2DB_JAVA_ENGINE_JAR: "${{ github.workspace }}/java/compat-runtime/target/chat2db-compat-runtime-0.1.0-SNAPSHOT.jar" | |
| CHAT2DB_H2_DRIVER_JAR: "${{ github.workspace }}/java/compat-runtime/target/test-drivers/h2-2.3.232.jar" | |
| run: cargo test -p chat2db-java-bridge --features java-integration --test java_engine --locked | |
| - name: Verify H2 JDBC vertical slice | |
| env: | |
| CHAT2DB_JAVA_ENGINE_JAR: "${{ github.workspace }}/java/compat-runtime/target/chat2db-compat-runtime-0.1.0-SNAPSHOT.jar" | |
| CHAT2DB_H2_DRIVER_JAR: "${{ github.workspace }}/java/compat-runtime/target/test-drivers/h2-2.3.232.jar" | |
| run: cargo test -p chat2db-java-bridge --features java-integration --test java_jdbc_h2 --locked | |
| frontend: | |
| name: Frontend | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4.2.2 | |
| - uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020 # v4.4.0 | |
| with: | |
| node-version: "22.22.2" | |
| cache: npm | |
| cache-dependency-path: apps/frontend/package-lock.json | |
| - name: Install | |
| working-directory: apps/frontend | |
| run: npm ci | |
| - name: Build | |
| working-directory: apps/frontend | |
| run: npm run build |