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
1 change: 0 additions & 1 deletion eng/pipelines/templates/jobs/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,6 @@ jobs:
filePath: $(Build.SourcesDirectory)/eng/scripts/Save-Package-Namespaces-Property.ps1
arguments: >
-ArtifactStagingDirectory $(Build.ArtifactStagingDirectory)
-ArtifactsList ('$(ArtifactsJson)' | ConvertFrom-Json)
pwsh: true
workingDirectory: $(Pipeline.Workspace)
displayName: Update package properties with namespaces
Expand Down
48 changes: 21 additions & 27 deletions eng/scripts/Save-Package-Namespaces-Property.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -18,54 +18,48 @@ libraries are com.azure.spring and their javadoc jars will be under that subdire
but azure-spring-data-cosmos' GroupId is com.azure and its javadoc jar will be under
com.azure.

.PARAMETER ArtifactsList
The list of artifacts to gather namespaces for, this is only done for libraries that are
producing docs.
-ArtifactsList ('$(ArtifactsJson)' | ConvertFrom-Json)
The ArtifactStagingDirectory

#>
[CmdletBinding()]
Param (
[Parameter(Mandatory = $True)]
[string] $ArtifactStagingDirectory,
[Parameter(Mandatory=$true)]
[array] $ArtifactsList
[string] $ArtifactStagingDirectory
)

$ArtifactsList = $ArtifactsList | Where-Object -Not "skipPublishDocMs"

. (Join-Path $PSScriptRoot ".." common scripts common.ps1)

if (-not $ArtifactsList) {
Write-Host "ArtifactsList is empty, nothing to process. This can happen if skipPublishDocMs is set to true for all libraries being built."
exit 0
}

Write-Host "ArtifactStagingDirectory=$ArtifactStagingDirectory"
if (-not (Test-Path -Path $ArtifactStagingDirectory)) {
LogError "ArtifactStagingDirectory '$ArtifactStagingDirectory' does not exist."
exit 1
}

Write-Host ""
Write-Host "ArtifactsList:"
$ArtifactsList | Format-Table -Property GroupId, Name, ReleaseInBatch | Out-String | Write-Host

$packageInfoDirectory = Join-Path $ArtifactStagingDirectory "PackageInfo"

$foundError = $false
# At this point the packageInfo files should have been already been created.
# The only thing being done here is adding or updating namespaces for libraries
# that will be producing docs. This ArtifactsList is
foreach($artifact in $ArtifactsList) {
if ($artifact.ReleaseInBatch -eq $false) {
Write-Host "Skipping $($artifact.Name) as it is not being released in this batch."
continue
}
$packageInfoFiles = Get-ChildItem -Path $packageInfoDirectory -File -Filter "*.json"

# Get the version from the packageInfo file
$packageInfoFile = Join-Path $packageInfoDirectory "$($artifact.Name).json"
foreach($packageInfoFile in $packageInfoFiles) {
Write-Host "processing $($packageInfoFile.FullName)"
$packageInfo = ConvertFrom-Json (Get-Content $packageInfoFile -Raw)

# ArtifactDetails will be null for AdditionalModules
if ($packageInfo.ArtifactDetails) {
# If skipPublishDocMs isn't there, then by default docs are being published for that library
if ($packageInfo.ArtifactDetails.PSobject.Properties.Name -contains "skipPublishDocMs") {
# If skipPublishDocMs is there and it's true, then skip publishing
if ($packageInfo.ArtifactDetails.skipPublishDocMs) {
Write-Host "Skipping DocsMS publishing for $($packageInfo.Name). skipPublishDocMs is set to false."
continue
}
}
} else {
Write-Host "Skipping DocsMS publishing for $($packageInfo.Name). ArtifactDetails is null meaning this is an AdditionalModule"
continue
}

$version = $packageInfo.Version
# If the dev version is set, use that. This will be set for nightly builds
if ($packageInfo.DevVersion) {
Expand Down
6 changes: 5 additions & 1 deletion eng/scripts/generate_from_source_pom.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,11 @@ def create_from_source_pom(artifacts_list: str, additional_modules_list: str, se
additional_modules_identifiers = []
if additional_modules_list is not None:
additional_modules_identifiers = additional_modules_list.split(',')
# Combine the lists so dependencies are calculated correctly. While there
# should be no duplicates between the artifacts list and additional modules,
# it's better to be safe. This will remove the duplicates
combined_list = artifacts_list_identifiers + additional_modules_identifiers
artifacts_list_identifiers = list(set(combined_list))

# Get the artifact identifiers from client_versions.txt to act as our source of truth.
artifact_identifier_to_version = load_client_artifact_identifiers()
Expand All @@ -83,7 +88,6 @@ def create_from_source_pom(artifacts_list: str, additional_modules_list: str, se

# Finally map the project identifiers to projects.
add_source_projects(source_projects, artifacts_list_identifiers, projects)
add_source_projects(source_projects, additional_modules_identifiers, projects)
add_source_projects(source_projects, dependent_modules, projects)
add_source_projects(source_projects, dependency_modules, projects)

Expand Down
2 changes: 2 additions & 0 deletions sdk/aot/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,3 +57,5 @@ extends:
AdditionalModules:
- name: azure-aot-graalvm-perf
groupId: com.azure
- name: azure-aot-graalvm-samples
groupId: com.azure
2 changes: 2 additions & 0 deletions sdk/core/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,8 @@ extends:
safeName: azurecoretracingopentelemetry
releaseInBatch: ${{ parameters.release_azurecoretracingopentelemetry }}
AdditionalModules:
- name: azure-core-tracing-opentelemetry-samples
groupId: com.azure
- name: azure-core-perf
groupId: com.azure
# required by the above perf library
Expand Down
2 changes: 2 additions & 0 deletions sdk/identity/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,8 @@ extends:
safeName: azureidentitybroker
releaseInBatch: ${{ parameters.release_azureidentitybroker }}
AdditionalModules:
- name: azure-identity-broker-samples
groupId: com.azure
- name: azure-identity-perf
groupId: com.azure
# required by the above perf library
Expand Down
6 changes: 1 addition & 5 deletions sdk/identity/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,11 @@
<!-- Need not change for every release-->

<modules>

<module>azure-identity</module>

<module>azure-identity-perf</module>

<module>azure-identity-extensions</module>

<module>azure-identity-broker</module>

<module>azure-identity-broker-samples</module>
</modules>

</project>