Skip to main content

Crate ruma_lean

Crate ruma_lean 

Source

Modules§

auth
Matrix Authorization Rules (Spec §10.4)

Structs§

HashMap
A hash map implemented with quadratic probing and SIMD lookup.
LeanEvent
A lightweight Matrix Event representation for Lean-equivalent resolution.
SubgraphResult
Result of conflicted subgraph computation with diagnostic info.

Enums§

KahnSortResult
Result of Kahn’s topological sort with diagnostic information.
StateResVersion
The version of the Matrix State Resolution algorithm to use.

Functions§

compute_v2_1_conflicted_subgraph
compute_v2_1_conflicted_subgraph_bounded
Bounded version of conflicted subgraph computation. max_auth_depth: If set, limits backwards traversal depth to prevent history-flooding DoS attacks where a rogue admin generates millions of spoofed events on a dead-end fork.
lean_kahn_sort
A simplified implementation of Kahn’s Topological Sort. Backward-compatible wrapper that returns an empty Vec on cycles.
lean_kahn_sort_detailed
Kahn’s Topological Sort with full diagnostic output. Returns a KahnSortResult that distinguishes between successful sorts and cycle detection, providing the stuck set for debugging.
resolve_lean