mirror of
https://gitee.com/qqtt-ah/ecom-dmb.git
synced 2026-11-23 23:19:19 +08:00
refactor: 拆分拼多多配置文件
This commit is contained in:
@@ -4,6 +4,9 @@
|
||||
spring:
|
||||
profiles:
|
||||
active: dev
|
||||
config:
|
||||
import:
|
||||
- optional:classpath:config/channel-pdd.yml
|
||||
jackson:
|
||||
time-zone: Asia/Shanghai
|
||||
# 配置404错误处理 - 注释掉,避免影响Swagger文档访问
|
||||
@@ -129,54 +132,7 @@ oss:
|
||||
endpoint: https://oss-cn-guangzhou.aliyuncs.com
|
||||
bucket-name: xyquan
|
||||
|
||||
# 拼多多开放平台 OAuth
|
||||
pdd:
|
||||
oauth:
|
||||
client-id: 9b71d887c8dc4b46998dedfdeca9b866
|
||||
client-secret: c626f640a6fd5f56b2c8c009a5eb2d5683e6b955
|
||||
redirect-uri: https://ecbi.newloop.top/api-dev/channel/pdd/auth/callback
|
||||
authorize-url: https://fuwu.pinduoduo.com/service-market/auth
|
||||
state-ttl-seconds: 600
|
||||
# POP 出站公共配置(限流、默认分页);业务同步配置见 order-sync
|
||||
pop:
|
||||
default-page-size: 100
|
||||
rate-limit:
|
||||
enabled: true
|
||||
acquire-wait-ms: 5000
|
||||
# 平台频控被动退避:2s → 5s → 15s
|
||||
backoff-ms: [2000, 5000, 15000]
|
||||
# 保守默认(约官方上限 60% 店铺余量 + 本 ISV 短窗);可按接口覆盖
|
||||
default-rule:
|
||||
shop-limit: 6000
|
||||
shop-window-seconds: 60
|
||||
app-burst-limit: 800
|
||||
app-burst-window-seconds: 10
|
||||
apis:
|
||||
pdd.order.list.get:
|
||||
shop-limit: 6000
|
||||
shop-window-seconds: 60
|
||||
app-burst-limit: 800
|
||||
app-burst-window-seconds: 10
|
||||
pdd.order.number.list.increment.get:
|
||||
shop-limit: 6000
|
||||
shop-window-seconds: 60
|
||||
app-burst-limit: 800
|
||||
app-burst-window-seconds: 10
|
||||
pdd.order.information.get:
|
||||
shop-limit: 6000
|
||||
shop-window-seconds: 60
|
||||
app-burst-limit: 800
|
||||
app-burst-window-seconds: 10
|
||||
pdd.mall.info.get:
|
||||
shop-limit: 6000
|
||||
shop-window-seconds: 60
|
||||
app-burst-limit: 800
|
||||
app-burst-window-seconds: 10
|
||||
order-sync:
|
||||
overlap-seconds: 120
|
||||
lock-ttl-seconds: 600
|
||||
incremental-job-enabled: true
|
||||
incremental-cron: "0 */5 * * * ?"
|
||||
# 拼多多渠道配置见 config/channel-pdd.yml
|
||||
|
||||
# License 授权(开关与公钥见 LicenseEnforcement 源码硬编码)
|
||||
ecom:
|
||||
|
||||
@@ -0,0 +1,54 @@
|
||||
# 拼多多渠道配置(OAuth / POP 出站 / 订单同步)
|
||||
# 由 application.yml 通过 spring.config.import 引入
|
||||
|
||||
pdd:
|
||||
oauth:
|
||||
client-id: 9b71d887c8dc4b46998dedfdeca9b866
|
||||
client-secret: c626f640a6fd5f56b2c8c009a5eb2d5683e6b955
|
||||
# 须与开放平台应用回调一致;经网关时注意 /api-dev 与后端 /api 前缀
|
||||
redirect-uri: https://ecbi.newloop.top/api-dev/api/channel/pdd/auth/callback
|
||||
authorize-url: https://fuwu.pinduoduo.com/service-market/auth
|
||||
state-ttl-seconds: 600
|
||||
|
||||
# POP 出站:分页、限流;未在 apis 中声明的接口走 default-rule / 代码默认
|
||||
pop:
|
||||
default-page-size: 100
|
||||
rate-limit:
|
||||
enabled: true
|
||||
acquire-wait-ms: 5000
|
||||
# 平台频控被动退避:2s → 5s → 15s
|
||||
backoff-ms: [2000, 5000, 15000]
|
||||
# 约官方上限 60% 单店余量 + 本 ISV 短窗
|
||||
default-rule:
|
||||
shop-limit: 6000
|
||||
shop-window-seconds: 60
|
||||
app-burst-limit: 800
|
||||
app-burst-window-seconds: 10
|
||||
# 按 API type 覆盖(key 与 PddPopApiTypes 一致)
|
||||
apis:
|
||||
pdd.order.list.get:
|
||||
shop-limit: 6000
|
||||
shop-window-seconds: 60
|
||||
app-burst-limit: 800
|
||||
app-burst-window-seconds: 10
|
||||
pdd.order.number.list.increment.get:
|
||||
shop-limit: 6000
|
||||
shop-window-seconds: 60
|
||||
app-burst-limit: 800
|
||||
app-burst-window-seconds: 10
|
||||
pdd.order.information.get:
|
||||
shop-limit: 6000
|
||||
shop-window-seconds: 60
|
||||
app-burst-limit: 800
|
||||
app-burst-window-seconds: 10
|
||||
pdd.mall.info.get:
|
||||
shop-limit: 6000
|
||||
shop-window-seconds: 60
|
||||
app-burst-limit: 800
|
||||
app-burst-window-seconds: 10
|
||||
|
||||
order-sync:
|
||||
overlap-seconds: 120
|
||||
lock-ttl-seconds: 600
|
||||
incremental-job-enabled: true
|
||||
incremental-cron: "0 */5 * * * ?"
|
||||
Reference in New Issue
Block a user