Skip to main content

## index_is_due

# Function index_is_due

Source

    pub(crate) fn index_is_due(
        last_synced_at: Option<&str>,
        now: DateTime<Utc>,
        ttl: Duration,
    ) -> bool

Expand description

Whether an index pass is due, given when one last completed.

Pure so the policy is unit-testable without a clock, a server, or a database. `None` (never indexed) and an unparseable stored value both mean “due” — a corrupt timestamp should trigger a re-index, not silently freeze the catalog.

TRACES: UR-065 | DR-109 | UT-115