{"action":"created","comment":{"url":"https://api.github.com/repos/nik1202/otus-spring-homework/pulls/comments/216152070","pull_request_review_id":153576289,"id":216152070,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIxNjE1MjA3MA==","diff_hunk":"@@ -0,0 +1,63 @@\n+package edu.otus.hw10.controller;\n+\n+import edu.otus.hw10.entities.Book;\n+import edu.otus.hw10.entities.Comment;\n+import edu.otus.hw10.service.BookService;\n+import lombok.extern.slf4j.Slf4j;\n+import org.springframework.beans.factory.annotation.Autowired;\n+import org.springframework.web.bind.annotation.DeleteMapping;\n+import org.springframework.web.bind.annotation.GetMapping;\n+import org.springframework.web.bind.annotation.PathVariable;\n+import org.springframework.web.bind.annotation.PostMapping;\n+import org.springframework.web.bind.annotation.PutMapping;\n+import org.springframework.web.bind.annotation.RequestBody;\n+import org.springframework.web.bind.annotation.RestController;\n+\n+import java.util.List;\n+\n+/**\n+ * Created by Nik Bespalov on 18/08/2018.\n+ *\n+ * @author Nik Bespalov.\n+ */\n+@Slf4j\n+@RestController\n+public class BookController {\n+    private BookService bookService;\n+\n+    @Autowired\n+    public BookController(BookService bookService) {\n+        this.bookService = bookService;\n+    }\n+\n+    @GetMapping({\"/books\"})\n+    public List<Book> list() {","path":"hw10/src/main/java/edu/otus/hw10/controller/BookController.java","position":34,"original_position":34,"commit_id":"778ddc39346de35ae268cc5331d58858f99841b4","original_commit_id":"778ddc39346de35ae268cc5331d58858f99841b4","user":{"login":"ydvorzhetskiy","id":5715941,"node_id":"MDQ6VXNlcjU3MTU5NDE=","avatar_url":"https://avatars2.githubusercontent.com/u/5715941?v=4","gravatar_id":"","url":"https://api.github.com/users/ydvorzhetskiy","html_url":"https://github.com/ydvorzhetskiy","followers_url":"https://api.github.com/users/ydvorzhetskiy/followers","following_url":"https://api.github.com/users/ydvorzhetskiy/following{/other_user}","gists_url":"https://api.github.com/users/ydvorzhetskiy/gists{/gist_id}","starred_url":"https://api.github.com/users/ydvorzhetskiy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ydvorzhetskiy/subscriptions","organizations_url":"https://api.github.com/users/ydvorzhetskiy/orgs","repos_url":"https://api.github.com/users/ydvorzhetskiy/repos","events_url":"https://api.github.com/users/ydvorzhetskiy/events{/privacy}","received_events_url":"https://api.github.com/users/ydvorzhetskiy/received_events","type":"User","site_admin":false},"body":"Вот лучше заводить спеициальные DTO. Просто тогда при изменении БД нужно будет менять UI, а это не очень. Предлагаю посмотреть пример из лекции.","created_at":"2018-09-09T09:11:29Z","updated_at":"2018-09-09T09:17:58Z","html_url":"https://github.com/nik1202/otus-spring-homework/pull/10#discussion_r216152070","pull_request_url":"https://api.github.com/repos/nik1202/otus-spring-homework/pulls/10","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/nik1202/otus-spring-homework/pulls/comments/216152070"},"html":{"href":"https://github.com/nik1202/otus-spring-homework/pull/10#discussion_r216152070"},"pull_request":{"href":"https://api.github.com/repos/nik1202/otus-spring-homework/pulls/10"}}},"pull_request":{"url":"https://api.github.com/repos/nik1202/otus-spring-homework/pulls/10","id":210759580,"node_id":"MDExOlB1bGxSZXF1ZXN0MjEwNzU5NTgw","html_url":"https://github.com/nik1202/otus-spring-homework/pull/10","diff_url":"https://github.com/nik1202/otus-spring-homework/pull/10.diff","patch_url":"https://github.com/nik1202/otus-spring-homework/pull/10.patch","issue_url":"https://api.github.com/repos/nik1202/otus-spring-homework/issues/10","number":10,"state":"open","locked":false,"title":"hw10","user":{"login":"nik1202","id":25549822,"node_id":"MDQ6VXNlcjI1NTQ5ODIy","avatar_url":"https://avatars2.githubusercontent.com/u/25549822?v=4","gravatar_id":"","url":"https://api.github.com/users/nik1202","html_url":"https://github.com/nik1202","followers_url":"https://api.github.com/users/nik1202/followers","following_url":"https://api.github.com/users/nik1202/following{/other_user}","gists_url":"https://api.github.com/users/nik1202/gists{/gist_id}","starred_url":"https://api.github.com/users/nik1202/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nik1202/subscriptions","organizations_url":"https://api.github.com/users/nik1202/orgs","repos_url":"https://api.github.com/users/nik1202/repos","events_url":"https://api.github.com/users/nik1202/events{/privacy}","received_events_url":"https://api.github.com/users/nik1202/received_events","type":"User","site_admin":false},"body":"hw10","created_at":"2018-08-24T14:36:55Z","updated_at":"2018-09-09T09:17:58Z","closed_at":null,"merged_at":null,"merge_commit_sha":"7459e0e9088361277acc271c0bffcb2defbdafe1","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/nik1202/otus-spring-homework/pulls/10/commits","review_comments_url":"https://api.github.com/repos/nik1202/otus-spring-homework/pulls/10/comments","review_comment_url":"https://api.github.com/repos/nik1202/otus-spring-homework/pulls/comments{/number}","comments_url":"https://api.github.com/repos/nik1202/otus-spring-homework/issues/10/comments","statuses_url":"https://api.github.com/repos/nik1202/otus-spring-homework/statuses/778ddc39346de35ae268cc5331d58858f99841b4","head":{"label":"nik1202:hw10","ref":"hw10","sha":"778ddc39346de35ae268cc5331d58858f99841b4","user":{"login":"nik1202","id":25549822,"node_id":"MDQ6VXNlcjI1NTQ5ODIy","avatar_url":"https://avatars2.githubusercontent.com/u/25549822?v=4","gravatar_id":"","url":"https://api.github.com/users/nik1202","html_url":"https://github.com/nik1202","followers_url":"https://api.github.com/users/nik1202/followers","following_url":"https://api.github.com/users/nik1202/following{/other_user}","gists_url":"https://api.github.com/users/nik1202/gists{/gist_id}","starred_url":"https://api.github.com/users/nik1202/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nik1202/subscriptions","organizations_url":"https://api.github.com/users/nik1202/orgs","repos_url":"https://api.github.com/users/nik1202/repos","events_url":"https://api.github.com/users/nik1202/events{/privacy}","received_events_url":"https://api.github.com/users/nik1202/received_events","type":"User","site_admin":false},"repo":{"id":138845309,"node_id":"MDEwOlJlcG9zaXRvcnkxMzg4NDUzMDk=","name":"otus-spring-homework","full_name":"nik1202/otus-spring-homework","owner":{"login":"nik1202","id":25549822,"node_id":"MDQ6VXNlcjI1NTQ5ODIy","avatar_url":"https://avatars2.githubusercontent.com/u/25549822?v=4","gravatar_id":"","url":"https://api.github.com/users/nik1202","html_url":"https://github.com/nik1202","followers_url":"https://api.github.com/users/nik1202/followers","following_url":"https://api.github.com/users/nik1202/following{/other_user}","gists_url":"https://api.github.com/users/nik1202/gists{/gist_id}","starred_url":"https://api.github.com/users/nik1202/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nik1202/subscriptions","organizations_url":"https://api.github.com/users/nik1202/orgs","repos_url":"https://api.github.com/users/nik1202/repos","events_url":"https://api.github.com/users/nik1202/events{/privacy}","received_events_url":"https://api.github.com/users/nik1202/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/nik1202/otus-spring-homework","description":"otus spring homeworks","fork":false,"url":"https://api.github.com/repos/nik1202/otus-spring-homework","forks_url":"https://api.github.com/repos/nik1202/otus-spring-homework/forks","keys_url":"https://api.github.com/repos/nik1202/otus-spring-homework/keys{/key_id}","collaborators_url":"https://api.github.com/repos/nik1202/otus-spring-homework/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/nik1202/otus-spring-homework/teams","hooks_url":"https://api.github.com/repos/nik1202/otus-spring-homework/hooks","issue_events_url":"https://api.github.com/repos/nik1202/otus-spring-homework/issues/events{/number}","events_url":"https://api.github.com/repos/nik1202/otus-spring-homework/events","assignees_url":"https://api.github.com/repos/nik1202/otus-spring-homework/assignees{/user}","branches_url":"https://api.github.com/repos/nik1202/otus-spring-homework/branches{/branch}","tags_url":"https://api.github.com/repos/nik1202/otus-spring-homework/tags","blobs_url":"https://api.github.com/repos/nik1202/otus-spring-homework/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/nik1202/otus-spring-homework/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/nik1202/otus-spring-homework/git/refs{/sha}","trees_url":"https://api.github.com/repos/nik1202/otus-spring-homework/git/trees{/sha}","statuses_url":"https://api.github.com/repos/nik1202/otus-spring-homework/statuses/{sha}","languages_url":"https://api.github.com/repos/nik1202/otus-spring-homework/languages","stargazers_url":"https://api.github.com/repos/nik1202/otus-spring-homework/stargazers","contributors_url":"https://api.github.com/repos/nik1202/otus-spring-homework/contributors","subscribers_url":"https://api.github.com/repos/nik1202/otus-spring-homework/subscribers","subscription_url":"https://api.github.com/repos/nik1202/otus-spring-homework/subscription","commits_url":"https://api.github.com/repos/nik1202/otus-spring-homework/commits{/sha}","git_commits_url":"https://api.github.com/repos/nik1202/otus-spring-homework/git/commits{/sha}","comments_url":"https://api.github.com/repos/nik1202/otus-spring-homework/comments{/number}","issue_comment_url":"https://api.github.com/repos/nik1202/otus-spring-homework/issues/comments{/number}","contents_url":"https://api.github.com/repos/nik1202/otus-spring-homework/contents/{+path}","compare_url":"https://api.github.com/repos/nik1202/otus-spring-homework/compare/{base}...{head}","merges_url":"https://api.github.com/repos/nik1202/otus-spring-homework/merges","archive_url":"https://api.github.com/repos/nik1202/otus-spring-homework/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/nik1202/otus-spring-homework/downloads","issues_url":"https://api.github.com/repos/nik1202/otus-spring-homework/issues{/number}","pulls_url":"https://api.github.com/repos/nik1202/otus-spring-homework/pulls{/number}","milestones_url":"https://api.github.com/repos/nik1202/otus-spring-homework/milestones{/number}","notifications_url":"https://api.github.com/repos/nik1202/otus-spring-homework/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/nik1202/otus-spring-homework/labels{/name}","releases_url":"https://api.github.com/repos/nik1202/otus-spring-homework/releases{/id}","deployments_url":"https://api.github.com/repos/nik1202/otus-spring-homework/deployments","created_at":"2018-06-27T07:25:47Z","updated_at":"2018-09-03T13:39:42Z","pushed_at":"2018-09-04T07:50:40Z","git_url":"git://github.com/nik1202/otus-spring-homework.git","ssh_url":"git@github.com:nik1202/otus-spring-homework.git","clone_url":"https://github.com/nik1202/otus-spring-homework.git","svn_url":"https://github.com/nik1202/otus-spring-homework","homepage":"","size":142,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":2,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":0,"open_issues":2,"watchers":0,"default_branch":"master"}},"base":{"label":"nik1202:master","ref":"master","sha":"0571833881f41654c7c16b48e062c9cbf4771c33","user":{"login":"nik1202","id":25549822,"node_id":"MDQ6VXNlcjI1NTQ5ODIy","avatar_url":"https://avatars2.githubusercontent.com/u/25549822?v=4","gravatar_id":"","url":"https://api.github.com/users/nik1202","html_url":"https://github.com/nik1202","followers_url":"https://api.github.com/users/nik1202/followers","following_url":"https://api.github.com/users/nik1202/following{/other_user}","gists_url":"https://api.github.com/users/nik1202/gists{/gist_id}","starred_url":"https://api.github.com/users/nik1202/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nik1202/subscriptions","organizations_url":"https://api.github.com/users/nik1202/orgs","repos_url":"https://api.github.com/users/nik1202/repos","events_url":"https://api.github.com/users/nik1202/events{/privacy}","received_events_url":"https://api.github.com/users/nik1202/received_events","type":"User","site_admin":false},"repo":{"id":138845309,"node_id":"MDEwOlJlcG9zaXRvcnkxMzg4NDUzMDk=","name":"otus-spring-homework","full_name":"nik1202/otus-spring-homework","owner":{"login":"nik1202","id":25549822,"node_id":"MDQ6VXNlcjI1NTQ5ODIy","avatar_url":"https://avatars2.githubusercontent.com/u/25549822?v=4","gravatar_id":"","url":"https://api.github.com/users/nik1202","html_url":"https://github.com/nik1202","followers_url":"https://api.github.com/users/nik1202/followers","following_url":"https://api.github.com/users/nik1202/following{/other_user}","gists_url":"https://api.github.com/users/nik1202/gists{/gist_id}","starred_url":"https://api.github.com/users/nik1202/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nik1202/subscriptions","organizations_url":"https://api.github.com/users/nik1202/orgs","repos_url":"https://api.github.com/users/nik1202/repos","events_url":"https://api.github.com/users/nik1202/events{/privacy}","received_events_url":"https://api.github.com/users/nik1202/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/nik1202/otus-spring-homework","description":"otus spring homeworks","fork":false,"url":"https://api.github.com/repos/nik1202/otus-spring-homework","forks_url":"https://api.github.com/repos/nik1202/otus-spring-homework/forks","keys_url":"https://api.github.com/repos/nik1202/otus-spring-homework/keys{/key_id}","collaborators_url":"https://api.github.com/repos/nik1202/otus-spring-homework/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/nik1202/otus-spring-homework/teams","hooks_url":"https://api.github.com/repos/nik1202/otus-spring-homework/hooks","issue_events_url":"https://api.github.com/repos/nik1202/otus-spring-homework/issues/events{/number}","events_url":"https://api.github.com/repos/nik1202/otus-spring-homework/events","assignees_url":"https://api.github.com/repos/nik1202/otus-spring-homework/assignees{/user}","branches_url":"https://api.github.com/repos/nik1202/otus-spring-homework/branches{/branch}","tags_url":"https://api.github.com/repos/nik1202/otus-spring-homework/tags","blobs_url":"https://api.github.com/repos/nik1202/otus-spring-homework/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/nik1202/otus-spring-homework/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/nik1202/otus-spring-homework/git/refs{/sha}","trees_url":"https://api.github.com/repos/nik1202/otus-spring-homework/git/trees{/sha}","statuses_url":"https://api.github.com/repos/nik1202/otus-spring-homework/statuses/{sha}","languages_url":"https://api.github.com/repos/nik1202/otus-spring-homework/languages","stargazers_url":"https://api.github.com/repos/nik1202/otus-spring-homework/stargazers","contributors_url":"https://api.github.com/repos/nik1202/otus-spring-homework/contributors","subscribers_url":"https://api.github.com/repos/nik1202/otus-spring-homework/subscribers","subscription_url":"https://api.github.com/repos/nik1202/otus-spring-homework/subscription","commits_url":"https://api.github.com/repos/nik1202/otus-spring-homework/commits{/sha}","git_commits_url":"https://api.github.com/repos/nik1202/otus-spring-homework/git/commits{/sha}","comments_url":"https://api.github.com/repos/nik1202/otus-spring-homework/comments{/number}","issue_comment_url":"https://api.github.com/repos/nik1202/otus-spring-homework/issues/comments{/number}","contents_url":"https://api.github.com/repos/nik1202/otus-spring-homework/contents/{+path}","compare_url":"https://api.github.com/repos/nik1202/otus-spring-homework/compare/{base}...{head}","merges_url":"https://api.github.com/repos/nik1202/otus-spring-homework/merges","archive_url":"https://api.github.com/repos/nik1202/otus-spring-homework/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/nik1202/otus-spring-homework/downloads","issues_url":"https://api.github.com/repos/nik1202/otus-spring-homework/issues{/number}","pulls_url":"https://api.github.com/repos/nik1202/otus-spring-homework/pulls{/number}","milestones_url":"https://api.github.com/repos/nik1202/otus-spring-homework/milestones{/number}","notifications_url":"https://api.github.com/repos/nik1202/otus-spring-homework/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/nik1202/otus-spring-homework/labels{/name}","releases_url":"https://api.github.com/repos/nik1202/otus-spring-homework/releases{/id}","deployments_url":"https://api.github.com/repos/nik1202/otus-spring-homework/deployments","created_at":"2018-06-27T07:25:47Z","updated_at":"2018-09-03T13:39:42Z","pushed_at":"2018-09-04T07:50:40Z","git_url":"git://github.com/nik1202/otus-spring-homework.git","ssh_url":"git@github.com:nik1202/otus-spring-homework.git","clone_url":"https://github.com/nik1202/otus-spring-homework.git","svn_url":"https://github.com/nik1202/otus-spring-homework","homepage":"","size":142,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":2,"license":{"key":"apache-2.0","name":"Apache License 2.0","spdx_id":"Apache-2.0","url":"https://api.github.com/licenses/apache-2.0","node_id":"MDc6TGljZW5zZTI="},"forks":0,"open_issues":2,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/nik1202/otus-spring-homework/pulls/10"},"html":{"href":"https://github.com/nik1202/otus-spring-homework/pull/10"},"issue":{"href":"https://api.github.com/repos/nik1202/otus-spring-homework/issues/10"},"comments":{"href":"https://api.github.com/repos/nik1202/otus-spring-homework/issues/10/comments"},"review_comments":{"href":"https://api.github.com/repos/nik1202/otus-spring-homework/pulls/10/comments"},"review_comment":{"href":"https://api.github.com/repos/nik1202/otus-spring-homework/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/nik1202/otus-spring-homework/pulls/10/commits"},"statuses":{"href":"https://api.github.com/repos/nik1202/otus-spring-homework/statuses/778ddc39346de35ae268cc5331d58858f99841b4"}},"author_association":"OWNER"}}
{"actor":{"display_login":"ydvorzhetskiy"}}