-
Notifications
You must be signed in to change notification settings - Fork 335
Expand file tree
/
Copy pathdotnet-sqlclient-ci-project-reference-pipeline.yml
More file actions
204 lines (181 loc) · 6.72 KB
/
Copy pathdotnet-sqlclient-ci-project-reference-pipeline.yml
File metadata and controls
204 lines (181 loc) · 6.72 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
#################################################################################
# Licensed to the .NET Foundation under one or more agreements. #
# The .NET Foundation licenses this file to you under the MIT license. #
# See the LICENSE file in the project root for more information. #
#################################################################################
# This pipeline builds and tests the following packages using project
# references:
#
# - Microsoft.SqlServer.Server
# - Microsoft.Data.SqlClient
# - Microsoft.Data.SqlClient.AlwaysEncrypted.AzureKeyVaultProvider
#
# It runs via CI push triggers and schedules and uses the Release build
# configuration:
#
# - Commits to the GitHub release/7.1 branch
# - Commits to the ADO internal/release/7.1 branch
# - Daily at 09:00 UTC on GitHub release/7.1
# - Daily at 17:00 UTC on ADO internal/release/7.1
#
# GOTCHA: This pipeline definition is triggered by GitHub _and_ ADO CI. We are
# able to define different triggers and schedules using branch filters:
#
# - The GitHub registration uses the release/7.1 branch filters.
#
# - The ADO registration uses the internal/release/7.1 branch filters.
#
# Changes are batched together to ensure that the pipline never runs
# concurrently.
#
# This pipeline definition is mapped to the following Azure DevOps pipelines:
#
# - CI-SqlClient in the Public project:
#
# https://sqlclientdrivers.visualstudio.com/public/_build?definitionId=1879
#
# - MDS Main CI in the ADO.net project:
#
# https://sqlclientdrivers.visualstudio.com/ADO.Net/_build?definitionId=1825
# Set the pipeline run name to the day-of-year and the daily run counter.
# This becomes BuildNumber, used as the revision component of FileVersion
# (Major.Minor.Patch.Revision). Revision must fit in a 16-bit unsigned int (max 65535).
# Format $(DayOfYear)$(Rev:rr) yields e.g. 15401 (day 154, run 01) — always < 65535.
name: $(DayOfYear)$(Rev:rr)
# Do not trigger this pipeline for PRs.
pr: none
# Trigger this pipeline on commits to certain branches.
trigger:
# Don't trigger a new run until the previous one completes. This may cause
# multiple commits to be batched into a single run.
batch: true
branches:
include:
# GitHub release branch.
- release/7.1-staging
# ADO release branch.
- internal/release/7.1-staging
# Trigger this pipeline on a schedule.
schedules:
# GitHub release/7.1 daily.
- cron: '0 9 * * *'
displayName: 7.1 GitHub Project-Reference Daily Run (09:00 UTC)
branches:
include:
- release/7.1-staging
always: true
# ADO internal/release/7.1 daily.
- cron: '0 17 * * *'
displayName: 7.1 ADO Project-Reference Daily Run (17:00 UTC)
branches:
include:
- internal/release/7.1-staging
always: true
# Pipeline parameters, visible in the Azure DevOps UI.
parameters:
# The C# build configuration to use; defaults to Release.
- name: buildConfiguration
displayName: Build Configuration
type: string
default: Release
values:
- Debug
- Release
- name: buildPlatforms
displayName: Build Platforms on Windows
type: object
default: [AnyCPU]
# True to emit debug information and steps.
- name: debug
displayName: Enable debug output
type: boolean
default: false
# The target frameworks to build and run tests for on Windows.
#
# These are _not_ the target frameworks to build the driver packages for.
#
# Note: We are excluding .NET 10.0 here to avoid consuming too many resources
# across every SQL Server image. .NET 10.0 coverage is provided by the
# primaryTargetFrameworks parameter below, which applies to the SQL Server
# 2025 and Azure SQL configurations.
#
- name: targetFrameworks
displayName: Target Frameworks on Windows
type: object
default: [net462, net8.0, net9.0]
# The target frameworks to build and run tests for on Unix.
#
# These are _not_ the target frameworks to build the driver packages for.
#
# Note: We are excluding .NET 10.0 here to avoid consuming too many resources
# across every SQL Server image. .NET 10.0 coverage is provided by the
# primaryTargetFrameworksUnix parameter below, which applies to the SQL
# Server 2025 and Azure SQL configurations.
#
- name: targetFrameworksUnix
displayName: Target Frameworks on Unix
type: object
default: [net8.0, net9.0]
# The target frameworks used by the primary test configurations (local SQL
# Server 2025 and Azure SQL) on Windows.
#
# net10.0 is included here so that unit, functional, and manual tests get
# .NET 10 coverage without paying for it on every legacy SQL Server image.
#
# Note: The driver itself does not ship a net10.0 target framework, so the
# net10.0 test assemblies resolve the net9.0 driver build. These jobs
# therefore validate the driver running on the .NET 10 runtime, rather than
# a net10.0 build of the driver.
#
- name: primaryTargetFrameworks
displayName: Target Frameworks on Windows (SQL 2025 and Azure SQL)
type: object
default: [net462, net8.0, net9.0, net10.0]
# The target frameworks used by the primary test configurations (local SQL
# Server 2025 and Azure SQL) on Unix.
- name: primaryTargetFrameworksUnix
displayName: Target Frameworks on Unix (SQL 2025 and Azure SQL)
type: object
default: [net8.0, net9.0, net10.0]
# The timeout, in minutes, for each test job.
- name: testJobTimeout
displayName: Test job timeout (in minutes)
type: number
default: 90
- name: testSets
displayName: Test Sets
type: object
default: [1, 2, 3]
- name: useManagedSNI
displayName: |
Use Managed/Native SNI on Windows,
values [false, true], [false] or [true] are allowed
type: object
default: [false, true]
# Dotnet CLI verbosity level.
- name: dotnetVerbosity
displayName: dotnet CLI Verbosity
type: string
default: normal
values:
- quiet
- minimal
- normal
- detailed
- diagnostic
extends:
template: /eng/pipelines/dotnet-sqlclient-ci-core.yml@self
parameters:
buildConfiguration: ${{ parameters.buildConfiguration }}
buildPlatforms: ${{ parameters.buildPlatforms }}
buildSuffix: 'ci'
referenceType: Project
debug: ${{ parameters.debug }}
dotnetVerbosity: ${{ parameters.dotnetVerbosity }}
targetFrameworks: ${{ parameters.targetFrameworks }}
targetFrameworksUnix: ${{ parameters.targetFrameworksUnix }}
primaryTargetFrameworks: ${{ parameters.primaryTargetFrameworks }}
primaryTargetFrameworksUnix: ${{ parameters.primaryTargetFrameworksUnix }}
testJobTimeout: ${{ parameters.testJobTimeout }}
testSets: ${{ parameters.testSets }}
useManagedSNI: ${{ parameters.useManagedSNI }}