perf(cmpp): decouple supplier result callbacks

This commit is contained in:
hectorzhao
2026-08-20 14:19:42 +08:00
parent 485af688d2
commit 67b760a599
27 changed files with 1000 additions and 66 deletions
@@ -6,7 +6,8 @@
{ "$ref": "#/$defs/SubmitCommand" },
{ "$ref": "#/$defs/SubmitResult" },
{ "$ref": "#/$defs/ReceiptEvent" },
{ "$ref": "#/$defs/UplinkEvent" }
{ "$ref": "#/$defs/UplinkEvent" },
{ "$ref": "#/$defs/SubmitResultOutboxEvent" }
],
"$defs": {
"Envelope": {
@@ -139,6 +140,26 @@
}
]
},
"SubmitResultOutboxEvent": {
"type": "object",
"required": ["schemaVersion", "eventId", "eventType", "path", "messageId", "channelId", "submitId", "payload", "createdAt"],
"properties": {
"schemaVersion": { "const": "v1" },
"eventId": { "type": "string", "pattern": "^submit:.+:(aggregate|segment:[1-9][0-9]*)$" },
"eventType": { "enum": ["submit_result", "submit_segment_result"] },
"path": { "enum": ["/gateway/events/submit-result", "/gateway/events/submit-segment-result"] },
"traceId": { "type": "string" },
"messageId": { "type": "string", "minLength": 1 },
"channelId": { "type": "string", "minLength": 1 },
"submitId": { "type": "string", "minLength": 1 },
"payload": {
"type": "object",
"required": ["eventId"],
"properties": { "eventId": { "type": "string", "minLength": 1 } }
},
"createdAt": { "type": "string", "format": "date-time" }
}
},
"ReceiptEvent": {
"allOf": [
{ "$ref": "#/$defs/Envelope" },