3D Application contract commit / push 前確認
本文件整理程式 repo poc/nmodbus-tcp 在提交 新增 3D Application contract 第一版 前的範圍、測試、停止線與風險確認。
0. 確認摘要
| 項目 | 內容 |
| 確認日期 | 2026-06-06 |
| 程式 repo | hs-device-control-template |
| 程式 branch | poc/nmodbus-tcp |
| commit | a1585512a750a52e08c9bc3f2a12773b57305e0b |
| push 狀態 | 已 push 至 origin/poc/nmodbus-tcp |
| Actions | Notify docs repo status run 27029042871,結果 success |
| 決策來源 | 3D Application contract 七項決策均已同意 |
1. staged 檔案範圍
| 類型 | 檔案範圍 |
| 修改 | src/HS.DeviceControl.Application/Common/ApplicationErrorCodes.cs |
| 新增 Application contract | src/HS.DeviceControl.Application/ControlUnits/*、Resources/*、Commands/*、Plugins/* |
| 新增測試 | tests/HS.DeviceControl.Application.Tests/ControlUnitCatalogServiceTests.cs、DeviceCommandPlannerTests.cs、InMemoryResourceLockServiceTests.cs、PluginCatalogServiceTests.cs |
| 未納入 | Core、Adapters、Infrastructure、ConsoleHost、WebApi、ServiceHost、config schema、DB DDL |
2. 測試與檢查
| 檢查項目 | 結果 |
| Application tests | dotnet test tests\HS.DeviceControl.Application.Tests\HS.DeviceControl.Application.Tests.csproj:30 passed,0 failed。 |
| solution tests | dotnet test HS.DeviceControl.sln:468 passed,0 failed。 |
| diff check | git diff --cached --check:通過。 |
| 污染字串掃描 | 未命中指定污染字串。 |
| 工作樹 | commit 後工作樹乾淨,分支已 push。 |
3. commit 訊息
新增 3D Application contract 第一版
- 新增 ControlUnits、Resources、Commands、Plugins Application contract 與 in-memory / metadata 第一版實作
- 補 APP-03xx Application error code
- 新增 Application.Tests 覆蓋 read-only catalog、resource lock、command plan、plugin metadata 驗證
- 不新增 ServiceHost、WebApi、Plugin Loader,不變更 Adapter public contract 與 config schema
4. 停止線確認
- 未新增
ServiceHost、WebApi、API route、controller、endpoint 或 middleware。
- 未建立 Plugin Loader、未載入 DLL、未新增 plugin folder。
- 未修改
IDeviceAdapter、DeviceCommand、ExecuteResult public contract。
- 未修改
devices.json、workflows.json、appsettings.json 或 config schema。
- 未新增 DB table、DDL、migration、正式 Apply 或外部服務設定。
- 未新增 NuGet package 或更換核心框架。
5. 結論
3D Application contract 程式 repo 提交與 push 前確認已完成,實際提交已推送至 origin/poc/nmodbus-tcp,且 GitHub Actions 回報成功。後續需完成文件 repo 同步、部署查驗與線上驗收紀錄。