ENT-4973 Introduce explicit constructors to evolve ReceiveFinalityFlow for binary backwards compatibility (#7404)

* Introduce explicit constructors to evolve ReceiveFinalityFlow for binary backwards compatibility.
This commit is contained in:
Jose Coll 2023-06-29 11:19:59 +01:00 committed by GitHub
parent 59404fbdfc
commit 49d5b6a4bf
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -16,6 +16,7 @@ import net.corda.core.internal.telemetry.telemetryServiceInternal
import net.corda.core.internal.warnOnce
import net.corda.core.node.StatesToRecord
import net.corda.core.node.StatesToRecord.ONLY_RELEVANT
import net.corda.core.serialization.DeprecatedConstructorForDeserialization
import net.corda.core.transactions.LedgerTransaction
import net.corda.core.transactions.SignedTransaction
import net.corda.core.utilities.ProgressTracker
@ -483,10 +484,16 @@ object NotarySigCheck {
* @param statesToRecord Which states to commit to the vault. Defaults to [StatesToRecord.ONLY_RELEVANT].
* @param handlePropagatedNotaryError Whether to catch and propagate Double Spend exception to peers.
*/
class ReceiveFinalityFlow @JvmOverloads constructor(private val otherSideSession: FlowSession,
private val expectedTxId: SecureHash? = null,
private val statesToRecord: StatesToRecord = ONLY_RELEVANT,
private val handlePropagatedNotaryError: Boolean? = null) : FlowLogic<SignedTransaction>() {
class ReceiveFinalityFlow(private val otherSideSession: FlowSession,
private val expectedTxId: SecureHash? = null,
private val statesToRecord: StatesToRecord = ONLY_RELEVANT,
private val handlePropagatedNotaryError: Boolean? = null) : FlowLogic<SignedTransaction>() {
@DeprecatedConstructorForDeserialization(version = 1)
@JvmOverloads constructor(otherSideSession: FlowSession,
expectedTxId: SecureHash? = null,
statesToRecord: StatesToRecord = ONLY_RELEVANT) : this(otherSideSession, expectedTxId, statesToRecord, null)
@Suppress("ComplexMethod", "NestedBlockDepth")
@Suspendable
override fun call(): SignedTransaction {