Skip to content

Commit

Permalink
Merge pull request #37 in N4FRA/debezium from DSOPS-101_session_loops…
Browse files Browse the repository at this point in the history
…_after_rollback_1 to master

Squashed commit of the following:

commit 996c0c0ff4c7989eb2469a8c2486de6f80e44484
Author: AndreyIg <gnyiny@gmail.com>
Date:   Thu Mar 12 13:11:16 2020 -0700

    DSOPS-101_session_loops_after_rollback

commit f49ae0bb1e205f7dce13c1ea342262cdd0b57ee8
Merge: 59b65a1b 76f9f80
Author: AndreyIg <gnyiny@gmail.com>
Date:   Thu Mar 12 13:04:47 2020 -0700

    Merge branch 'master' into DSOPS-101_session_loops_after_rollback

commit 76f9f80
Merge: 77e567e af6f8a3
Author: AndreyIg <gnyiny@gmail.com>
Date:   Wed Mar 11 12:33:09 2020 -0700

    Merge branch 'master' of http://git.navis.lan/scm/n4fra/debezium

commit 59b65a1ba27436e75774593d35a76a1379b5e830
Merge: ddd3c186 77e567e
Author: AndreyIg <gnyiny@gmail.com>
Date:   Mon Mar 9 12:08:39 2020 -0700

    Merge branch 'master' into DSOPS-101_session_loops_after_rollback

commit 77e567e
Merge: 8e3d922 0585b2b
Author: AndreyIg <gnyiny@gmail.com>
Date:   Mon Mar 9 12:07:58 2020 -0700

    Merge branch 'master' of http://git.navis.lan/scm/n4fra/debezium

commit ddd3c1867ca7fd5aea6f0d54c8b431e8bc6648f1
Author: AndreyIg <gnyiny@gmail.com>
Date:   Mon Mar 9 11:16:49 2020 -0700

    DSOPS-101, mining session loops after rollback

commit 8e3d922
Merge: a98bb75 d4bc528
Author: AndreyIg <gnyiny@gmail.com>
Date:   Sat Mar 7 04:26:18 2020 -0800

    Merge branch 'master' of http://git.navis.lan/scm/n4fra/debezium

commit a98bb75
Merge: c78c368 a23eb5a
Author: AndreyIg <gnyiny@gmail.com>
Date:   Sat Mar 7 04:12:31 2020 -0800

    Merge branch 'master' of http://git.navis.lan/scm/n4fra/debezium

commit c78c368
Merge: 90bcc19 4619fcd
Author: AndreyIg <gnyiny@gmail.com>
Date:   Fri Mar 6 06:52:42 2020 -0800

    Merge branch 'master' of http://git.navis.lan/scm/n4fra/debezium

commit 90bcc19
Merge: b5d1ea7 3e3aeea
Author: AndreyIg <gnyiny@gmail.com>
Date:   Mon Mar 2 14:31:07 2020 -0800

    Merge branch 'master' of http://git.navis.lan/scm/n4fra/debezium

commit b5d1ea7
Merge: 9686041 51f0dcb
Author: AndreyIg <gnyiny@gmail.com>
Date:   Wed Feb 26 17:17:38 2020 -0800

    Merge branch 'master' of http://git.navis.lan/scm/n4fra/debezium

commit 9686041
Merge: 926c648 4996a49
Author: AndreyIg <gnyiny@gmail.com>
Date:   Wed Feb 26 12:02:35 2020 -0800

    Merge branch 'master' of http://git.navis.lan/scm/n4fra/debezium

commit 926c648
Merge: 92140a3 829206c
Author: AndreyIg <gnyiny@gmail.com>
Date:   Wed Feb 26 10:49:29 2020 -0800

    Merge branch 'master' of http://git.navis.lan/scm/n4fra/debezium

commit 92140a3
Merge: 9fa48df 15a6c6c
Author: AndreyIg <gnyiny@gmail.com>
Date:   Tue Feb 25 18:14:58 2020 -0800

    Merge branch 'master' of http://git.navis.lan/scm/n4fra/debezium

commit 9fa48df
Merge: d3da472 27eb9af
Author: AndreyIg <gnyiny@gmail.com>
Date:   Fri Feb 14 16:11:29 2020 -0800

    Merge branch 'master' of http://git.navis.lan/scm/n4fra/debezium

commit d3da472
Merge: 86f3f65 081731f
Author: AndreyIg <gnyiny@gmail.com>
Date:   Mon Feb 3 16:18:33 2020 -0800

    Merge branch 'master' of http://git.navis.lan/scm/n4fra/debezium

commit 86f3f65
Author: AndreyIg <gnyiny@gmail.com>
Date:   Mon Feb 3 16:02:43 2020 -0800

    DSCON-117, DBConnector exception while incremental loading - revert

    This reverts commit c3a6023.

commit c3a6023
Author: AndreyIg <gnyiny@gmail.com>
Date:   Mon Feb 3 15:56:18 2020 -0800

    DSCON-117, DBConnector exception while incremental loading

commit 90f1823
Merge: 605d22f 8f53bba
Author: AndreyIg <gnyiny@gmail.com>
Date:   Mon Feb 3 13:52:09 2020 -0800

    Merge branch 'master' of http://git.navis.lan/scm/n4fra/debezium

commit 605d22f
Merge: 276c19b e68ada6
Author: AndreyIg <gnyiny@gmail.com>
Date:   Fri Jan 24 07:32:11 2020 -0800

    Merge branch 'master' of http://git.navis.lan/scm/n4fra/debezium

... and 16 more commits
  • Loading branch information
Ignatenko Andrey committed Mar 12, 2020
1 parent af6f8a3 commit e30cfbd
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ public static String getSqlRedo(ResultSet rs) {
return rs.getString(SQL_REDO);
} else {
result = new StringBuilder(rs.getString(SQL_REDO));
int lobLimit = 10000; // todo : decide on approach ( XStream chunk option) and Lob limit
int lobLimit = 40000; // todo : decide on approach ( XStream chunk option) and Lob limit
BigDecimal scn = getScn(rs);
while (csf == 1) {
rs.next();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -259,21 +259,25 @@ private void calculateLargestScn() {
* @return true if the rollback is for a transaction in the buffer
*/
boolean rollback(String transactionId, String debugMessage) {
Transaction transaction = transactions.remove(transactionId);

Transaction transaction = transactions.get(transactionId);
if (transaction != null) {
LOGGER.debug("Transaction {} rolled back", transactionId, debugMessage);
LOGGER.debug("Transaction {} rolled back, {}", transactionId, debugMessage);

transaction.lastScn = transaction.lastScn.add(BigDecimal.ONE);
calculateLargestScn();
calculateSmallestScn();

abandonedTransactionIds.remove(transactionId);
rolledBackTransactionIds.add(transactionId);

metrics.ifPresent(m -> m.setActiveTransactions(transactions.size()));
metrics.ifPresent(TransactionalBufferMetrics::incrementRolledBackTransactions);
metrics.ifPresent(m -> m.addRolledBackTransactionId(transactionId));

calculateSmallestScn();
calculateLargestScn();

return true;
}

transactions.remove(transactionId);
return false;
}

Expand Down

0 comments on commit e30cfbd

Please sign in to comment.