| <!DOCTYPE html> |
| <html lang="en"> |
| <head> |
| <meta charset="UTF-8" /> |
| <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1" /> |
| <title>ACID transactions | Apache Ignite</title> |
| <link rel="stylesheet" href="/js/vendor/hystmodal/hystmodal.min.css" /> |
| <link rel="stylesheet" href="/js/vendor/swiper/swiper-bundle.min.css" /> |
| <link rel="stylesheet" href="/css/utils.css" /> |
| <link rel="stylesheet" href="/css/site.css" /> |
| <link rel="stylesheet" href="/css/media.css" media="only screen and (max-width:1199px)" /> |
| <link rel="icon" type="image/png" href="/img/favicon.png" /> |
| <link rel="stylesheet" href="../css/native-persistence.css" /> |
| <link rel="stylesheet" href="../css/acid-transactions.css" /> |
| </head> |
| <body> |
| <!-- MOBILE MENU START --> |
| <div class="hystmodal" id="jsMenuModal" aria-hidden="true"> |
| <div class="hystmodal__wrap"> |
| <div class="hystmodal__window mobmenu" role="dialog" aria-modal="true"> |
| <button data-hystclose class="hystmodal__close">Close</button> |
| <div class="mobmenu__wrap"> |
| <a href="/" class="mobmenu__logo"><img src="/img/logo.svg" alt="Логотип" /></a> |
| <div class="mobmenu__menu"> |
| <div class="mobmenu__h1 berlin">Navigation</div> |
| <ul> |
| <li> |
| <a href="/">Get started</a> |
| </li> |
| <li> |
| <a href="/features/">Features</a> |
| </li> |
| <li> |
| <a href="/community.html">Community</a> |
| </li> |
| <li> |
| <a href="/use-cases/provenusecases.html">Powered by</a> |
| </li> |
| <li> |
| <a href="https://ignite.apache.org/docs/latest/">Docs</a> |
| </li> |
| </ul> |
| </div> |
| <!-- //mobmenu__menu --> |
| </div> |
| <!-- //mobmenu__wrap --> |
| </div> |
| <!-- //mobmenu --> |
| </div> |
| </div> |
| <!-- MOBILE MENU END --> |
| <header class="hdr hdr__blue"> |
| <div class="cmtyhero__wrap flexi"> |
| <button class="hdr__burger" data-menumodal="#jsMenuModal"><img src="/img/menu.svg" alt="" /></button><a class="hdr__logo" href="/"><img class="hdr__logoimg" src="/img/logo-white.svg" alt="" /></a |
| ><a class="button hdr__button" href="/download.html">Download Ignite 2.11 </a> |
| <nav class="hdrmenu"> |
| <ul class="flexi"> |
| <li><a href="/">Get started</a></li> |
| <li><a class="hdrmenu__current" href="/features">Features</a></li> |
| <li><a href="/community.html">Community</a></li> |
| <li><a href="/use-cases/provenusecases.html">Powered by</a></li> |
| <li><a href="///ignite.apache.org/docs/latest/">Docs</a></li> |
| </ul> |
| </nav> |
| </div> |
| </header> |
| <header class="hdrfloat"> |
| <div class="cmtyhero__wrap flexi"> |
| <button class="hdr__burger" data-menumodal="#jsMenuModal"><img src="/img/menu.svg" alt="" /></button><a class="hdr__logo" href="/"><img class="hdr__logoimg" src="/img/logo.svg" alt="" /></a |
| ><a class="button hdr__button" href="/download.html">Download Ignite 2.11 </a> |
| <nav class="hdrmenu"> |
| <ul class="flexi"> |
| <li><a href="/">Get started</a></li> |
| <li><a class="hdrmenu__current" href="/features">Features</a></li> |
| <li><a href="/community.html">Community</a></li> |
| <li><a href="/use-cases/provenusecases.html">Powered by</a></li> |
| <li><a href="/docs.html">Docs</a></li> |
| </ul> |
| </nav> |
| </div> |
| </header> |
| <section class="innerhero"> |
| <div class="container innerhero__cont"> |
| <div class="innerhero__main"> |
| <h1 class="h1 innerhero__h1">Distributed ACID <br />Transactions</h1> |
| <div class="pt-2 h3">with Apache Ignite</div> |
| <div class="innerhero__descr pt-4 h5">Classical ACID transactions that let you update distributed data <br />consistently, durably and with in-memory speed</div> |
| <div class="innerhero__action"><a class="button innerhero__button" href="https://ignite.apache.org/docs/latest/index">Start Coding</a></div> |
| </div> |
| <img class="innerhero__pic innerhero__pic--acid" src="/img/features/acid/hero.svg" alt="Distributed ACID transactions" /> |
| </div> |
| </section> |
| <!-- /.innerhero--> |
| <section class="acid1 container"> |
| <h2 class="acid1__h2 h4">Update multiple records from different tables that span across many cluster nodes</h2> |
| <div class="acid1__wrap flexi"> |
| <div class="acid1__item"> |
| <div class="acid1__title fz20">Consistency</div> |
| <div class="acid1__text pt-3"><p>Ignite transactional APIs are used by banks to implement payments services that transfer money between accounts in real-time.</p></div> |
| </div> |
| <div class="acid1__item"> |
| <div class="acid1__title fz20">Durability</div> |
| <div class="acid1__text pt-3"><p>Multi-tier storage persists changes durably to disk. Committed transactions always survive failures, incomplete transactions are rolled back.</p></div> |
| </div> |
| <div class="acid1__item"> |
| <div class="acid1__title fz20">Fault-Tolerance</div> |
| <div class="acid1__text pt-3"><p>The transactional engine avoids inconsistencies even if your transaction is failed in the middle of a commit.</p></div> |
| </div> |
| </div> |
| </section> |
| <!-- /.acid1--> |
| <section class="acid2 container"> |
| <h2 class="acid2__h2"> |
| To guarantee data consistency, durability and fault-tolerance<br /> |
| <strong>Ignite implements the two-phase commit protocol</strong> |
| </h2> |
| <div class="acid2__wrap flexi pt-5"> |
| <div class="acid2__main"> |
| <p>In distributed systems, a transaction usually spans across multiple cluster nodes.</p> |
| <p>To handle possible distributed failures properly and avoid data inconsistencies cluster-wide, a two-phase commit protocol (2PC) is used.</p> |
| <h3 class="acid2__subtitle h5 pb-2">How ACID transactions work</h3> |
| <p>Whenever the records get updated within a transaction, Ignite keeps the transactional state in a local transaction map until the changes are committed.</p> |
| <p>At which point, the data is transferred to the participating remote nodes. Only the nodes that hold primary or backup copies of the data participate in the transaction.</p> |
| <p>If a transaction is mapped to a single node, then, Ignite optimizes the transaction execution by switching to the one-phase-commit (1PC) protocol.</p> |
| </div> |
| <aside class="acid2__right"><img class="acid2__funcimg" src="/img/features/acid/acid-func.svg" alt="" /></aside> |
| </div> |
| </section> |
| <!-- /.acid2--> |
| <section class="acid3 container pt-5"> |
| <h2 class="h4 acid3__title">Records are updated consistently across <br />memory and disk tiers</h2> |
| <div class="acid3__wrap pt-5 flexi"> |
| <div class="acid3__col"> |
| <h3 class="h5 pb-2">Transactions with Ignite native persistence</h3> |
| <p class="fz20 acid3__collead">In case of any failure you can always recover to a consistent state</p> |
| <div class="acid3__small pt-4"> |
| <p> |
| When native persistence mode is enabled and Apache Ignite is used as a database that scales beyond available memory capacity, the distributed transactions update data across memory and disk |
| in a consistent way. |
| </p> |
| <p> |
| All the changes stay durable, because they are written to the write-ahead log (WAL) files. It guarantees data consistency even if the cluster or individual nodes go down in the middle |
| of a transaction. |
| </p> |
| </div> |
| <a class="acid3__detlink" href="#" data-hideopen="acidbox"> WAL in details</a> |
| <div class="acid3__detwrap" data-hidebox="acidbox"> |
| <div class="acid3__detmore"> |
| <button class="acid3__close" data-hideopen="acidbox"><img src="/img/features/acid/icon-cross.svg" alt="" /></button> |
| <p>The purpose of the WAL is to propagate updates to the disk in the append-only mode, which is the fastest way to persist data to disk.</p> |
| <p class="pt-1"> |
| The WAL provides a recovery mechanism for failure scenarios when a single node or the whole cluster goes down. A cluster can always be recovered to the latest successfully committed transaction. |
| </p> |
| </div> |
| </div> |
| </div> |
| <div class="acid3__col"> |
| <h3 class="h5 pb-2">Transactions with external databases</h3> |
| <p class="fz20 acid3__collead">Your transactions will be updated both i external database and Apache Ignite</p> |
| <div class="acid3__small pt-4"> |
| <p> |
| When Apache Ignite is used as a caching layer for an external database, such as RDBMS, transactions span the cached data in Ignite as well as the data persisted in a database |
| supporting transactional APIs. |
| </p> |
| <p> |
| For instance, if a relational database is configured as a disk tier, Ignite writes the transactional changes to the database before sending a commit message to participating cluster |
| nodes. |
| </p> |
| <p>This way, if a transaction fails at the database level, Ignite can still send the rollback message to the cluster nodes, keeping the data consistent across memory and disk tiers.</p> |
| </div> |
| </div> |
| </div> |
| </section> |
| <section class="native-bottom container"> |
| <div class="native-bottom__grid"> |
| <article class="nativebotblock"> |
| <h3 class="h4 nativebotblock__title"><img class="nativebotblock__icon" src="/img/features/native-rocket.svg" alt="" /><span>Ready to Start?</span></h3> |
| <p class="nativebotblock__text">Create your transactional application <br />with Apache Ignite</p> |
| <a class="nativebotblock__link arrowlink" href="https://ignite.apache.org/docs/latest/key-value-api/transactions" target="_blank">Performing ACID Transactions</a> |
| </article> |
| <article class="nativebotblock nativebotblock--learn"> |
| <h3 class="h4 nativebotblock__title"><img class="nativebotblock__icon" src="/img/features/native-docs.svg" alt="" /><span>Want to Learn More?</span></h3> |
| <p class="nativebotblock__text">Ignite 3.0 advances its replication and transactional components with the support of the <strong>Raft consensus algorithm</strong></p> |
| <a class="nativebotblock__link arrowlink" href="https://cwiki.apache.org/confluence/display/IGNITE/IEP-61%3A+Common+Replication+Infrastructure" target="_blank">Ignite 3.0 and Raft Details</a> |
| </article> |
| </div> |
| </section> |
| <a class="scrollTop" href="#" |
| ><svg class="feather feather-chevron-up" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewbox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"> |
| <polyline points="18 15 12 9 6 15"></polyline></svg |
| ></a> |
| <script src="/js/vendor/hystmodal/hystmodal.min.js"></script> |
| <script src="/js/vendor/swiper/swiper-bundle.min.js"></script> |
| <script src="/js/vendor/waypoints.min.js"></script> |
| <script src="/js/main.js"></script> |
| </body> |
| </html> |