Skip to content

[Internal] Release: Adds latest master commits to release-3.58.0-v2#5710

Merged
kirankumarkolli merged 5 commits intorelease-3.58.0-v2from
users/aavasthy/update-release-3.58.0-v2
Mar 19, 2026
Merged

[Internal] Release: Adds latest master commits to release-3.58.0-v2#5710
kirankumarkolli merged 5 commits intorelease-3.58.0-v2from
users/aavasthy/update-release-3.58.0-v2

Conversation

@aavasthy
Copy link
Copy Markdown
Contributor

Summary

Merges latest master commits into the release-3.58.0-v2 branch to include:

  • #5614 ThinClient Integration: Adds support for QueryPlan in thinclient mode
  • #5682 [Internal] Query: Adds SubstringAfter/LastSubstringAfter/SubstringBefore/LastSubstringBefore to SDK
  • #5681 [Internal] Tooling: Adds msdata/direct sync Copilot agent and helper script

Changelog Update

This updates the existing release PR #5698.

NaluTripician and others added 5 commits March 18, 2026 01:09
…script (#5681)

# Pull Request Template

## Description

This PR adds a **Copilot agent** and **PowerShell helper script** to
automate the `msdata/direct` branch sync workflow, which merges the v3
`master` branch into `msdata/direct` and syncs files from the internal
msdata CosmosDB repository.

### Problem

The msdata/direct sync process ([documented
here](docs/sync_up_msdata_direct.md)) is a manual, multi-step workflow
involving branch creation, merging, conflict resolution, file syncing
via `msdata_sync.ps1`, build validation, and PR creation. This process
is error-prone and time-consuming when done manually.

### Solution

Two new automation tools:

#### 1. Copilot Agent
(`.github/agents/msdata-direct-sync-agent.agent.md`)

A structured agent with 5 workflow phases:

| Phase | Description |
|-------|-------------|
| **Phase 1: Environment Setup** | Validates prerequisites (git, dotnet,
gh CLI), prompts for msdata repo path |
| **Phase 2: Branch Preparation** | Creates feature branch from
`msdata/direct`, merges latest `master`, resolves conflicts |
| **Phase 3: msdata File Sync** | Configures and runs `msdata_sync.ps1`
with user-provided repo path, handles missing files |
| **Phase 4: Build Validation** | Runs `dotnet build` to verify sync
succeeded, provides troubleshooting guidance |
| **Phase 5: PR Creation** | Stages, commits, pushes, creates draft PR
with proper format and reviewers |

**Usage:**
```
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.
```

#### 2. PowerShell Helper Script (`tools/msdata-direct-sync-helper.ps1`)

Automates the mechanical parts of the workflow. Can run the full
workflow or individual phases:

```powershell
# Full workflow
.\tools\msdata-direct-sync-helper.ps1 -MsdataRepoPath "Q:\CosmosDB"

# Individual phases
.\tools\msdata-direct-sync-helper.ps1 -MsdataRepoPath "Q:\CosmosDB" -Phase Setup
.\tools\msdata-direct-sync-helper.ps1 -MsdataRepoPath "Q:\CosmosDB" -Phase Branch
.\tools\msdata-direct-sync-helper.ps1 -MsdataRepoPath "Q:\CosmosDB" -Phase Sync
.\tools\msdata-direct-sync-helper.ps1 -MsdataRepoPath "Q:\CosmosDB" -Phase Build
.\tools\msdata-direct-sync-helper.ps1 -MsdataRepoPath "Q:\CosmosDB" -Phase PR
```

**Key features:**
- Prompts for msdata repo path at runtime (no hardcoded paths)
- Auto-detects GitHub username for branch naming
- Branch naming: `users/<username>/update_msdata_direct_<mm_dd_yyyy>`
- Automatically reverts `msdata_sync.ps1` path changes after sync
- Creates draft PR with standard reviewers and description
- Phase-by-phase execution for debugging or re-running failed steps

#### 3. Documentation Update (`docs/sync_up_msdata_direct.md`)

Updated to reference the new agent and helper script as recommended
automated alternatives, and added the latest sample PR (#5612).

### Design Decisions

- **msdata repo path prompted at runtime**: Different developers have
the repo at different local paths
- **`[Internal]` PR prefix**: This is internal tooling, not
customer-facing
- **Draft PR by default**: Follows repository convention of creating
drafts first
- **Conflict resolution strategy**: Accept incoming master changes by
default, with manual review flagged for critical files

## Type of change

- [x] New feature (non-breaking change which adds functionality)

## Does this pull request offer a public API change?

No - this is internal tooling only (agent + script), no SDK API changes.

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Kiran Kumar Kolli <kirankk@microsoft.com>
…de. (#5614)

# Pull Request Template

## Description

Adds support for QueryPlan in thinclient mode. The change also now
converts partition key ranges from PartitionKeyInternal format to EPK
hex strings required by the RNTBD protocol. This enables complex queries
(ORDER BY, GROUP BY, aggregates) to work in ThinClient mode by
translating backend QueryPlan responses.

## Type of change

Please delete options that are not relevant.

- [X] New feature (non-breaking change which adds functionality)


## Closing issues

To automatically close an issue: closes #IssueNumber
…ore/LastSubstringBefore to SDK (#5682)

# 4 new system functions

**SubstringAfter**
Returns the part of a string expression after the first occurrence of
another string expression.

```
SubstringAfter("", "") = "";
SubstringAfter("abcde", "bc") = "de";
```


**SubstringBefore**
Returns the part of a string expression before the first occurrence of
another string expression.

```
SubstringBefore("", "") = "";
SubstringBefore("abcde", "bc") = "a";
```


**LastSubstringAfter**
Returns the part of a string expression after the last occurrence of
another string expression.

```
LastSubstringAfter("", "") = "";
LastSubstringAfter("abcdeabcde", "bc") = "de";
```


**LastSubstringBefore**
Returns the part of a string expression before the last occurrence of
another string expression.

```
LastSubstringBefore("", "") = "";
LastSubstringBefore("abcdeabcde", "bc") = "abcdea";
```

## Type of change

Please delete options that are not relevant.

- [] Bug fix (non-breaking change which fixes an issue)
- [x] New feature (non-breaking change which adds functionality)
- [] Breaking change (fix or feature that would cause existing
functionality to not work as expected)
- [] This change requires a documentation update

## Closing issues

To automatically close an issue: closes #IssueNumber
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@kirankumarkolli kirankumarkolli merged commit ea81b15 into release-3.58.0-v2 Mar 19, 2026
9 checks passed
@kirankumarkolli kirankumarkolli deleted the users/aavasthy/update-release-3.58.0-v2 branch March 19, 2026 19:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants