一键导入
servicestack-schema-migrations
Manages schema evolution using OrmLite migrations and deployment-safe patterns.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Manages schema evolution using OrmLite migrations and deployment-safe patterns.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Designs stable, discoverable APIs using routes, metadata, and versioning conventions.
Implements authentication using ServiceStack Auth Providers and session handling.
Applies role-, permission-, and ownership-based authorization using ServiceStack idioms.
Implements AutoQuery services, custom filters, and permission-aware querying.
Designs request/response DTOs using DTO-first, message-based ServiceStack conventions.
Controls OpenAPI / metadata exposure without compromising ServiceStack-first design.
| name | servicestack-schema-migrations |
| description | Manages schema evolution using OrmLite migrations and deployment-safe patterns. |
ServiceStack recommended approach for database schema changes is code-first migrations.
MigrationBase.Up and Down methods.Db.CreateTable<T>, Db.DropTable<T>, Db.AddColumn<T>, etc.public class Migration1000 : MigrationBase
{
public override void Up()
{
Db.CreateTable<Customer>();
}
public override void Down()
{
Db.DropTable<Customer>();
}
}
dotnet run -- AppTasks=migrate.Migrations folder in the AppHost project.Migration1000, Migration20231027_Initial).Db.CreateTable<T>) where possible to keep POCOs as the source of truth.Db.ExecuteSql("...") if you need complex transformations or custom SQL that OrmLite doesn't support directly.Down method.