Skip to content

[Access] Proposal: Remove transaction retry functionality #7632

@peterargue

Description

@peterargue

Access nodes have functionality that allows retrying transactions that are never finalized. This handles the case where a transaction is successfully sent to a collection node, but for whatever reason gets dropped and never ends up in a finalized block.

Implementation

This feature needs some work to cleanup some tech debt. Before we spend the time on it, I wanted to kick off a conversation about whether or not we actually need or want this feature. It's currently not used on the public Access nodes, and does not appear to have ever been.

A couple examples of problematic code that should be fixed:

// naive cleanup for now, prune every 120 Blocks
if height%retryFrequency == 0 {
r.prune(height)
}

we will block the consensus follower while serially resending tx to collection nodes.

// ATTENTION: might be a source of problems in future. We run this code on finalization gorotuine,
// potentially lagging finalization events if operations take long time.
// We might need to move this logic on dedicated goroutine and provide a way to skip finalization events if they are delivered
// too often for this engine. An example of similar approach - https://github.com/onflow/flow-go/blob/10b0fcbf7e2031674c00f3cdd280f27bd1b16c47/engine/common/follower/compliance_engine.go#L201..
// No errors expected during normal operations.
func (b *backendTransactions) ProcessFinalizedBlockHeight(height uint64) error {
return b.retry.Retry(height)
}

The logic could be fixed, but it's only worth the time if we think we actually need/want this functionality at all. Under heavy load, if collection nodes start dropping transactions, ANs using this feature would continually resubmit them compounding the problem.

My opinion is we should remove the feature, but curious what other's opinion are.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions