{"id":3611,"date":"2016-11-28T14:00:13","date_gmt":"2016-11-28T18:00:13","guid":{"rendered":"http:\/\/www.acarlstein.com\/?p=3611"},"modified":"2016-11-28T14:02:57","modified_gmt":"2016-11-28T18:02:57","slug":"architectural-principles","status":"publish","type":"post","link":"http:\/\/blog.acarlstein.com\/?p=3611","title":{"rendered":"Architectural Principles"},"content":{"rendered":"<h3>Service Autonomy Principles<\/h3>\n<ul>\n<li>One service should not depend and\/or rely on any other service to do its work.\n<ul>\n<li>Any service failing should not affect other services.<\/li>\n<\/ul>\n<\/li>\n<li>Any external service should be considered unstable and be expected to fail\n<ul>\n<li>If any external service fails then there should not be a cascade of these failures into our service, we should instead degrade the functionality so that such failure doesn\u2019t become catastrophic to our service.<\/li>\n<\/ul>\n<\/li>\n<li>Each service update should be dependent without requiring any other service to coordinate updates as well. In other words, the update of any service should affect the rest of services.<\/li>\n<li>Services should have the ability to be changes and deployed any time<\/li>\n<\/ul>\n<h3>No Coordinated Transactions Principles<\/h3>\n<ul>\n<li>One service should not be forced to enroll in a transaction which is owned by another service.\n<ul>\n<li>The service should not rely on other services<\/li>\n<li>The service should not be allowed to do complex transactions, be involved with multiple services changing continuously of states, and\/or interacting with multiple services and\/or objects.<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<h3>Microchanges Priciples<\/h3>\n<ul>\n<li>ACID 2.0 model.\n<ul>\n<li>Commutative. Idempotent. Distributed.<\/li>\n<li>Achieving high throughput by altering our data model.<\/li>\n<\/ul>\n<\/li>\n<li>Create as small of database transactions as is logical.<\/li>\n<li>Change as little as possible.<\/li>\n<li>As events, capture user-intent rather than data objects<\/li>\n<\/ul>\n<h3>Change Tolerant Principles<\/h3>\n<ul>\n<li>Defensive coding.<\/li>\n<li>How tolerant is your service in respect to other services changing?\n<ul>\n<li>How the service will react to failures?<\/li>\n<li>How the service will react with changes in another service\u2019s API?<\/li>\n<li>How the service will react with changes in events and\/or messages it receive?<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<p><strong>Articles Related<\/strong><\/p>\n<ul>\n<li><a href=\"https:\/\/lostechies.com\/jimmybogard\/2013\/06\/06\/acid-2-0-in-action\/\">ACID 2.0 Article<\/a>: <p class=\"d12srcp\">Jimmi Bogard. \u201cACID 2.0 in action.\u201d <i>Los Techies<\/i>. . (2013): . . https:\/\/lostechies.com\/jimmybogard\/2013\/06\/06\/acid-2-0-in-action\/<\/p><\/li>\n<\/ul>\n\n<script>\nvar zbPregResult = '0';\n<\/script>\n","protected":false},"excerpt":{"rendered":"<p>Service Autonomy Principles One service should not depend and\/or rely on any other service to do its work. Any service failing should not affect other services. Any external service should be considered unstable and be expected to fail If any external service fails then there should not be a cascade of these failures into our [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[19,1472],"tags":[1477,1473,1475,1476,1474,1418,1478,961],"class_list":["post-3611","post","type-post","status-publish","format-standard","hentry","category-programming","category-architecture","tag-acid","tag-architecture","tag-autonomy","tag-microchanges","tag-service","tag-services","tag-tolerant","tag-transaction"],"_links":{"self":[{"href":"http:\/\/blog.acarlstein.com\/index.php?rest_route=\/wp\/v2\/posts\/3611","targetHints":{"allow":["GET"]}}],"collection":[{"href":"http:\/\/blog.acarlstein.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/blog.acarlstein.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/blog.acarlstein.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/blog.acarlstein.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=3611"}],"version-history":[{"count":5,"href":"http:\/\/blog.acarlstein.com\/index.php?rest_route=\/wp\/v2\/posts\/3611\/revisions"}],"predecessor-version":[{"id":3616,"href":"http:\/\/blog.acarlstein.com\/index.php?rest_route=\/wp\/v2\/posts\/3611\/revisions\/3616"}],"wp:attachment":[{"href":"http:\/\/blog.acarlstein.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=3611"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/blog.acarlstein.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=3611"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/blog.acarlstein.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=3611"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}