Vhat.Infrastructure
13.0.0
dotnet add package Vhat.Infrastructure --version 13.0.0
NuGet\Install-Package Vhat.Infrastructure -Version 13.0.0
<PackageReference Include="Vhat.Infrastructure" Version="13.0.0" />
<PackageVersion Include="Vhat.Infrastructure" Version="13.0.0" />
<PackageReference Include="Vhat.Infrastructure" />
paket add Vhat.Infrastructure --version 13.0.0
#r "nuget: Vhat.Infrastructure, 13.0.0"
#:package Vhat.Infrastructure@13.0.0
#addin nuget:?package=Vhat.Infrastructure&version=13.0.0
#tool nuget:?package=Vhat.Infrastructure&version=13.0.0
core-lib
Repo làm gì
Thư viện .NET dùng chung cho các service backend trong workspace Loipv.
Entry points chính
CoreLib.slnx: solution chính.src/: source các package/thư viện dùng chung.tests/: test cho shared library nếu có.
Lệnh dev/build/test/lint
- Dev: không có service chạy độc lập.
- Build:
dotnet build CoreLib.slnx - Test:
dotnet test CoreLib.slnx - Lint/typecheck: không có lệnh riêng; dùng compiler/analyzer của .NET.
- Validate:
dotnet build CoreLib.slnx
Port/local URL
Không có port hoặc local URL vì repo này không chạy service.
Dependency quan trọng
- .NET SDK theo cấu hình repo/workspace.
- Các backend phụ thuộc vào contract/package dùng chung từ repo này.
Verify theo scope
- Sửa shared API/model/helper: chạy
dotnet build CoreLib.slnx, sau đó build repo tiêu thụ liên quan. - Sửa test/shared behavior: chạy
dotnet test CoreLib.slnxnếu test có sẵn.
Deploy note
Không có nhánh production. Thay đổi được tiêu thụ bởi các repo backend phụ thuộc.
Contract của phiên bản 13
Bản đồ repo, tác động từng luồng queue và bằng chứng kiểm thử: Báo cáo Vhat 13.
AddScopedTimeServicetạoICoreTimeServicetheo scope. Repo ứng dụng sở hữu quyết định chọn scoped hay singleton.GetClientIpvàGetClientSchemeđọc connection/request đã được middleware chuẩn hóa. Ứng dụng đăng kýAddTrustedForwardedHeadersbằng sectionForwardedHeadersgồmKnownProxies,KnownNetworks,ForwardLimit; không có danh sách thì không nhận forwarded headers.- Consumer phải truyền chính sách
mayRetrytheo nghiệp vụ và callback phục hồi khi ACK/transport lỗi. Core không tự phân loại nghiệp vụ dựa trên tên task. - Chỉ ACK khi handler hoàn tất hoặc message được broker xác nhận đã chuyển sang retry/queue
.failed. Nghiệp vụ được xác nhận idempotent có tối đa 3 lần chạy; nghiệp vụ còn lại không tự chạy lại khi lỗi hoặc redelivery chưa rõ kết quả. - Publisher phải dùng channel có publisher confirms và serializer chung. Envelope phải có
MessageId,Type, schema hợp lệ và payload JSON;ContentEncodingchỉ để trống hoặc làgzip. Không đoán gzip khi thiếu header, không tự sinh ID thay cho message lỗi. - Publisher tác vụ dùng
mandatory=true; broadcast cho subscriber tạm thời có thể dùngmandatory=false. Confirm của broker không đồng nghĩa handler hoặc hệ thống bên ngoài đã xử lý thành công. .failedgiữ nguyên body và metadata cần đối soát. Không có replay tự động cho SMTP, Telegram, tăng bộ đếm, vị thế giao dịch hoặc tác vụ nhiều bước chưa chứng minh idempotent. Quyết định đối soát, sửa dữ liệu và phát lại thuộc repo nghiệp vụ/ops.
Triển khai phải cập nhật cả producer và consumer. Với backlog từ publisher cũ thiếu metadata, cần drain hoặc chuyển đổi có kiểm chứng trước khi bật consumer strict; không thêm fallback tương thích vào runtime.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net10.0
- Dapper (>= 2.1.79)
- InfluxDB.Client (>= 5.1.0)
- MeiliSearch (>= 0.20.0)
- Microsoft.EntityFrameworkCore (>= 10.0.11)
- Microsoft.EntityFrameworkCore.Relational (>= 10.0.11)
- Microsoft.Extensions.Caching.Hybrid (>= 10.9.0)
- Microsoft.Extensions.Caching.StackExchangeRedis (>= 10.0.11)
- Microsoft.Extensions.Http.Polly (>= 10.0.11)
- Microsoft.Extensions.Http.Resilience (>= 10.9.0)
- Minio (>= 7.0.0)
- MongoDB.Driver (>= 3.11.1)
- Npgsql (>= 10.0.3)
- Npgsql.OpenTelemetry (>= 10.0.3)
- OpenTelemetry.Exporter.OpenTelemetryProtocol (>= 1.18.0)
- OpenTelemetry.Extensions.Hosting (>= 1.18.0)
- OpenTelemetry.Instrumentation.AspNetCore (>= 1.18.0)
- OpenTelemetry.Instrumentation.Http (>= 1.18.0)
- OpenTelemetry.Instrumentation.Runtime (>= 1.18.0)
- Polly (>= 8.7.0)
- RabbitMQ.Client (>= 7.2.2)
- Snappier (>= 1.3.1)
- Ulid (>= 1.4.1)
- Vhat.Core (>= 13.0.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 13.0.0 | 236 | 9/6/2026 |
| 11.0.5 | 473 | 8/30/2026 |
| 11.0.3 | 110 | 8/25/2026 |
| 11.0.2 | 281 | 8/24/2026 |
| 11.0.1 | 173 | 8/23/2026 |
| 11.0.0 | 121 | 8/22/2026 |
| 10.27.485 | 182 | 8/16/2026 |
| 10.27.484 | 101 | 8/16/2026 |
| 10.27.483 | 173 | 8/12/2026 |
| 10.27.482 | 99 | 8/11/2026 |
| 10.27.481 | 98 | 8/11/2026 |
| 10.27.480 | 102 | 8/11/2026 |
| 10.27.479 | 128 | 8/10/2026 |
| 10.27.478 | 202 | 8/9/2026 |
| 10.27.477 | 308 | 7/27/2026 |
| 10.27.476 | 320 | 7/19/2026 |
| 10.27.475 | 112 | 7/13/2026 |
| 10.27.474 | 274 | 7/9/2026 |
| 10.27.473 | 357 | 6/28/2026 |
| 10.27.472 | 123 | 6/24/2026 |