python-peps/pep-0532/circuit-breaking-protocol.svg

2 lines
9.1 KiB
XML

<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="403px" height="324px" version="1.1" content="&lt;mxfile userAgent=&quot;Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:50.0) Gecko/20100101 Firefox/50.0&quot; version=&quot;6.0.1.5&quot; editor=&quot;www.draw.io&quot; type=&quot;google&quot;&gt;&lt;diagram&gt;7Vhdb5swFP01SN3DIsCB0Mcma9eHTZrUSV2fIgcMeHUwM6Yh/fW7BgPha236sa3TEimxj32vnXOvD9cx0GpbfBQ4jT/zgDDDNoPCQB8M27bmlgdfCtlXyGKOKiASNNCTWuCK3hMNmhrNaUCyzkTJOZM07YI+TxLiyw6GheC77rSQs+6qKY7IALjyMRui1zSQcYV6jtnil4RGcb2yZeqRLa4nayCLccB3BxA6N9BKcC6r1rZYEabIq3mp7C4mRpuNCZLIxxjYlcEdZrn+bYWhTFwG5ssNNCLVoGENgasGhZkbQfAtEWM2hGVkwmrfTBYtWtIh9zXHu5hKcpViX/V3kEcwKZZbBj0LmiFPpE4My1V9ytiKMy5Ka3TuqjfgmRT8ltQjCU9Is9gdEZIUk8RZTTggjwnfEilg32aTxDqCOoWbiO7ahLBcjcUHyYA0hnUORo3rNkzQ0JEajxoaRO2rgFafQhJA1uqu/uWC50lAlBuzyycpqPym4Jmjezf1SAK7OxhS3Rvt4DuRcq/DgHPJAeJCxjziCWafOE8nolVtVe2vQ3/Gc+FryNHnGouIaOrco4Nkd4OE7Bcgfz4g/wKXqf6Ps784ln37Ndh3BuxvQPlPtA69O1ZGGN4QtsT+bVTGpqcTPVG5KF+ThD5PT1BPT07toZ54I3pie88n1R2SWvE5W69lTJL1+qR4u9T2mEXe6e9jdvELZtUDEpjdv11mbecPUuu9IcWtqpC6VrQep8H2UIOd52pwE7Ex5rWXL5yC82kXrtV1Ue1ZW/Xi1+zoUSE9HZyWulDMUpzUpeI1KFJVcP7IVZ28HC9Zs4dK1trcsFfDelTGyoFZfuCyUIdAv/ep8HM4m8FYATuC6BWeViXfH25xajmwOeRmcCa6mQcxXj4gLnAjSdXItojU5W22wRn1ZwKuUSvMGM/VKuVNDqkDUd7gLOdYUQrD0Pb9yYNyMDNwN66jRpRQUbiCnTEaJTAm1WF7kceD3UnvORop5BfeUMMs6wXKmdrHsSm//9tT/onXyP8J3yR8yGh6qff4asnff4K/avZDt/1no3o8tP8PofOf&lt;/diagram&gt;&lt;/mxfile&gt;"><defs/><g transform="translate(0.5,0.5)"><rect x="111" y="1" width="160" height="30" fill="#e6e6e6" stroke="none" pointer-events="none"/><g transform="translate(127.5,6.5)"><switch><foreignObject style="overflow:visible;" pointer-events="all" width="126" height="18" requiredFeatures="http://www.w3.org/TR/SVG11/feature#Extensibility"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; font-size: 16px; font-family: Helvetica; color: rgb(0, 0, 0); line-height: 1.2; vertical-align: top; width: 127px; white-space: nowrap; overflow-wrap: normal; text-align: center;"><div xmlns="http://www.w3.org/1999/xhtml" style="display:inline-block;text-align:inherit;text-decoration:inherit;">x <b>if</b> breaker <b>else</b> y<br /></div></div></foreignObject><text x="63" y="17" fill="#000000" text-anchor="middle" font-size="16px" font-family="Helvetica">x &lt;b&gt;if&lt;/b&gt; breaker &lt;b&gt;else&lt;/b&gt; y&lt;br&gt;</text></switch></g><path d="M 191 101 L 96.24 166.38" fill="none" stroke="#000000" stroke-miterlimit="10" pointer-events="none"/><path d="M 91.92 169.37 L 95.69 162.51 L 96.24 166.38 L 99.67 168.27 Z" fill="#000000" stroke="#000000" stroke-miterlimit="10" pointer-events="none"/><g transform="translate(124.5,126.5)"><switch><foreignObject style="overflow:visible;" pointer-events="all" width="32" height="17" requiredFeatures="http://www.w3.org/TR/SVG11/feature#Extensibility"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; font-size: 16px; font-family: Helvetica; color: rgb(0, 0, 0); line-height: 1.2; vertical-align: top; white-space: nowrap; text-align: center;"><div xmlns="http://www.w3.org/1999/xhtml" style="display:inline-block;text-align:inherit;text-decoration:inherit;background-color:#ffffff;">True</div></div></foreignObject><text x="16" y="17" fill="#000000" text-anchor="middle" font-size="16px" font-family="Helvetica">True</text></switch></g><path d="M 191 101 L 305.48 166.83" fill="none" stroke="#000000" stroke-miterlimit="10" pointer-events="none"/><path d="M 310.03 169.44 L 302.22 168.99 L 305.48 166.83 L 305.71 162.92 Z" fill="#000000" stroke="#000000" stroke-miterlimit="10" pointer-events="none"/><g transform="translate(230.5,126.5)"><switch><foreignObject style="overflow:visible;" pointer-events="all" width="39" height="17" requiredFeatures="http://www.w3.org/TR/SVG11/feature#Extensibility"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; font-size: 16px; font-family: Helvetica; color: rgb(0, 0, 0); line-height: 1.2; vertical-align: top; white-space: nowrap; text-align: center;"><div xmlns="http://www.w3.org/1999/xhtml" style="display:inline-block;text-align:inherit;text-decoration:inherit;background-color:#ffffff;">False</div></div></foreignObject><text x="20" y="17" fill="#000000" text-anchor="middle" font-size="16px" font-family="Helvetica">False</text></switch></g><rect x="101" y="73" width="180" height="28" fill="#ffffff" stroke="#000000" pointer-events="none"/><g transform="translate(143.5,78.5)"><switch><foreignObject style="overflow:visible;" pointer-events="all" width="95" height="17" requiredFeatures="http://www.w3.org/TR/SVG11/feature#Extensibility"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; font-size: 16px; font-family: Helvetica; color: rgb(0, 0, 0); line-height: 1.2; vertical-align: top; width: 96px; white-space: nowrap; overflow-wrap: normal; text-align: center;"><div xmlns="http://www.w3.org/1999/xhtml" style="display:inline-block;text-align:inherit;text-decoration:inherit;">bool(breaker)</div></div></foreignObject><text x="48" y="17" fill="#000000" text-anchor="middle" font-size="16px" font-family="Helvetica">bool(breaker)</text></switch></g><rect x="1" y="170" width="180" height="28" fill="#ffffff" stroke="#000000" pointer-events="none"/><g transform="translate(19.5,175.5)"><switch><foreignObject style="overflow:visible;" pointer-events="all" width="142" height="17" requiredFeatures="http://www.w3.org/TR/SVG11/feature#Extensibility"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; font-size: 16px; font-family: Helvetica; color: rgb(0, 0, 0); line-height: 1.2; vertical-align: top; width: 143px; white-space: nowrap; overflow-wrap: normal; text-align: center;"><div xmlns="http://www.w3.org/1999/xhtml" style="display:inline-block;text-align:inherit;text-decoration:inherit;">breaker.__then__(x)</div></div></foreignObject><text x="71" y="17" fill="#000000" text-anchor="middle" font-size="16px" font-family="Helvetica">breaker.__then__(x)</text></switch></g><rect x="221" y="170" width="180" height="28" fill="#ffffff" stroke="#000000" pointer-events="none"/><g transform="translate(240.5,175.5)"><switch><foreignObject style="overflow:visible;" pointer-events="all" width="141" height="17" requiredFeatures="http://www.w3.org/TR/SVG11/feature#Extensibility"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; font-size: 16px; font-family: Helvetica; color: rgb(0, 0, 0); line-height: 1.2; vertical-align: top; width: 142px; white-space: nowrap; overflow-wrap: normal; text-align: center;"><div xmlns="http://www.w3.org/1999/xhtml" style="display:inline-block;text-align:inherit;text-decoration:inherit;">breaker.__else__(y)</div></div></foreignObject><text x="71" y="17" fill="#000000" text-anchor="middle" font-size="16px" font-family="Helvetica">breaker.__else__(y)</text></switch></g><path d="M 191 31 L 191 66.63" fill="none" stroke="#000000" stroke-miterlimit="10" pointer-events="none"/><path d="M 191 71.88 L 187.5 64.88 L 191 66.63 L 194.5 64.88 Z" fill="#000000" stroke="#000000" stroke-miterlimit="10" pointer-events="none"/><path d="M 25.5 306 L 3 306 L 3 211 L 181 211 L 181 306 L 40.5 306 L 18 321 Z" fill="#fff2cc" stroke="#d6b656" stroke-width="2" stroke-miterlimit="10" pointer-events="none"/><g transform="translate(12.5,218.5)"><switch><foreignObject style="overflow:visible;" pointer-events="all" width="158" height="76" requiredFeatures="http://www.w3.org/TR/SVG11/feature#Extensibility"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; font-size: 16px; font-family: Helvetica; color: rgb(0, 0, 0); line-height: 1.2; vertical-align: top; width: 159px; white-space: nowrap; overflow-wrap: normal; text-align: center;"><div xmlns="http://www.w3.org/1999/xhtml" style="display:inline-block;text-align:inherit;text-decoration:inherit;"><span>When "x <b>is</b> breaker",<br />this is a short-circuited<br /><br />"breaker <b>else</b> z"<br /></span></div></div></foreignObject><text x="79" y="46" fill="#000000" text-anchor="middle" font-size="16px" font-family="Helvetica">[Not supported by viewer]</text></switch></g><path d="M 243.5 306 L 221 306 L 221 211 L 399 211 L 399 306 L 258.5 306 L 236 321 Z" fill="#fff2cc" stroke="#d6b656" stroke-width="2" stroke-miterlimit="10" transform="translate(310,0)scale(-1,1)translate(-310,0)" pointer-events="none"/><g transform="translate(230.5,218.5)"><switch><foreignObject style="overflow:visible;" pointer-events="all" width="158" height="76" requiredFeatures="http://www.w3.org/TR/SVG11/feature#Extensibility"><div xmlns="http://www.w3.org/1999/xhtml" style="display: inline-block; font-size: 16px; font-family: Helvetica; color: rgb(0, 0, 0); line-height: 1.2; vertical-align: top; width: 159px; white-space: nowrap; overflow-wrap: normal; text-align: center;"><div xmlns="http://www.w3.org/1999/xhtml" style="display:inline-block;text-align:inherit;text-decoration:inherit;"><span>When "y <b>is</b> breaker",<br />this is a short-circuited<br /><br />"x <b>if</b> breaker"<br /></span></div></div></foreignObject><text x="79" y="46" fill="#000000" text-anchor="middle" font-size="16px" font-family="Helvetica">[Not supported by viewer]</text></switch></g></g></svg>