feat: 添加争议微服务,支持订单争议流程
This commit is contained in:
@@ -121,6 +121,8 @@ services:
|
||||
condition: service_started
|
||||
review-api:
|
||||
condition: service_started
|
||||
dispute-api:
|
||||
condition: service_started
|
||||
|
||||
ratelimit:
|
||||
image: envoyproxy/ratelimit:05c08d03
|
||||
@@ -276,6 +278,19 @@ services:
|
||||
snowflake:
|
||||
condition: service_started
|
||||
|
||||
dispute-rpc:
|
||||
image: juwan/dispute-rpc:dev
|
||||
container_name: juwan-dispute-rpc
|
||||
restart: unless-stopped
|
||||
env_file: .env
|
||||
depends_on:
|
||||
postgres:
|
||||
condition: service_healthy
|
||||
redis:
|
||||
condition: service_healthy
|
||||
snowflake:
|
||||
condition: service_started
|
||||
|
||||
# ==================== API 层 ====================
|
||||
users-api:
|
||||
image: juwan/users-api:dev
|
||||
@@ -399,6 +414,19 @@ services:
|
||||
order-rpc:
|
||||
condition: service_started
|
||||
|
||||
dispute-api:
|
||||
image: juwan/dispute-api:dev
|
||||
container_name: juwan-dispute-api
|
||||
restart: unless-stopped
|
||||
env_file: .env
|
||||
ports:
|
||||
- "18811:8888"
|
||||
depends_on:
|
||||
dispute-rpc:
|
||||
condition: service_started
|
||||
order-rpc:
|
||||
condition: service_started
|
||||
|
||||
# ==================== MQ ====================
|
||||
email-mq:
|
||||
image: juwan/email-mq:dev
|
||||
|
||||
+32
-4
@@ -285,6 +285,22 @@ static_resources:
|
||||
cluster: shop_api_cluster
|
||||
timeout: 30s
|
||||
|
||||
- match:
|
||||
safe_regex:
|
||||
google_re2: {}
|
||||
regex: "^/api/v1/orders/[0-9]+/review.*"
|
||||
route:
|
||||
cluster: review_api_cluster
|
||||
timeout: 30s
|
||||
|
||||
- match:
|
||||
safe_regex:
|
||||
google_re2: {}
|
||||
regex: "^/api/v1/orders/[0-9]+/dispute$"
|
||||
route:
|
||||
cluster: dispute_api_cluster
|
||||
timeout: 30s
|
||||
|
||||
- match:
|
||||
prefix: /api/v1/orders
|
||||
route:
|
||||
@@ -350,11 +366,9 @@ static_resources:
|
||||
disabled: true
|
||||
|
||||
- match:
|
||||
safe_regex:
|
||||
google_re2: {}
|
||||
regex: "^/api/v1/orders/[0-9]+/review.*"
|
||||
prefix: /api/v1/disputes
|
||||
route:
|
||||
cluster: review_api_cluster
|
||||
cluster: dispute_api_cluster
|
||||
timeout: 30s
|
||||
|
||||
- match:
|
||||
@@ -790,6 +804,20 @@ static_resources:
|
||||
address: review-api
|
||||
port_value: 8888
|
||||
|
||||
- name: dispute_api_cluster
|
||||
connect_timeout: 2s
|
||||
type: STRICT_DNS
|
||||
lb_policy: ROUND_ROBIN
|
||||
load_assignment:
|
||||
cluster_name: dispute_api_cluster
|
||||
endpoints:
|
||||
- lb_endpoints:
|
||||
- endpoint:
|
||||
address:
|
||||
socket_address:
|
||||
address: dispute-api
|
||||
port_value: 8888
|
||||
|
||||
- name: authz_adapter_cluster
|
||||
connect_timeout: 0.5s
|
||||
type: STRICT_DNS
|
||||
|
||||
Reference in New Issue
Block a user