{"action":"created","issue":{"url":"https://api.github.com/repos/stepancheg/grpc-rust/issues/101","repository_url":"https://api.github.com/repos/stepancheg/grpc-rust","labels_url":"https://api.github.com/repos/stepancheg/grpc-rust/issues/101/labels{/name}","comments_url":"https://api.github.com/repos/stepancheg/grpc-rust/issues/101/comments","events_url":"https://api.github.com/repos/stepancheg/grpc-rust/issues/101/events","html_url":"https://github.com/stepancheg/grpc-rust/issues/101","id":271718808,"number":101,"title":"How to use Arc<> in new_service_def()","user":{"login":"VenusHu","id":12372693,"avatar_url":"https://avatars3.githubusercontent.com/u/12372693?v=4","gravatar_id":"","url":"https://api.github.com/users/VenusHu","html_url":"https://github.com/VenusHu","followers_url":"https://api.github.com/users/VenusHu/followers","following_url":"https://api.github.com/users/VenusHu/following{/other_user}","gists_url":"https://api.github.com/users/VenusHu/gists{/gist_id}","starred_url":"https://api.github.com/users/VenusHu/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/VenusHu/subscriptions","organizations_url":"https://api.github.com/users/VenusHu/orgs","repos_url":"https://api.github.com/users/VenusHu/repos","events_url":"https://api.github.com/users/VenusHu/events{/privacy}","received_events_url":"https://api.github.com/users/VenusHu/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":3,"created_at":"2017-11-07T06:03:20Z","updated_at":"2017-11-09T15:38:03Z","closed_at":"2017-11-08T21:05:31Z","author_association":"NONE","body":"Hi, I'm new to rust, so I have a problem bothering me, hoping to get help.\r\nI define a struct called Peer, wrapped it using Arc, then use a new thread to start PRC server:\r\n\r\n```\r\nfn start_server(p: Arc<Peer>) {\r\n...\r\nserver.add_service(PeerSrvServer::new_service_def(p));\r\n...\r\n}\r\n```\r\n\r\nthen I get compile error: \r\n```\r\nthe trait bound `std::sync::Arc<demo_with_grpc::peer::Peer>: demo_with_grpc::peerpb_grpc::PeerSrv` is not satisfied\r\n```\r\n\r\nSo what's the correct way to write the code? \r\nMany thanks!\r\n"},"comment":{"url":"https://api.github.com/repos/stepancheg/grpc-rust/issues/comments/343192829","html_url":"https://github.com/stepancheg/grpc-rust/issues/101#issuecomment-343192829","issue_url":"https://api.github.com/repos/stepancheg/grpc-rust/issues/101","id":343192829,"user":{"login":"thedodd","id":2380740,"avatar_url":"https://avatars1.githubusercontent.com/u/2380740?v=4","gravatar_id":"","url":"https://api.github.com/users/thedodd","html_url":"https://github.com/thedodd","followers_url":"https://api.github.com/users/thedodd/followers","following_url":"https://api.github.com/users/thedodd/following{/other_user}","gists_url":"https://api.github.com/users/thedodd/gists{/gist_id}","starred_url":"https://api.github.com/users/thedodd/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thedodd/subscriptions","organizations_url":"https://api.github.com/users/thedodd/orgs","repos_url":"https://api.github.com/users/thedodd/repos","events_url":"https://api.github.com/users/thedodd/events{/privacy}","received_events_url":"https://api.github.com/users/thedodd/received_events","type":"User","site_admin":false},"created_at":"2017-11-09T15:38:03Z","updated_at":"2017-11-09T15:38:03Z","author_association":"NONE","body":"Absolutely."}}
{"actor":{"display_login":"thedodd"}}