fix cluster stubs: deterministic fallback, payload forwarding, and handler guards
CI / build (pull_request) Successful in 40s
CI / build (pull_request) Successful in 40s
- Replace non-deterministic map range fallback with sorted node selection in PlaceActor and RebalanceShards - Add Body field to MessagePayload to preserve message data during cross-node routing - Forward actual message body in route_message handler instead of discarding it - Add self-message guard to route_message handler to prevent loops - Add nil guard for shardMap in handleRebalanceRequest - Add self-message guard to handleRebalanceRequest in DistributedVM
This commit is contained in:
+4
-3
@@ -197,9 +197,10 @@ const MaxRouteHops = 10
|
||||
// MessagePayload is a concrete type for JSON-unmarshaling RuntimeMessage payloads.
|
||||
// Use this when receiving message data over the network.
|
||||
type MessagePayload struct {
|
||||
TargetActorID string `json:"targetActorId"`
|
||||
Type string `json:"type"`
|
||||
Hops int `json:"hops,omitempty"`
|
||||
TargetActorID string `json:"targetActorId"`
|
||||
Type string `json:"type"`
|
||||
Hops int `json:"hops,omitempty"`
|
||||
Body map[string]interface{} `json:"body,omitempty"`
|
||||
}
|
||||
|
||||
// GetTargetActorID implements RuntimeMessage
|
||||
|
||||
Reference in New Issue
Block a user