diff --git a/.github/agents/issue-fix-agent.agent.md b/.github/agents/issue-fix-agent.agent.md
index 9ac56264dc..8ea9fd0824 100644
--- a/.github/agents/issue-fix-agent.agent.md
+++ b/.github/agents/issue-fix-agent.agent.md
@@ -706,20 +706,20 @@ line_endings:
prevention:
before_editing:
- - "Check original line endings: git show master:{file} | python -c \"import sys; d=sys.stdin.buffer.read(); print(f'CRLF:{d.count(chr(13).encode()+chr(10).encode())} LF:{d.count(chr(10).encode())}')\""
+ - "Check original line endings: git show main:{file} | python -c \"import sys; d=sys.stdin.buffer.read(); print(f'CRLF:{d.count(chr(13).encode()+chr(10).encode())} LF:{d.count(chr(10).encode())}')\""
after_editing:
- - "Verify no whitespace-only changes: git diff master --ignore-all-space -- {file}"
- - "If whitespace diff appears, restore from master and re-apply only intentional changes"
+ - "Verify no whitespace-only changes: git diff main --ignore-all-space -- {file}"
+ - "If whitespace diff appears, restore from main and re-apply only intentional changes"
restore_pattern: |
# If you accidentally introduced whitespace changes:
- git checkout master -- {file} # Restore original
+ git checkout main -- {file} # Restore original
# Then re-apply only your intentional additions using edit tool
diff_verification:
- always_run: "git diff master --ignore-cr-at-eol -- {file}"
- if_spurious_changes: "git checkout master -- {file} and re-apply edits"
+ always_run: "git diff main --ignore-cr-at-eol -- {file}"
+ if_spurious_changes: "git checkout main -- {file} and re-apply edits"
```
---
@@ -844,7 +844,7 @@ mandatory_checkpoints:
- "If before/after evidence is not possible (environment-specific issue), document why and provide unit test evidence instead"
- "PR MUST be created as DRAFT: `gh pr create --draft`"
- "PR title MUST follow format: `[Internal] Category: (Adds|Fixes|Refactors|Removes) Description` (enforced by PR Lint bot)"
- - "Verify no spurious whitespace changes: `git diff master --ignore-all-space`"
+ - "Verify no spurious whitespace changes: `git diff main --ignore-all-space`"
before_marking_pr_ready:
- "ALL CI gates MUST show green (passed) status — not just completed"
@@ -1313,7 +1313,7 @@ I've analyzed issue #{number} and gathered the following initial context:
**Proposed Investigation Plan:**
1. Historical search: GitHub issues, PRs, StackOverflow, changelog
2. Code analysis: {specific areas to investigate}
-3. Reproduction: Test against {reported version}, {latest SDK}, {master branch}
+3. Reproduction: Test against {reported version}, {latest SDK}, {main branch}
**Estimated Time:** {X minutes}
@@ -1685,19 +1685,19 @@ reproduction_versions:
source: "NuGet package (latest)"
3_master_branch:
- description: "Current master/main branch"
+ description: "Current main/main branch"
purpose: "Check if fix exists but not released"
- source: "Local build from master"
+ source: "Local build from main"
```
**Version Matrix Test Results:**
| Version | Result | Implication |
|---------|--------|-------------|
-| Reported ✅ / Latest ✅ / Master ✅ | Issue persists | Needs fix |
-| Reported ✅ / Latest ❌ / Master ❌ | Fixed in release | Recommend upgrade |
-| Reported ✅ / Latest ✅ / Master ❌ | Fixed, not released | Mention upcoming fix |
-| Reported ❌ / Latest ❌ / Master ❌ | Cannot reproduce | Request more info |
+| Reported ✅ / Latest ✅ / Main ✅ | Issue persists | Needs fix |
+| Reported ✅ / Latest ❌ / Main ❌ | Fixed in release | Recommend upgrade |
+| Reported ✅ / Latest ✅ / Main ❌ | Fixed, not released | Mention upcoming fix |
+| Reported ❌ / Latest ❌ / Main ❌ | Cannot reproduce | Request more info |
### 4.2 Environment Setup
@@ -1725,11 +1725,11 @@ version_setup:
cd IssueRepro_{number}_latest
dotnet add package Microsoft.Azure.Cosmos # Gets latest
- master_branch:
+ main_branch:
command: |
- # Build from local master
- git checkout master
- git pull origin master
+ # Build from local main
+ git checkout main
+ git pull origin main
dotnet build Microsoft.Azure.Cosmos.sln -c Release
# Reference local build in test project
```
@@ -1751,7 +1751,7 @@ version_setup:
///
/// Reproduction tests for GitHub Issue #{number}
-/// Run against: Reported version, Latest stable, Master branch
+/// Run against: Reported version, Latest stable, Main branch
///
[TestClass]
public class Issue_{number}_Tests
@@ -1829,15 +1829,15 @@ test_execution:
command: dotnet test --filter "Issue_{number}" -- CosmosDB:ConnectionMode=Direct
record: "version=latest, gateway={pass/fail}, direct={pass/fail}"
- master_branch:
+ main_branch:
setup: |
- # Ensure master is built
+ # Ensure main is built
dotnet build Microsoft.Azure.Cosmos.sln -c Release
gateway:
command: dotnet test --filter "Issue_{number}" -- CosmosDB:ConnectionMode=Gateway
direct:
command: dotnet test --filter "Issue_{number}" -- CosmosDB:ConnectionMode=Direct
- record: "version=master, gateway={pass/fail}, direct={pass/fail}"
+ record: "version=main, gateway={pass/fail}, direct={pass/fail}"
capture:
- CosmosDiagnostics output
@@ -1856,12 +1856,12 @@ capture:
|---------|--------------|-------------|-------|
| {reported_version} | ✅ Reproduced / ❌ Not Reproduced | ✅ / ❌ | {notes} |
| {latest_version} | ✅ / ❌ | ✅ / ❌ | {notes} |
-| master ({commit_sha}) | ✅ / ❌ | ✅ / ❌ | {notes} |
+| main ({commit_sha}) | ✅ / ❌ | ✅ / ❌ | {notes} |
**Conclusion:**
- [ ] Issue persists in all versions → Needs fix
- [ ] Fixed in latest release → Recommend upgrade to {version}
-- [ ] Fixed in master, not released → Will be available in next release
+- [ ] Fixed in main, not released → Will be available in next release
- [ ] Cannot reproduce → Need more information
```
@@ -1898,7 +1898,7 @@ public class Issue_{number}_Benchmark
[Params("Gateway", "Direct")]
public string ConnectionMode { get; set; }
- [Params("3.35.0", "Latest", "Master")] // Versions to compare
+ [Params("3.35.0", "Latest", "Main")] // Versions to compare
public string SdkVersion { get; set; }
[GlobalSetup]
@@ -1977,8 +1977,8 @@ benchmark_workflow:
command: dotnet run -c Release -- --filter "*" --artifacts ./results/v{reported}
latest_version:
command: dotnet run -c Release -- --filter "*" --artifacts ./results/latest
- master_branch:
- command: dotnet run -c Release -- --filter "*" --artifacts ./results/master
+ main_branch:
+ command: dotnet run -c Release -- --filter "*" --artifacts ./results/main
```
#### Benchmark Metrics to Capture
@@ -2022,8 +2022,8 @@ metrics:
| {reported} | Direct | {ms} | {ms} | {ms} | {ms} | {KB} |
| {latest} | Gateway | {ms} | {ms} | {ms} | {ms} | {KB} |
| {latest} | Direct | {ms} | {ms} | {ms} | {ms} | {KB} |
-| master | Gateway | {ms} | {ms} | {ms} | {ms} | {KB} |
-| master | Direct | {ms} | {ms} | {ms} | {ms} | {KB} |
+| main | Gateway | {ms} | {ms} | {ms} | {ms} | {KB} |
+| main | Direct | {ms} | {ms} | {ms} | {ms} | {KB} |
### Throughput Comparison
@@ -2385,7 +2385,7 @@ Created: {date}
## Reproduction Status
- [ ] Reproduced with reported SDK version ({version})
- [ ] Reproduced with latest SDK version ({version})
-- [ ] Reproduced with master branch ({commit_sha})
+- [ ] Reproduced with main branch ({commit_sha})
- [ ] Reproduced in Gateway mode
- [ ] Reproduced in Direct mode
- [ ] Unable to reproduce
@@ -2397,7 +2397,7 @@ Created: {date}
|---------|---------|--------|-------|-------|
| {reported_version} | ✅/❌ | ✅/❌ | ✅ | {notes} |
| {latest_version} | ✅/❌ | ✅/❌ | ✅ | {notes} |
-| master ({short_sha}) | ✅/❌ | ✅/❌ | ✅ | {notes} |
+| main ({short_sha}) | ✅/❌ | ✅/❌ | ✅ | {notes} |
### Reproduction Steps Attempted
~~~
@@ -2947,8 +2947,8 @@ reviewer_feedback_workflow:
naming_feedback:
action: "Rename as requested, update all references, reply with new name"
whitespace_noise:
- action: "Restore original file from master, re-apply only intentional changes"
- command: "git checkout master -- {file} && re-apply edits"
+ action: "Restore original file from main, re-apply only intentional changes"
+ command: "git checkout main -- {file} && re-apply edits"
missing_tests:
action: "Add requested tests, show pass evidence in reply"
style_issues:
@@ -4362,14 +4362,14 @@ flaky_tests:
action: "Retry failed stage via ADO API"
pre_existing_failures:
- description: "Tests that consistently fail in master (not flaky)"
+ description: "Tests that consistently fail in main (not flaky)"
note: "These are baseline issues, not caused by your PR changes"
tests:
- name: "TestQueryExecutionInfo_FromString"
location: "OptimisticDirectExecutionQueryBaselineTests.cs"
- name: "TestTextDistributionPlanParsingFromStream"
location: "OptimisticDirectExecutionQueryBaselineTests.cs"
- handling: "Ignore if they fail - verify by running on master branch"
+ handling: "Ignore if they fail - verify by running on main branch"
handling_flaky_failures:
step_1: "Check if failed test is in flaky registry"
@@ -4448,7 +4448,7 @@ ci_monitoring_loop:
code_related: "Your changes broke something"
flaky_test: "Known intermittent failure (see Section 16.7)"
infrastructure: "Emulator/network/timeout issues"
- unrelated: "Pre-existing failure in master"
+ unrelated: "Pre-existing failure in main"
respond:
code_related:
@@ -4464,7 +4464,7 @@ ci_monitoring_loop:
action: "Wait 5 min, then retry failed stage via MCP"
unrelated:
- action: "Document that failure exists in master, proceed"
+ action: "Document that failure exists in main, proceed"
step_4_iterate:
loop: "Repeat step_2 and step_3 until all gates GREEN"
@@ -4473,10 +4473,10 @@ ci_monitoring_loop:
step_5_pre_ready_checks:
description: "Verify branch is ready before marking for review"
checks:
- - name: "Ensure branch is up-to-date with master"
+ - name: "Ensure branch is up-to-date with main"
commands: |
- git fetch origin master
- git rebase origin/master
+ git fetch origin main
+ git rebase origin/main
# If conflicts, resolve and push
git push origin {branch_name} --force-with-lease
note: "Rebase ensures clean merge, re-triggers CI if needed"
@@ -4495,7 +4495,7 @@ ci_monitoring_loop:
auto_ready_behavior:
principle: "Mark PR ready for review immediately when conditions met"
required_conditions:
- - "Branch is up-to-date with master (rebased)"
+ - "Branch is up-to-date with main (rebased)"
- "dotnet-v3-ci check is SUCCESS (main CI gate)"
do_not_wait_for:
- "User confirmation"
@@ -4505,7 +4505,7 @@ ci_monitoring_loop:
success_criteria:
required:
- - "Branch rebased on latest master"
+ - "Branch rebased on latest main"
- "**dotnet-v3-ci check is SUCCESS** (primary gate)"
- "PR lint passed"
- "CLA signed"
@@ -4850,7 +4850,7 @@ pre_existing_failures:
purpose: "Distinguish regressions from known issues"
approach:
- step_1: "Run tests on clean master before making changes"
+ step_1: "Run tests on clean main before making changes"
step_2: "Document any failures as 'pre-existing'"
step_3: "After fix, compare failure list - new failures = regression"
@@ -4861,7 +4861,7 @@ pre_existing_failures:
ci_implications:
- "Pre-existing failures may cause CI to fail"
- "Check if same tests fail in recent passing PRs"
- - "If test passes in master but fails in PR, it's a regression"
+ - "If test passes in main but fails in PR, it's a regression"
```
### 17.3 Check for Existing PRs First
@@ -5510,7 +5510,7 @@ performance:
benchmarking:
location: "Microsoft.Azure.Cosmos.Samples/Tools/Benchmark"
- url: "https://github.com/Azure/azure-cosmos-dotnet-v3/tree/master/Microsoft.Azure.Cosmos.Samples/Tools/Benchmark"
+ url: "https://github.com/Azure/azure-cosmos-dotnet-v3/tree/main/Microsoft.Azure.Cosmos.Samples/Tools/Benchmark"
important: "ALL benchmarks go here ONLY - do not add benchmarks elsewhere"
adding_benchmarks:
diff --git a/.github/agents/msdata-direct-sync-agent.agent.md b/.github/agents/msdata-direct-sync-agent.agent.md
index c648ef0b40..b61cfc36df 100644
--- a/.github/agents/msdata-direct-sync-agent.agent.md
+++ b/.github/agents/msdata-direct-sync-agent.agent.md
@@ -1,6 +1,6 @@
---
name: 'MsdataDirectSyncAgent'
-description: 'Orchestrates syncing the msdata/direct branch with the latest v3 master and msdata direct codebase.'
+description: 'Orchestrates syncing the msdata/direct branch with the latest v3 main and msdata direct codebase.'
tools:
- read
- search
@@ -20,14 +20,14 @@ tools:
```
Follow the msdata/direct sync agent plan in .github/agents/msdata-direct-sync-agent.agent.md
-Sync the msdata/direct branch with the latest v3 master and msdata direct codebase.
+Sync the msdata/direct branch with the latest v3 main and msdata direct codebase.
```
**What the agent will do:**
1. Verify environment setup (git, .NET SDK, repo clones)
2. Prompt for msdata CosmosDB repo path
3. Create feature branch from `msdata/direct`
-4. Merge latest `master` into feature branch
+4. Merge latest `main` into feature branch
5. Run `msdata_sync.ps1` to sync direct package files
6. **Verify sync completeness** — scan msdata source dirs for files missed by the script and auto-copy them
7. Build and validate
@@ -67,14 +67,14 @@ required_repos:
azure_cosmos_dotnet_v3:
url: "https://github.com/Azure/azure-cosmos-dotnet-v3.git"
required_branches:
- - master
+ - main
- msdata/direct
verify: "git branch -a | Select-String 'msdata/direct'"
msdata_cosmosdb:
description: "Internal CosmosDB repository (msdata)"
note: "User will be prompted for local path at runtime"
- required_branch: "master"
+ required_branch: "main"
verify: "Test-Path "
```
@@ -87,7 +87,7 @@ required_repos:
- [ ] .NET SDK installed: `dotnet --version`
- [ ] gh CLI authenticated: `gh auth status`
- [ ] v3 repo cloned with msdata/direct branch available
-- [ ] msdata CosmosDB repo cloned and on master branch
+- [ ] msdata CosmosDB repo cloned and on main branch
```
---
@@ -100,7 +100,7 @@ required_repos:
sync_principles:
rules:
- "ALWAYS verify each phase before proceeding to the next"
- - "ALWAYS accept incoming master changes when resolving merge conflicts"
+ - "ALWAYS accept incoming main changes when resolving merge conflicts"
- "NEVER force-push to msdata/direct directly"
- "ALWAYS create PRs as draft first"
- "ALWAYS run a clean build before creating the PR"
@@ -150,19 +150,19 @@ phase_1_steps:
commands:
- "cd && git status"
- "cd && git branch --show-current"
- action: "Ensure msdata repo is on master and up to date"
- fix: "cd && git checkout master && git pull"
+ action: "Ensure msdata repo is on main and up to date"
+ fix: "cd && git checkout main && git pull"
```
### Phase 2: Branch Preparation
-**Goal:** Create a feature branch from `msdata/direct` and merge latest `master`.
+**Goal:** Create a feature branch from `msdata/direct` and merge latest `main`.
```yaml
phase_2_steps:
step_1_update_branches:
commands:
- - "git fetch origin master:master --quiet"
+ - "git fetch origin main:main --quiet"
- "git fetch origin msdata/direct --quiet"
verify: "Both branches are up to date with remote"
@@ -178,11 +178,11 @@ phase_2_steps:
step_3_merge_master:
commands:
- - "git merge master"
+ - "git merge main"
expect: "Merge conflicts are likely"
step_4_resolve_conflicts:
- strategy: "Accept incoming master changes for most conflicts"
+ strategy: "Accept incoming main changes for most conflicts"
commands:
- "git checkout --theirs "
- "git add "
@@ -296,7 +296,7 @@ phase_4_steps:
fix: "Check using statements, resolve with fully qualified names"
api_changes:
symptom: "Method signature mismatch"
- fix: "Update to match latest API from master or direct"
+ fix: "Update to match latest API from main or direct"
action: "Fix errors, rebuild, repeat until clean"
step_3_verify_build:
@@ -314,7 +314,7 @@ phase_5_steps:
step_1_stage_and_commit:
commands:
- "git add -A"
- - 'git commit -m "[Internal] Direct package: Adds msdata/direct update from master"'
+ - 'git commit -m "[Internal] Direct package: Adds msdata/direct update from main"'
verify: "git status shows clean working tree"
step_2_push_branch:
@@ -325,7 +325,7 @@ phase_5_steps:
command: |
gh pr create --draft \
--base msdata/direct \
- --title "[Internal] Direct package: Adds msdata/direct update from master" \
+ --title "[Internal] Direct package: Adds msdata/direct update from main" \
--body ""
pr_description_template: |
# Pull Request Template
@@ -333,13 +333,13 @@ phase_5_steps:
## Description
Syncs the `msdata/direct` branch with:
- - Latest `master` branch (v3 SDK changes)
+ - Latest `main` branch (v3 SDK changes)
- Latest `Microsoft.Azure.Cosmos.Direct` files from msdata CosmosDB repo
### Changes Include
- - Merged latest `master` branch into `msdata/direct`
+ - Merged latest `main` branch into `msdata/direct`
- Updated `Microsoft.Azure.Cosmos.Direct` files via `msdata_sync.ps1`
- - Resolved merge conflicts (accepted master changes)
+ - Resolved merge conflicts (accepted main changes)
- Build validated: `dotnet build` passes
## Type of change
@@ -409,8 +409,8 @@ helper_script:
```yaml
merge_conflicts:
directory_build_props:
- description: "Version number conflicts between master and msdata/direct"
- resolution: "Accept master version numbers, they are the source of truth"
+ description: "Version number conflicts between main and msdata/direct"
+ resolution: "Accept main version numbers, they are the source of truth"
csproj_files:
description: "Project file conflicts from both sides adding references"
@@ -435,7 +435,7 @@ build_failures:
duplicate_definitions:
symptom: "error CS0111: Type already defines a member"
causes:
- - "Same file exists in both master and direct"
+ - "Same file exists in both main and direct"
fix: "Remove the duplicate, keep the direct version"
api_incompatibility:
@@ -473,8 +473,8 @@ Reference these PRs for expected format and scope:
| PR | Title | Date | Scope |
|----|-------|------|-------|
-| [#5612](https://github.com/Azure/azure-cosmos-dotnet-v3/pull/5612) | [Internal] Direct package: Adds msdata/direct update from master | Feb 2026 | 545 files, 76K additions |
-| [#3776](https://github.com/Azure/azure-cosmos-dotnet-v3/pull/3776) | [Internal] Msdata/Direct: Refactors msdata/direct with v3 master and Direct v3.30.4 | Mar 2023 | 155 files, 13K additions |
+| [#5612](https://github.com/Azure/azure-cosmos-dotnet-v3/pull/5612) | [Internal] Direct package: Adds msdata/direct update from main | Feb 2026 | 545 files, 76K additions |
+| [#3776](https://github.com/Azure/azure-cosmos-dotnet-v3/pull/3776) | [Internal] Msdata/Direct: Refactors msdata/direct with v3 main and Direct v3.30.4 | Mar 2023 | 155 files, 13K additions |
| [#3726](https://github.com/Azure/azure-cosmos-dotnet-v3/pull/3726) | [Internal] Msdata/Direct: Refactors msdata branch with latest v3 and direct release | Feb 2023 | 361 files, 27K additions |
---
diff --git a/.github/agents/release-copilot-agent.agent.md b/.github/agents/release-copilot-agent.agent.md
index 250e6ddcba..cb8c48377e 100644
--- a/.github/agents/release-copilot-agent.agent.md
+++ b/.github/agents/release-copilot-agent.agent.md
@@ -124,17 +124,17 @@ Example: If releasing `3.58.0`:
### 2.2 Determine the Previous Release Version
-Read `Directory.Build.props` on the `master` branch — the current `ClientOfficialVersion` value represents the last released version. Use this to determine which PRs to include in the changelog.
+Read `Directory.Build.props` on the `main` branch — the current `ClientOfficialVersion` value represents the last released version. Use this to determine which PRs to include in the changelog.
### 2.3 Generate Changelog
#### 2.3.1 List Merged PRs Since Last Release
-Use the GitHub MCP server or `gh` CLI to list all merged PRs to `master` since the last release:
+Use the GitHub MCP server or `gh` CLI to list all merged PRs to `main` since the last release:
```powershell
# Find the merge commit date of the last release PR, or the date of the last release tag
-gh pr list --repo Azure/azure-cosmos-dotnet-v3 --state merged --base master --limit 200 --json number,title,mergedAt
+gh pr list --repo Azure/azure-cosmos-dotnet-v3 --state merged --base main --limit 200 --json number,title,mergedAt
```
Or use the GitHub MCP `list_pull_requests` tool to fetch merged PRs.
@@ -256,7 +256,7 @@ git checkout -b users//release-X.Y.Z
Where `` is the GitHub username obtained above (e.g., `users/nalutripician/release-3.58.0`).
-> **🚫 NEVER push directly to `master`.** Always create a feature branch and PR.
+> **🚫 NEVER push directly to `main`.** Always create a feature branch and PR.
#### 2.6.2 Commit Changes
@@ -323,7 +323,7 @@ After the PR is approved and merged:
1. **Create release branch:**
```powershell
- git checkout master && git pull
+ git checkout main && git pull
git checkout -b releases/X.Y.Z
git push origin releases/X.Y.Z
```
@@ -465,13 +465,13 @@ Present the existing versions and **ask the user to confirm the target hotfix ve
> **Existing versions for 3.Y: 3.Y.0, 3.Y.1**
> **What version should this hotfix target?** (suggested: 3.Y.2)
-After the user confirms, update versioning accordingly. The preview version is calculated relative to the **hotfix base version**, not from `master`:
+After the user confirms, update versioning accordingly. The preview version is calculated relative to the **hotfix base version**, not from `main`:
- `ClientOfficialVersion` → user-confirmed version (e.g., `3.55.2`)
- `ClientPreviewVersion` → hotfix minor + 1, patch 0 (e.g., `3.56.0`)
- `ClientPreviewSuffixVersion` → `preview.{hotfix_patch}` (e.g., `preview.2`)
-> **⚠️ Important:** Do NOT use the `master` branch preview version. The hotfix preview version is always derived from the hotfix's own minor version.
+> **⚠️ Important:** Do NOT use the `main` branch preview version. The hotfix preview version is always derived from the hotfix's own minor version.
**Examples:**
@@ -578,24 +578,24 @@ git diff --no-index "Microsoft.Azure.Cosmos\contracts\API_PREV_PREVIEW.txt" "Mic
**Capture both diffs — they must be included in the PR description.**
-### 3.9 Ensure Master Sync
+### 3.9 Ensure Main Sync
-**Important:** Contract file changes and changelog updates must also be reflected on `master`.
+**Important:** Contract file changes and changelog updates must also be reflected on `main`.
-1. Create a working branch from `master` for the sync PR:
+1. Create a working branch from `main` for the sync PR:
```powershell
- git checkout master && git pull
- git checkout -b users//hotfix-X.Y.Z+1-master-sync
+ git checkout main && git pull
+ git checkout -b users//hotfix-X.Y.Z+1-main-sync
```
2. Add the following to the branch:
- The new GA API contract file (`API_X.Y.Z+1.txt`)
- The new preview API contract file (`API_X.Y+1.0-preview.Z+1.txt`)
- Changelog entries for the hotfix version
-3. Create a PR targeting `master`:
+3. Create a PR targeting `main`:
```powershell
- gh pr create --base master --title "[Internal] Contracts: Adds hotfix X.Y.Z+1 contract files and changelog" --body "Syncs master with hotfix release X.Y.Z+1 contract files and changelog entries."
+ gh pr create --base main --title "[Internal] Contracts: Adds hotfix X.Y.Z+1 contract files and changelog" --body "Syncs main with hotfix release X.Y.Z+1 contract files and changelog entries."
```
-4. This ensures `master` stays in sync with released versions
+4. This ensures `main` stays in sync with released versions
### 3.10 Create Hotfix PR
@@ -626,7 +626,7 @@ gh pr create --base releases/X.Y.Z+1 --title "Hotfix: Adds version X.Y.Z+1" --bo
### Checklist
- [ ] Cherry-picks verified
- [ ] Contract files (GA and preview) added to hotfix branch
-- [ ] Contract files (GA and preview) synced to master (separate PR)
+- [ ] Contract files (GA and preview) synced to main (separate PR)
- [ ] Kiran sign-off obtained
"
```
@@ -878,7 +878,7 @@ Then create a new branch and PR:
1. Create a new branch:
```powershell
- git checkout master && git pull
+ git checkout main && git pull
git checkout -b users//changelog-fix-X.Y.Z
```
2. Edit `changelog.md` to add the missed entries under the existing X.Y.Z version heading
@@ -888,7 +888,7 @@ Then create a new branch and PR:
git add changelog.md
git commit -m "Changelog: Adds missed PRs to X.Y.Z changelog"
git push origin users//changelog-fix-X.Y.Z
- gh pr create --base master --title "Changelog: Adds missed PRs to X.Y.Z release notes" --body "## Changelog Fix for X.Y.Z
+ gh pr create --base main --title "Changelog: Adds missed PRs to X.Y.Z release notes" --body "## Changelog Fix for X.Y.Z
### Added PRs
- #PR1: Title
diff --git a/.github/copilot-instructions.md b/.github/copilot-instructions.md
index 9295c2c702..9c14594689 100644
--- a/.github/copilot-instructions.md
+++ b/.github/copilot-instructions.md
@@ -40,7 +40,7 @@ Purpose: quick, actionable context so an AI coding assistant can be immediately
- `Microsoft.Azure.Cosmos.Samples/` — minimal runnable samples for usage patterns
- **How AI should produce code/changes here**:
- - **🚫 HARD RULE: NEVER push directly to `master` — NO EXCEPTIONS.** Always create a feature branch and submit a pull request. This rule cannot be overridden.
+ - **🚫 HARD RULE: NEVER push directly to `main` — NO EXCEPTIONS.** Always create a feature branch and submit a pull request. This rule cannot be overridden.
- **Branch naming**: Always use the format `users//feature-name` (e.g. `users/ntripician/fix-retry-logic`). Do not use other conventions like `feature/`, `fix/`, or `dev/`.
- **PR title format**: All pull request titles **must** match the CI lint regex: `(\[Internal\]|\[v4\] )?.{3}.+: (Adds|Fixes|Refactors|Removes) .{3}.+`. The format is `[Optional Prefix] Category: Verb Description` where the verb is one of `Adds`, `Fixes`, `Refactors`, or `Removes`. Optional prefixes are `[Internal]` (for PRs with no customer impact) or `[v4]` (for v4-specific changes). Examples:
- `Diagnostics: Adds GetElapsedClientLatency to CosmosDiagnostics`
@@ -64,8 +64,8 @@ Purpose: quick, actionable context so an AI coding assistant can be immediately
- Three modes: **Minor Mode** (full GA + Preview release), **Hotfix Mode** (cherry-pick patch release on any previous version), and **Add Missed PRs** (add PRs that were missed in a previous changelog).
- In VS Code Copilot Chat: `@ReleaseCopilotAgent start minor`, `@ReleaseCopilotAgent start hotfix`, or `@ReleaseCopilotAgent add missed PRs`.
- In the Copilot CLI: describe the task naturally (e.g., "I want to start a minor release", "start hotfix", or "I need to add missed PRs to a release"). The agent instructions are loaded automatically via this file.
- - **MsdataDirectSyncAgent** (`.github/agents/msdata-direct-sync-agent.agent.md`) — Orchestrates syncing the msdata/direct branch with the latest v3 master and msdata direct codebase.
+ - **MsdataDirectSyncAgent** (`.github/agents/msdata-direct-sync-agent.agent.md`) — Orchestrates syncing the msdata/direct branch with the latest v3 main and msdata direct codebase.
- In VS Code Copilot Chat: `@MsdataDirectSyncAgent sync msdata/direct`.
- - In the Copilot CLI: describe the task naturally (e.g., "sync the msdata/direct branch with master").
+ - In the Copilot CLI: describe the task naturally (e.g., "sync the msdata/direct branch with main").
If anything here is unclear or you want the file to include additional examples (specific files, common refactor targets, or typical PR reviewers), tell me what to add and I will iterate.
diff --git a/.gitignore b/.gitignore
index ff02fec1b5..a02d350b97 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,7 +1,7 @@
## Ignore Visual Studio temporary files, build results, and
## files generated by popular Visual Studio add-ons.
##
-## Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore
+## Get latest from https://github.com/github/gitignore/blob/main/VisualStudio.gitignore
# User-specific files
*.suo
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index e3cb1edc66..5a4ed58a6e 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -93,7 +93,7 @@ When evaluating adding new tests, please search in the existing test files if th
1. Create a branch for your contribution (if you are an external contributor, on your own fork).
1. Make sure your work is adding [tests](#tests) as required (either unit and/or emulator tests depending on the scope of the work).
-1. Send a Pull Request to the master branch once your work is ready to be reviewed.
+1. Send a Pull Request to the main branch once your work is ready to be reviewed.
1. The CI pipeline will start any required tests. If you are an external contributor, a team member will start the verification once we confirm the nature of the contribution through a `/azp run` comment in your Pull Request.
1. Look for review comments and attempt to answer/address them to the best of your ability.
1. Check for [test failures](#test-failures) and address them if they are not transient.
@@ -128,7 +128,7 @@ Or all through `Re-run failed checks` on the top right corner:
## Usage of Cosmos DB Emulator for running unit tests
- - The same version of the emulator used in the CI pipelines can be downloaded [here](https://aka.ms/cosmosdb-emulator)
-- More information about how ro use the emulator for development is documented [here](https://github.com/Azure/azure-documentdb-dotnet/blob/master/docs/documentdb-nosql-local-emulator.md)
+- More information about how ro use the emulator for development is documented [here](https://github.com/Azure/azure-documentdb-dotnet/blob/main/docs/documentdb-nosql-local-emulator.md)
- You can start the emulator with same parameters as the emulator unit tests in the CI pipeline via `.\CosmosDB.Emulator.exe /DisableRateLimiting /PartitionCount=100 /Consistency=Strong /enableRio /EnablePreview /EnableAadAuthentication /EnableSqlComputeEndpoint`
## Troubleshooting
diff --git a/README.md b/README.md
index 861235223a..294553b194 100644
--- a/README.md
+++ b/README.md
@@ -41,17 +41,17 @@ For available versions, see [SDK versioning](./docs/versioning.md).
## Useful links
- [Get Started APP](https://docs.microsoft.com/azure/cosmos-db/sql-api-get-started)
-- [GitHub samples](https://github.com/Azure/azure-cosmos-dotnet-v3/tree/master/Microsoft.Azure.Cosmos.Samples)
+- [GitHub samples](https://github.com/Azure/azure-cosmos-dotnet-v3/tree/main/Microsoft.Azure.Cosmos.Samples)
- [SDK Best practices](https://docs.microsoft.com/azure/cosmos-db/sql/best-practice-dotnet)
-- [MultiMaster samples](https://github.com/markjbrown/azure-cosmosdb-dotnet/tree/master/samples/MultiMaster)
+- [MultiMaster samples](https://github.com/markjbrown/azure-cosmosdb-dotnet/tree/main/samples/MultiMaster)
- [Resource Model of Azure Cosmos DB Service](https://docs.microsoft.com/azure/cosmos-db/sql-api-resources)
- [Cosmos DB Resource URI](https://docs.microsoft.com/rest/api/documentdb/documentdb-resource-uri-syntax-for-rest)
- [Partitioning](https://docs.microsoft.com/azure/cosmos-db/partition-data)
- [Introduction to Azure Cosmos DB for NoSQL queries](https://docs.microsoft.com/azure/cosmos-db/sql-api-sql-query)
- [SDK API](https://docs.microsoft.com/dotnet/api/microsoft.azure.cosmos?view=azure-dotnet)
-- [Using emulator](https://github.com/Azure/azure-documentdb-dotnet/blob/master/docs/documentdb-nosql-local-emulator.md)
-- [Capture traces](https://github.com/Azure/azure-documentdb-dotnet/blob/master/docs/documentdb-sdk_capture_etl.md)
-- [Release notes](https://github.com/Azure/azure-cosmos-dotnet-v3/blob/master/changelog.md)
+- [Using emulator](https://github.com/Azure/azure-documentdb-dotnet/blob/main/docs/documentdb-nosql-local-emulator.md)
+- [Capture traces](https://github.com/Azure/azure-documentdb-dotnet/blob/main/docs/documentdb-sdk_capture_etl.md)
+- [Release notes](https://github.com/Azure/azure-cosmos-dotnet-v3/blob/main/changelog.md)
- [Diagnose and troubleshooting](https://docs.microsoft.com/azure/cosmos-db/troubleshoot-dot-net-sdk)
## Microsoft Open Source Code of Conduct
diff --git a/changelog.md b/changelog.md
index 9c12398bd7..a0ad03bf50 100644
--- a/changelog.md
+++ b/changelog.md
@@ -2,7 +2,7 @@
The **minimum recommended version is [3.57.0](#3.57.0)**.
-Make sure that your applications, when using the .NET V3 SDK, are using at least the version described here to have all the critical fixes. With the release of [3.47.0](#3.47.0), it is now best practice to include a cross regional hedging availability strategy when using the Azure Cosmos DB .NET SDK. For more information about cross regional hedging, see [here](https://github.com/Azure/azure-cosmos-dotnet-v3/blob/master/docs/Cross%20Region%20Request%20Hedging.md).
+Make sure that your applications, when using the .NET V3 SDK, are using at least the version described here to have all the critical fixes. With the release of [3.47.0](#3.47.0), it is now best practice to include a cross regional hedging availability strategy when using the Azure Cosmos DB .NET SDK. For more information about cross regional hedging, see [here](https://github.com/Azure/azure-cosmos-dotnet-v3/blob/main/docs/Cross%20Region%20Request%20Hedging.md).
Any known issues detected on that version are listed in the [known issues](#known-issues) section.
diff --git a/docs/Cross Region Request Hedging.md b/docs/Cross Region Request Hedging.md
index db5aae2cad..9ee24d513a 100644
--- a/docs/Cross Region Request Hedging.md
+++ b/docs/Cross Region Request Hedging.md
@@ -4,7 +4,7 @@ The Cross Region Hedging Availability Strategy is a feature in the Cosmos SDK th
When the cross region hedging strategy is enabled, the SDK will send the first request to the primary region. If there is no response from the backend before the threshold time, then the SDK will begin sending hedged requests to the regions in order of the preferred regions list. After the first hedged request is sent out, the hedged requests will continue to be fired off one by one after waiting for the time specified in the threshold step. Once a response is received from one of the requests, the availability strategy will check to see if the result is considered final. If the result is final, then it is returned. If not, the SDK will skip the remaining threshold/threshold step time and send out the next hedged request. If all hedged requests are sent out and no final response is received, the SDK will return the last response it received.
-The `AvailabilityStrategy` operates on the `RequestInvokerHandler` level meaning that each hedged request will go through its own [handler pipeline](https://github.com/Azure/azure-cosmos-dotnet-v3/blob/master/docs/SdkDesign.md#handler-pipeline), including the `ClientRetryPolicy`. This means that the hedged requests will be retried independently of each other. Note that the hedged requests are restricted to the region they are sent out in so no cross region retries will be made, only local retries. The primary request however, will behave as a normal request.
+The `AvailabilityStrategy` operates on the `RequestInvokerHandler` level meaning that each hedged request will go through its own [handler pipeline](https://github.com/Azure/azure-cosmos-dotnet-v3/blob/main/docs/SdkDesign.md#handler-pipeline), including the `ClientRetryPolicy`. This means that the hedged requests will be retried independently of each other. Note that the hedged requests are restricted to the region they are sent out in so no cross region retries will be made, only local retries. The primary request however, will behave as a normal request.
> **Note:** Hedging requires at least two available regions. If only a single region endpoint is available, the SDK will skip hedging and send the request normally.
@@ -98,7 +98,7 @@ CosmosClient client = new CosmosClient(
## Diagnostics
-In the diagnostics data there are three areas of note that will appear when hedging occurs: `Hedge Config`, `Hedge Context`, and `Response Region`. `Hedge Config` shows the configured availability strategy parameters, including the threshold, threshold step, and whether hedging for write requests is enabled. `Hedge Context` lists all the regions that requests were sent to. `Response Region` indicates which region's response was ultimately returned to the caller. A full example of a hedged request can be seen [here](https://github.com/Azure/azure-cosmos-dotnet-v3/tree/master/Microsoft.Azure.Cosmos.Samples/Usage/Hedging/ReadRequestDiagnosticsExample.json).
+In the diagnostics data there are three areas of note that will appear when hedging occurs: `Hedge Config`, `Hedge Context`, and `Response Region`. `Hedge Config` shows the configured availability strategy parameters, including the threshold, threshold step, and whether hedging for write requests is enabled. `Hedge Context` lists all the regions that requests were sent to. `Response Region` indicates which region's response was ultimately returned to the caller. A full example of a hedged request can be seen [here](https://github.com/Azure/azure-cosmos-dotnet-v3/tree/main/Microsoft.Azure.Cosmos.Samples/Usage/Hedging/ReadRequestDiagnosticsExample.json).
```json
"Summary": {
diff --git a/docs/LocalQuorum.md b/docs/LocalQuorum.md
index a971955006..a4fa47ff90 100644
--- a/docs/LocalQuorum.md
+++ b/docs/LocalQuorum.md
@@ -27,7 +27,7 @@ It involves three stages
#### Create CosmosDB account with Eventual/ConsistentPrefix/Session consistency
#### Enabling/opt-in ability to upgrade consistency level
-SDK version: MA [3.35.1](https://github.com/Azure/azure-cosmos-dotnet-v3/blob/master/changelog.md#-3351---2023-06-27) or [minimum recommended version](https://github.com/Azure/azure-cosmos-dotnet-v3/blob/master/changelog.md#-recommended-version)
+SDK version: MA [3.35.1](https://github.com/Azure/azure-cosmos-dotnet-v3/blob/main/changelog.md#-3351---2023-06-27) or [minimum recommended version](https://github.com/Azure/azure-cosmos-dotnet-v3/blob/main/changelog.md#-recommended-version)
```C#
CosmosClientOptions clientOptions = new CosmosClientOptions();
diff --git a/docs/builds-and-pipelines.md b/docs/builds-and-pipelines.md
index 0747982783..f514f34b50 100644
--- a/docs/builds-and-pipelines.md
+++ b/docs/builds-and-pipelines.md
@@ -29,7 +29,7 @@ This pipeline executes on Azure Pipelines as [dotnet-v3-release](https://cosmos-
## Nightly release
-[azure-pipelines-nightly.yml](../azure-pipelines-nightly.yml) is a scheduled run that executes every day at 0:00 UTC and produces two Nuget packages with the content on the `master` branch:
+[azure-pipelines-nightly.yml](../azure-pipelines-nightly.yml) is a scheduled run that executes every day at 0:00 UTC and produces two Nuget packages with the content on the `main` branch:
* A non-preview package with versioning `Microsoft.Azure.Cosmos.X.Y.Z-nightly-DATE` where `X.Y.Z` is the current version from [Directory.Build.Props](../Directory.Build.props) and `DATE` is the current date in `MMDDYYYY` format.
* A preview package with versioning `Microsoft.Azure.Cosmos.X.Y.Z-preview-nightly-DATE` where `X.Y.Z` is the current version from [Directory.Build.Props](../Directory.Build.props) and `DATE` is the current date in `MMDDYYYY` format.
@@ -43,7 +43,7 @@ This pipeline executes on Azure Pipelines as [dotnet-v3-nightly](https://cosmos-
## Docker image for CTL workloads
-[azure-pipelines-ctl-publishing.yml](../azure-pipelines-ctl-publishing.yml) executes every time a change is merged into `master` and it will:
+[azure-pipelines-ctl-publishing.yml](../azure-pipelines-ctl-publishing.yml) executes every time a change is merged into `main` and it will:
* Generate [docker config files](../Microsoft.Azure.Cosmos.Samples/Tools/CTL/Dockerfile).
* Copy the [executable shell file](../Microsoft.Azure.Cosmos.Samples/Tools/CTL/run_ctl.sh).
diff --git a/docs/caches.md b/docs/caches.md
index 91f5eea16f..3af3e16e55 100644
--- a/docs/caches.md
+++ b/docs/caches.md
@@ -30,8 +30,8 @@ flowchart LR
end
end
subgraph AddressCaches
- GAC1[GatewayAddressCache/R1]
- GACN[GatewayAddressCache/RN]
+ GAC1[GatewayAddressCache/R1]
+ GACN[GatewayAddressCache/RN]
GAC1 --> |NonBlockingAsyncCache| CDBR1_GW
GAC1 -.-> CDBR1_BE
diff --git a/docs/observability.md b/docs/observability.md
index a762879b26..996573ef12 100644
--- a/docs/observability.md
+++ b/docs/observability.md
@@ -28,9 +28,9 @@ flowchart TD
classDef orange fill:#f96
classDef blue fill:#6fa8dc
subgraph ClientContextCore
- OpenTelemetryRecorderFactory --> CheckFeatureFlag{isDistributedTracing Enabled?}
+ OpenTelemetryRecorderFactory --> CheckFeatureFlag{isDistributedTracing Enabled?}
CheckFeatureFlag --> |Yes| CreateActivity(Start an Activity or Child activity
with preloaded attributes)
- CreateActivity --> HandlerPipeline{Handler Pipeline}
+ CreateActivity --> HandlerPipeline{Handler Pipeline}
GetResponse --> TriggerDispose(Trigger Dispose of Diagnostic Scope)
subgraph Dispose
TriggerDispose --> CheckLatencyThreshold{Is high latency/errored response?}
@@ -99,7 +99,7 @@ CosmosClientOptions options = new CosmosClientOptions()
#### Sample
-For Sample refer [this](https://github.com/Azure/azure-cosmos-dotnet-v3/tree/master/Microsoft.Azure.Cosmos.Samples/Usage/OpenTelemetry)
+For Sample refer [this](https://github.com/Azure/azure-cosmos-dotnet-v3/tree/main/Microsoft.Azure.Cosmos.Samples/Usage/OpenTelemetry)
### Metrics
@@ -229,19 +229,19 @@ When configuring the `OTEL_SEMCONV_STABILITY_OPT_IN` environment variable, the f
1. **`database`**:
- The SDK emits all attributes as per the OpenTelemetry database semantic conventions outlined [here](https://opentelemetry.io/docs/specs/semconv/database/cosmosdb/).
- - Refer to the [list of OpenTelemetry attributes emitted by the SDK](https://github.com/Azure/azure-cosmos-dotnet-v3/blob/master/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryAttributeKeys.cs).
+ - Refer to the [list of OpenTelemetry attributes emitted by the SDK](https://github.com/Azure/azure-cosmos-dotnet-v3/blob/main/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryAttributeKeys.cs).
2. **`database/dup`**:
- The SDK emits attributes that follow both OpenTelemetry database semantic conventions, available [here](https://opentelemetry.io/docs/specs/semconv/database/cosmosdb/), and additional attributes supported by the Classic Application Insights SDK.
- - For a complete attribute list, refer to the OpenTelemetry attributes [here](https://github.com/Azure/azure-cosmos-dotnet-v3/blob/master/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryAttributeKeys.cs) and Classic Application Insights attributes [here](https://github.com/Azure/azure-cosmos-dotnet-v3/blob/master/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/AppInsightClassicAttributeKeys.cs).
+ - For a complete attribute list, refer to the OpenTelemetry attributes [here](https://github.com/Azure/azure-cosmos-dotnet-v3/blob/main/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryAttributeKeys.cs) and Classic Application Insights attributes [here](https://github.com/Azure/azure-cosmos-dotnet-v3/blob/main/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/AppInsightClassicAttributeKeys.cs).
3. **`default`**:
- This mode functions similarly to `database`, emitting attributes that adhere to the OpenTelemetry database semantic conventions.
- - View the full [attribute list emitted by the SDK](https://github.com/Azure/azure-cosmos-dotnet-v3/blob/master/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryAttributeKeys.cs).
+ - View the full [attribute list emitted by the SDK](https://github.com/Azure/azure-cosmos-dotnet-v3/blob/main/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/OpenTelemetryAttributeKeys.cs).
4. **`appinsightssdk`**:
- The SDK emits only those attributes supported by the Classic Application Insights SDK.
- - For a comprehensive list of attributes, refer [here](https://github.com/Azure/azure-cosmos-dotnet-v3/blob/master/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/AppInsightClassicAttributeKeys.cs).
+ - For a comprehensive list of attributes, refer [here](https://github.com/Azure/azure-cosmos-dotnet-v3/blob/main/Microsoft.Azure.Cosmos/src/Telemetry/OpenTelemetry/AppInsightClassicAttributeKeys.cs).
Choose the appropriate mode to align with your telemetry requirements.
diff --git a/docs/sync_up_msdata_direct.md b/docs/sync_up_msdata_direct.md
index 28d2ffb425..5fa2df5f96 100644
--- a/docs/sync_up_msdata_direct.md
+++ b/docs/sync_up_msdata_direct.md
@@ -29,8 +29,8 @@ Before covering the sync-up process in detail, please follow the below steps to
- Clone the CosmosDB repository in the local environment, using the CosmosDB onboarding guide. Please note, building the entire repository is not required for the sync-up process.
-- Navigate to the cloned `CosmosDB` directory and check out the following branch, `master` using the below git commands:
- - git pull && git checkout master
+- Navigate to the cloned `CosmosDB` directory and check out the following branch, `main` using the below git commands:
+ - git pull && git checkout main
## Steps Required to Update msdata direct Repo
@@ -42,11 +42,11 @@ The first step to sync up the `msdata/direct` repo is to create a feature branch
### Merging the cosmos db v3 Code into Feature Branch.
-The next step is to port the latest `master` branch code into the newly created feature branch. Please see the below git commands to perform this action:
+The next step is to port the latest `main` branch code into the newly created feature branch. Please see the below git commands to perform this action:
-- Make sure the `master` branch is up-to-date.
-- Stay on the newly created feature branch `users//update_msdata_direct_` and run `git merge master`.
-- There are likely to be conflicts during the merge. If that happens, we will need to resolve the conflicts gracefully by accepting the incoming `master` branch changes.
+- Make sure the `main` branch is up-to-date.
+- Stay on the newly created feature branch `users//update_msdata_direct_` and run `git merge main`.
+- There are likely to be conflicts during the merge. If that happens, we will need to resolve the conflicts gracefully by accepting the incoming `main` branch changes.
### Pick the Required Microsoft Azure Cosmos.Direct files into `msdata/direct` repo.
@@ -89,9 +89,9 @@ Once the feature branch builds successfully, it's time to submit the PR to `msda
## Sample Pull Requests to Sync-up msdata direct
-- [[Internal] Direct package: Adds msdata/direct update from master](https://github.com/Azure/azure-cosmos-dotnet-v3/pull/5612)
+- [[Internal] Direct package: Adds msdata/direct update from main](https://github.com/Azure/azure-cosmos-dotnet-v3/pull/5612)
- [[Internal] Msdata/Direct: Refactors msdata branch with latest v3 and direct release](https://github.com/Azure/azure-cosmos-dotnet-v3/pull/3726)
-- [[Internal] Msdata/Direct: Refactors msdata/direct branch with latest v3 master and Cosmos.Direct v3.30.4](https://github.com/Azure/azure-cosmos-dotnet-v3/pull/3776)
+- [[Internal] Msdata/Direct: Refactors msdata/direct branch with latest v3 main and Cosmos.Direct v3.30.4](https://github.com/Azure/azure-cosmos-dotnet-v3/pull/3776)
## Automated Workflow (Recommended)
@@ -104,10 +104,10 @@ Use the Copilot agent at [`.github/agents/msdata-direct-sync-agent.agent.md`](..
```
Follow the msdata/direct sync agent plan in .github/agents/msdata-direct-sync-agent.agent.md
-Sync the msdata/direct branch with the latest v3 master and msdata direct codebase.
+Sync the msdata/direct branch with the latest v3 main and msdata direct codebase.
```
-The agent handles: environment validation, branch creation, master merge, conflict resolution, msdata file sync, build validation, and PR creation.
+The agent handles: environment validation, branch creation, main merge, conflict resolution, msdata file sync, build validation, and PR creation.
### Option 2: PowerShell Helper Script
diff --git a/templates/build-preview.yml b/templates/build-preview.yml
index 856110d040..76678f3b8b 100644
--- a/templates/build-preview.yml
+++ b/templates/build-preview.yml
@@ -72,7 +72,7 @@ jobs:
arguments: -p:Optimize=true -p:IsPreview=true;SdkProjectRef=true
versioningScheme: OFF
- # Parity check: build Microsoft.Azure.Cosmos.Encryption against master SDK
+ # Parity check: build Microsoft.Azure.Cosmos.Encryption against main SDK
# source WITHOUT defining SDKPROJECTREF. This matches the exact preprocessor
# surface the shipped NuGet package is built with (PREVIEW on, SDKPROJECTREF
# off) while still linking against the latest SDK abstractions. Any new
@@ -81,7 +81,7 @@ jobs:
# instead of a runtime TypeLoadException for customers after a future SDK
# NuGet release. See PR #5783 (SemanticRerankAsync) for a concrete example.
- task: DotNetCoreCLI@2
- displayName: Build Microsoft.Azure.Cosmos.Encryption (NuGet-surface parity vs master SDK source)
+ displayName: Build Microsoft.Azure.Cosmos.Encryption (NuGet-surface parity vs main SDK source)
inputs:
command: build
configuration: $(parameters.BuildConfiguration)
@@ -159,17 +159,17 @@ jobs:
arguments: -p:Optimize=true -p:IsPreview=true;SdkProjectRef=true
versioningScheme: OFF
- # Parity check: build Microsoft.Azure.Cosmos.Encryption.Custom against master
+ # Parity check: build Microsoft.Azure.Cosmos.Encryption.Custom against main
# SDK source WITHOUT defining SDKPROJECTREF. This matches the exact
# preprocessor surface the shipped NuGet package is built with (PREVIEW on,
# SDKPROJECTREF off, so SDKPROJECTREF-gated overrides in EncryptionContainer
# are stripped) while still linking against the latest SDK abstractions from
- # master. Any new abstract member on Container under #if PREVIEW that lacks
+ # main. Any new abstract member on Container under #if PREVIEW that lacks
# an unconditional override in EncryptionContainer will produce a CS0534
# compile error here instead of a runtime TypeLoadException for customers
# after a future SDK NuGet release. See PR #5783 (SemanticRerankAsync).
- task: DotNetCoreCLI@2
- displayName: Build Microsoft.Azure.Cosmos.Encryption.Custom (NuGet-surface parity vs master SDK source)
+ displayName: Build Microsoft.Azure.Cosmos.Encryption.Custom (NuGet-surface parity vs main SDK source)
inputs:
command: build
configuration: $(parameters.BuildConfiguration)
diff --git a/templates/static-tools-encryption-custom.yml b/templates/static-tools-encryption-custom.yml
index 65b1c6a256..9098a63169 100644
--- a/templates/static-tools-encryption-custom.yml
+++ b/templates/static-tools-encryption-custom.yml
@@ -30,12 +30,12 @@ jobs:
# repo (SdkProjectRef=True / SDKPROJECTREF) with IsPreview=true so the SDK
# source compiles with the same preview surface that the Encryption.Custom
# package references via NuGet. This catches mismatches between the
- # Encryption.Custom package and the latest SDK surface in master (for
+ # Encryption.Custom package and the latest SDK surface in main (for
# example, new abstract members on Container) that would otherwise only
# surface at customer runtime as TypeLoadException once a newer SDK NuGet is
# released. See PR #5783 for a concrete example (SemanticRerankAsync).
- task: DotNetCoreCLI@2
- displayName: Build Microsoft.Azure.Cosmos.Encryption.Custom (SDKREF - master SDK source)
+ displayName: Build Microsoft.Azure.Cosmos.Encryption.Custom (SDKREF - main SDK source)
inputs:
command: build
nugetConfigPath: NuGet.config
@@ -43,17 +43,17 @@ jobs:
arguments: '-p:Optimize=true -p:IsPreview=true -p:SdkProjectRef=true --configuration Release'
versioningScheme: OFF
- # Parity check: build against master SDK source WITHOUT defining SDKPROJECTREF.
+ # Parity check: build against main SDK source WITHOUT defining SDKPROJECTREF.
# This matches the exact preprocessor surface the shipped NuGet package is
# built with (PREVIEW on, SDKPROJECTREF off, so SDKPROJECTREF-gated overrides
# in EncryptionContainer are stripped) while still linking against the latest
- # SDK abstractions from master. Any new abstract member on Container under
+ # SDK abstractions from main. Any new abstract member on Container under
# #if PREVIEW that lacks an unconditional override in EncryptionContainer
# will produce a CS0534 compile error here instead of a runtime
# TypeLoadException for customers after a future SDK NuGet release. This is
# the exact class of defect addressed by PR #5783 (SemanticRerankAsync).
- task: DotNetCoreCLI@2
- displayName: Build Microsoft.Azure.Cosmos.Encryption.Custom (NuGet-surface parity vs master SDK source)
+ displayName: Build Microsoft.Azure.Cosmos.Encryption.Custom (NuGet-surface parity vs main SDK source)
inputs:
command: build
nugetConfigPath: NuGet.config
diff --git a/templates/static-tools-encryption.yml b/templates/static-tools-encryption.yml
index 217126a276..c545f16303 100644
--- a/templates/static-tools-encryption.yml
+++ b/templates/static-tools-encryption.yml
@@ -28,11 +28,11 @@ jobs:
# Build using a ProjectReference to the Microsoft.Azure.Cosmos source in this
# repo (SdkProjectRef=True / SDKPROJECTREF). This catches mismatches between
- # the Encryption package and the latest SDK surface in master (for example,
+ # the Encryption package and the latest SDK surface in main (for example,
# new abstract members on Container) that would otherwise only surface at
# customer runtime as TypeLoadException once a newer SDK NuGet is released.
- task: DotNetCoreCLI@2
- displayName: Build Microsoft.Azure.Cosmos.Encryption (SDKREF - master SDK source)
+ displayName: Build Microsoft.Azure.Cosmos.Encryption (SDKREF - main SDK source)
inputs:
command: build
nugetConfigPath: NuGet.config
@@ -40,7 +40,7 @@ jobs:
arguments: '-p:Optimize=true -p:IsPreview=true -p:SdkProjectRef=true --configuration Release'
versioningScheme: OFF
- # Parity check: build against master SDK source WITHOUT defining SDKPROJECTREF.
+ # Parity check: build against main SDK source WITHOUT defining SDKPROJECTREF.
# This matches the exact preprocessor surface the shipped NuGet package is
# built with (PREVIEW on, SDKPROJECTREF off) while still linking against the
# latest SDK abstractions. Any new abstract member on Container that is not
@@ -48,7 +48,7 @@ jobs:
# CS0534 compile error here instead of a runtime TypeLoadException for
# customers after a future SDK NuGet release.
- task: DotNetCoreCLI@2
- displayName: Build Microsoft.Azure.Cosmos.Encryption (NuGet-surface parity vs master SDK source)
+ displayName: Build Microsoft.Azure.Cosmos.Encryption (NuGet-surface parity vs main SDK source)
inputs:
command: build
nugetConfigPath: NuGet.config
diff --git a/tools/msdata-direct-sync-helper.ps1 b/tools/msdata-direct-sync-helper.ps1
index 0414f12e67..2413876486 100644
--- a/tools/msdata-direct-sync-helper.ps1
+++ b/tools/msdata-direct-sync-helper.ps1
@@ -1,12 +1,12 @@
<#
.SYNOPSIS
- Helper script for syncing the msdata/direct branch with latest v3 master and msdata CosmosDB repo.
+ Helper script for syncing the msdata/direct branch with latest v3 main and msdata CosmosDB repo.
.DESCRIPTION
Automates the mechanical parts of the msdata/direct sync workflow:
- Validates prerequisites (git, dotnet CLI, gh CLI)
- Creates feature branch with correct naming convention
- - Merges master into the feature branch
+ - Merges main into the feature branch
- Configures and runs msdata_sync.ps1
- Runs build validation
- Optionally creates a PR
@@ -199,20 +199,20 @@ function Invoke-SetupPhase {
}
# ============================================================================
-# Phase: Branch — Create feature branch and merge master
+# Phase: Branch — Create feature branch and merge main
# ============================================================================
function Invoke-BranchPhase {
- Write-Phase "Branch" "Creating feature branch and merging master"
+ Write-Phase "Branch" "Creating feature branch and merging main"
$username = Get-GitHubUsername
$script:BranchName = "users/$username/update_msdata_direct_$script:DateStamp"
# Step 1: Fetch latest
Write-Step 1 "Fetching latest branches from origin..."
- git fetch origin master --quiet 2>$null
+ git fetch origin main --quiet 2>$null
git fetch origin msdata/direct --quiet 2>$null
- Write-Success "Fetched latest master and msdata/direct"
+ Write-Success "Fetched latest main and msdata/direct"
# Step 2: Check if branch already exists
Write-Step 2 "Checking for existing feature branch..."
@@ -235,9 +235,9 @@ function Invoke-BranchPhase {
}
Write-Success "Created branch: $($script:BranchName)"
- # Step 4: Merge master
- Write-Step 4 "Merging master into feature branch..."
- $mergeOutput = git merge origin/master --no-edit 2>&1
+ # Step 4: Merge main
+ Write-Step 4 "Merging main into feature branch..."
+ $mergeOutput = git merge origin/main --no-edit 2>&1
if ($LASTEXITCODE -ne 0) {
Write-Info "Merge conflicts detected. Listing conflicted files:"
$conflicts = git diff --name-only --diff-filter=U 2>$null
@@ -247,9 +247,9 @@ function Invoke-BranchPhase {
}
}
Write-Host ""
- Write-Info "Attempting auto-resolution (accept master changes)..."
+ Write-Info "Attempting auto-resolution (accept main changes)..."
- # Try to auto-resolve by accepting master (theirs) changes
+ # Try to auto-resolve by accepting main (theirs) changes
foreach ($file in $conflicts) {
git checkout --theirs $file 2>$null
git add $file 2>$null
@@ -531,7 +531,7 @@ function Invoke-PRPhase {
git add -A 2>$null
$status = git status --porcelain 2>$null
if ($status) {
- git commit -m "[Internal] Direct package: Adds msdata/direct update from master" 2>$null
+ git commit -m "[Internal] Direct package: Adds msdata/direct update from main" 2>$null
if ($LASTEXITCODE -ne 0) {
Write-Failure "Commit failed"
return $false
@@ -558,13 +558,13 @@ function Invoke-PRPhase {
## Description
Syncs the ``msdata/direct`` branch with:
-- Latest ``master`` branch (v3 SDK changes)
+- Latest ``main`` branch (v3 SDK changes)
- Latest ``Microsoft.Azure.Cosmos.Direct`` files from msdata CosmosDB repo
### Changes Include
-- Merged latest ``master`` branch into ``msdata/direct``
+- Merged latest ``main`` branch into ``msdata/direct``
- Updated ``Microsoft.Azure.Cosmos.Direct`` files via ``msdata_sync.ps1``
-- Resolved merge conflicts (accepted master changes)
+- Resolved merge conflicts (accepted main changes)
- Build validated: ``dotnet build`` passes
## Type of change
@@ -578,7 +578,7 @@ Syncs the ``msdata/direct`` branch with:
$prUrl = gh pr create --draft `
--base "msdata/direct" `
- --title "[Internal] Direct package: Adds msdata/direct update from master" `
+ --title "[Internal] Direct package: Adds msdata/direct update from main" `
--body $prBody `
--reviewer "kirillg,khdang,adityasa,sboshra,FabianMeiswinkel,leminh98,neildsh" 2>&1