Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
67 commits
Select commit Hold shift + click to select a range
efee669
Second Commit
jeffrymsft Jan 23, 2025
ac7fdcf
Revert "Second Commit"
jeffrymsft Jan 23, 2025
dbdcd4b
common first commit
jeffrymsft Jan 23, 2025
964b4ad
common project now able to build with new gradle version change
jeffrymsft Jan 24, 2025
73ce450
commiting to run pipeline in commons
jeffrymsft Feb 3, 2025
0f1b874
changing pipeline jdk version
jeffrymsft Feb 4, 2025
95eb973
updating the pipeline jdk version for the build-consumers.yml file
jeffrymsft Feb 4, 2025
fdb6dbc
REAL change for the spotbugs jdk 11 -> jdk 17 error
jeffrymsft Feb 4, 2025
901d6d9
modifying yml files
jeffrymsft Feb 7, 2025
ce219a3
enforcing pipeline task ordering
jeffrymsft Feb 18, 2025
6e1e01e
updating buildsystem plugin to 0.2.4
jeffrymsft Feb 20, 2025
48fb2c8
fixing typo
jeffrymsft Feb 21, 2025
776d321
allowing distDebug to publish
jeffrymsft Feb 21, 2025
3b786ca
making the default java version 17
jeffrymsft Feb 24, 2025
2988b79
removing common4j java upgrade specification
jeffrymsft Feb 25, 2025
8d82f4c
undoing common java upgrade
jeffrymsft Feb 25, 2025
c6c238f
adding production flavour
jeffrymsft Feb 27, 2025
4bcb223
adding matchingFallbacks
jeffrymsft Feb 28, 2025
5aff8a1
redoing old gradle changes in uiautomation buildgradle
jeffrymsft Mar 1, 2025
a6abeea
java 17 workaround
jeffrymsft Mar 5, 2025
31475b9
undoing previous change
jeffrymsft Mar 17, 2025
a377971
updating testutils
jeffrymsft Mar 26, 2025
f66fe3d
nit
jeffrymsft Mar 28, 2025
e759353
nit
jeffrymsft Mar 28, 2025
9987ac7
nits
jeffrymsft Mar 28, 2025
1f9b8f7
removing comments and production flavor
jeffrymsft Mar 29, 2025
f55b680
nits
jeffrymsft Apr 2, 2025
b0efb08
nits
jeffrymsft Apr 2, 2025
effe0d7
java 17
jeffrymsft Apr 2, 2025
0447544
reverting to java 8
jeffrymsft Apr 3, 2025
0a40f8a
reverting plugin upgrade
jeffrymsft Apr 3, 2025
6fe27be
adding javaVersion param
jeffrymsft Apr 4, 2025
0697486
new plugin version
jeffrymsft Apr 7, 2025
6a0c281
updating common4j pipeline and nits
jeffrymsft Apr 9, 2025
364e0c8
nits
jeffrymsft Apr 9, 2025
0ddb5e6
adding dependsOn on common build.gradle
jeffrymsft Apr 9, 2025
8a3a129
LabApiUtilities -add-opens
jeffrymsft Apr 10, 2025
7829f67
plugin version is now 0.2.5
jeffrymsft Apr 10, 2025
d2f7441
updating labapiutilies and testing the dependency
jeffrymsft Apr 10, 2025
d0c4fdc
java 17 labapiutilies
jeffrymsft Apr 10, 2025
a24ae42
Update lab-utilities.yml for Azure Pipelines
jeffrymsft Apr 11, 2025
0774679
more labapiupdates
jeffrymsft Apr 11, 2025
87716c4
reverting change
jeffrymsft Apr 11, 2025
e796de6
nits and adding information
jeffrymsft Apr 12, 2025
d9b3ab7
more comments
jeffrymsft Apr 12, 2025
efbe11e
renaming back to 0.2.4-1
jeffrymsft Apr 15, 2025
8d3c355
reverting labapi to java 8 and removing compiler args
jeffrymsft Apr 15, 2025
0c56d8d
labapiutilies going to java 11 to use compiler options
jeffrymsft Apr 15, 2025
8ad5f67
everything java 11
jeffrymsft Apr 15, 2025
14fb3b5
common4j java 11 too (missed it earlier)
jeffrymsft Apr 15, 2025
75cee87
testing sowmya edit
jeffrymsft Apr 16, 2025
f9670f7
upgrade msal4j version
jeffrymsft Apr 16, 2025
9f5c5e2
back to 8
jeffrymsft Apr 16, 2025
a142dc1
nits
jeffrymsft Apr 16, 2025
b48cd75
back to 0.2.5
jeffrymsft Apr 16, 2025
20db413
updating change log
jeffrymsft Apr 17, 2025
a84bf13
monthly pipeline utiltiy libraries version increase
jeffrymsft Apr 17, 2025
4ce1296
updating changelog
jeffrymsft Apr 17, 2025
ff2f66b
fixing maven publishing bug
jeffrymsft Apr 18, 2025
3fe84e9
nits
jeffrymsft Apr 18, 2025
19e3f35
changing back the prs dev pointers
jeffrymsft Apr 22, 2025
aa16b8a
Merge branch 'dev' into gradleVersionChange2
somalaya May 14, 2025
63f8e5b
Merge branch 'dev' into gradleVersionChange2
somalaya May 15, 2025
359aba4
Merge branch 'dev' into gradleVersionChange2
somalaya May 20, 2025
371b884
Merge branch 'dev' into gradleVersionChange2
somalaya May 23, 2025
7d743e0
Trigger Build
somalaya May 23, 2025
c73e69f
Merge branch 'dev' into gradleVersionChange2
somalaya May 27, 2025
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
2 changes: 1 addition & 1 deletion LabApiUtilities/build.gradle
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
plugins {
id 'java-library'
id 'maven-publish'
id 'com.microsoft.identity.buildsystem' version '0.2.3'
id 'com.microsoft.identity.buildsystem' version '0.2.5'

// the below build plugin allows to generate BuildConfig files in a JAVA gradle project.
// BuildConfig files are generated by default in an Android project, however, a non-Android java
Expand Down
13 changes: 7 additions & 6 deletions azure-pipelines/pull-request-validation/build-consumers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -125,15 +125,15 @@ stages:
displayName: Assemble msal
inputs:
jdkArchitecture: x64
jdkVersionOption: "1.11"
jdkVersionOption: "1.17"
tasks: clean msal:assembleLocal
- template: ../templates/steps/automation-cert.yml
- task: Gradle@3
displayName: Run msal Unit tests
inputs:
tasks: msal:testLocalDebugUnitTest -Plabtest -PlabSecret=$(LabVaultAppCert) -ProbolectricSdkVersion=${{variables.robolectricSdkVersion}} -PmockApiUrl=$(MOCK_API_URL)
jdkArchitecture: x64
jdkVersionOption: "1.11"
jdkVersionOption: "1.17"
# broker
- job: brokerValidation
displayName: Broker
Expand Down Expand Up @@ -171,13 +171,13 @@ stages:
tasks: AADAuthenticator:clean AADAuthenticator:assembleLocal --build-cache --info
publishJUnitResults: false
jdkArchitecture: x64
jdkVersionOption: "1.11"
jdkVersionOption: "1.17"
- task: Gradle@3
displayName: Run broker Unit tests
inputs:
tasks: AADAuthenticator:localDebugAADAuthenticatorUnitTestCoverageReport --build-cache --info -Plabtest -PlabSecret=$(LabVaultAppCert) -ProbolectricSdkVersion=${{variables.robolectricSdkVersion}} -PpowerLiftApiKey=$(powerliftApiKey) -PcodeCoverageEnabled=true ${{variables.shouldSkipLongRunningTest}}
jdkArchitecture: x64
jdkVersionOption: "1.11"
jdkVersionOption: "1.17"
# Linux broker
- job: linuxBrokerValidation
displayName: Linux Broker
Expand Down Expand Up @@ -226,6 +226,7 @@ stages:
tasks: LinuxBroker:clean LinuxBroker:assemble --build-cache --info
publishJUnitResults: false
jdkArchitecture: x86
jdkVersionOption: "1.17"
- task: Bash@3
displayName: Execute tests
inputs:
Expand Down Expand Up @@ -277,10 +278,10 @@ stages:
inputs:
tasks: clean adal:assembleLocal
jdkArchitecture: x64
jdkVersionOption: "1.11"
jdkVersionOption: "1.17"
- task: Gradle@3
displayName: Run adal Unit tests
inputs:
tasks: adal:testLocalDebugUnitTest -Plabtest -ProbolectricSdkVersion=${{variables.robolectricSdkVersion}} -PlabSecret=$(LabVaultAppCert)
jdkArchitecture: x64
jdkVersionOption: "1.11"
jdkVersionOption: "1.17"
9 changes: 5 additions & 4 deletions azure-pipelines/pull-request-validation/common.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ jobs:
displayName: Assemble Local
inputs:
javaHomeSelection: JDKVersion
jdkVersionOption: "1.11"
jdkVersionOption: "1.17"
tasks: clean common:assembleLocal
publishJUnitResults: false
jdkArchitecture: x64
Expand All @@ -48,14 +48,14 @@ jobs:
displayName: Run Unit tests
inputs:
javaHomeSelection: JDKVersion
jdkVersionOption: "1.11"
jdkVersionOption: "1.17"
tasks: common:testLocalDebugUnitTest -PlabSecret=$(LabVaultAppCert) -PmockApiUrl=$(MOCK_API_URL)
- task: Gradle@3
displayName: Check Dependencies size
condition: eq(variables['system.pullRequest.targetBranch'], 'dev')
inputs:
tasks: common:dependenciesSizeCheck -PdependenciesSizeCheckConfig=distReleaseRuntimeClasspath
jdkVersionOption: "1.11"
jdkVersionOption: "1.17"

- job: spotbugs
displayName: SpotBugs
Expand All @@ -68,6 +68,7 @@ jobs:
- template: ../templates/steps/spotbugs.yml
parameters:
project: common

- job: lint
displayName: Lint
cancelTimeoutInMinutes: 1
Expand All @@ -87,5 +88,5 @@ jobs:
tasks: clean common:lintLocalDebug
publishJUnitResults: false
javaHomeSelection: JDKVersion
jdkVersionOption: "1.11"
jdkVersionOption: "1.17"
...
4 changes: 4 additions & 0 deletions azure-pipelines/pull-request-validation/common4j.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ jobs:
inputs:
cwd: $(Build.SourcesDirectory)/common-java-root
tasks: clean common4j:assemble
javaHomeOption: JDKVersion
jdkVersionOption: 1.17
- template: ../templates/steps/spotbugs.yml
parameters:
project: common4j
Expand All @@ -41,4 +43,6 @@ jobs:
inputs:
cwd: $(Build.SourcesDirectory)/common-java-root
tasks: common4j:test -Psugar=true -PmockApiUrl=$(MOCK_API_URL)
javaHomeOption: JDKVersion
jdkVersionOption: 1.17
...
4 changes: 4 additions & 0 deletions azure-pipelines/pull-request-validation/lab-utilities.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ jobs:
inputs:
cwd: $(Build.SourcesDirectory)/common-java-root
tasks: LabApiUtilities:clean LabApiUtilities:assemble
javaHomeSelection: JDKVersion
jdkVersionOption: "1.17"
- template: ../templates/steps/spotbugs.yml
parameters:
project: LabApiUtilities
Expand All @@ -41,4 +43,6 @@ jobs:
inputs:
cwd: $(Build.SourcesDirectory)/common-java-root
tasks: LabApiUtilities:test -Psugar=true -PlabSecret=$(LabVaultAppCert)
javaHomeSelection: JDKVersion
jdkVersionOption: "1.17"
...
Original file line number Diff line number Diff line change
Expand Up @@ -37,19 +37,19 @@ steps:
displayName: Assemble ${{ parameters.project }} ${{ parameters.variant }}
inputs:
javaHomeSelection: JDKVersion
jdkVersionOption: "1.11"
jdkVersionOption: "1.17"
tasks: '${{ parameters.project }}:clean ${{ parameters.project }}:assemble${{ parameters.variant }} ${{ parameters.buildArguments }}'
- task: Gradle@2
displayName: Publish
inputs:
javaHomeSelection: JDKVersion
jdkVersionOption: "1.11"
jdkVersionOption: "1.17"
tasks: '${{ parameters.project }}:publish${{ parameters.variant }} ${{ parameters.buildArguments }}'
- task: Gradle@2
displayName: Run unit tests
inputs:
javaHomeSelection: JDKVersion
jdkVersionOption: "1.11"
jdkVersionOption: "1.17"
tasks: '${{ parameters.project }}:test${{ parameters.variant }} -PlabSecret=$(LabVaultAppCert)'
- ${{ if ne(parameters.artifactFolder, '') }}:
- task: CopyFiles@2
Expand Down
5 changes: 3 additions & 2 deletions azure-pipelines/templates/steps/spotbugs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,14 @@ parameters:
default: CodeAnalysisLogs
- name: cwd
default: $(Build.SourcesDirectory)

- name: javaVersion
default: "1.17"
steps:
- task: Gradle@3
displayName: 'Run Spotbugs'
inputs:
javaHomeSelection: JDKVersion
jdkVersionOption: "1.11"
jdkVersionOption: ${{parameters.javaVersion}}
jdkArchitecture: x64
cwd: ${{ parameters.cwd }}
tasks: ${{ parameters.project }}:${{ parameters.spotbugsCommand }}
Expand Down
1 change: 1 addition & 0 deletions changelog.txt
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ Version 21.0.0
- [PATCH] Fix multiple prompts issue in cross cloud request (#2599)
- [PATCH] Corrected error handling in cross cloud scenario (#2602)
- [MINOR] Native auth: Add claimsRequest also to getAccessToken and signIn after signUp/SSPR flows (#2622)
- [MINOR] Upgrading AGP Version to 8.1.1 (#2587)

Version 20.1.1
----------
Expand Down
3 changes: 2 additions & 1 deletion common-java-root/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@ org.gradle.daemon=true

# See https://stackoverflow.com/questions/56075455/expiring-daemon-because-jvm-heap-space-is-exhausted
# we must make sure that the total size is <7G, as that's the RAM size of VM on the build pipeline.
org.gradle.jvmargs=-Xmx2048m -XX:MaxPermSize=512m -XX:+HeapDumpOnOutOfMemoryError
# MaxMetaspaceSize replaced MaxPermSize as of java 8+.https://www.oracle.com/java/technologies/javase/8-whats-new.html
org.gradle.jvmargs=-Xmx2048m -XX:MaxMetaspaceSize=512m -XX:+HeapDumpOnOutOfMemoryError

# This the TSL versionName...
versionName=1.5.9
Expand Down
3 changes: 2 additions & 1 deletion common-java-root/gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-7.5-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.1-all.zip

zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
46 changes: 37 additions & 9 deletions common/build.gradle
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
plugins {
id 'com.microsoft.identity.buildsystem' version '0.2.3'
id 'com.microsoft.identity.buildsystem' version '0.2.5'
id 'com.android.library'
id 'pmd'
id 'checkstyle'
Expand Down Expand Up @@ -61,7 +61,11 @@ android {
buildConfigField("boolean", "trustDebugBrokerFlag", "$trustDebugBrokerFlag")
buildConfigField("boolean", "bypassRedirectUriCheck", "$bypassRedirectUriCheck")
}

//aidl is being set to true since aidl only generated with this set
buildFeatures {
buildConfig = true
aidl = true
}
buildTypes {
debug {
testCoverageEnabled enableCodeCoverage
Expand Down Expand Up @@ -118,6 +122,7 @@ android {
sourceSets {
main {
manifest.srcFile 'src/main/AndroidManifest.xml'
aidl.srcDirs = ['src/main/aidl']

// Also load source from common-java
java.srcDirs = ['src/main/java', 'src/main/kotlin']
Expand Down Expand Up @@ -240,15 +245,15 @@ android.libraryVariants.all { variant ->
// Create tasks to generate javadoc jar
android.libraryVariants.all { variant ->
task("${variant.name}JavadocJar", type: Jar, dependsOn: "${variant.name}Javadoc") {
classifier 'javadoc'
archiveClassifier.set('javadoc')
from tasks["${variant.name}Javadoc"].destinationDir
}
}


tasks.register('sourcesJar', Jar) {
from android.sourceSets.main.java.srcDirs
classifier 'sources'
archiveClassifier.set('sources')
destinationDirectory = reporting.file("$project.buildDir/outputs/jar/")
}

Expand Down Expand Up @@ -284,11 +289,10 @@ tasks.register('pmd', Pmd) {
source = fileTree('src/main/java')

reports {
xml.enabled = false
html.enabled = true
xml.required = false
html.required = true
}
}

// For publishing to the remote maven repo.
afterEvaluate {

Expand Down Expand Up @@ -335,6 +339,7 @@ afterEvaluate {
groupId 'com.microsoft.identity'
artifactId 'common-debug'
//Edit the 'version' here for VSTS RC build

version = project.version
}
}
Expand Down Expand Up @@ -364,11 +369,34 @@ tasks.configureEach { task ->
if (task.name == 'assembleDistRelease') {
task.dependsOn 'sourcesJar'
}
//Due to gradle version increase, we need to be more explicit in the dependency chain
// More information https://discuss.gradle.org/t/g./gradle-8-project-dependency-requirement-clarification/46336
if (task.name == "publishDistDebugPublicationToVsts-maven-adal-androidRepository") {
task.dependsOn 'generatePomFileForDistReleasePublication'
}
if (task.name == "publishDistReleasePublicationToVsts-maven-adal-androidRepository") {
task.dependsOn 'bundleDistReleaseAar'
}
if (task.name == "publishDistDebugPublicationToVsts-maven-adal-androidRepository") {
task.dependsOn 'bundleDistReleaseAar'
}
if (task.name == "generateMetadataFileForDistDebugPublication") {
task.dependsOn 'bundleDistReleaseAar'
}
if (task.name == "generateMetadataFileForDistReleasePublication") {
task.dependsOn 'bundleDistDebugAar'
}
}

// This is used to generate the pom file for publishing to external maven in maven-release-jobs.yml
// This is used to generate the pom file for publishing to external maven in maven-release-jobs.yml.
// Need to distinguish between distDebug and distRelease for the distination
tasks.withType(GenerateMavenPom).all {
destination = layout.buildDirectory.file("poms/${project.name}-${project.version}.pom").get().asFile
def functionName = name.toLowerCase()
if (functionName.contains("distdebug")) {
destination = layout.buildDirectory.file("poms/common-debug-${project.version}.pom").get().asFile
} else if (functionName.contains("distrelease")) {
destination = layout.buildDirectory.file("poms/common-${project.version}.pom").get().asFile
}
}

def dependenciesSizeInMb = project.hasProperty("dependenciesSizeMb") ? project.dependenciesSizeMb : "15"
Expand Down
8 changes: 5 additions & 3 deletions common4j/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

plugins {
id 'java-library'
id 'com.microsoft.identity.buildsystem' version '0.2.3'
id 'com.microsoft.identity.buildsystem' version '0.2.5'
id 'maven-publish'

// the below build plugin allows to generate BuildConfig files in a JAVA gradle project.
Expand Down Expand Up @@ -61,13 +61,15 @@ project.ext.vstsPassword = System.getenv("ENV_VSTS_MVN_ANDROIDCOMMON_ACCESSTOKEN
version = getAppVersionName()

task sourcesJar(type: Jar) {
dependsOn generateBuildConfig
from sourceSets.main.java.srcDirs
classifier 'sources'
archiveClassifier.set('sources')
destinationDirectory = reporting.file("$project.buildDir/outputs/jars")
}

// Task to generate javadoc
task generateJavadoc(type: Javadoc) {
dependsOn generateBuildConfig
failOnError false
title = "Microsoft Identity Common Java"
source = sourceSets.main.java
Expand All @@ -84,7 +86,7 @@ task generateJavadoc(type: Javadoc) {
// Task to generate javadoc.jar
task javadocJar(type: Jar, dependsOn: generateJavadoc) {
from javadoc.destinationDir
classifier 'javadoc'
archiveClassifier.set('javadoc')
destinationDirectory = reporting.file("$project.buildDir/outputs/jars")
}

Expand Down
2 changes: 1 addition & 1 deletion common4j/gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-7.5-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.1-all.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
3 changes: 2 additions & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,8 @@ org.gradle.daemon=true

# See https://stackoverflow.com/questions/56075455/expiring-daemon-because-jvm-heap-space-is-exhausted
# we must make sure that the total size is <7G, as that's the RAM size of VM on the build pipeline.
org.gradle.jvmargs=-Xmx3072m -XX:MaxPermSize=1024m -XX:+HeapDumpOnOutOfMemoryError
# MaxMetaspaceSize replaced MaxPermSize as of java 8+.https://www.oracle.com/java/technologies/javase/8-whats-new.html
org.gradle.jvmargs=-Xmx3072m -XX:MaxMetaspaceSize=1024m -XX:+HeapDumpOnOutOfMemoryError

# This the TSL versionName...
versionName=1.5.9
Expand Down
4 changes: 2 additions & 2 deletions gradle/versions.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ ext {
buildToolsVersion = "28.0.3"

// Plugins
gradleVersion = '7.4.2'
gradleVersion = '8.1.1'
kotlinVersion = '1.7.21'
spotBugsGradlePluginVersion = '4.7.1'
jupiterApiVersion = '5.6.0'
Expand Down Expand Up @@ -47,7 +47,7 @@ ext {
uiAutomatorVersion = "2.2.0"
daggerVersion = "2.31.2"
daggerCompilerVersion = "2.31.2"
msal4jVersion = "1.10.0"
msal4jVersion = "1.20.1"
moshiVersion = "1.14.0"
moshiAdaptersVersion = "1.14.0"
openpojoVersion = "0.9.1"
Expand Down
2 changes: 1 addition & 1 deletion gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-7.5-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-8.1-all.zip
Loading