mirror of
https://github.com/corda/corda.git
synced 2025-06-01 15:10:54 +00:00
CORDA-1622 Correct broken de-dup header logic on node restart for restored flows. Multi-threaded version. (#985)
This commit is contained in:
parent
70a1a3a3d4
commit
d95b1b0e6a
@ -364,8 +364,7 @@ class MultiThreadedStateMachineManager(
|
|||||||
checkpoint = checkpoint,
|
checkpoint = checkpoint,
|
||||||
initialDeduplicationHandler = null,
|
initialDeduplicationHandler = null,
|
||||||
isAnyCheckpointPersisted = true,
|
isAnyCheckpointPersisted = true,
|
||||||
isStartIdempotent = false,
|
isStartIdempotent = false
|
||||||
senderUUID = null
|
|
||||||
)
|
)
|
||||||
} else {
|
} else {
|
||||||
// Just flow initiation message
|
// Just flow initiation message
|
||||||
@ -664,8 +663,7 @@ class MultiThreadedStateMachineManager(
|
|||||||
checkpoint: Checkpoint,
|
checkpoint: Checkpoint,
|
||||||
isAnyCheckpointPersisted: Boolean,
|
isAnyCheckpointPersisted: Boolean,
|
||||||
isStartIdempotent: Boolean,
|
isStartIdempotent: Boolean,
|
||||||
initialDeduplicationHandler: DeduplicationHandler?,
|
initialDeduplicationHandler: DeduplicationHandler?
|
||||||
senderUUID: String? = ourSenderUUID
|
|
||||||
): Flow {
|
): Flow {
|
||||||
val flowState = checkpoint.flowState
|
val flowState = checkpoint.flowState
|
||||||
val resultFuture = openFuture<Any?>()
|
val resultFuture = openFuture<Any?>()
|
||||||
@ -681,7 +679,7 @@ class MultiThreadedStateMachineManager(
|
|||||||
isStartIdempotent = isStartIdempotent,
|
isStartIdempotent = isStartIdempotent,
|
||||||
isRemoved = false,
|
isRemoved = false,
|
||||||
flowLogic = logic,
|
flowLogic = logic,
|
||||||
senderUUID = senderUUID
|
senderUUID = null
|
||||||
)
|
)
|
||||||
val fiber = FlowStateMachineImpl(id, logic, scheduler)
|
val fiber = FlowStateMachineImpl(id, logic, scheduler)
|
||||||
fiber.transientValues = TransientReference(createTransientValues(id, resultFuture))
|
fiber.transientValues = TransientReference(createTransientValues(id, resultFuture))
|
||||||
@ -700,7 +698,7 @@ class MultiThreadedStateMachineManager(
|
|||||||
isStartIdempotent = isStartIdempotent,
|
isStartIdempotent = isStartIdempotent,
|
||||||
isRemoved = false,
|
isRemoved = false,
|
||||||
flowLogic = fiber.logic,
|
flowLogic = fiber.logic,
|
||||||
senderUUID = senderUUID
|
senderUUID = null
|
||||||
)
|
)
|
||||||
fiber.transientValues = TransientReference(createTransientValues(id, resultFuture))
|
fiber.transientValues = TransientReference(createTransientValues(id, resultFuture))
|
||||||
fiber.transientState = TransientReference(state)
|
fiber.transientState = TransientReference(state)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user