使用运行 Moodle 1.9.X 的 InnoDB 的 MySql 的最佳隔离级别是多少

发布于 2024-08-24 21:56:46 字数 87 浏览 7 评论 0原文

Moodle 1.9.X 应该使用哪种 InnoDB 隔离级别。默认是 REPEATABLE READ,但是使用 READ COMMITTED 可以节省性能吗?

Which InnoDB isolation level should be used with Moodle 1.9.X. The default is REPEATABLE READ, is it save, however, to use READ COMMITTED for better performace?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(3

心是晴朗的。 2024-08-31 21:56:46

如果没有……获得……更详细的信息,您将不会得到明智的答案。这实际上不依赖于数据库的使用 - 你甚至可以混合它们。例如,在 Web 应用程序中只读取快速事务...

  • 表单时,您只读取,不写入
  • 在创建不需要可重复读取的 ,因为您只加载下拉菜单(例如)
    =>不需要比 ReadCommited 更多的隔离。

OTOH 如果您进行复杂的处理和更新,那么 ReadCommited 可能不够好。

我见过应用程序在不同部分使用多个不同级别。

You wont get a sensible answer.... without.... getting.... more detailed. This REALLY depends no the usage of the database - you may even MIX them. Read only fast transactions in a web application, for example...

  • you only read, no write when creating the form
  • you dont need repeatable read, as you only load drop downs (as example)
    => no need for more isolation than ReadCommited.

OTOH if you do complex processing, and updates, then ReadCommited may not be good enough.

I have seen application using multiple different levels in different parts.

白芷 2024-08-31 21:56:46

Moodle 将在 myisam 上运行,因此答案是“可能是的,但通过其他方式提高性能可能更容易,并且一旦这样做,在 Moodle.org 上获得其他问题的支持可能会更困难。”

Moodle will run on myisam, so the answer is 'probably yes, but it is probably easier to increase performance through other means and getting support with other issues on moodle.org may be harder once you do this.'

小ぇ时光︴ 2024-08-31 21:56:46

您可能想做的是一些分析。分析

下载并安装 XDebug,这是一个用于跟踪和分析 PHP 函数的 PHP 扩展。
有关 Xdebug 分析器的更多详细信息,请参阅此处

使用 Xdebug,可以很容易地找到瓶颈并了解某个函数或操作对内存和 CPU 的负荷有多大。

调整参数,尝试不同的设置和配置文件!

另外,请与 Moodle 社区分享结果。

What you might want to do is some profiling.

Download and install XDebug, a PHP extension for tracing and profiling PHP functions.
More details about the Xdebug profiler are available here.

With Xdebug, it's really easy to find bottlenecks and to understand how much a function or an operation is heavy for both memory and CPU.

Play with the parameters, try different settings and profile!

Also, please share the results with the Moodle community.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文