|
|
|
@ -10,7 +10,7 @@ |
|
|
|
① 统一入口 ChannelSdk / 各能力视图(SalesOrders / Products / Outbounds / AfterSales / Settlements) |
|
|
|
① 统一入口 ChannelSdk / 各能力视图(SalesOrders / Products / Outbounds / AfterSales / Settlements) |
|
|
|
② 能力接口 ProductCapable / SalesOrderCapable / ShippingLabelCapable / AfterSaleCapable / ... |
|
|
|
② 能力接口 ProductCapable / SalesOrderCapable / ShippingLabelCapable / AfterSaleCapable / ... |
|
|
|
③ 平台适配 lingxing(聚合:amazon-sc / walmart / tiktok / temu / ebay / shein / target …) |
|
|
|
③ 平台适配 lingxing(聚合:amazon-sc / walmart / tiktok / temu / ebay / shein / target …) |
|
|
|
④ 基础设施 HttpTransport / Signer / TokenManager / LingxingRateLimiter / SyncEngine / Idempotency |
|
|
|
④ 基础设施 HttpTransport / TokenManager / LingxingRateLimiter / SyncEngine / Idempotency |
|
|
|
⑤ 宿主 SPI AccountRepository / TokenStore / SyncCursorStore / Sink / Clock / LockProvider / ... |
|
|
|
⑤ 宿主 SPI AccountRepository / TokenStore / SyncCursorStore / Sink / Clock / LockProvider / ... |
|
|
|
``` |
|
|
|
``` |
|
|
|
|
|
|
|
|
|
|
|
@ -32,7 +32,7 @@ graph TD |
|
|
|
CMODEL["channel · 领域模型<br/>SalesOrder · ProductListing · AccountKey · Page"] |
|
|
|
CMODEL["channel · 领域模型<br/>SalesOrder · ProductListing · AccountKey · Page"] |
|
|
|
ENGINE["channel · 同步管道<br/>SyncEngine"] |
|
|
|
ENGINE["channel · 同步管道<br/>SyncEngine"] |
|
|
|
SHARED["shared · 跨域共享层<br/>异常 · 幂等 · 审计 · 枚举 · SPI 定义 · Money/Page"] |
|
|
|
SHARED["shared · 跨域共享层<br/>异常 · 幂等 · 审计 · 枚举 · SPI 定义 · Money/Page"] |
|
|
|
HTTPM["http · 出入网层<br/>HttpTransport · Signer · TokenManager · JsonCodec"] |
|
|
|
HTTPM["http · 出入网层<br/>HttpTransport · TokenManager · JsonCodec"] |
|
|
|
LX["lingxing · 聚合适配器<br/>LingxingAdapter → LingxingSubPlatforms → 子平台 Source"] |
|
|
|
LX["lingxing · 聚合适配器<br/>LingxingAdapter → LingxingSubPlatforms → 子平台 Source"] |
|
|
|
end |
|
|
|
end |
|
|
|
|
|
|
|
|
|
|
|
@ -187,7 +187,7 @@ common.ecommerce |
|
|
|
│ |
|
|
|
│ |
|
|
|
├── http HTTP 与令牌(http) |
|
|
|
├── http HTTP 与令牌(http) |
|
|
|
│ HttpTransport / OkHttpTransport / HttpRequest / HttpResponse / |
|
|
|
│ HttpTransport / OkHttpTransport / HttpRequest / HttpResponse / |
|
|
|
│ JsonCodec / JacksonJsonCodec / Signer / TokenManager / Responses |
|
|
|
│ JsonCodec / JacksonJsonCodec / TokenManager / Responses |
|
|
|
│ |
|
|
|
│ |
|
|
|
└── lingxing 领星聚合适配器(lingxing) |
|
|
|
└── lingxing 领星聚合适配器(lingxing) |
|
|
|
├── LingxingApi 接口定义(路径 + 限流参数) |
|
|
|
├── LingxingApi 接口定义(路径 + 限流参数) |
|
|
|
@ -401,7 +401,6 @@ common.ecommerce |
|
|
|
| `HttpTransport` | 传输接口,默认 `OkHttpTransport`(连接 5s / 读 30s) | |
|
|
|
| `HttpTransport` | 传输接口,默认 `OkHttpTransport`(连接 5s / 读 30s) | |
|
|
|
| `HttpRequest` / `HttpResponse` | 统一请求响应,保留原始 header/body 供留痕 | |
|
|
|
| `HttpRequest` / `HttpResponse` | 统一请求响应,保留原始 header/body 供留痕 | |
|
|
|
| `JsonCodec` | JSON 抽象,`JacksonJsonCodec` 提供点路径取值 `nodeAt("data.list")` | |
|
|
|
| `JsonCodec` | JSON 抽象,`JacksonJsonCodec` 提供点路径取值 `nodeAt("data.list")` | |
|
|
|
| `Signer` | 签名接口,各平台实现 | |
|
|
|
|
|
|
|
| `TokenManager` | 令牌模板:账户隔离、提前续期、`LockProvider` 防击穿、日志只打指纹 | |
|
|
|
| `TokenManager` | 令牌模板:账户隔离、提前续期、`LockProvider` 防击穿、日志只打指纹 | |
|
|
|
| `Responses` | 状态码 → 异常映射(`throwIfNotSuccess`) | |
|
|
|
| `Responses` | 状态码 → 异常映射(`throwIfNotSuccess`) | |
|
|
|
|
|
|
|
|
|
|
|
@ -710,7 +709,7 @@ public final class AmazonScAdapter implements SalesOrderCapable, FulfillmentCapa |
|
|
|
} |
|
|
|
} |
|
|
|
``` |
|
|
|
``` |
|
|
|
|
|
|
|
|
|
|
|
**第 3 步:写签名器**,实现 `Signer`(LWA 只需 `Authorization: Bearer`,签名器可为空实现)。 |
|
|
|
**第 3 步:写签名器**,静态工具类即可(如 `LingxingSigner`)——签名参数往往要在构造 `HttpRequest` 之前算,没有统一接口。LWA 只需 `Authorization: Bearer`,连签名器都不用。 |
|
|
|
|
|
|
|
|
|
|
|
**第 4 步:写报文映射**,平台 JSON → 统一模型。**平台字段名只出现在 DTO 和 Mapper 里**。 |
|
|
|
**第 4 步:写报文映射**,平台 JSON → 统一模型。**平台字段名只出现在 DTO 和 Mapper 里**。 |
|
|
|
|
|
|
|
|
|
|
|
|