关于Goldengate中的Checkpoint和Checkpoint Lag

一.概要
前段时间,一个朋友问我关于goldengate中的Lag的问题。因涉及到Lag的详细行程过程,而我一直觉得Lag就是: 本进程处理一条记录的时间点和前一个进程处理该记录时的时间点的差距,因为一般情况下都是目标端的REP进程出现LAG的机会比较大,平时也更加侧重于如何去诊断LAG和优化,所以当纠结一些详细原因的时候就卡住了(到底是不是当前处理时间和源库产生的时间)。那既然要更加明确Lag是怎么回事,就需要了解ogg的checkpoint和Lag的原理。以下是相关官方文档的说法:

Checkpoints  store the current read and write positions of a process to disk for recovery purposes. Checkpoints ensure that data changes that are marked for synchronization actually are captured by Extract and applied to the target by Replicat, and they prevent redundant processing. They provide fault tolerance by preventing the loss of data should the system, the network, or an Oracle GoldenGate process need to be restarted. For complex synchronization configurations, checkpoints enable multiple Extract or Replicat processes to read from the same set of trails. Checkpoints work with inter-process acknowledgments to prevent messages from being lost in the network. Oracle GoldenGate has a proprietary guaranteed-message delivery technology.(通过这一段,说明checkpoint是用于记录进程当前到底处理到哪个位置的,这个checkpoint是用于防止数据的丢失和重复应用的。)

Extract creates checkpoints for its positions in the data source and in the trail. Because  Extract only captures committed transactions, it must keep track of operations in all open transactions, in the event that any of them are committed. This requires Extract to record
a checkpoint where it is currently reading in a transaction log, plus the position of the start of the oldest open transaction, which can be in the current or any preceding log. To control the amount of transaction log that must be re-processed after an outage, Extract persists the current state and data of processing to disk at specific intervals, including the state and data (if any) of long-running transactions. If Extract stops after one of these intervals, it can recover from a position within the previous interval or at the last checkpoint, instead of having to return to the log position where the oldest open longrunning transaction first appeared. For more information, see the BR parameter in the Oracle GoldenGate Windows and UNIX Referen
  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值