Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
46 changes: 46 additions & 0 deletions .github/workflows/build-test-codecov.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
name: Java CI with Maven and CodeCov

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3

- name: Set up JDK 11
uses: actions/setup-java@v3
with:
java-version: '11'
distribution: 'temurin'
cache: maven

- name: Build with Maven and run tests
run: mvn -B clean test

- name: Generate Site with Reports
run: mvn -B site:site -DskipTests -N

- name: Run JaCoCo Report Aggregate
run: mvn -B jacoco:report-aggregate -DskipTests

- name: Debug - Check JaCoCo Report Location
run: |
echo "Checking for JaCoCo reports..."
find ./target -name "*.xml" | grep jacoco || echo "No JaCoCo XML reports found"

- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
continue-on-error: true
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
with:
fail_ci_if_error: false
directory: ./target/site/jacoco-aggregate/
flags: unittests
verbose: true
32 changes: 32 additions & 0 deletions .github/workflows/java11-build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: Java 11 Build

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
workflow_dispatch:

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- name: Set up JDK 11
uses: actions/setup-java@v3
with:
java-version: '11'
distribution: 'temurin'
cache: maven

- name: Build with Maven
run: mvn -B clean test

- name: Upload Test Results
if: always()
uses: actions/upload-artifact@v4
with:
name: test-results
path: target/surefire-reports
32 changes: 32 additions & 0 deletions .github/workflows/java17-build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: Java 17 Build

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
workflow_dispatch:

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- name: Set up JDK 17
uses: actions/setup-java@v3
with:
java-version: '17'
distribution: 'temurin'
cache: maven

- name: Build with Maven
run: mvn -B clean test

- name: Upload Test Results
if: always()
uses: actions/upload-artifact@v4
with:
name: test-results
path: target/surefire-reports
32 changes: 32 additions & 0 deletions .github/workflows/java21-build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: Java 21 Build

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
workflow_dispatch:

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- name: Set up JDK 21
uses: actions/setup-java@v3
with:
java-version: '21'
distribution: 'temurin'
cache: maven

- name: Build with Maven
run: mvn -B clean test

- name: Upload Test Results
if: always()
uses: actions/upload-artifact@v4
with:
name: test-results
path: target/surefire-reports
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
* This class is not intended to be instantiated directly. Instead, use one of the subclasses that are provided
* by the library.
* <p>
* Example: {@link com.salesforce.multicloudj.blob.ali.AliBlobClient}
*
* @param <T>
*/
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,8 @@
* Interface representing a provider in the SDK.
* This provider interface should be implemented by every single
* abstract class for the service which gets extended by
* provider implementations. See this abstract class for Sts implementing this
* provider as example
* {@link com.salesforce.multicloudj.sts.driver.AbstractSts}.
* provider implementations. See the Abstract class for each service
* as examples of implementing this provider interface.
*/
public interface Provider {

Expand Down
53 changes: 51 additions & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,9 @@
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<version>3.6.3</version>
<configuration>
<skip>true</skip>
</configuration>
<executions>
<execution>
<id>aggregate-javadoc</id>
Expand All @@ -126,9 +129,10 @@
<goal>aggregate</goal>
</goals>
<configuration>
<skip>false</skip>
<source>${compileSource}</source>
<reportOutputDirectory>${project.basedir}/api/java</reportOutputDirectory>
<outputDirectory>${project.basedir}/api/java</outputDirectory>
<reportOutputDirectory>${project.build.directory}/site</reportOutputDirectory>
<destDir>apidocs</destDir>
</configuration>
</execution>
</executions>
Expand All @@ -137,6 +141,10 @@
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-site-plugin</artifactId>
<version>3.21.0</version>
<configuration>
<skipDeploy>true</skipDeploy>
</configuration>
<inherited>false</inherited>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
Expand Down Expand Up @@ -166,6 +174,37 @@
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-failsafe-plugin</artifactId>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
</plugin>
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<version>0.8.7</version>
<executions>
<execution>
<id>prepare-agent</id>
<goals>
<goal>prepare-agent</goal>
</goals>
</execution>
<execution>
<id>report</id>
<phase>test</phase>
<goals>
<goal>report</goal>
</goals>
</execution>
<execution>
<id>report-aggregate</id>
<phase>test</phase>
<goals>
<goal>report-aggregate</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>

Expand Down Expand Up @@ -253,6 +292,16 @@
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-project-info-reports-plugin</artifactId>
<version>3.4.2</version> <!-- Use a stable version -->
<inherited>false</inherited>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-report-plugin</artifactId>
<version>3.4.0</version>
<configuration>
<aggregate>true</aggregate>
</configuration>
<inherited>false</inherited>
</plugin>
</plugins>
</reporting>
Expand Down
Loading