You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@servicecomb.apache.org by "Willem Jiang (JIRA)" <ji...@apache.org> on 2018/09/04 03:15:00 UTC
[jira] [Resolved] (SCB-885) saga alpha event scanner delete
duplicate events sql optimization
[ https://issues.apache.org/jira/browse/SCB-885?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Willem Jiang resolved SCB-885.
------------------------------
Resolution: Fixed
Merged the patch into master branch.
> saga alpha event scanner delete duplicate events sql optimization
> -----------------------------------------------------------------
>
> Key: SCB-885
> URL: https://issues.apache.org/jira/browse/SCB-885
> Project: Apache ServiceComb
> Issue Type: Improvement
> Components: Saga
> Affects Versions: saga-0.2.0
> Reporter: FuChenGeng
> Assignee: FuChenGeng
> Priority: Minor
> Fix For: saga-0.3.0
>
>
> The count of txevents is about 100m. and this sql spend too much time so that the event scanner is blocked.
> [SQL]DELETE FROM TxEvent t WHERE t.type = 'SagaEndedEvent' AND t.surrogateId NOT IN ( SELECT MAX(t1.surrogateId) FROM TxEvent t1 WHERE t1.type = 'SagaEndedEvent' GROUP BY t1.globalTxId);
>
> 时间: 1308.376s
>
> 受影响的行: 5
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)