Some checks failed
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Has been cancelled
完成运营商实名回调、业务事件观测序列与受控配置装配,同时恢复 UR43 已交付的 packages[].remove 字段及旧响应兼容,统一更新 OpenSpec、OpenAPI 和交付文档。 Constraint: 七月测试环境里程碑不新增或运行自动化测试 Rejected: 以必填 operation_type 替换 packages[].remove | 会破坏已交付前端契约 Confidence: high Scope-risk: broad Directive: 后续修改系列套餐管理接口必须保持 packages[].remove 和 ShopSeriesGrantResponse 兼容 Tested: go run ./cmd/gendocs;go build -buildvcs=false ./...;openspec validate complete-july-iteration-test-release --strict;git diff --check Not-tested: 按本 Change 约定未运行 go test,真实运营商与 Gateway 联调延期
33 lines
1.8 KiB
Go
33 lines
1.8 KiB
Go
package bootstrap
|
||
|
||
import (
|
||
systemConfigApp "github.com/break/junhong_cmp_fiber/internal/application/systemconfig"
|
||
"github.com/break/junhong_cmp_fiber/internal/gateway"
|
||
systemConfigInfra "github.com/break/junhong_cmp_fiber/internal/infrastructure/systemconfig"
|
||
"github.com/break/junhong_cmp_fiber/internal/service/verification"
|
||
"github.com/break/junhong_cmp_fiber/pkg/auth"
|
||
"github.com/break/junhong_cmp_fiber/pkg/queue"
|
||
"github.com/break/junhong_cmp_fiber/pkg/storage"
|
||
"github.com/break/junhong_cmp_fiber/pkg/wechat"
|
||
"github.com/redis/go-redis/v9"
|
||
"go.uber.org/zap"
|
||
"gorm.io/gorm"
|
||
)
|
||
|
||
// Dependencies 封装所有基础依赖
|
||
// 这些是应用启动时初始化的核心组件
|
||
type Dependencies struct {
|
||
DB *gorm.DB // PostgreSQL 数据库连接
|
||
Redis *redis.Client // Redis 客户端
|
||
Logger *zap.Logger // 应用日志器
|
||
JWTManager *auth.JWTManager // JWT 管理器(个人客户认证)
|
||
TokenManager *auth.TokenManager // Token 管理器(后台和H5认证)
|
||
VerificationService *verification.Service // 验证码服务
|
||
QueueClient *queue.Client // Asynq 任务队列客户端
|
||
StorageService *storage.Service // 对象存储服务(可选,配置缺失时为 nil)
|
||
GatewayClient *gateway.Client // Gateway API 客户端(可选,配置缺失时为 nil)
|
||
WechatPayment wechat.PaymentServiceInterface // 微信支付服务(可选)
|
||
SystemConfigRegistry *systemConfigInfra.Registry // 业务模块共享的受控配置注册表(可选)
|
||
SystemConfigAudit systemConfigApp.AuditWriter // 配置变更审计 Port(可选,装配后与配置同事务写入)
|
||
}
|