Loading...
Loading...
Compare original and translation side by side
dotnet-inithealth-checkmigratearchitecture-advisordotnet-inithealth-checkmigratearchitecture-advisorHybridCacheHybridCache| Dimension | Options | Default | Why |
|---|---|---|---|
| Database | PostgreSQL, SQL Server, SQLite | PostgreSQL | Open source, best EF Core provider outside SQL Server, first-class Testcontainers support |
| Auth | JWT Bearer, OIDC (Keycloak/Auth0), None | JWT Bearer | Simplest secure default for APIs; move to OIDC when an external IdP exists |
| Caching | HybridCache, Redis, None | HybridCache | Built-in, stampede protection, L1+L2 — add Redis only as its L2 backend |
| Messaging | Wolverine (RabbitMQ), MassTransit, None | None (add later) | Premature messaging adds ops burden; Wolverine (MIT) when needed |
| Observability | Serilog + OpenTelemetry, Basic logging | Serilog + OTEL | Structured logs + traces from day one are cheap; retrofitting is not |
| Resilience | Polly v8 pipelines, Basic retry | Polly v8 | |
| API docs | Built-in OpenAPI + Scalar | OpenAPI + Scalar | Framework-maintained spec generation; Scalar replaces Swagger UI |
| Testing | xUnit v3 + Testcontainers | xUnit v3 + Testcontainers | Real databases in tests; in-memory providers hide real bugs |
dotnet-initef-coreauthenticationcachingmessagingserilogopentelemetryresilienceopenapiscalartesting| 维度 | 可选方案 | 默认推荐 | 理由 |
|---|---|---|---|
| 数据库 | PostgreSQL, SQL Server, SQLite | PostgreSQL | 开源,是SQL Server之外最佳的EF Core提供程序,支持一流的Testcontainers |
| 认证 | JWT Bearer, OIDC(Keycloak/Auth0), 无 | JWT Bearer | 是API最简单的安全默认方案;当存在外部身份提供商时再切换到OIDC |
| 缓存 | HybridCache, Redis, 无 | HybridCache | 内置功能,具备缓存击穿防护,支持L1+L2层级 —— 仅在需要L2后端时添加Redis |
| 消息传递 | Wolverine(RabbitMQ), MassTransit, 无 | 无(后续添加) | 过早引入消息传递会增加运维负担;需要时选用MIT许可的Wolverine |
| 可观测性 | Serilog + OpenTelemetry, 基础日志 | Serilog + OTEL | 从项目初期就启用结构化日志和追踪成本很低;后期再改造则难度极大 |
| 韧性 | Polly v8管道, 基础重试 | Polly v8 | |
| API文档 | 内置OpenAPI + Scalar | OpenAPI + Scalar | 由框架维护的规范生成;Scalar替代Swagger UI |
| 测试 | xUnit v3 + Testcontainers | xUnit v3 + Testcontainers | 测试中使用真实数据库;内存提供程序会掩盖真实bug |
dotnet-initef-coreauthenticationcachingmessagingserilogopentelemetryresilienceopenapiscalartestingundefinedundefinedundefinedundefinedundefinedundefinedundefinedundefined| Scenario | Route to |
|---|---|
| "Set up this project for Claude Code" | |
| "Which database/auth/caching should I use?" | This skill — table above |
| "How healthy is this codebase?" | |
| "Upgrade to .NET 10" / "update packages" | |
| "Which architecture fits?" | |
| Stack chosen, ready to build | |
| 场景 | 引导至工具 |
|---|---|
| "为Claude Code搭建此项目" | |
| "我应该使用哪个数据库/认证/缓存?" | 本工具——参考上方表格 |
| "我的代码库健康状况如何?" | |
| "升级到.NET 10" / "更新包" | |
| "哪种架构适合?" | |
| 已选定技术栈,准备开发 | |