[opt](common)Do not use deprecated method. #2676
  
    
      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: supersonic mac CI | |
| on: | |
| push: | |
| branches: | |
| - master | |
| pull_request: | |
| branches: | |
| - master | |
| jobs: | |
| build: | |
| runs-on: macos-latest # Specify a macOS runner | |
| strategy: | |
| matrix: | |
| java-version: [21] # Define the JDK versions to test | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up JDK ${{ matrix.java-version }} | |
| uses: actions/setup-java@v3 | |
| with: | |
| java-version: ${{ matrix.java-version }} | |
| distribution: 'temurin' | |
| - name: Cache Maven packages | |
| uses: actions/cache@v3 | |
| with: | |
| path: ~/Library/Caches/Maven # macOS Maven cache path | |
| key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }} | |
| restore-keys: ${{ runner.os }}-m2 | |
| - name: Install system dependencies | |
| run: | | |
| brew update | |
| brew install cmake | |
| brew install gcc | |
| - name: Build with Maven | |
| run: mvn -B package --file pom.xml | |
| - name: Test with Maven | |
| run: mvn test |