|
34 | 34 | distribution: 'temurin' |
35 | 35 | cache: 'maven' |
36 | 36 |
|
37 | | - - name: Build all modules (skip tests) |
| 37 | + - name: Build all modules with unit tests |
38 | 38 | run: | |
39 | | - ./mvnw -T 1C -DskipTests --batch-mode --update-snapshots clean install |
40 | | -
|
41 | | - - name: Generate Java docs |
42 | | - if: github.ref == 'refs/heads/main' |
43 | | - run: ./mvnw --batch-mode javadoc:aggregate |
44 | | - |
45 | | - - name: Generate assembly |
46 | | - if: github.ref == 'refs/heads/main' |
47 | | - working-directory: spring-ai-docs |
48 | | - run: ../mvnw --batch-mode assembly:single |
| 39 | + ./mvnw -T 1C --batch-mode --update-snapshots clean install |
49 | 40 |
|
50 | 41 | - name: Upload Maven repository |
51 | 42 | uses: actions/upload-artifact@v4 |
|
54 | 45 | path: ~/.m2/repository |
55 | 46 | retention-days: 1 |
56 | 47 |
|
57 | | - - name: Upload Javadoc |
58 | | - if: github.ref == 'refs/heads/main' |
59 | | - uses: actions/upload-artifact@v4 |
60 | | - with: |
61 | | - name: javadoc |
62 | | - path: target/site/apidocs |
63 | | - retention-days: 1 |
64 | | - |
65 | | - - name: Upload assembly |
66 | | - if: github.ref == 'refs/heads/main' |
67 | | - uses: actions/upload-artifact@v4 |
68 | | - with: |
69 | | - name: assembly |
70 | | - path: spring-ai-docs/target/*.zip |
71 | | - retention-days: 1 |
72 | | - |
73 | 48 | test-ollama: |
74 | 49 | name: Test Ollama |
75 | 50 | runs-on: ubuntu-latest |
|
110 | 85 | SPRING_AI_OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }} |
111 | 86 | run: | |
112 | 87 | ./mvnw --batch-mode --no-snapshot-updates \ |
113 | | - -pl auto-configurations/models/spring-ai-autoconfigure-model-ollama \ |
| 88 | + -pl models/spring-ai-ollama,auto-configurations/models/spring-ai-autoconfigure-model-ollama \ |
114 | 89 | -Pci-fast-integration-tests \ |
115 | 90 | -Dfailsafe.rerunFailingTestsCount=3 \ |
116 | 91 | verify |
@@ -184,11 +159,54 @@ jobs: |
184 | 159 | SPRING_AI_OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }} |
185 | 160 | run: | |
186 | 161 | ./mvnw --batch-mode --no-snapshot-updates \ |
187 | | - -pl models/spring-ai-google-genai,auto-configurations/models/spring-ai-autoconfigure-model-google-genai,mcp/common,mcp/mcp-annotations-spring,auto-configurations/mcp/spring-ai-autoconfigure-mcp-client-common,auto-configurations/mcp/spring-ai-autoconfigure-mcp-client-httpclient,auto-configurations/mcp/spring-ai-autoconfigure-mcp-client-webflux,auto-configurations/mcp/spring-ai-autoconfigure-mcp-server-common,auto-configurations/mcp/spring-ai-autoconfigure-mcp-server-webmvc,auto-configurations/mcp/spring-ai-autoconfigure-mcp-server-webflux,vector-stores/spring-ai-chroma-store,vector-stores/spring-ai-pgvector-store \ |
| 162 | + -pl models/spring-ai-google-genai,auto-configurations/models/spring-ai-autoconfigure-model-google-genai,mcp/common,mcp/mcp-annotations-spring,auto-configurations/mcp/spring-ai-autoconfigure-mcp-client-common,auto-configurations/mcp/spring-ai-autoconfigure-mcp-client-httpclient,auto-configurations/mcp/spring-ai-autoconfigure-mcp-client-webflux,auto-configurations/mcp/spring-ai-autoconfigure-mcp-server-common,auto-configurations/mcp/spring-ai-autoconfigure-mcp-server-webmvc,auto-configurations/mcp/spring-ai-autoconfigure-mcp-server-webflux,vector-stores/spring-ai-chroma-store,vector-stores/spring-ai-pgvector-store,spring-ai-integration-tests \ |
188 | 163 | -Pci-fast-integration-tests \ |
189 | 164 | -Dfailsafe.rerunFailingTestsCount=3 \ |
190 | 165 | verify |
191 | 166 |
|
| 167 | + generate-artifacts: |
| 168 | + name: Generate documentation artifacts |
| 169 | + runs-on: ubuntu-latest |
| 170 | + needs: [build-all, test-ollama, test-openai, test-remaining] |
| 171 | + if: ${{ github.ref == 'refs/heads/main' && github.repository_owner == 'spring-projects' }} |
| 172 | + steps: |
| 173 | + - name: Checkout source code |
| 174 | + uses: actions/checkout@v4 |
| 175 | + |
| 176 | + - name: Set up JDK 17 |
| 177 | + uses: actions/setup-java@v4 |
| 178 | + with: |
| 179 | + java-version: '17' |
| 180 | + distribution: 'temurin' |
| 181 | + cache: 'maven' |
| 182 | + |
| 183 | + - name: Download Maven repository |
| 184 | + uses: actions/download-artifact@v4 |
| 185 | + with: |
| 186 | + name: maven-repo |
| 187 | + path: ~/.m2/repository |
| 188 | + |
| 189 | + - name: Generate Java docs |
| 190 | + run: ./mvnw --batch-mode javadoc:aggregate |
| 191 | + |
| 192 | + - name: Generate assembly |
| 193 | + working-directory: spring-ai-docs |
| 194 | + run: ../mvnw --batch-mode assembly:single |
| 195 | + |
| 196 | + - name: Upload Javadoc |
| 197 | + uses: actions/upload-artifact@v4 |
| 198 | + with: |
| 199 | + name: javadoc |
| 200 | + path: target/site/apidocs |
| 201 | + retention-days: 1 |
| 202 | + |
| 203 | + - name: Upload assembly |
| 204 | + uses: actions/upload-artifact@v4 |
| 205 | + with: |
| 206 | + name: assembly |
| 207 | + path: spring-ai-docs/target/*.zip |
| 208 | + retention-days: 1 |
| 209 | + |
192 | 210 | deploy-artifactory: |
193 | 211 | name: Deploy to Artifactory |
194 | 212 | runs-on: ubuntu-latest |
@@ -221,7 +239,7 @@ jobs: |
221 | 239 | deploy-docs: |
222 | 240 | name: Deploy documentation |
223 | 241 | runs-on: ubuntu-latest |
224 | | - needs: [build-all, test-ollama, test-openai, test-remaining] |
| 242 | + needs: [generate-artifacts] |
225 | 243 | if: ${{ github.ref == 'refs/heads/main' && github.repository_owner == 'spring-projects' }} |
226 | 244 | steps: |
227 | 245 | - name: Checkout source code |
|
0 commit comments