【等待事件】global cache cr request/gc current request

global cache cr request/gc current request
The session is waiting for all pending lock operations on the lock elements (le) attached to a lock context to complete. The session sits in a loop until all requests are complete, and this wait event is effectively a poll interval while waiting.
The event is waited for when a session is looking for a consistent read version of a block but cannot find it in its local cache. The wait implies that the current block is not cached locally. The wait ends when either a block or a grant arrives for all queued requests. Depending on whether the remote instance has the block cached or not, the requesting instance receives:


A CR block, resulting in the statistic "global cache cr block received" being incremented
A grant, resulting in the statistic "global cache gets" being incremented
A current block, resulting in the statistic "global cache current blocks received" being incremented.
In the second case, the global cache cr request wait completion is followed by a read I/O because a current block version must be read from disk. An example of this is a global cache CR request wait followed by a "db file sequential read" wait for the same block (P1 and P2 are the same) . If a remote instance has a CR version or a CURRENT version, it will in most cases ship the block. If the block is not cached anywhere else, the requestor will read the block from disk.


Parameters:


P1 = file#
P2 = block#
P3 = lenum


Reducing Waits / Wait times:


The average wait time for this event should be low because a CR request should not be blocked and therefore be bounded only by processing time and network latencies. In the event of high wait times and user response time complaints, the actions to be taken are:
Identify the session and SQL causing the CR requests and tune the SQL
Determine whether the cause is a small buffer cache by monitoring I/O rates on files and objects
Monitor statistics in <> to determine whether there are many CR reads of undo segment and/or violations of the lightweight rule (remote instances cannot produce a CR buffer because too much work is involved, such as reading data or undo from disk).
Distribute a workload more evenly to achieve better locality of access
Set the fairness threshold to 1 if blocks are more often read than modified

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/15747463/viewspace-1068658/,如需转载,请注明出处,否则将追究法律责任。

转载于:http://blog.itpub.net/15747463/viewspace-1068658/

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
在UniApp中,我们可以使用GlobalData来封装request请求。GlobalData是UniApp中的全局数据对象,可以在整个应用程序中共享数据。 首先,我们可以在main.js文件中创建一个GlobalData对象,并将其挂载到Vue的原型上,以便在整个应用程序中访问。我们可以在main.js文件中添加以下代码: ``` import Vue from 'vue' import App from './App' Vue.prototype.$GlobalData = { // 这里可以定义一些全局数据 // 例如:request请求的封装函数 request: function(options) { // 在这里可以进行request请求的相关逻辑 }, } const app = new Vue({ ...App }) app.$mount() ``` 然后,在需要发起request请求的地方,我们可以通过this.$GlobalData.request来调用封装好的request函数。例如,在一个页面中,我们可以这样使用: ``` export default { methods: { getData: function() { let url = 'http://example.com/api/data' // 发起request请求 this.$GlobalData.request({ url: url, method: 'GET', success: function(res) { // 请求成功的回调函数 console.log(res) }, fail: function(error) { // 请求失败的回调函数 console.error(error) } }) } } } ``` 这样,我们就可以使用GlobalData来封装request请求,并在整个应用程序中共享使用。通过这种方式,我们可以避免在各个页面中重复编写相同的request请求逻辑,提高代码的重用性和开发效率。同时,使用GlobalData对象也可以方便地管理全局的数据和方法。
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值