Agents & OrchestrationSûr100100/100

Update Pipeline (.NET)

Implementation details for EF Core SaveChanges and the update pipeline. Use when changing CommandBatchPreparer, UpdateSqlGenerator, ModificationCommand, or related classes.

ou envoie-le directement à ton agent.

Installer dans ton projet

$ curl -fsSL https://arboristhree.xyz/cli/install-skill.mjs -o /tmp/arboris-install-skill.mjs && node /tmp/arboris-install-skill.mjs update-pipeline__dotnet-dotnet__src-efcore-agents-skills-cdc3c839318d
.NET
dotnet/dotnet
Contenu à copier
---
name: update-pipeline
description: 'Implementation details for EF Core SaveChanges and the update pipeline. Use when changing CommandBatchPreparer, UpdateSqlGenerator, ModificationCommand, or related classes.'
user-invocable: false
metadata:
  origin: .NET
---

# Update Pipeline

Converts tracked entity changes into database INSERT/UPDATE/DELETE commands during `SaveChanges()`.

## Flow

`SaveChanges()` → `DetectChanges()` → `IDatabase.SaveChanges()`
  → `UpdateAdapter` creates `IUpdateEntry` list
  → `CommandBatchPreparer.BatchCommands()`
    → `ModificationCommand` per table row, composed of `ColumnModification` per column
      → `SharedTableEntryMap` is used to track entries mapped to the same row
    → Topological sort via Multigraph (FK dependency ordering)
    → Groups into `ModificationCommandBatch` (respects max batch size)
  → `UpdateSqlGenerator` generates SQL per batch
  → `BatchExecutor` executes all batches in a transaction
  → `StateManager.AcceptAllChanges()`

## Concurrency

Concurrency tokens → WHERE conditions on UPDATE/DELETE. `AffectedCountModificationCommandBatch` checks affected rows. Throws `DbUpdateConcurrencyException` on mismatch.

## Validation

- `SaveChanges()` returns expected affected row count
- Store-generated values propagate back to entities after INSERT/UPDATE
- `DbUpdateConcurrencyException` thrown when expected for stale data
Colle ce Markdown dans ton agent ou utilise les boutons ci-dessus pour l’écrire dans ton projet.

Ce que fait Update Pipeline (.NET)

`SaveChanges()` returns expected affected row count
Store-generated values propagate back to entities after INSERT/UPDATE
`DbUpdateConcurrencyException` thrown when expected for stale data

Comment utiliser Update Pipeline (.NET)

1
Copie le prompt
Un clic copie le prompt packagé (ou l'envoie à ton agent).
2
L'agent installe le skill
Il ajoute le SKILL.md et ses ressources à ton projet.
3
Activation automatique
Le skill s'active dès que le contexte correspond.

Déclencheurs pour Update Pipeline (.NET)

Dis simplement à ton agent quelque chose comme :

Applique le skill update-pipeline__dotnet-dotnet__src-efcore-agents-skills-cdc3c839318d à cette tâche
Utilise update-pipeline__dotnet-dotnet__src-efcore-agents-skills-cdc3c839318d pour améliorer cette implémentation
Passe en revue ce sujet avec update-pipeline__dotnet-dotnet__src-efcore-agents-skills-cdc3c839318d

Skills liés à Update Pipeline (.NET)