本文介绍了指数如何应对MVCC?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

问候语Overflowers

Greetings Overflowers,


  • 根据我的理解(我希望我不正确),对索引的更改不能被MVCC。

  • 因为记录是通过索引(通常)访问的,所以MVCC如何

最近有关此主题的好看法吗?非常感谢!

Any recent good reading on this subject ? Really appreciated !

尊敬

推荐答案


  1. 索引本身可以具有可以在返回之前修剪的记录。所以在这种情况下,ondex单独不能用于获取记录(由PostGres完成的MVCC)。

  1. Index itself can have both the records which can be pruned before returning. So in this case ondex alone can't be used to get the records (the MVCC done by PostGres). InnoDB/Oracle keeps only one version of data/index and using undo section it rebuilds the older versions for older transactions.

您在数据库中没有太多的副本一般使用定期复制将被垃圾收集(在PostGres)和Oracle / InnoDB将有undo部分,当事务被中止/提交时将被重用。如果你有太多的长时间运行的事务,你会有问题。

You wont have too many copies when DB is use in general as periodically copies will be garbage collected (In PostGres) and Oracle/InnoDB will have undo sections which will be reused when transaction is aborted/committed. If you have too many long running transaction obviously you will have problems.

索引是加快访问,更快地找到记录, ,索引在第一遍不需要准确,你可能需要看看元组,看看它是否在一个特定事务中的有效(如在PostGres)。

Indexes are to speed up the access, find the record faster, without touch all of them, Index need not be accurate in first pass, you may need to look at tuple to see if its valid in one particular transaction or not (like in PostGres). racle or InnoDB even index is versioned so you can get data from indexes itself.

以获取实现MVCC(PresGres和Oracle / InnoDB)的两种方法的详细信息。

Read this to get detail idea of two ways of implementing MVCC (PresGres and Oracle/InnoDB).

PS:我不是mysql / oracle / postgres内部专家,仍然在学习如何工作。

PS: I'm not expert in mysql/oracle/postgres internal, still learning how things work.

这篇关于指数如何应对MVCC?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-23 02:32