{"action":"created","comment":{"url":"https://api.github.com/repos/adessoAG/devblog/pulls/comments/195726380","pull_request_review_id":129153285,"id":195726380,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDE5NTcyNjM4MA==","diff_hunk":"@@ -0,0 +1,201 @@\n+---\n+layout:         [post, post-xml]\n+title:          \"Kommunikationsmuster in verteilten Systemen\"\n+date:           2018-05-25 12:01\n+modified_date:  2018-05-25 12:01\n+author:         thombergs\n+categories:     [Architekturen]\n+tags:           [Microservices]\n+---\n+\n+In einer verteilten Architektur spielt die Kommunikation der verteilten Services eine zentrale Rolle.\n+Wie sollen die Services miteinander reden? Sollten sie synchron kommunizieren? Oder asynchron über\n+einen Messaging-Mechanismus? Wie so oft ist dies keine einfache Entscheidung zwischen zwei Alternativen, die\n+Abhängig vom jeweiligen Kontext getroffen werden muss. Dieser Artikel beschreibt einige Kommunikationsmuster\n+zwischen verteilten Services.\n+\n+# Synchrone Aufrufe\n+\n+Das einfachste Kommunikationsmuster ist es, einen entfernten Service einfach synchron aufzurufen.\n+Dies geschieht heutzutage üblicherweise per REST:\n+\n+![Synchroner Aufruf](/assets/images/posts/communication-patterns/rest.jpg)\n+\n+Service 1 ruft Service 2 auf und wartet, bis dieser die Anfrage verarbeitet hat und eine Antwort geliefert hat.\n+Service 1 kann dann die Antwort von Service 2 in derselben Transaktion verarbeiten, in der auch die Anfrage\n+an Service 2 stattgefunden hat.\n+\n+Dieses Kommunikationsmuster ist leicht nachvollziehbar, schließlich nutzen wir alle es jeden Tag, wenn wir im Browser\n+eine beliebige Webseite öffnen. Synchrone Aufrufe werden auch technologisch gut unterstützt. Es gibt viele Libraries,\n+die synchrone Kommunikation über HTTP unterstützen, z.B. die Open Source Libraries [Feign](https://github.com/OpenFeign/feign)\n+und [Hystrix](https://github.com/Netflix/Hystrix) von Netflix.\n+\n+Beleuchten wir mal einige Vor- und Nachteile von synchroner Kommunikation:\n+\n+## Timeouts\n+\n+Was passiert, wenn Service 2 zwischendurch einfach mal sehr lange braucht, um eine Anfrage zu beantworten? Irgendwann\n+will Service 1 nicht mehr auf eine Antwort warten, was sich üblicherweise in einer Timeout-Exception niederschlägt, die\n+dafür sorgt, dass die lokale Transaktion in Service zurückgerollt wird.","path":"_posts/2018-05-25-microservice-kommunikationsmuster.md","position":39,"original_position":39,"commit_id":"88f55d815acc84ef2e390a185ce1139d30b370df","original_commit_id":"88f55d815acc84ef2e390a185ce1139d30b370df","user":{"login":"thombergs","id":1363578,"node_id":"MDQ6VXNlcjEzNjM1Nzg=","avatar_url":"https://avatars3.githubusercontent.com/u/1363578?v=4","gravatar_id":"","url":"https://api.github.com/users/thombergs","html_url":"https://github.com/thombergs","followers_url":"https://api.github.com/users/thombergs/followers","following_url":"https://api.github.com/users/thombergs/following{/other_user}","gists_url":"https://api.github.com/users/thombergs/gists{/gist_id}","starred_url":"https://api.github.com/users/thombergs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thombergs/subscriptions","organizations_url":"https://api.github.com/users/thombergs/orgs","repos_url":"https://api.github.com/users/thombergs/repos","events_url":"https://api.github.com/users/thombergs/events{/privacy}","received_events_url":"https://api.github.com/users/thombergs/received_events","type":"User","site_admin":false},"body":"done","created_at":"2018-06-15T13:08:14Z","updated_at":"2018-06-15T13:45:23Z","html_url":"https://github.com/adessoAG/devblog/pull/53#discussion_r195726380","pull_request_url":"https://api.github.com/repos/adessoAG/devblog/pulls/53","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/adessoAG/devblog/pulls/comments/195726380"},"html":{"href":"https://github.com/adessoAG/devblog/pull/53#discussion_r195726380"},"pull_request":{"href":"https://api.github.com/repos/adessoAG/devblog/pulls/53"}},"in_reply_to_id":191152583},"pull_request":{"url":"https://api.github.com/repos/adessoAG/devblog/pulls/53","id":190634719,"node_id":"MDExOlB1bGxSZXF1ZXN0MTkwNjM0NzE5","html_url":"https://github.com/adessoAG/devblog/pull/53","diff_url":"https://github.com/adessoAG/devblog/pull/53.diff","patch_url":"https://github.com/adessoAG/devblog/pull/53.patch","issue_url":"https://api.github.com/repos/adessoAG/devblog/issues/53","number":53,"state":"open","locked":false,"title":"Artikel über Kommunikationspatterns","user":{"login":"thombergs","id":1363578,"node_id":"MDQ6VXNlcjEzNjM1Nzg=","avatar_url":"https://avatars3.githubusercontent.com/u/1363578?v=4","gravatar_id":"","url":"https://api.github.com/users/thombergs","html_url":"https://github.com/thombergs","followers_url":"https://api.github.com/users/thombergs/followers","following_url":"https://api.github.com/users/thombergs/following{/other_user}","gists_url":"https://api.github.com/users/thombergs/gists{/gist_id}","starred_url":"https://api.github.com/users/thombergs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thombergs/subscriptions","organizations_url":"https://api.github.com/users/thombergs/orgs","repos_url":"https://api.github.com/users/thombergs/repos","events_url":"https://api.github.com/users/thombergs/events{/privacy}","received_events_url":"https://api.github.com/users/thombergs/received_events","type":"User","site_admin":false},"body":"Wenn du einen Pull-Request stellt, teile uns biite deine Änderungen mit, indem du die unten engegebene Publish-Checkliste nutzt. \r\n\r\n# Publish Checkliste\r\n\r\n- [X ] 1. Wurde der [Github Fork- und Pullprozess](https://reflectoring.io/github-fork-and-pull/) beachtet?\r\n- [ X] 2. Dateien eingebunden\r\n  - [ X] [Artikeldatei einbinden](https://github.com/adessoAG/devblog/blob/master/examples/2017-08-10-blog-post-guide.md#dateiname-und-ablageort)\r\n  - [ X] Autorenfoto: attets/images/avatars/mein_avatar.jpg/png\r\n  - [ X] [Artikel-Bilder hinterlegt](https://github.com/adessoAG/devblog/blob/master/examples/2017-08-10-blog-post-guide.md#bilder)\r\n- [ X] 3. Dateien angepasst:\r\n  - [ X] [Autorinfo gepflegt](https://github.com/adessoAG/devblog/blob/master/examples/2017-08-10-blog-post-guide.md#autoren-informationen)\r\n- [ X] 4. Artikel überprüfen:\r\n  - [ X] Metadaten: \"title\" vergeben\r\n\t- [X] Metadaten: \"date\" liegt in der Vergangenheit\r\n\t- [X] Metadaten: \"author\" angegeben\r\n\t- [X] Metadaten: \"categories [Java]\" enthält maximal eine der Hauptkategorien (Java, Microsoft, Methodik, Architekturen, Softwareentwicklung, Business & People)\r\n\t- [X] Metadaten: \"tags [Spring, Microservices]\" gesetzt\r\n\t- [X] [Einleitung/Teaser geschrieben](https://github.com/adessoAG/devblog/blob/master/examples/2017-08-10-blog-post-guide.md#einleitung--teaser)\r\n\t- [X] Rechtschreibung korrigiert\r\n\t- [X] [Bilder korrekt in den Artikel eingebunden](https://github.com/adessoAG/devblog/blob/master/examples/2017-08-10-blog-post-guide.md#bilder)\r\n\t- [x]  Reviewer angegeben (Liste mit Reviewern?)\r\n    - [x]  Online-Preview angesehen\r\n\r\n","created_at":"2018-05-25T16:12:13Z","updated_at":"2018-06-15T13:45:23Z","closed_at":null,"merged_at":null,"merge_commit_sha":"73e850dd46ec878bb217bc9709d516bf8935ae78","assignee":{"login":"thombergs","id":1363578,"node_id":"MDQ6VXNlcjEzNjM1Nzg=","avatar_url":"https://avatars3.githubusercontent.com/u/1363578?v=4","gravatar_id":"","url":"https://api.github.com/users/thombergs","html_url":"https://github.com/thombergs","followers_url":"https://api.github.com/users/thombergs/followers","following_url":"https://api.github.com/users/thombergs/following{/other_user}","gists_url":"https://api.github.com/users/thombergs/gists{/gist_id}","starred_url":"https://api.github.com/users/thombergs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thombergs/subscriptions","organizations_url":"https://api.github.com/users/thombergs/orgs","repos_url":"https://api.github.com/users/thombergs/repos","events_url":"https://api.github.com/users/thombergs/events{/privacy}","received_events_url":"https://api.github.com/users/thombergs/received_events","type":"User","site_admin":false},"assignees":[{"login":"thombergs","id":1363578,"node_id":"MDQ6VXNlcjEzNjM1Nzg=","avatar_url":"https://avatars3.githubusercontent.com/u/1363578?v=4","gravatar_id":"","url":"https://api.github.com/users/thombergs","html_url":"https://github.com/thombergs","followers_url":"https://api.github.com/users/thombergs/followers","following_url":"https://api.github.com/users/thombergs/following{/other_user}","gists_url":"https://api.github.com/users/thombergs/gists{/gist_id}","starred_url":"https://api.github.com/users/thombergs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thombergs/subscriptions","organizations_url":"https://api.github.com/users/thombergs/orgs","repos_url":"https://api.github.com/users/thombergs/repos","events_url":"https://api.github.com/users/thombergs/events{/privacy}","received_events_url":"https://api.github.com/users/thombergs/received_events","type":"User","site_admin":false}],"requested_reviewers":[],"requested_teams":[],"labels":[{"id":943217459,"node_id":"MDU6TGFiZWw5NDMyMTc0NTk=","url":"https://api.github.com/repos/adessoAG/devblog/labels/blogpost","name":"blogpost","color":"0e38f4","default":false}],"milestone":null,"commits_url":"https://api.github.com/repos/adessoAG/devblog/pulls/53/commits","review_comments_url":"https://api.github.com/repos/adessoAG/devblog/pulls/53/comments","review_comment_url":"https://api.github.com/repos/adessoAG/devblog/pulls/comments{/number}","comments_url":"https://api.github.com/repos/adessoAG/devblog/issues/53/comments","statuses_url":"https://api.github.com/repos/adessoAG/devblog/statuses/88f55d815acc84ef2e390a185ce1139d30b370df","head":{"label":"thombergs:communication-patterns","ref":"communication-patterns","sha":"88f55d815acc84ef2e390a185ce1139d30b370df","user":{"login":"thombergs","id":1363578,"node_id":"MDQ6VXNlcjEzNjM1Nzg=","avatar_url":"https://avatars3.githubusercontent.com/u/1363578?v=4","gravatar_id":"","url":"https://api.github.com/users/thombergs","html_url":"https://github.com/thombergs","followers_url":"https://api.github.com/users/thombergs/followers","following_url":"https://api.github.com/users/thombergs/following{/other_user}","gists_url":"https://api.github.com/users/thombergs/gists{/gist_id}","starred_url":"https://api.github.com/users/thombergs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thombergs/subscriptions","organizations_url":"https://api.github.com/users/thombergs/orgs","repos_url":"https://api.github.com/users/thombergs/repos","events_url":"https://api.github.com/users/thombergs/events{/privacy}","received_events_url":"https://api.github.com/users/thombergs/received_events","type":"User","site_admin":false},"repo":{"id":102643068,"node_id":"MDEwOlJlcG9zaXRvcnkxMDI2NDMwNjg=","name":"devblog","full_name":"thombergs/devblog","owner":{"login":"thombergs","id":1363578,"node_id":"MDQ6VXNlcjEzNjM1Nzg=","avatar_url":"https://avatars3.githubusercontent.com/u/1363578?v=4","gravatar_id":"","url":"https://api.github.com/users/thombergs","html_url":"https://github.com/thombergs","followers_url":"https://api.github.com/users/thombergs/followers","following_url":"https://api.github.com/users/thombergs/following{/other_user}","gists_url":"https://api.github.com/users/thombergs/gists{/gist_id}","starred_url":"https://api.github.com/users/thombergs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thombergs/subscriptions","organizations_url":"https://api.github.com/users/thombergs/orgs","repos_url":"https://api.github.com/users/thombergs/repos","events_url":"https://api.github.com/users/thombergs/events{/privacy}","received_events_url":"https://api.github.com/users/thombergs/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/thombergs/devblog","description":"adesso Developer Blog","fork":true,"url":"https://api.github.com/repos/thombergs/devblog","forks_url":"https://api.github.com/repos/thombergs/devblog/forks","keys_url":"https://api.github.com/repos/thombergs/devblog/keys{/key_id}","collaborators_url":"https://api.github.com/repos/thombergs/devblog/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/thombergs/devblog/teams","hooks_url":"https://api.github.com/repos/thombergs/devblog/hooks","issue_events_url":"https://api.github.com/repos/thombergs/devblog/issues/events{/number}","events_url":"https://api.github.com/repos/thombergs/devblog/events","assignees_url":"https://api.github.com/repos/thombergs/devblog/assignees{/user}","branches_url":"https://api.github.com/repos/thombergs/devblog/branches{/branch}","tags_url":"https://api.github.com/repos/thombergs/devblog/tags","blobs_url":"https://api.github.com/repos/thombergs/devblog/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/thombergs/devblog/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/thombergs/devblog/git/refs{/sha}","trees_url":"https://api.github.com/repos/thombergs/devblog/git/trees{/sha}","statuses_url":"https://api.github.com/repos/thombergs/devblog/statuses/{sha}","languages_url":"https://api.github.com/repos/thombergs/devblog/languages","stargazers_url":"https://api.github.com/repos/thombergs/devblog/stargazers","contributors_url":"https://api.github.com/repos/thombergs/devblog/contributors","subscribers_url":"https://api.github.com/repos/thombergs/devblog/subscribers","subscription_url":"https://api.github.com/repos/thombergs/devblog/subscription","commits_url":"https://api.github.com/repos/thombergs/devblog/commits{/sha}","git_commits_url":"https://api.github.com/repos/thombergs/devblog/git/commits{/sha}","comments_url":"https://api.github.com/repos/thombergs/devblog/comments{/number}","issue_comment_url":"https://api.github.com/repos/thombergs/devblog/issues/comments{/number}","contents_url":"https://api.github.com/repos/thombergs/devblog/contents/{+path}","compare_url":"https://api.github.com/repos/thombergs/devblog/compare/{base}...{head}","merges_url":"https://api.github.com/repos/thombergs/devblog/merges","archive_url":"https://api.github.com/repos/thombergs/devblog/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/thombergs/devblog/downloads","issues_url":"https://api.github.com/repos/thombergs/devblog/issues{/number}","pulls_url":"https://api.github.com/repos/thombergs/devblog/pulls{/number}","milestones_url":"https://api.github.com/repos/thombergs/devblog/milestones{/number}","notifications_url":"https://api.github.com/repos/thombergs/devblog/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/thombergs/devblog/labels{/name}","releases_url":"https://api.github.com/repos/thombergs/devblog/releases{/id}","deployments_url":"https://api.github.com/repos/thombergs/devblog/deployments","created_at":"2017-09-06T18:19:37Z","updated_at":"2018-05-25T16:10:22Z","pushed_at":"2018-05-25T16:16:18Z","git_url":"git://github.com/thombergs/devblog.git","ssh_url":"git@github.com:thombergs/devblog.git","clone_url":"https://github.com/thombergs/devblog.git","svn_url":"https://github.com/thombergs/devblog","homepage":null,"size":2971,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"adessoAG:master","ref":"master","sha":"8512476243576bee6865fd3dd25eb9748b1f983c","user":{"login":"adessoAG","id":1710422,"node_id":"MDEyOk9yZ2FuaXphdGlvbjE3MTA0MjI=","avatar_url":"https://avatars1.githubusercontent.com/u/1710422?v=4","gravatar_id":"","url":"https://api.github.com/users/adessoAG","html_url":"https://github.com/adessoAG","followers_url":"https://api.github.com/users/adessoAG/followers","following_url":"https://api.github.com/users/adessoAG/following{/other_user}","gists_url":"https://api.github.com/users/adessoAG/gists{/gist_id}","starred_url":"https://api.github.com/users/adessoAG/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adessoAG/subscriptions","organizations_url":"https://api.github.com/users/adessoAG/orgs","repos_url":"https://api.github.com/users/adessoAG/repos","events_url":"https://api.github.com/users/adessoAG/events{/privacy}","received_events_url":"https://api.github.com/users/adessoAG/received_events","type":"Organization","site_admin":false},"repo":{"id":97385250,"node_id":"MDEwOlJlcG9zaXRvcnk5NzM4NTI1MA==","name":"devblog","full_name":"adessoAG/devblog","owner":{"login":"adessoAG","id":1710422,"node_id":"MDEyOk9yZ2FuaXphdGlvbjE3MTA0MjI=","avatar_url":"https://avatars1.githubusercontent.com/u/1710422?v=4","gravatar_id":"","url":"https://api.github.com/users/adessoAG","html_url":"https://github.com/adessoAG","followers_url":"https://api.github.com/users/adessoAG/followers","following_url":"https://api.github.com/users/adessoAG/following{/other_user}","gists_url":"https://api.github.com/users/adessoAG/gists{/gist_id}","starred_url":"https://api.github.com/users/adessoAG/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adessoAG/subscriptions","organizations_url":"https://api.github.com/users/adessoAG/orgs","repos_url":"https://api.github.com/users/adessoAG/repos","events_url":"https://api.github.com/users/adessoAG/events{/privacy}","received_events_url":"https://api.github.com/users/adessoAG/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/adessoAG/devblog","description":"adesso Developer Blog","fork":false,"url":"https://api.github.com/repos/adessoAG/devblog","forks_url":"https://api.github.com/repos/adessoAG/devblog/forks","keys_url":"https://api.github.com/repos/adessoAG/devblog/keys{/key_id}","collaborators_url":"https://api.github.com/repos/adessoAG/devblog/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/adessoAG/devblog/teams","hooks_url":"https://api.github.com/repos/adessoAG/devblog/hooks","issue_events_url":"https://api.github.com/repos/adessoAG/devblog/issues/events{/number}","events_url":"https://api.github.com/repos/adessoAG/devblog/events","assignees_url":"https://api.github.com/repos/adessoAG/devblog/assignees{/user}","branches_url":"https://api.github.com/repos/adessoAG/devblog/branches{/branch}","tags_url":"https://api.github.com/repos/adessoAG/devblog/tags","blobs_url":"https://api.github.com/repos/adessoAG/devblog/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/adessoAG/devblog/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/adessoAG/devblog/git/refs{/sha}","trees_url":"https://api.github.com/repos/adessoAG/devblog/git/trees{/sha}","statuses_url":"https://api.github.com/repos/adessoAG/devblog/statuses/{sha}","languages_url":"https://api.github.com/repos/adessoAG/devblog/languages","stargazers_url":"https://api.github.com/repos/adessoAG/devblog/stargazers","contributors_url":"https://api.github.com/repos/adessoAG/devblog/contributors","subscribers_url":"https://api.github.com/repos/adessoAG/devblog/subscribers","subscription_url":"https://api.github.com/repos/adessoAG/devblog/subscription","commits_url":"https://api.github.com/repos/adessoAG/devblog/commits{/sha}","git_commits_url":"https://api.github.com/repos/adessoAG/devblog/git/commits{/sha}","comments_url":"https://api.github.com/repos/adessoAG/devblog/comments{/number}","issue_comment_url":"https://api.github.com/repos/adessoAG/devblog/issues/comments{/number}","contents_url":"https://api.github.com/repos/adessoAG/devblog/contents/{+path}","compare_url":"https://api.github.com/repos/adessoAG/devblog/compare/{base}...{head}","merges_url":"https://api.github.com/repos/adessoAG/devblog/merges","archive_url":"https://api.github.com/repos/adessoAG/devblog/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/adessoAG/devblog/downloads","issues_url":"https://api.github.com/repos/adessoAG/devblog/issues{/number}","pulls_url":"https://api.github.com/repos/adessoAG/devblog/pulls{/number}","milestones_url":"https://api.github.com/repos/adessoAG/devblog/milestones{/number}","notifications_url":"https://api.github.com/repos/adessoAG/devblog/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/adessoAG/devblog/labels{/name}","releases_url":"https://api.github.com/repos/adessoAG/devblog/releases{/id}","deployments_url":"https://api.github.com/repos/adessoAG/devblog/deployments","created_at":"2017-07-16T13:31:04Z","updated_at":"2018-06-13T13:25:49Z","pushed_at":"2018-06-04T16:54:00Z","git_url":"git://github.com/adessoAG/devblog.git","ssh_url":"git@github.com:adessoAG/devblog.git","clone_url":"https://github.com/adessoAG/devblog.git","svn_url":"https://github.com/adessoAG/devblog","homepage":"https://www.adesso.de/de/news/blog/index.jsp","size":5856,"stargazers_count":6,"watchers_count":6,"language":"JavaScript","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":16,"mirror_url":null,"archived":false,"open_issues_count":5,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":16,"open_issues":5,"watchers":6,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/adessoAG/devblog/pulls/53"},"html":{"href":"https://github.com/adessoAG/devblog/pull/53"},"issue":{"href":"https://api.github.com/repos/adessoAG/devblog/issues/53"},"comments":{"href":"https://api.github.com/repos/adessoAG/devblog/issues/53/comments"},"review_comments":{"href":"https://api.github.com/repos/adessoAG/devblog/pulls/53/comments"},"review_comment":{"href":"https://api.github.com/repos/adessoAG/devblog/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/adessoAG/devblog/pulls/53/commits"},"statuses":{"href":"https://api.github.com/repos/adessoAG/devblog/statuses/88f55d815acc84ef2e390a185ce1139d30b370df"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"thombergs"}}