General Graph Directory
General graph directory 允許 directory graph 出現 cycles。
A → B → C → ACycle 讓 sharing 最彈性,但 traversal 不能只照 tree walk,否則 backup、search、du 可能 infinite loop。Traversal algorithm 需要 visited set、link-following rule,或最大深度限制。
Deletion 也更難:reference count 無法處理 cycle 中互相指向但已不可達的 objects,可能需要 garbage collection。
Tradeoff
General graph 提供最大 sharing flexibility,但讓 traversal 與 storage reclamation 最複雜;多數 general-purpose file system 會限制 directory links 來避免這個問題。