CINXE.COM

RubyGems - erp_integration - Versions diffs - 0.54.0 → 0.55.0 - Mend - Supply Chain Defender

<!DOCTYPE html> <html> <head> <title> RubyGems - erp_integration - Versions diffs - 0.54.0 → 0.55.0 - Mend - Supply Chain Defender </title> <link rel="icon" type="image/png" href="/packs/media/images/production/favicons/favicon-32x32-fa0286238d4d512e71dba3881cbbcc42.png" /> <link rel="mask-icon" type="image/x-icon" href="/packs/media/images/production/favicons/favicon-786db6a85c0dea068c1a7047338024d2.svg" /> <link rel="apple-touch-icon" type="image/png" href="/packs/media/images/production/favicons/apple-touch-icon-11491aa2351c88b3b48534d1576a2ff9.png" /> <link rel="shortcut icon" type="image/x-icon" href="/packs/media/images/production/favicons/favicon-81c62e5500c39bd10e99844e94455995.ico" /> <meta name="csrf-param" content="authenticity_token" /> <meta name="csrf-token" content="p0MxCOjbzdG4V6dmJ0j1MNvbrCHBybSlT-JmHPYjPQ53aupjlmXtpRPundRANOkTfY1WroekgxU8o66THUYPXw" /> <meta content='no-cache' name='turbolinks-cache-control'> <meta content='width=device-width, initial-scale=1' name='viewport'> <link rel="stylesheet" href="/packs/css/application-b44eb75784afb1e9f8ce.css" media="all" /> <script src="/packs/js/application-9f130b109122a7b55e22.js" data-turbolinks-track="reload"></script> <link href='https://fonts.googleapis.com/css?family=Nunito:200,200i,300,300i,400,400i,600,600i,700,700i,800,800i,900,900i' rel='stylesheet'> </head> <body class='registries ruby_gems diffs' id='page-top'> <div id='wrapper'> <div class='d-flex flex-column' id='content-wrapper'> <div id='content'> <nav class='navbar navbar-expand navbar-light bg-white topbar mb-4 shadow'> <a class='sidebar-brand d-flex align-items-center justify-content-center' href='/'> <div class='sidebar-brand-text mx-3 d-none d-xxl-block d-xl-block'> <img alt="Diffend" src="/packs/media/images/production/logos/vertical-dark-5363ad390f9fcfd11bfecf89a3fb60f1.svg" /> </div> </a> <div class='container'> <ul class='navbar-nav'> <li class='nav-item'> <a class='nav-link' href='/gems'> <span class='mr-2 d-none d-lg-inline text-gray-600'> RubyGems </span> </a> </li> <li class='nav-item'> <a class='nav-link' href='/npm'> <span class='mr-2 d-none d-lg-inline text-gray-600'> npm </span> </a> </li> <div class='topbar-divider d-sm-block'></div> <li class='nav-item'> <a class='nav-link' href='/organizations'> <span class='mr-2 d-none d-lg-inline text-gray-600'> Organizations </span> </a> </li> </ul> <ul class='navbar-nav'> <div class='topbar-divider d-none d-sm-block'></div> <li class='nav-item'> <a class='nav-link' href='/users/sign_in'> <span class='mr-2 d-none d-lg-inline text-gray-600'> <i class='fas fa-key fa-fw mr-2'></i> Log in </span> </a> </li> <li class='nav-item'> <a class='nav-link' href='/users/sign_up'> <span class='mr-2 d-none d-lg-inline text-gray-600'> <i class='fas fa-user-plus fa-fw mr-2'></i> Sign up </span> </a> </li> </ul> </div> </nav> <div class='container'> <div class='row'> <div class='col mb-1'> <nav> <ol class='breadcrumb'> <li class='breadcrumb-item'> <a href="/gems">RubyGems</a> </li> <li class='breadcrumb-item'> <a href="/gems/erp_integration">erp_integration</a> </li> <li class='breadcrumb-item'> <a href="/gems/erp_integration">Versions diffs</a> </li> <li class='breadcrumb-item'> <a href="/gems/erp_integration/0.54.0/0.55.0">0.54.0 → 0.55.0</a> </li> </ol> </nav> </div> </div> <div class='row'> <div class='col'> <div class='text-right mb-4'> </div> </div> </div> <div class='row'> <div class='col align-items-center mb-4'> <div class='text-center'> <h2 class='text-gray-800'> erp_integration 0.54.0 → 0.55.0 </h2> </div> </div> </div> <div data-diff-id='6e778d74-6289-4d50-a6d2-205cc8499241' data-diff-state='finished' id='diff-id'> <div class='row'> <div class='col pt-2 text-black'> <div class='row'> <div class='col-lg-12 mb-4 mt-2'> <div class='card bg-info text-white shadow'> <div class='card-body'> <span class='icon text-white-100 mr-2'> <i class='fas fa-info-circle'></i> </span> Sign up to get <strong>free</strong> protection for your applications and to get access to all the features. </div> </div> </div> </div> <div id='diff'> <div class='mb-3'> <div class="d2h-file-list-wrapper"> <div class="d2h-file-list-header"> <span class="d2h-file-list-title">Files changed (9)</span> <a class="d2h-file-switch d2h-hide">hide</a> <a class="d2h-file-switch d2h-show">show</a> </div> <ol class="d2h-file-list"> <li class="d2h-file-list-line"> <span class="d2h-file-name-wrapper"> <svg aria-hidden="true" class="d2h-icon d2h-changed" height="16" title="modified" version="1.1" viewBox="0 0 14 16" width="14"> <path d="M13 1H1C0.45 1 0 1.45 0 2v12c0 0.55 0.45 1 1 1h12c0.55 0 1-0.45 1-1V2c0-0.55-0.45-1-1-1z m0 13H1V2h12v12zM4 8c0-1.66 1.34-3 3-3s3 1.34 3 3-1.34 3-3 3-3-1.34-3-3z"></path> </svg> <a href="/gems/erp_integration/0.54.0/0.55.0/page/1#d2h-683205" class="d2h-file-name">checksums.yaml</a> <span class="d2h-file-stats"> <span class="d2h-lines-added">+4</span> <span class="d2h-lines-deleted">-4</span> </span> </span> </li> <li class="d2h-file-list-line"> <span class="d2h-file-name-wrapper"> <svg aria-hidden="true" class="d2h-icon d2h-changed" height="16" title="modified" version="1.1" viewBox="0 0 14 16" width="14"> <path d="M13 1H1C0.45 1 0 1.45 0 2v12c0 0.55 0.45 1 1 1h12c0.55 0 1-0.45 1-1V2c0-0.55-0.45-1-1-1z m0 13H1V2h12v12zM4 8c0-1.66 1.34-3 3-3s3 1.34 3 3-1.34 3-3 3-3-1.34-3-3z"></path> </svg> <a href="/gems/erp_integration/0.54.0/0.55.0/page/1#d2h-027470" class="d2h-file-name">data/README.md</a> <span class="d2h-file-stats"> <span class="d2h-lines-added">+41</span> <span class="d2h-lines-deleted">-0</span> </span> </span> </li> <li class="d2h-file-list-line"> <span class="d2h-file-name-wrapper"> <svg aria-hidden="true" class="d2h-icon d2h-changed" height="16" title="modified" version="1.1" viewBox="0 0 14 16" width="14"> <path d="M13 1H1C0.45 1 0 1.45 0 2v12c0 0.55 0.45 1 1 1h12c0.55 0 1-0.45 1-1V2c0-0.55-0.45-1-1-1z m0 13H1V2h12v12zM4 8c0-1.66 1.34-3 3-3s3 1.34 3 3-1.34 3-3 3-3-1.34-3-3z"></path> </svg> <a href="/gems/erp_integration/0.54.0/0.55.0/page/1#d2h-725330" class="d2h-file-name">data/lib/erp_integration/configuration.rb</a> <span class="d2h-file-stats"> <span class="d2h-lines-added">+12</span> <span class="d2h-lines-deleted">-0</span> </span> </span> </li> <li class="d2h-file-list-line"> <span class="d2h-file-name-wrapper"> <svg aria-hidden="true" class="d2h-icon d2h-changed" height="16" title="modified" version="1.1" viewBox="0 0 14 16" width="14"> <path d="M13 1H1C0.45 1 0 1.45 0 2v12c0 0.55 0.45 1 1 1h12c0.55 0 1-0.45 1-1V2c0-0.55-0.45-1-1-1z m0 13H1V2h12v12zM4 8c0-1.66 1.34-3 3-3s3 1.34 3 3-1.34 3-3 3-3-1.34-3-3z"></path> </svg> <a href="/gems/erp_integration/0.54.0/0.55.0/page/1#d2h-577302" class="d2h-file-name">data/lib/erp_integration/fulfil/client.rb</a> <span class="d2h-file-stats"> <span class="d2h-lines-added">+7</span> <span class="d2h-lines-deleted">-1</span> </span> </span> </li> <li class="d2h-file-list-line"> <span class="d2h-file-name-wrapper"> <svg aria-hidden="true" class="d2h-icon d2h-changed" height="16" title="modified" version="1.1" viewBox="0 0 14 16" width="14"> <path d="M13 1H1C0.45 1 0 1.45 0 2v12c0 0.55 0.45 1 1 1h12c0.55 0 1-0.45 1-1V2c0-0.55-0.45-1-1-1z m0 13H1V2h12v12zM4 8c0-1.66 1.34-3 3-3s3 1.34 3 3-1.34 3-3 3-3-1.34-3-3z"></path> </svg> <a href="/gems/erp_integration/0.54.0/0.55.0/page/1#d2h-803881" class="d2h-file-name">data/lib/erp_integration/middleware/logger.rb</a> <span class="d2h-file-stats"> <span class="d2h-lines-added">+2</span> <span class="d2h-lines-deleted">-0</span> </span> </span> </li> <li class="d2h-file-list-line"> <span class="d2h-file-name-wrapper"> <svg aria-hidden="true" class="d2h-icon d2h-added" height="16" title="added" version="1.1" viewBox="0 0 14 16" width="14"> <path d="M13 1H1C0.45 1 0 1.45 0 2v12c0 0.55 0.45 1 1 1h12c0.55 0 1-0.45 1-1V2c0-0.55-0.45-1-1-1z m0 13H1V2h12v12zM6 9H3V7h3V4h2v3h3v2H8v3H6V9z"></path> </svg> <a href="/gems/erp_integration/0.54.0/0.55.0/page/1#d2h-263535" class="d2h-file-name">data/lib/erp_integration/rate_limiter.rb</a> <span class="d2h-file-stats"> <span class="d2h-lines-added">+66</span> <span class="d2h-lines-deleted">-0</span> </span> </span> </li> <li class="d2h-file-list-line"> <span class="d2h-file-name-wrapper"> <svg aria-hidden="true" class="d2h-icon d2h-changed" height="16" title="modified" version="1.1" viewBox="0 0 14 16" width="14"> <path d="M13 1H1C0.45 1 0 1.45 0 2v12c0 0.55 0.45 1 1 1h12c0.55 0 1-0.45 1-1V2c0-0.55-0.45-1-1-1z m0 13H1V2h12v12zM4 8c0-1.66 1.34-3 3-3s3 1.34 3 3-1.34 3-3 3-3-1.34-3-3z"></path> </svg> <a href="/gems/erp_integration/0.54.0/0.55.0/page/1#d2h-491188" class="d2h-file-name">data/lib/erp_integration/version.rb</a> <span class="d2h-file-stats"> <span class="d2h-lines-added">+1</span> <span class="d2h-lines-deleted">-1</span> </span> </span> </li> <li class="d2h-file-list-line"> <span class="d2h-file-name-wrapper"> <svg aria-hidden="true" class="d2h-icon d2h-changed" height="16" title="modified" version="1.1" viewBox="0 0 14 16" width="14"> <path d="M13 1H1C0.45 1 0 1.45 0 2v12c0 0.55 0.45 1 1 1h12c0.55 0 1-0.45 1-1V2c0-0.55-0.45-1-1-1z m0 13H1V2h12v12zM4 8c0-1.66 1.34-3 3-3s3 1.34 3 3-1.34 3-3 3-3-1.34-3-3z"></path> </svg> <a href="/gems/erp_integration/0.54.0/0.55.0/page/1#d2h-801163" class="d2h-file-name">data/lib/erp_integration.rb</a> <span class="d2h-file-stats"> <span class="d2h-lines-added">+1</span> <span class="d2h-lines-deleted">-0</span> </span> </span> </li> <li class="d2h-file-list-line"> <span class="d2h-file-name-wrapper"> <svg aria-hidden="true" class="d2h-icon d2h-changed" height="16" title="modified" version="1.1" viewBox="0 0 14 16" width="14"> <path d="M13 1H1C0.45 1 0 1.45 0 2v12c0 0.55 0.45 1 1 1h12c0.55 0 1-0.45 1-1V2c0-0.55-0.45-1-1-1z m0 13H1V2h12v12zM4 8c0-1.66 1.34-3 3-3s3 1.34 3 3-1.34 3-3 3-3-1.34-3-3z"></path> </svg> <a href="/gems/erp_integration/0.54.0/0.55.0/page/1#d2h-004177" class="d2h-file-name">metadata</a> <span class="d2h-file-stats"> <span class="d2h-lines-added">+3</span> <span class="d2h-lines-deleted">-2</span> </span> </span> </li> </ol> </div> </div> <div id="d2h-683205" class="d2h-file-wrapper" data-lang="yaml"> <div class="d2h-file-header"> <span class="d2h-file-name-wrapper"> <svg aria-hidden="true" class="d2h-icon" height="16" version="1.1" viewBox="0 0 12 16" width="12"> <path d="M6 5H2v-1h4v1zM2 8h7v-1H2v1z m0 2h7v-1H2v1z m0 2h7v-1H2v1z m10-7.5v9.5c0 0.55-0.45 1-1 1H1c-0.55 0-1-0.45-1-1V2c0-0.55 0.45-1 1-1h7.5l3.5 3.5z m-1 0.5L8 2H1v12h10V5z"></path> </svg> <span class="d2h-file-name"><a href="#d2h-683205">checksums.yaml</a></span> <span class="d2h-tag d2h-changed d2h-changed-tag">CHANGED</span></span> <label class="d2h-file-collapse"> <input class="d2h-file-collapse-input" type="checkbox" name="viewed" value="viewed"> Viewed </label> </div> <div class="d2h-file-diff"> <div class="d2h-code-wrapper"> <table class="d2h-diff-table"> <tbody class="d2h-diff-tbody"> <tr> <td class="d2h-code-linenumber d2h-info"></td> <td class="d2h-info"> <div class="d2h-code-line">@@ -1,7 +1,7 @@</div> </td> </tr><tr> <td id="d2h-683205-23" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-683205-23"> <div class="line-num1">1</div> <div class="line-num2">1</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">---</span> </div> </td> </tr><tr> <td id="d2h-683205-34" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-683205-34"> <div class="line-num1">2</div> <div class="line-num2">2</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">SHA256:</span> </div> </td> </tr><tr> <td class="d2h-code-linenumber d2h-del d2h-change"> <div class="line-num1">3</div> <div class="line-num2"></div> </a></td> <td class="d2h-del d2h-change"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">-</span> <span class="d2h-code-line-ctn"> metadata.gz: <del>015dee8d29c0a8bcd763966f25c24b77efb9cd2e7ac4a1555aa104e9a708c2ec</del></span> </div> </td> </tr><tr> <td class="d2h-code-linenumber d2h-del d2h-change"> <div class="line-num1">4</div> <div class="line-num2"></div> </a></td> <td class="d2h-del d2h-change"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">-</span> <span class="d2h-code-line-ctn"> data.tar.gz: <del>92f5a27785677904bd7b0cd60fc5a033195ed99d64d9c16941fbb4d942db8b31</del></span> </div> </td> </tr><tr> <td class="d2h-code-linenumber d2h-ins d2h-change"> <div class="line-num1"></div> <div class="line-num2">3</div> </a></td> <td class="d2h-ins d2h-change"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> metadata.gz: <ins>865d21dfcb8c0caaed6bb6e76151e019424294a04c5a553c68459cbda871278b</ins></span> </div> </td> </tr><tr> <td class="d2h-code-linenumber d2h-ins d2h-change"> <div class="line-num1"></div> <div class="line-num2">4</div> </a></td> <td class="d2h-ins d2h-change"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> data.tar.gz: <ins>5da7b05a69bc74a8dcfa508ebe2b7b544e5902b26398b6da552fd139f20170f1</ins></span> </div> </td> </tr><tr> <td id="d2h-683205-89" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-683205-89"> <div class="line-num1">5</div> <div class="line-num2">5</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">SHA512:</span> </div> </td> </tr><tr> <td class="d2h-code-linenumber d2h-del d2h-change"> <div class="line-num1">6</div> <div class="line-num2"></div> </a></td> <td class="d2h-del d2h-change"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">-</span> <span class="d2h-code-line-ctn"> metadata.gz: <del>526e86fb610c85d0b5c69f36e2cf1b1c396ff36e6f74c2db6d9764eae9eb1f076d9ed7771b5347ac3060bbdbd047777c1901c427351a280bcb26bf49b6edb269</del></span> </div> </td> </tr><tr> <td class="d2h-code-linenumber d2h-del d2h-change"> <div class="line-num1">7</div> <div class="line-num2"></div> </a></td> <td class="d2h-del d2h-change"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">-</span> <span class="d2h-code-line-ctn"> data.tar.gz: <del>f876d9874077923090353f7e2c9d6766cae725fe1558345ba98f4d5cfc07495bb272f451205f04c6a957402fdf10bc756d69ad8792a55405c91a07ce856d5e4e</del></span> </div> </td> </tr><tr> <td class="d2h-code-linenumber d2h-ins d2h-change"> <div class="line-num1"></div> <div class="line-num2">6</div> </a></td> <td class="d2h-ins d2h-change"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> metadata.gz: <ins>ea5e4f2a3f0e8bec393964d050ef9db305d1b7859032989d6899750306eba46efba5627e741fc469b95c215a23a42e6f6fcdee7f418f1ddf3da2f276cb201629</ins></span> </div> </td> </tr><tr> <td class="d2h-code-linenumber d2h-ins d2h-change"> <div class="line-num1"></div> <div class="line-num2">7</div> </a></td> <td class="d2h-ins d2h-change"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> data.tar.gz: <ins>71db26f1be6f150c53f34591d7ca46f7f89805fb65b5f44258c6dac86067bb8752feae8a08c11bf5cc4f6c096e7b3749b511583d1e3cf536921463e0d829e385</ins></span> </div> </td> </tr> </tbody> </table> </div> </div> </div> <div id="d2h-027470" class="d2h-file-wrapper" data-lang="md"> <div class="d2h-file-header"> <span class="d2h-file-name-wrapper"> <svg aria-hidden="true" class="d2h-icon" height="16" version="1.1" viewBox="0 0 12 16" width="12"> <path d="M6 5H2v-1h4v1zM2 8h7v-1H2v1z m0 2h7v-1H2v1z m0 2h7v-1H2v1z m10-7.5v9.5c0 0.55-0.45 1-1 1H1c-0.55 0-1-0.45-1-1V2c0-0.55 0.45-1 1-1h7.5l3.5 3.5z m-1 0.5L8 2H1v12h10V5z"></path> </svg> <span class="d2h-file-name"><a href="#d2h-027470">data/README.md</a></span> <span class="d2h-tag d2h-changed d2h-changed-tag">CHANGED</span></span> <label class="d2h-file-collapse"> <input class="d2h-file-collapse-input" type="checkbox" name="viewed" value="viewed"> Viewed </label> </div> <div class="d2h-file-diff"> <div class="d2h-code-wrapper"> <table class="d2h-diff-table"> <tbody class="d2h-diff-tbody"> <tr> <td class="d2h-code-linenumber d2h-info"></td> <td class="d2h-info"> <div class="d2h-code-line">@@ -61,6 +61,47 @@ ErpIntegration::SalesOrder.api_keys_pool = &#x27;&lt;your-api-key&gt;&#x27;</div> </td> </tr><tr> <td id="d2h-027470-171" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-027470-171"> <div class="line-num1">61</div> <div class="line-num2">61</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">ErpIntegration::SalesOrder.api_keys_pool = [&#x27;&lt;your-api-key1&gt;&#x27;, &#x27;&lt;your-api-key2&gt;&#x27;]</span> </div> </td> </tr><tr> <td id="d2h-027470-182" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-027470-182"> <div class="line-num1">62</div> <div class="line-num2">62</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">```</span> </div> </td> </tr><tr> <td id="d2h-027470-193" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-027470-193"> <div class="line-num1">63</div> <div class="line-num2">63</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-027470-204" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-204"> <div class="line-num1"></div> <div class="line-num2">64</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn">### Rate limiting</span> </div> </td> </tr><tr> <td id="d2h-027470-215" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-215"> <div class="line-num1"></div> <div class="line-num2">65</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-027470-226" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-226"> <div class="line-num1"></div> <div class="line-num2">66</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn">To manage the number of requests made to avoid rate limiting by the API provider, you can configure rate limiters in the ERP Integration gem. Each rate limiter should implement the `api_key_fragment` and `within_limit` methods.</span> </div> </td> </tr><tr> <td id="d2h-027470-237" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-237"> <div class="line-num1"></div> <div class="line-num2">67</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-027470-248" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-248"> <div class="line-num1"></div> <div class="line-num2">68</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn">### Setting Up Rate Limiters</span> </div> </td> </tr><tr> <td id="d2h-027470-259" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-259"> <div class="line-num1"></div> <div class="line-num2">69</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn">You can configure multiple rate limiters to be used for HTTP operations on the client.</span> </div> </td> </tr><tr> <td id="d2h-027470-270" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-270"> <div class="line-num1"></div> <div class="line-num2">70</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-027470-281" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-281"> <div class="line-num1"></div> <div class="line-num2">71</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn">```ruby</span> </div> </td> </tr><tr> <td id="d2h-027470-292" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-292"> <div class="line-num1"></div> <div class="line-num2">72</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"># config&#x2F;initializers&#x2F;erp_integration.rb</span> </div> </td> </tr><tr> <td id="d2h-027470-303" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-303"> <div class="line-num1"></div> <div class="line-num2">73</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn">ErpIntegration.configure do |config|</span> </div> </td> </tr><tr> <td id="d2h-027470-314" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-314"> <div class="line-num1"></div> <div class="line-num2">74</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> config.rate_limiters = [</span> </div> </td> </tr><tr> <td id="d2h-027470-325" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-325"> <div class="line-num1"></div> <div class="line-num2">75</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> MyRateLimiter.new(api_key_fragment: &#x27;key1&#x27;),</span> </div> </td> </tr><tr> <td id="d2h-027470-336" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-336"> <div class="line-num1"></div> <div class="line-num2">76</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> MyRateLimiter.new(api_key_fragment: &#x27;key2&#x27;)</span> </div> </td> </tr><tr> <td id="d2h-027470-347" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-347"> <div class="line-num1"></div> <div class="line-num2">77</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> ]</span> </div> </td> </tr><tr> <td id="d2h-027470-358" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-358"> <div class="line-num1"></div> <div class="line-num2">78</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn">end</span> </div> </td> </tr><tr> <td id="d2h-027470-369" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-369"> <div class="line-num1"></div> <div class="line-num2">79</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn">```</span> </div> </td> </tr><tr> <td id="d2h-027470-380" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-380"> <div class="line-num1"></div> <div class="line-num2">80</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-027470-391" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-391"> <div class="line-num1"></div> <div class="line-num2">81</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn">Each rate limiter must implement the following methods:</span> </div> </td> </tr><tr> <td id="d2h-027470-402" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-402"> <div class="line-num1"></div> <div class="line-num2">82</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn">- `api_key_fragment`: This method should return a string that is used to identify the rate limiter by the API key.</span> </div> </td> </tr><tr> <td id="d2h-027470-413" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-413"> <div class="line-num1"></div> <div class="line-num2">83</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn">- `within_limit`: This method should `yield` to the block if the rate limit is not exceeded.</span> </div> </td> </tr><tr> <td id="d2h-027470-424" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-424"> <div class="line-num1"></div> <div class="line-num2">84</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-027470-435" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-435"> <div class="line-num1"></div> <div class="line-num2">85</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn">### Example Rate Limiter</span> </div> </td> </tr><tr> <td id="d2h-027470-446" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-446"> <div class="line-num1"></div> <div class="line-num2">86</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn">Here is an example implementation of a rate limiter:</span> </div> </td> </tr><tr> <td id="d2h-027470-457" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-457"> <div class="line-num1"></div> <div class="line-num2">87</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-027470-468" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-468"> <div class="line-num1"></div> <div class="line-num2">88</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn">```ruby</span> </div> </td> </tr><tr> <td id="d2h-027470-479" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-479"> <div class="line-num1"></div> <div class="line-num2">89</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn">class MyRateLimiter</span> </div> </td> </tr><tr> <td id="d2h-027470-490" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-490"> <div class="line-num1"></div> <div class="line-num2">90</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> def initialize(api_key_fragment:)</span> </div> </td> </tr><tr> <td id="d2h-027470-501" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-501"> <div class="line-num1"></div> <div class="line-num2">91</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> @api_key_fragment = api_key_fragment</span> </div> </td> </tr><tr> <td id="d2h-027470-512" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-512"> <div class="line-num1"></div> <div class="line-num2">92</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> end</span> </div> </td> </tr><tr> <td id="d2h-027470-523" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-523"> <div class="line-num1"></div> <div class="line-num2">93</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-027470-534" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-534"> <div class="line-num1"></div> <div class="line-num2">94</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> def api_key_fragment</span> </div> </td> </tr><tr> <td id="d2h-027470-545" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-545"> <div class="line-num1"></div> <div class="line-num2">95</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> @api_key_fragment</span> </div> </td> </tr><tr> <td id="d2h-027470-556" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-556"> <div class="line-num1"></div> <div class="line-num2">96</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> end</span> </div> </td> </tr><tr> <td id="d2h-027470-567" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-567"> <div class="line-num1"></div> <div class="line-num2">97</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-027470-578" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-578"> <div class="line-num1"></div> <div class="line-num2">98</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> def within_limit</span> </div> </td> </tr><tr> <td id="d2h-027470-589" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-589"> <div class="line-num1"></div> <div class="line-num2">99</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> # Implement your rate limiting logic here</span> </div> </td> </tr><tr> <td id="d2h-027470-600" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-600"> <div class="line-num1"></div> <div class="line-num2">100</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> yield</span> </div> </td> </tr><tr> <td id="d2h-027470-611" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-611"> <div class="line-num1"></div> <div class="line-num2">101</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> end</span> </div> </td> </tr><tr> <td id="d2h-027470-622" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-622"> <div class="line-num1"></div> <div class="line-num2">102</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn">end</span> </div> </td> </tr><tr> <td id="d2h-027470-633" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-633"> <div class="line-num1"></div> <div class="line-num2">103</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn">```</span> </div> </td> </tr><tr> <td id="d2h-027470-644" class="d2h-code-linenumber d2h-ins"><a href="#d2h-027470-644"> <div class="line-num1"></div> <div class="line-num2">104</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-027470-655" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-027470-655"> <div class="line-num1">64</div> <div class="line-num2">105</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">### Supported Query Methods</span> </div> </td> </tr><tr> <td id="d2h-027470-666" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-027470-666"> <div class="line-num1">65</div> <div class="line-num2">106</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-027470-677" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-027470-677"> <div class="line-num1">66</div> <div class="line-num2">107</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">After configuring the gem, one can easily query all the available ERP resources from the connected third-parties. In all cases, the API will return a collection of resources.</span> </div> </td> </tr> </tbody> </table> </div> </div> </div> <div id="d2h-725330" class="d2h-file-wrapper" data-lang="rb"> <div class="d2h-file-header"> <span class="d2h-file-name-wrapper"> <svg aria-hidden="true" class="d2h-icon" height="16" version="1.1" viewBox="0 0 12 16" width="12"> <path d="M6 5H2v-1h4v1zM2 8h7v-1H2v1z m0 2h7v-1H2v1z m0 2h7v-1H2v1z m10-7.5v9.5c0 0.55-0.45 1-1 1H1c-0.55 0-1-0.45-1-1V2c0-0.55 0.45-1 1-1h7.5l3.5 3.5z m-1 0.5L8 2H1v12h10V5z"></path> </svg> <span class="d2h-file-name"><a href="#d2h-725330">data/lib/erp_integration/configuration.rb</a></span> <span class="d2h-tag d2h-changed d2h-changed-tag">CHANGED</span></span> <label class="d2h-file-collapse"> <input class="d2h-file-collapse-input" type="checkbox" name="viewed" value="viewed"> Viewed </label> </div> <div class="d2h-file-diff"> <div class="d2h-code-wrapper"> <table class="d2h-diff-table"> <tbody class="d2h-diff-tbody"> <tr> <td class="d2h-code-linenumber d2h-info"></td> <td class="d2h-info"> <div class="d2h-code-line">@@ -299,6 +299,18 @@ module ErpIntegration</div> </td> </tr><tr> <td id="d2h-725330-715" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-725330-715"> <div class="line-num1">299</div> <div class="line-num2">299</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"> def product_option_adapter</span> </div> </td> </tr><tr> <td id="d2h-725330-726" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-725330-726"> <div class="line-num1">300</div> <div class="line-num2">300</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"> @product_option_adapter || :fulfil</span> </div> </td> </tr><tr> <td id="d2h-725330-737" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-725330-737"> <div class="line-num1">301</div> <div class="line-num2">301</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"> end</span> </div> </td> </tr><tr> <td id="d2h-725330-748" class="d2h-code-linenumber d2h-ins"><a href="#d2h-725330-748"> <div class="line-num1"></div> <div class="line-num2">302</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-725330-759" class="d2h-code-linenumber d2h-ins"><a href="#d2h-725330-759"> <div class="line-num1"></div> <div class="line-num2">303</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> # Rate limiters that will be used for HTTP operations on Client</span> </div> </td> </tr><tr> <td id="d2h-725330-770" class="d2h-code-linenumber d2h-ins"><a href="#d2h-725330-770"> <div class="line-num1"></div> <div class="line-num2">304</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> # to manage the number of requests made to avoid rate limiting by the API provider.</span> </div> </td> </tr><tr> <td id="d2h-725330-781" class="d2h-code-linenumber d2h-ins"><a href="#d2h-725330-781"> <div class="line-num1"></div> <div class="line-num2">305</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> def rate_limiters</span> </div> </td> </tr><tr> <td id="d2h-725330-792" class="d2h-code-linenumber d2h-ins"><a href="#d2h-725330-792"> <div class="line-num1"></div> <div class="line-num2">306</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> @rate_limiters ||= []</span> </div> </td> </tr><tr> <td id="d2h-725330-803" class="d2h-code-linenumber d2h-ins"><a href="#d2h-725330-803"> <div class="line-num1"></div> <div class="line-num2">307</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> end</span> </div> </td> </tr><tr> <td id="d2h-725330-814" class="d2h-code-linenumber d2h-ins"><a href="#d2h-725330-814"> <div class="line-num1"></div> <div class="line-num2">308</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-725330-825" class="d2h-code-linenumber d2h-ins"><a href="#d2h-725330-825"> <div class="line-num1"></div> <div class="line-num2">309</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> # Sets the rate limiters that will be used</span> </div> </td> </tr><tr> <td id="d2h-725330-836" class="d2h-code-linenumber d2h-ins"><a href="#d2h-725330-836"> <div class="line-num1"></div> <div class="line-num2">310</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> # @raise [MissingMethodError] if the rate limiter object doesn&#x27;t respond to the required methods.</span> </div> </td> </tr><tr> <td id="d2h-725330-847" class="d2h-code-linenumber d2h-ins"><a href="#d2h-725330-847"> <div class="line-num1"></div> <div class="line-num2">311</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> def rate_limiters=(rate_limiters)</span> </div> </td> </tr><tr> <td id="d2h-725330-858" class="d2h-code-linenumber d2h-ins"><a href="#d2h-725330-858"> <div class="line-num1"></div> <div class="line-num2">312</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> @rate_limiters = rate_limiters.each { |limiter| RateLimiter.validate!(limiter) }</span> </div> </td> </tr><tr> <td id="d2h-725330-869" class="d2h-code-linenumber d2h-ins"><a href="#d2h-725330-869"> <div class="line-num1"></div> <div class="line-num2">313</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> end</span> </div> </td> </tr><tr> <td id="d2h-725330-880" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-725330-880"> <div class="line-num1">302</div> <div class="line-num2">314</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"> end</span> </div> </td> </tr><tr> <td id="d2h-725330-891" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-725330-891"> <div class="line-num1">303</div> <div class="line-num2">315</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-725330-902" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-725330-902"> <div class="line-num1">304</div> <div class="line-num2">316</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"> # Returns ERP Integration&#x27;s configuration.</span> </div> </td> </tr> </tbody> </table> </div> </div> </div> <div id="d2h-577302" class="d2h-file-wrapper" data-lang="rb"> <div class="d2h-file-header"> <span class="d2h-file-name-wrapper"> <svg aria-hidden="true" class="d2h-icon" height="16" version="1.1" viewBox="0 0 12 16" width="12"> <path d="M6 5H2v-1h4v1zM2 8h7v-1H2v1z m0 2h7v-1H2v1z m0 2h7v-1H2v1z m10-7.5v9.5c0 0.55-0.45 1-1 1H1c-0.55 0-1-0.45-1-1V2c0-0.55 0.45-1 1-1h7.5l3.5 3.5z m-1 0.5L8 2H1v12h10V5z"></path> </svg> <span class="d2h-file-name"><a href="#d2h-577302">data/lib/erp_integration/fulfil/client.rb</a></span> <span class="d2h-tag d2h-changed d2h-changed-tag">CHANGED</span></span> <label class="d2h-file-collapse"> <input class="d2h-file-collapse-input" type="checkbox" name="viewed" value="viewed"> Viewed </label> </div> <div class="d2h-file-diff"> <div class="d2h-code-wrapper"> <table class="d2h-diff-table"> <tbody class="d2h-diff-tbody"> <tr> <td class="d2h-code-linenumber d2h-info"></td> <td class="d2h-info"> <div class="d2h-code-line">@@ -48,7 +48,9 @@ module ErpIntegration</div> </td> </tr><tr> <td id="d2h-577302-940" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-577302-940"> <div class="line-num1">48</div> <div class="line-num2">48</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"> raise ErpIntegration::Error, &#x27;The Fulfil API key and&#x2F;or base URL are missing.&#x27;</span> </div> </td> </tr><tr> <td id="d2h-577302-951" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-577302-951"> <div class="line-num1">49</div> <div class="line-num2">49</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"> end</span> </div> </td> </tr><tr> <td id="d2h-577302-962" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-577302-962"> <div class="line-num1">50</div> <div class="line-num2">50</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td class="d2h-code-linenumber d2h-del d2h-change"> <div class="line-num1">51</div> <div class="line-num2"></div> </a></td> <td class="d2h-del d2h-change"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">-</span> <span class="d2h-code-line-ctn"> <del>connection</del>.<del>public_send(action_name,</del> <del>&quot;api&#x2F;#{version}&#x2F;#{path}&quot;, options).body</del></span> </div> </td> </tr><tr> <td class="d2h-code-linenumber d2h-ins d2h-change"> <div class="line-num1"></div> <div class="line-num2">51</div> </a></td> <td class="d2h-ins d2h-change"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> <ins>rate_limiter</ins>.<ins>within_limit</ins> <ins>do</ins></span> </div> </td> </tr><tr> <td id="d2h-577302-995" class="d2h-code-linenumber d2h-ins"><a href="#d2h-577302-995"> <div class="line-num1"></div> <div class="line-num2">52</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> connection.public_send(action_name, &quot;api&#x2F;#{version}&#x2F;#{path}&quot;, options).body</span> </div> </td> </tr><tr> <td id="d2h-577302-1006" class="d2h-code-linenumber d2h-ins"><a href="#d2h-577302-1006"> <div class="line-num1"></div> <div class="line-num2">53</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> end</span> </div> </td> </tr><tr> <td id="d2h-577302-1017" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-577302-1017"> <div class="line-num1">52</div> <div class="line-num2">54</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"> end</span> </div> </td> </tr><tr> <td id="d2h-577302-1028" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-577302-1028"> <div class="line-num1">53</div> <div class="line-num2">55</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"> end</span> </div> </td> </tr><tr> <td id="d2h-577302-1039" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-577302-1039"> <div class="line-num1">54</div> <div class="line-num2">56</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr> <tr> <td class="d2h-code-linenumber d2h-info"></td> <td class="d2h-info"> <div class="d2h-code-line">@@ -64,6 +66,10 @@ module ErpIntegration</div> </td> </tr><tr> <td id="d2h-577302-1056" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-577302-1056"> <div class="line-num1">64</div> <div class="line-num2">66</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"> api_keys_pool.current_key</span> </div> </td> </tr><tr> <td id="d2h-577302-1067" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-577302-1067"> <div class="line-num1">65</div> <div class="line-num2">67</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"> end</span> </div> </td> </tr><tr> <td id="d2h-577302-1078" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-577302-1078"> <div class="line-num1">66</div> <div class="line-num2">68</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-577302-1089" class="d2h-code-linenumber d2h-ins"><a href="#d2h-577302-1089"> <div class="line-num1"></div> <div class="line-num2">69</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> def rate_limiter</span> </div> </td> </tr><tr> <td id="d2h-577302-1100" class="d2h-code-linenumber d2h-ins"><a href="#d2h-577302-1100"> <div class="line-num1"></div> <div class="line-num2">70</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> RateLimiter.find_by_api_key(api_key)</span> </div> </td> </tr><tr> <td id="d2h-577302-1111" class="d2h-code-linenumber d2h-ins"><a href="#d2h-577302-1111"> <div class="line-num1"></div> <div class="line-num2">71</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> end</span> </div> </td> </tr><tr> <td id="d2h-577302-1122" class="d2h-code-linenumber d2h-ins"><a href="#d2h-577302-1122"> <div class="line-num1"></div> <div class="line-num2">72</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-577302-1133" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-577302-1133"> <div class="line-num1">67</div> <div class="line-num2">73</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"> def default_headers</span> </div> </td> </tr><tr> <td id="d2h-577302-1144" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-577302-1144"> <div class="line-num1">68</div> <div class="line-num2">74</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"> {</span> </div> </td> </tr><tr> <td id="d2h-577302-1155" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-577302-1155"> <div class="line-num1">69</div> <div class="line-num2">75</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"> &#x27;Accept&#x27;: &#x27;application&#x2F;json&#x27;,</span> </div> </td> </tr> </tbody> </table> </div> </div> </div> <div id="d2h-803881" class="d2h-file-wrapper" data-lang="rb"> <div class="d2h-file-header"> <span class="d2h-file-name-wrapper"> <svg aria-hidden="true" class="d2h-icon" height="16" version="1.1" viewBox="0 0 12 16" width="12"> <path d="M6 5H2v-1h4v1zM2 8h7v-1H2v1z m0 2h7v-1H2v1z m0 2h7v-1H2v1z m10-7.5v9.5c0 0.55-0.45 1-1 1H1c-0.55 0-1-0.45-1-1V2c0-0.55 0.45-1 1-1h7.5l3.5 3.5z m-1 0.5L8 2H1v12h10V5z"></path> </svg> <span class="d2h-file-name"><a href="#d2h-803881">data/lib/erp_integration/middleware/logger.rb</a></span> <span class="d2h-tag d2h-changed d2h-changed-tag">CHANGED</span></span> <label class="d2h-file-collapse"> <input class="d2h-file-collapse-input" type="checkbox" name="viewed" value="viewed"> Viewed </label> </div> <div class="d2h-file-diff"> <div class="d2h-code-wrapper"> <table class="d2h-diff-table"> <tbody class="d2h-diff-tbody"> <tr> <td class="d2h-code-linenumber d2h-info"></td> <td class="d2h-info"> <div class="d2h-code-line">@@ -43,6 +43,8 @@ module ErpIntegration</div> </td> </tr><tr> <td id="d2h-803881-1193" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-803881-1193"> <div class="line-num1">43</div> <div class="line-num2">43</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"> @formatter.exception(exc) if @formatter.respond_to?(:exception)</span> </div> </td> </tr><tr> <td id="d2h-803881-1204" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-803881-1204"> <div class="line-num1">44</div> <div class="line-num2">44</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"> end</span> </div> </td> </tr><tr> <td id="d2h-803881-1215" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-803881-1215"> <div class="line-num1">45</div> <div class="line-num2">45</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-803881-1226" class="d2h-code-linenumber d2h-ins"><a href="#d2h-803881-1226"> <div class="line-num1"></div> <div class="line-num2">46</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> # @param [String] api_key</span> </div> </td> </tr><tr> <td id="d2h-803881-1237" class="d2h-code-linenumber d2h-ins"><a href="#d2h-803881-1237"> <div class="line-num1"></div> <div class="line-num2">47</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> # @return [String] The last 4 characters of the API key</span> </div> </td> </tr><tr> <td id="d2h-803881-1248" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-803881-1248"> <div class="line-num1">46</div> <div class="line-num2">48</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"> def sanitize_api_key(api_key)</span> </div> </td> </tr><tr> <td id="d2h-803881-1259" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-803881-1259"> <div class="line-num1">47</div> <div class="line-num2">49</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"> api_key[-4..-1] if api_key</span> </div> </td> </tr><tr> <td id="d2h-803881-1270" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-803881-1270"> <div class="line-num1">48</div> <div class="line-num2">50</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"> end</span> </div> </td> </tr> </tbody> </table> </div> </div> </div> <div id="d2h-263535" class="d2h-file-wrapper" data-lang="rb"> <div class="d2h-file-header"> <span class="d2h-file-name-wrapper"> <svg aria-hidden="true" class="d2h-icon" height="16" version="1.1" viewBox="0 0 12 16" width="12"> <path d="M6 5H2v-1h4v1zM2 8h7v-1H2v1z m0 2h7v-1H2v1z m0 2h7v-1H2v1z m10-7.5v9.5c0 0.55-0.45 1-1 1H1c-0.55 0-1-0.45-1-1V2c0-0.55 0.45-1 1-1h7.5l3.5 3.5z m-1 0.5L8 2H1v12h10V5z"></path> </svg> <span class="d2h-file-name"><a href="#d2h-263535">data/lib/erp_integration/rate_limiter.rb</a></span> <span class="d2h-tag d2h-added d2h-added-tag">ADDED</span></span> <label class="d2h-file-collapse"> <input class="d2h-file-collapse-input" type="checkbox" name="viewed" value="viewed"> Viewed </label> </div> <div class="d2h-file-diff"> <div class="d2h-code-wrapper"> <table class="d2h-diff-table"> <tbody class="d2h-diff-tbody"> <tr> <td class="d2h-code-linenumber d2h-info"></td> <td class="d2h-info"> <div class="d2h-code-line">@@ -0,0 +1,66 @@</div> </td> </tr><tr> <td id="d2h-263535-1308" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1308"> <div class="line-num1"></div> <div class="line-num2">1</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"># frozen_string_literal: true</span> </div> </td> </tr><tr> <td id="d2h-263535-1319" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1319"> <div class="line-num1"></div> <div class="line-num2">2</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-263535-1330" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1330"> <div class="line-num1"></div> <div class="line-num2">3</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn">module ErpIntegration</span> </div> </td> </tr><tr> <td id="d2h-263535-1341" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1341"> <div class="line-num1"></div> <div class="line-num2">4</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> class RateLimiter</span> </div> </td> </tr><tr> <td id="d2h-263535-1352" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1352"> <div class="line-num1"></div> <div class="line-num2">5</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> class MissingMethodError &lt; StandardError; end</span> </div> </td> </tr><tr> <td id="d2h-263535-1363" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1363"> <div class="line-num1"></div> <div class="line-num2">6</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> # The `api_key_fragment` method should return a string that is used to identify</span> </div> </td> </tr><tr> <td id="d2h-263535-1374" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1374"> <div class="line-num1"></div> <div class="line-num2">7</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> # the rate limiter by the API key.</span> </div> </td> </tr><tr> <td id="d2h-263535-1385" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1385"> <div class="line-num1"></div> <div class="line-num2">8</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> #</span> </div> </td> </tr><tr> <td id="d2h-263535-1396" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1396"> <div class="line-num1"></div> <div class="line-num2">9</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> # The `within_limit` method should yield to the block if the rate limit is not exceeded.</span> </div> </td> </tr><tr> <td id="d2h-263535-1407" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1407"> <div class="line-num1"></div> <div class="line-num2">10</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> REQUIRED_METHODS = %i[api_key_fragment within_limit].freeze</span> </div> </td> </tr><tr> <td id="d2h-263535-1418" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1418"> <div class="line-num1"></div> <div class="line-num2">11</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-263535-1429" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1429"> <div class="line-num1"></div> <div class="line-num2">12</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> class &lt;&lt; self</span> </div> </td> </tr><tr> <td id="d2h-263535-1440" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1440"> <div class="line-num1"></div> <div class="line-num2">13</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> # Validates that the rate limiter object responds to the required methods.</span> </div> </td> </tr><tr> <td id="d2h-263535-1451" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1451"> <div class="line-num1"></div> <div class="line-num2">14</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> # It requires the `api_key_fragment` and `within_limit` methods to be present.</span> </div> </td> </tr><tr> <td id="d2h-263535-1462" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1462"> <div class="line-num1"></div> <div class="line-num2">15</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> #</span> </div> </td> </tr><tr> <td id="d2h-263535-1473" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1473"> <div class="line-num1"></div> <div class="line-num2">16</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> # @raise [MissingMethodError]</span> </div> </td> </tr><tr> <td id="d2h-263535-1484" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1484"> <div class="line-num1"></div> <div class="line-num2">17</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> # @param rate_limiter [Object]</span> </div> </td> </tr><tr> <td id="d2h-263535-1495" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1495"> <div class="line-num1"></div> <div class="line-num2">18</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> def validate!(rate_limiter)</span> </div> </td> </tr><tr> <td id="d2h-263535-1506" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1506"> <div class="line-num1"></div> <div class="line-num2">19</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> REQUIRED_METHODS.each do |method|</span> </div> </td> </tr><tr> <td id="d2h-263535-1517" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1517"> <div class="line-num1"></div> <div class="line-num2">20</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> next if rate_limiter.respond_to?(method)</span> </div> </td> </tr><tr> <td id="d2h-263535-1528" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1528"> <div class="line-num1"></div> <div class="line-num2">21</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-263535-1539" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1539"> <div class="line-num1"></div> <div class="line-num2">22</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> raise MissingMethodError, &quot;&#x27;#{rate_limiter.class}##{method}&#x27; method is required.&quot;</span> </div> </td> </tr><tr> <td id="d2h-263535-1550" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1550"> <div class="line-num1"></div> <div class="line-num2">23</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> end</span> </div> </td> </tr><tr> <td id="d2h-263535-1561" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1561"> <div class="line-num1"></div> <div class="line-num2">24</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> end</span> </div> </td> </tr><tr> <td id="d2h-263535-1572" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1572"> <div class="line-num1"></div> <div class="line-num2">25</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-263535-1583" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1583"> <div class="line-num1"></div> <div class="line-num2">26</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> # Finds the rate limiter by the API key.</span> </div> </td> </tr><tr> <td id="d2h-263535-1594" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1594"> <div class="line-num1"></div> <div class="line-num2">27</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> # If the API key is not found, it returns an unlimited rate limiter.</span> </div> </td> </tr><tr> <td id="d2h-263535-1605" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1605"> <div class="line-num1"></div> <div class="line-num2">28</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> #</span> </div> </td> </tr><tr> <td id="d2h-263535-1616" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1616"> <div class="line-num1"></div> <div class="line-num2">29</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> # @param api_key [String]</span> </div> </td> </tr><tr> <td id="d2h-263535-1627" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1627"> <div class="line-num1"></div> <div class="line-num2">30</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> # @return [Object] The rate limiter object.</span> </div> </td> </tr><tr> <td id="d2h-263535-1638" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1638"> <div class="line-num1"></div> <div class="line-num2">31</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> def find_by_api_key(api_key)</span> </div> </td> </tr><tr> <td id="d2h-263535-1649" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1649"> <div class="line-num1"></div> <div class="line-num2">32</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> rate_limiters[api_key] || unlimited</span> </div> </td> </tr><tr> <td id="d2h-263535-1660" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1660"> <div class="line-num1"></div> <div class="line-num2">33</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> end</span> </div> </td> </tr><tr> <td id="d2h-263535-1671" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1671"> <div class="line-num1"></div> <div class="line-num2">34</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-263535-1682" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1682"> <div class="line-num1"></div> <div class="line-num2">35</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> # Returns an unlimited rate limiter.</span> </div> </td> </tr><tr> <td id="d2h-263535-1693" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1693"> <div class="line-num1"></div> <div class="line-num2">36</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> #</span> </div> </td> </tr><tr> <td id="d2h-263535-1704" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1704"> <div class="line-num1"></div> <div class="line-num2">37</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> # @return [RateLimiter::Unlimited] The unlimited rate limiter object.</span> </div> </td> </tr><tr> <td id="d2h-263535-1715" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1715"> <div class="line-num1"></div> <div class="line-num2">38</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> def unlimited</span> </div> </td> </tr><tr> <td id="d2h-263535-1726" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1726"> <div class="line-num1"></div> <div class="line-num2">39</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> @unlimited ||= Unlimited.new</span> </div> </td> </tr><tr> <td id="d2h-263535-1737" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1737"> <div class="line-num1"></div> <div class="line-num2">40</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> end</span> </div> </td> </tr><tr> <td id="d2h-263535-1748" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1748"> <div class="line-num1"></div> <div class="line-num2">41</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-263535-1759" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1759"> <div class="line-num1"></div> <div class="line-num2">42</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> private</span> </div> </td> </tr><tr> <td id="d2h-263535-1770" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1770"> <div class="line-num1"></div> <div class="line-num2">43</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-263535-1781" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1781"> <div class="line-num1"></div> <div class="line-num2">44</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> # The `rate_limiters` hash stores the rate limiter objects found by the API key.</span> </div> </td> </tr><tr> <td id="d2h-263535-1792" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1792"> <div class="line-num1"></div> <div class="line-num2">45</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> #</span> </div> </td> </tr><tr> <td id="d2h-263535-1803" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1803"> <div class="line-num1"></div> <div class="line-num2">46</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> # @return [Hash] The rate limiters hash.</span> </div> </td> </tr><tr> <td id="d2h-263535-1814" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1814"> <div class="line-num1"></div> <div class="line-num2">47</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> def rate_limiters</span> </div> </td> </tr><tr> <td id="d2h-263535-1825" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1825"> <div class="line-num1"></div> <div class="line-num2">48</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> @rate_limiters ||= Hash.new do |h, api_key|</span> </div> </td> </tr><tr> <td id="d2h-263535-1836" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1836"> <div class="line-num1"></div> <div class="line-num2">49</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> h[api_key] = ErpIntegration.config.rate_limiters.find do |rate_limiter|</span> </div> </td> </tr><tr> <td id="d2h-263535-1847" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1847"> <div class="line-num1"></div> <div class="line-num2">50</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> api_key.end_with?(rate_limiter.api_key_fragment)</span> </div> </td> </tr><tr> <td id="d2h-263535-1858" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1858"> <div class="line-num1"></div> <div class="line-num2">51</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> end</span> </div> </td> </tr><tr> <td id="d2h-263535-1869" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1869"> <div class="line-num1"></div> <div class="line-num2">52</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> end</span> </div> </td> </tr><tr> <td id="d2h-263535-1880" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1880"> <div class="line-num1"></div> <div class="line-num2">53</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> end</span> </div> </td> </tr><tr> <td id="d2h-263535-1891" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1891"> <div class="line-num1"></div> <div class="line-num2">54</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> end</span> </div> </td> </tr><tr> <td id="d2h-263535-1902" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1902"> <div class="line-num1"></div> <div class="line-num2">55</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-263535-1913" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1913"> <div class="line-num1"></div> <div class="line-num2">56</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> # {Unlimited} is a rate limiter that allows all requests.</span> </div> </td> </tr><tr> <td id="d2h-263535-1924" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1924"> <div class="line-num1"></div> <div class="line-num2">57</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> # When the rate limiter wasn&#x27;t found by the API key, it defaults to this class.</span> </div> </td> </tr><tr> <td id="d2h-263535-1935" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1935"> <div class="line-num1"></div> <div class="line-num2">58</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> # Or if the `rate_limiters` option is not set in the configuration.</span> </div> </td> </tr><tr> <td id="d2h-263535-1946" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1946"> <div class="line-num1"></div> <div class="line-num2">59</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> class Unlimited</span> </div> </td> </tr><tr> <td id="d2h-263535-1957" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1957"> <div class="line-num1"></div> <div class="line-num2">60</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> # Executes the block without any restrictions.</span> </div> </td> </tr><tr> <td id="d2h-263535-1968" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1968"> <div class="line-num1"></div> <div class="line-num2">61</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> def within_limit</span> </div> </td> </tr><tr> <td id="d2h-263535-1979" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1979"> <div class="line-num1"></div> <div class="line-num2">62</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> yield</span> </div> </td> </tr><tr> <td id="d2h-263535-1990" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-1990"> <div class="line-num1"></div> <div class="line-num2">63</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> end</span> </div> </td> </tr><tr> <td id="d2h-263535-2001" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-2001"> <div class="line-num1"></div> <div class="line-num2">64</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> end</span> </div> </td> </tr><tr> <td id="d2h-263535-2012" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-2012"> <div class="line-num1"></div> <div class="line-num2">65</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> end</span> </div> </td> </tr><tr> <td id="d2h-263535-2023" class="d2h-code-linenumber d2h-ins"><a href="#d2h-263535-2023"> <div class="line-num1"></div> <div class="line-num2">66</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn">end</span> </div> </td> </tr> </tbody> </table> </div> </div> </div> <div id="d2h-491188" class="d2h-file-wrapper" data-lang="rb"> <div class="d2h-file-header"> <span class="d2h-file-name-wrapper"> <svg aria-hidden="true" class="d2h-icon" height="16" version="1.1" viewBox="0 0 12 16" width="12"> <path d="M6 5H2v-1h4v1zM2 8h7v-1H2v1z m0 2h7v-1H2v1z m0 2h7v-1H2v1z m10-7.5v9.5c0 0.55-0.45 1-1 1H1c-0.55 0-1-0.45-1-1V2c0-0.55 0.45-1 1-1h7.5l3.5 3.5z m-1 0.5L8 2H1v12h10V5z"></path> </svg> <span class="d2h-file-name"><a href="#d2h-491188">data/lib/erp_integration/version.rb</a></span> <span class="d2h-tag d2h-changed d2h-changed-tag">CHANGED</span></span> <label class="d2h-file-collapse"> <input class="d2h-file-collapse-input" type="checkbox" name="viewed" value="viewed"> Viewed </label> </div> <div class="d2h-file-diff"> <div class="d2h-code-wrapper"> <table class="d2h-diff-table"> <tbody class="d2h-diff-tbody"> <tr> <td class="d2h-code-linenumber d2h-info"></td> <td class="d2h-info"> <div class="d2h-code-line">@@ -1,5 +1,5 @@</div> </td> </tr><tr> <td id="d2h-491188-2061" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-491188-2061"> <div class="line-num1">1</div> <div class="line-num2">1</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"># frozen_string_literal: true</span> </div> </td> </tr><tr> <td id="d2h-491188-2072" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-491188-2072"> <div class="line-num1">2</div> <div class="line-num2">2</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-491188-2083" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-491188-2083"> <div class="line-num1">3</div> <div class="line-num2">3</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">module ErpIntegration</span> </div> </td> </tr><tr> <td class="d2h-code-linenumber d2h-del d2h-change"> <div class="line-num1">4</div> <div class="line-num2"></div> </a></td> <td class="d2h-del d2h-change"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">-</span> <span class="d2h-code-line-ctn"> VERSION = &#x27;0.<del>54</del>.0&#x27;</span> </div> </td> </tr><tr> <td class="d2h-code-linenumber d2h-ins d2h-change"> <div class="line-num1"></div> <div class="line-num2">4</div> </a></td> <td class="d2h-ins d2h-change"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> VERSION = &#x27;0.<ins>55</ins>.0&#x27;</span> </div> </td> </tr><tr> <td id="d2h-491188-2116" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-491188-2116"> <div class="line-num1">5</div> <div class="line-num2">5</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">end</span> </div> </td> </tr> </tbody> </table> </div> </div> </div> <div id="d2h-801163" class="d2h-file-wrapper" data-lang="rb"> <div class="d2h-file-header"> <span class="d2h-file-name-wrapper"> <svg aria-hidden="true" class="d2h-icon" height="16" version="1.1" viewBox="0 0 12 16" width="12"> <path d="M6 5H2v-1h4v1zM2 8h7v-1H2v1z m0 2h7v-1H2v1z m0 2h7v-1H2v1z m10-7.5v9.5c0 0.55-0.45 1-1 1H1c-0.55 0-1-0.45-1-1V2c0-0.55 0.45-1 1-1h7.5l3.5 3.5z m-1 0.5L8 2H1v12h10V5z"></path> </svg> <span class="d2h-file-name"><a href="#d2h-801163">data/lib/erp_integration.rb</a></span> <span class="d2h-tag d2h-changed d2h-changed-tag">CHANGED</span></span> <label class="d2h-file-collapse"> <input class="d2h-file-collapse-input" type="checkbox" name="viewed" value="viewed"> Viewed </label> </div> <div class="d2h-file-diff"> <div class="d2h-code-wrapper"> <table class="d2h-diff-table"> <tbody class="d2h-diff-tbody"> <tr> <td class="d2h-code-linenumber d2h-info"></td> <td class="d2h-info"> <div class="d2h-code-line">@@ -11,6 +11,7 @@ require &#x27;json&#x27;</div> </td> </tr><tr> <td id="d2h-801163-2154" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-801163-2154"> <div class="line-num1">11</div> <div class="line-num2">11</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">require_relative &#x27;erp_integration&#x2F;version&#x27;</span> </div> </td> </tr><tr> <td id="d2h-801163-2165" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-801163-2165"> <div class="line-num1">12</div> <div class="line-num2">12</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">require_relative &#x27;erp_integration&#x2F;errors&#x27;</span> </div> </td> </tr><tr> <td id="d2h-801163-2176" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-801163-2176"> <div class="line-num1">13</div> <div class="line-num2">13</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">require_relative &#x27;erp_integration&#x2F;api_keys_pool&#x27;</span> </div> </td> </tr><tr> <td id="d2h-801163-2187" class="d2h-code-linenumber d2h-ins"><a href="#d2h-801163-2187"> <div class="line-num1"></div> <div class="line-num2">14</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn">require_relative &#x27;erp_integration&#x2F;rate_limiter&#x27;</span> </div> </td> </tr><tr> <td id="d2h-801163-2198" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-801163-2198"> <div class="line-num1">14</div> <div class="line-num2">15</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">require_relative &#x27;erp_integration&#x2F;configuration&#x27;</span> </div> </td> </tr><tr> <td id="d2h-801163-2209" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-801163-2209"> <div class="line-num1">15</div> <div class="line-num2">16</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"><br></span> </div> </td> </tr><tr> <td id="d2h-801163-2220" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-801163-2220"> <div class="line-num1">16</div> <div class="line-num2">17</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"># Middleware</span> </div> </td> </tr> </tbody> </table> </div> </div> </div> <div id="d2h-004177" class="d2h-file-wrapper" data-lang=""> <div class="d2h-file-header"> <span class="d2h-file-name-wrapper"> <svg aria-hidden="true" class="d2h-icon" height="16" version="1.1" viewBox="0 0 12 16" width="12"> <path d="M6 5H2v-1h4v1zM2 8h7v-1H2v1z m0 2h7v-1H2v1z m0 2h7v-1H2v1z m10-7.5v9.5c0 0.55-0.45 1-1 1H1c-0.55 0-1-0.45-1-1V2c0-0.55 0.45-1 1-1h7.5l3.5 3.5z m-1 0.5L8 2H1v12h10V5z"></path> </svg> <span class="d2h-file-name"><a href="#d2h-004177">metadata</a></span> <span class="d2h-tag d2h-changed d2h-changed-tag">CHANGED</span></span> <label class="d2h-file-collapse"> <input class="d2h-file-collapse-input" type="checkbox" name="viewed" value="viewed"> Viewed </label> </div> <div class="d2h-file-diff"> <div class="d2h-code-wrapper"> <table class="d2h-diff-table"> <tbody class="d2h-diff-tbody"> <tr> <td class="d2h-code-linenumber d2h-info"></td> <td class="d2h-info"> <div class="d2h-code-line">@@ -1,7 +1,7 @@</div> </td> </tr><tr> <td id="d2h-004177-2258" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-004177-2258"> <div class="line-num1">1</div> <div class="line-num2">1</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">--- !ruby&#x2F;object:Gem::Specification</span> </div> </td> </tr><tr> <td id="d2h-004177-2269" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-004177-2269"> <div class="line-num1">2</div> <div class="line-num2">2</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">name: erp_integration</span> </div> </td> </tr><tr> <td id="d2h-004177-2280" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-004177-2280"> <div class="line-num1">3</div> <div class="line-num2">3</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">version: !ruby&#x2F;object:Gem::Version</span> </div> </td> </tr><tr> <td class="d2h-code-linenumber d2h-del d2h-change"> <div class="line-num1">4</div> <div class="line-num2"></div> </a></td> <td class="d2h-del d2h-change"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">-</span> <span class="d2h-code-line-ctn"> version: 0.<del>54</del>.0</span> </div> </td> </tr><tr> <td class="d2h-code-linenumber d2h-ins d2h-change"> <div class="line-num1"></div> <div class="line-num2">4</div> </a></td> <td class="d2h-ins d2h-change"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn"> version: 0.<ins>55</ins>.0</span> </div> </td> </tr><tr> <td id="d2h-004177-2313" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-004177-2313"> <div class="line-num1">5</div> <div class="line-num2">5</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">platform: ruby</span> </div> </td> </tr><tr> <td id="d2h-004177-2324" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-004177-2324"> <div class="line-num1">6</div> <div class="line-num2">6</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">authors:</span> </div> </td> </tr><tr> <td id="d2h-004177-2335" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-004177-2335"> <div class="line-num1">7</div> <div class="line-num2">7</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">- Stefan Vermaas</span> </div> </td> </tr> <tr> <td class="d2h-code-linenumber d2h-info"></td> <td class="d2h-info"> <div class="d2h-code-line">@@ -329,6 +329,7 @@ files:</div> </td> </tr><tr> <td id="d2h-004177-2352" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-004177-2352"> <div class="line-num1">329</div> <div class="line-num2">329</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">- lib&#x2F;erp_integration&#x2F;purchase_order.rb</span> </div> </td> </tr><tr> <td id="d2h-004177-2363" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-004177-2363"> <div class="line-num1">330</div> <div class="line-num2">330</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">- lib&#x2F;erp_integration&#x2F;purchase_order_line.rb</span> </div> </td> </tr><tr> <td id="d2h-004177-2374" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-004177-2374"> <div class="line-num1">331</div> <div class="line-num2">331</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">- lib&#x2F;erp_integration&#x2F;purchase_request.rb</span> </div> </td> </tr><tr> <td id="d2h-004177-2385" class="d2h-code-linenumber d2h-ins"><a href="#d2h-004177-2385"> <div class="line-num1"></div> <div class="line-num2">332</div> </a></td> <td class="d2h-ins"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn">- lib&#x2F;erp_integration&#x2F;rate_limiter.rb</span> </div> </td> </tr><tr> <td id="d2h-004177-2396" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-004177-2396"> <div class="line-num1">332</div> <div class="line-num2">333</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">- lib&#x2F;erp_integration&#x2F;resource.rb</span> </div> </td> </tr><tr> <td id="d2h-004177-2407" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-004177-2407"> <div class="line-num1">333</div> <div class="line-num2">334</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">- lib&#x2F;erp_integration&#x2F;resources&#x2F;errors.rb</span> </div> </td> </tr><tr> <td id="d2h-004177-2418" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-004177-2418"> <div class="line-num1">334</div> <div class="line-num2">335</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">- lib&#x2F;erp_integration&#x2F;resources&#x2F;persistence.rb</span> </div> </td> </tr> <tr> <td class="d2h-code-linenumber d2h-info"></td> <td class="d2h-info"> <div class="d2h-code-line">@@ -368,7 +369,7 @@ required_rubygems_version: !ruby&#x2F;object:Gem::Requirement</div> </td> </tr><tr> <td id="d2h-004177-2435" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-004177-2435"> <div class="line-num1">368</div> <div class="line-num2">369</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"> - !ruby&#x2F;object:Gem::Version</span> </div> </td> </tr><tr> <td id="d2h-004177-2446" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-004177-2446"> <div class="line-num1">369</div> <div class="line-num2">370</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn"> version: &#x27;0&#x27;</span> </div> </td> </tr><tr> <td id="d2h-004177-2457" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-004177-2457"> <div class="line-num1">370</div> <div class="line-num2">371</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">requirements: []</span> </div> </td> </tr><tr> <td class="d2h-code-linenumber d2h-del d2h-change"> <div class="line-num1">371</div> <div class="line-num2"></div> </a></td> <td class="d2h-del d2h-change"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">-</span> <span class="d2h-code-line-ctn">rubygems_version: 3.<del>5</del>.<del>11</del></span> </div> </td> </tr><tr> <td class="d2h-code-linenumber d2h-ins d2h-change"> <div class="line-num1"></div> <div class="line-num2">372</div> </a></td> <td class="d2h-ins d2h-change"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">+</span> <span class="d2h-code-line-ctn">rubygems_version: 3.<ins>2</ins>.<ins>22</ins></span> </div> </td> </tr><tr> <td id="d2h-004177-2490" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-004177-2490"> <div class="line-num1">372</div> <div class="line-num2">373</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">signing_key:</span> </div> </td> </tr><tr> <td id="d2h-004177-2501" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-004177-2501"> <div class="line-num1">373</div> <div class="line-num2">374</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">specification_version: 4</span> </div> </td> </tr><tr> <td id="d2h-004177-2512" class="d2h-code-linenumber d2h-cntx"><a href="#d2h-004177-2512"> <div class="line-num1">374</div> <div class="line-num2">375</div> </a></td> <td class="d2h-cntx"> <div class="d2h-code-line"> <span class="d2h-code-line-prefix">&nbsp;</span> <span class="d2h-code-line-ctn">summary: Connects Mejuri with third-party ERP vendors</span> </div> </td> </tr> </tbody> </table> </div> </div> </div> </div> </div> </div> </div> </div> <footer class='sticky-footer mt-3'> <div class='container text-center mb-3 copyright'> <a class='mr-4 text-gray-600' href='mailto:diffend@whitesourcesoftware.com'> Contact Us </a> <a class='mr-4 text-gray-600' href='https://www.whitesourcesoftware.com/terms-of-service/'> Terms of Service </a> <a class='mr-4 text-gray-600' href='https://www.whitesourcesoftware.com/privacy-policy/'> Privacy Policy </a> <a class='mr-4 text-gray-600' href='https://diffend.io/docs'> Docs </a> </div> <div class='container mt-4'> <div class='copyright text-center'> Copyright © 2024 Mend Software </div> </div> </footer> </div> </div> </div> </body> </html>

Pages: 1 2 3 4 5 6 7 8 9 10