database-specialist
БесплатноБез исполняемых скриптовНе проверенData-pipeline implementation specialist — change-tracker/data-loader configurations, stored procedure integration, MongoDB repository code, DI registration…
от gabrielmoreira★ 23 звезды на GitHubОб этом скилле
Database Specialist — Data Pipeline
Implement and troubleshoot data-pipeline code: change-tracker jobs, data-loader configurations, SQL stored procedure integration, MongoDB repository patterns, and database tests.
Scope: data pipeline implementation only.
- For MongoDB analysis, indexing strategy, and query optimization → delegate to
MongoDB Expertagent.- For SQL Server query optimization, execution plans, and schema design → delegate to
MS-SQL Expertagent.- For general backend patterns (GraphQL, MassTransit, Startup) →
backend-developerskill.- For test conventions →
tests.instructions.md.
Architecture Overview
The data pipeline is a system that synchronizes source data (MS SQL) into a MongoDB target database:
SQL Server (Stored Procedures)
→ SqlChangeTracker (Quartz job, Cron)
→ Extract keys
→ MongoDB (store keys, transactions)
→ DomainProcessor (transformation)
→ MongoDB (store snapshots, hashes)
Relevant Paths in the Repo
| Area | Path |
|---|---|
| SQL Client & Execution | src/DataAccess/ |
| SQL Configurations | src/Abstractions/Configuration/ |
| Change Tracker & Loader | src/Core/ChangeTracker/, src/Core/Loader/ |
| MongoDB Repositories | src/Repository/ |
| DI Registration | src/Core/DataPipelineCoreCollectionExtensions.cs |
| Domain Configuration | src/Repository/ConfigureDomainSettings.cs |
| Tests | test/ |
MS SQL Server
SqlClient — Core SQL Execution
SqlClient.cs in src/DataAccess/ uses Microsoft.Data.SqlClient (not System.Data.SqlClient). Key properties:
CommandType.StoredProcedure— exclusively stored procedures, no inline SQLCommandTimeout= 10 minutes- Polly
WaitAndRetry(3, retryAttempt => TimeSpan.FromSeconds(5))for transient errors - Streaming via
IAsyncEnumerable<SqlTable>with optional batching
// Simplified pattern from SqlClient.cs
await using SqlConnection connection = new(context.ConnectionString);
await connection.OpenAsync(cancellationToken);
await using SqlCommand command = new(context.StoredProcedure, connection)
{
CommandType = CommandType.StoredProcedure,
CommandTimeout = (int)TimeSpan.FromMinutes(10).TotalSeconds
};
// Add parameters
foreach (SqlParameter parameter in context.Parameters)
{
command.Parameters.Add(parameter);
}
await using SqlDataReader reader = await command.ExecuteReaderAsync(cancellationToken);
SqlExecutionContext
Internal context object for SQL calls:
internal class SqlExecutionContext
{
public string ConnectionString { get; set; }
public string StoredProcedure { get; set; }
public IList<SqlParameter> Parameters { get; set; }
public bool UseBatching { get; set; }
public int BatchSize { get; set; }
}
Two SQL Client Types
| Client | Implements | Batching | Purpose |
|---|---|---|---|
SqlChangeTrackerClient |
ISqlChangeTrackerClient |
Yes | Periodic change detection via Cron |
SqlDataLoaderClient |
ISqlDataLoaderClient |
No | Full entity data loading |
Both create a SqlExecutionContext from their respective configuration.
SQL Configurations
SqlChangeTrackerConfiguration
Implements IChangeTrackerConfiguration:
public class SqlChangeTrackerConfiguration : IChangeTrackerConfiguration
{
public string StoredProcedure { get; set; }
public string QueryParameterName { get; set; }
public string QueryParameterType { get; set; }
public long InitialTransactionId { get; set; }
public string ResultPrimaryKeyColumnName { get; set; }
public string ResultTransactionIdColumnName { get; set; }
public string ConnectionString { get; set; }
public string CronSchedule { get; set; } = "0 {0} * ? * * *";
public EntityAction EntityAction { get; set; }
public void Resolve(ConnectionsOptions options)
{
// Resolves ConnectionString via ConnectionsOptions
}
}
CronScheduledefault:"0 {0} * ? * * *"— placeholder{0}is replaced with minute valueResolve(ConnectionsOptions)— resolve connection string from named configuration
SqlLoaderConfiguration
Implements ILoaderConfiguration:
public class SqlLoaderConfiguration : ILoaderConfiguration
{
public string StoredProcedure { get; set; }
public string ResultPrimaryKeyColumnName { get; set; }
public string QueryParameterName { get; set; }
public string QueryParameterType { get; set; }
public string QueryParameterTypeName { get; set; } // For TVP support
public string ConnectionString { get; set; }
public void Resolve(ConnectionsOptions options) { /* ... */ }
}
Connection Resolution
Connection strings are not stored directly in configurations but resolved via ConnectionsOptions:
Config section: Pipeline_Connections
→ ConnectionsOptions (name/value pairs)
→ Loader/Tracker call Resolve(ConnectionsOptions)
Change Tracker Pipeline
SqlCha
Установить database-specialist в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл database-specialist?
Data-pipeline implementation specialist — change-tracker/data-loader configurations, stored procedure integration, MongoDB repository code, DI registration, and Squadron-based database tests. Triggers: SqlChangeTracker, SqlDataLoader, SqlExecutionContext, IMongoCollection, MongoConventions, DomainEntityRepository, SourceRepository, Pipeline_Database, Pipeline_Connections, Squadron, new data pipeline entity setup.
Как установить скилл database-specialist?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл database-specialist запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
skill-creator
Create new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an…
от Anthropicdiscernment-nudge
After you give a substantive answer or draft that the user may act on — advice or recommendations, drafted artifacts such as goals, plans, pitches, proposals…
от Anthropicdata-consolidate
Joins the plant's scheduled exports and connector data into one working dataset — ERP items (NetSuite or Infor M3), sales orders, production work orders…
от Anthropicinspection-to-capa
Runs the quality chain end to end: writes the nonconformance against the requirement it violates, searches history at the moment of writing to say whether…
от Anthropic