请输入您要查询的百科知识:

 

词条 Dancing tree
释义

  1. References

  2. External links

In computer science, a dancing tree is a tree data structure similar to B+ trees. It was invented by Hans Reiser, for use by the Reiser4 file system. As opposed to self-balancing binary search trees that attempt to keep their nodes balanced at all times, dancing trees only balance their nodes when flushing data to a disk (either because of memory constraints or because a transaction has completed).[1]

The idea behind this is to speed up file system operations by delaying optimization of the tree and only writing to disk when necessary, as writing to disk is thousands of times slower than writing to memory. Also, because this optimization is done less often than with other tree data structures, the optimization can be more extensive.

In some sense, this can be considered to be a self-balancing binary search tree that is optimized for storage on a slow medium, in that the on-disc form will always be balanced but will get no mid-transaction writes; doing so eases the difficulty (at the time) of adding and removing nodes, and instead performs these (slow) rebalancing operations at the same time as the (much slower) write to the storage medium.

However, a (negative) side effect of this behavior is witnessed in cases of unexpected shutdown, incomplete data writes, and other occurrences that may prevent the final (balanced) transaction from completing. In general, dancing trees will pose a greater difficulty for data recovery from incomplete transactions than a normal tree; though this can be addressed by either adding extra transaction logs or developing an algorithm to locate data on disk not previously present, then going through with the optimizations once more before continuing with any other pending operations/transactions.

References

1. ^{{cite web | url=http://www.namesys.com/v4/v4.html#dancing_tree | title=Reiser4 release notes - Dancing Tree | author=Hans Reiser | accessdate=2009-07-22 | publisher = Archive.org, as Namesys.com is no longer accessible |archiveurl = https://web.archive.org/web/20071024001500/http://www.namesys.com/v4/v4.html#dancing_tree |archivedate = 2007-10-24}}

External links

  • Software Engineering Based Reiser4 Design Principles
  • Description of the Reiser4 internal tree
{{CS-Trees}}{{compu-storage-stub}}

2 : Computer file systems|B-tree

随便看

 

开放百科全书收录14589846条英语、德语、日语等多语种百科知识,基本涵盖了大多数领域的百科知识,是一部内容自由、开放的电子版国际百科全书。

 

Copyright © 2023 OENC.NET All Rights Reserved
京ICP备2021023879号 更新时间:2024/9/22 7:11:23