Skip to content

Reconsider ticket wait-time give-up: demote slow registrations instead of dropping, abandon only when replaceable by a shorter-wait candidate #73

Description

@srene

PR #62 drops a registration attempt when the ticket's cumulative WaitTime exceeds RegAttemptTimeout (1.5×AdLifetime), to avoid spending forever on a registrar that keeps returning long wait times.

Concern

A high-wait-time registrar may still be the only useful candidate for its bucket. Unconditionally giving up:

  1. drains the bucket's candidate pool — the same failure mode p2p/discover/topicindex: renew registrations on expiry instead of dropping them #70 addresses for expiry, and
  2. discards a registrar that would eventually admit us, with no guarantee a better one exists.

Proposal

Instead of dropping when WaitTime > threshold, demote the attempt to low priority (Standby) and abandon it only when there is a replacement candidate for the same bucket with a shorter wait time — opportunistic replacement, not unconditional give-up.

This mirrors #70's "demote-on-expiry instead of drop": prefer demotion over deletion; evict only when a strictly-better candidate is available.

Open questions

  • How to compare wait times across candidates (a replacement may not have a TICKET response yet).
  • Whether to keep the slow registrar's ticket warm in the background.
  • Interaction with RegBucketStandbyLimit (standby pool cap).

Design/discussion issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions