feat: ML Vector Improvements - Embedding Cache & Performance Optimization #6
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: CI/CD Pipeline | |
| on: | |
| push: | |
| branches: [ main, develop ] | |
| pull_request: | |
| branches: [ main ] | |
| jobs: | |
| test-backend: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up JDK 17 | |
| uses: actions/setup-java@v4 | |
| with: | |
| java-version: '17' | |
| distribution: 'temurin' | |
| - name: Cache Maven dependencies | |
| uses: actions/cache@v3 | |
| with: | |
| path: ~/.m2 | |
| key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }} | |
| restore-keys: ${{ runner.os }}-m2 | |
| - name: Run backend tests | |
| run: | | |
| cd backend | |
| mvn clean test | |
| - name: Generate test report | |
| uses: dorny/test-reporter@v1 | |
| if: success() || failure() | |
| with: | |
| name: Backend Tests | |
| path: backend/target/surefire-reports/*.xml | |
| reporter: java-junit | |
| test-frontend: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '18' | |
| cache: 'npm' | |
| cache-dependency-path: app/package-lock.json | |
| - name: Install dependencies | |
| run: | | |
| cd app | |
| npm ci | |
| - name: Run frontend tests | |
| run: | | |
| cd app | |
| npm run test -- --watchAll=false | |
| - name: Run linting | |
| run: | | |
| cd app | |
| npm run lint | |
| build-backend: | |
| needs: test-backend | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up JDK 17 | |
| uses: actions/setup-java@v4 | |
| with: | |
| java-version: '17' | |
| distribution: 'temurin' | |
| - name: Build backend | |
| run: | | |
| cd backend | |
| mvn clean package -DskipTests | |
| - name: Upload backend artifact | |
| uses: actions/upload-artifact@v3 | |
| with: | |
| name: backend-jar | |
| path: backend/target/*.jar | |
| build-frontend: | |
| needs: test-frontend | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '18' | |
| cache: 'npm' | |
| cache-dependency-path: app/package-lock.json | |
| - name: Install dependencies | |
| run: | | |
| cd app | |
| npm ci | |
| - name: Build frontend | |
| run: | | |
| cd app | |
| npm run build | |
| - name: Upload frontend artifact | |
| uses: actions/upload-artifact@v3 | |
| with: | |
| name: frontend-build | |
| path: app/dist/ |