{"action":"created","comment":{"url":"https://api.github.com/repos/codingteam/horta-hell/pulls/comments/46571216","id":46571216,"diff_hunk":"@@ -52,26 +54,34 @@ class JabberProtocol() extends Actor with ActorLogging {\n     case Reconnect(otherConnection) =>\n       log.info(s\"Ignored reconnect request from connection $otherConnection\")\n \n-    case JoinRoom(jid, locale, nickname, greeting) =>\n+    case message@JoinRoom(jid, locale, nickname, greeting) =>\n       log.info(s\"Joining room $jid\")\n       val actor = context.actorOf(\n         Props(new MucMessageHandler(locale, self, jid, nickname)), jid)\n \n-      val muc = new MultiUserChat(connection, jid)\n-      rooms = rooms.updated(jid, RoomDefinition(muc, actor))\n-\n-      muc.addMessageListener(new MucMessageListener(jid, actor, log))\n-      muc.addParticipantStatusListener(new MucParticipantStatusListener(muc, actor))\n-\n-      val filter = new AndFilter(new PacketTypeFilter(classOf[Message]), new FromContainsFilter(jid))\n-      connection.addPacketListener(\n-        new MessageAutoRepeater(context.system, self, context.system.scheduler, jid, context.dispatcher),\n-        filter)\n-\n-      muc.join(nickname)\n-      greeting match {\n-        case Some(message) => muc.sendMessage(message)\n-        case None =>\n+      try {\n+        // TODO: Move this code to the room actor and use \"let it fall\" strategy ~ F\n+        val muc = new MultiUserChat(connection, jid)\n+        rooms = rooms.updated(jid, RoomDefinition(muc, actor))\n+\n+        muc.addMessageListener(new MucMessageListener(jid, actor, log))\n+        muc.addParticipantStatusListener(new MucParticipantStatusListener(muc, actor))\n+\n+        val filter = new AndFilter(new PacketTypeFilter(classOf[Message]), new FromContainsFilter(jid))\n+        connection.addPacketListener(\n+          new MessageAutoRepeater(context.system, self, context.system.scheduler, jid, context.dispatcher),\n+          filter)\n+\n+        muc.join(nickname)\n+        greeting match {\n+          case Some(text) => muc.sendMessage(text)\n+          case None =>\n+        }\n+      } catch {\n+        case t: Throwable =>","path":"src/main/scala/ru/org/codingteam/horta/protocol/jabber/JabberProtocol.scala","position":53,"original_position":53,"commit_id":"2b6e657f9e4f6dbfdb7436bc281ebd0fa9374da4","original_commit_id":"2b6e657f9e4f6dbfdb7436bc281ebd0fa9374da4","user":{"login":"ForNeVeR","id":92793,"avatar_url":"https://avatars.githubusercontent.com/u/92793?v=3","gravatar_id":"","url":"https://api.github.com/users/ForNeVeR","html_url":"https://github.com/ForNeVeR","followers_url":"https://api.github.com/users/ForNeVeR/followers","following_url":"https://api.github.com/users/ForNeVeR/following{/other_user}","gists_url":"https://api.github.com/users/ForNeVeR/gists{/gist_id}","starred_url":"https://api.github.com/users/ForNeVeR/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ForNeVeR/subscriptions","organizations_url":"https://api.github.com/users/ForNeVeR/orgs","repos_url":"https://api.github.com/users/ForNeVeR/repos","events_url":"https://api.github.com/users/ForNeVeR/events{/privacy}","received_events_url":"https://api.github.com/users/ForNeVeR/received_events","type":"User","site_admin":false},"body":"That's a nice suggestion about logging. Thank you, I'll implement that.","created_at":"2015-12-03T16:09:00Z","updated_at":"2015-12-03T16:09:00Z","html_url":"https://github.com/codingteam/horta-hell/pull/359#discussion_r46571216","pull_request_url":"https://api.github.com/repos/codingteam/horta-hell/pulls/359","_links":{"self":{"href":"https://api.github.com/repos/codingteam/horta-hell/pulls/comments/46571216"},"html":{"href":"https://github.com/codingteam/horta-hell/pull/359#discussion_r46571216"},"pull_request":{"href":"https://api.github.com/repos/codingteam/horta-hell/pulls/359"}}},"pull_request":{"url":"https://api.github.com/repos/codingteam/horta-hell/pulls/359","id":52551736,"html_url":"https://github.com/codingteam/horta-hell/pull/359","diff_url":"https://github.com/codingteam/horta-hell/pull/359.diff","patch_url":"https://github.com/codingteam/horta-hell/pull/359.patch","issue_url":"https://api.github.com/repos/codingteam/horta-hell/issues/359","number":359,"state":"open","locked":false,"title":"Add auto rejoin on join errors","user":{"login":"ForNeVeR","id":92793,"avatar_url":"https://avatars.githubusercontent.com/u/92793?v=3","gravatar_id":"","url":"https://api.github.com/users/ForNeVeR","html_url":"https://github.com/ForNeVeR","followers_url":"https://api.github.com/users/ForNeVeR/followers","following_url":"https://api.github.com/users/ForNeVeR/following{/other_user}","gists_url":"https://api.github.com/users/ForNeVeR/gists{/gist_id}","starred_url":"https://api.github.com/users/ForNeVeR/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ForNeVeR/subscriptions","organizations_url":"https://api.github.com/users/ForNeVeR/orgs","repos_url":"https://api.github.com/users/ForNeVeR/repos","events_url":"https://api.github.com/users/ForNeVeR/events{/privacy}","received_events_url":"https://api.github.com/users/ForNeVeR/received_events","type":"User","site_admin":false},"body":"This is a hotfix that will close #357. I've also created the new issue #358 to refactor this code a bit.","created_at":"2015-12-03T15:49:44Z","updated_at":"2015-12-03T16:09:00Z","closed_at":null,"merged_at":null,"merge_commit_sha":"bf24927513cd773590fc9f79febe186382b215f4","assignee":{"login":"rexim","id":165283,"avatar_url":"https://avatars.githubusercontent.com/u/165283?v=3","gravatar_id":"","url":"https://api.github.com/users/rexim","html_url":"https://github.com/rexim","followers_url":"https://api.github.com/users/rexim/followers","following_url":"https://api.github.com/users/rexim/following{/other_user}","gists_url":"https://api.github.com/users/rexim/gists{/gist_id}","starred_url":"https://api.github.com/users/rexim/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rexim/subscriptions","organizations_url":"https://api.github.com/users/rexim/orgs","repos_url":"https://api.github.com/users/rexim/repos","events_url":"https://api.github.com/users/rexim/events{/privacy}","received_events_url":"https://api.github.com/users/rexim/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/codingteam/horta-hell/milestones/1","html_url":"https://github.com/codingteam/horta-hell/milestones/1.0","labels_url":"https://api.github.com/repos/codingteam/horta-hell/milestones/1/labels","id":508016,"number":1,"title":"1.0","description":"First stable Horta release.","creator":{"login":"ForNeVeR","id":92793,"avatar_url":"https://avatars.githubusercontent.com/u/92793?v=3","gravatar_id":"","url":"https://api.github.com/users/ForNeVeR","html_url":"https://github.com/ForNeVeR","followers_url":"https://api.github.com/users/ForNeVeR/followers","following_url":"https://api.github.com/users/ForNeVeR/following{/other_user}","gists_url":"https://api.github.com/users/ForNeVeR/gists{/gist_id}","starred_url":"https://api.github.com/users/ForNeVeR/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ForNeVeR/subscriptions","organizations_url":"https://api.github.com/users/ForNeVeR/orgs","repos_url":"https://api.github.com/users/ForNeVeR/repos","events_url":"https://api.github.com/users/ForNeVeR/events{/privacy}","received_events_url":"https://api.github.com/users/ForNeVeR/received_events","type":"User","site_admin":false},"open_issues":30,"closed_issues":154,"state":"open","created_at":"2013-12-08T14:16:49Z","updated_at":"2015-12-03T15:49:44Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/codingteam/horta-hell/pulls/359/commits","review_comments_url":"https://api.github.com/repos/codingteam/horta-hell/pulls/359/comments","review_comment_url":"https://api.github.com/repos/codingteam/horta-hell/pulls/comments{/number}","comments_url":"https://api.github.com/repos/codingteam/horta-hell/issues/359/comments","statuses_url":"https://api.github.com/repos/codingteam/horta-hell/statuses/2b6e657f9e4f6dbfdb7436bc281ebd0fa9374da4","head":{"label":"codingteam:bugfix/room-bans","ref":"bugfix/room-bans","sha":"2b6e657f9e4f6dbfdb7436bc281ebd0fa9374da4","user":{"login":"codingteam","id":6565747,"avatar_url":"https://avatars.githubusercontent.com/u/6565747?v=3","gravatar_id":"","url":"https://api.github.com/users/codingteam","html_url":"https://github.com/codingteam","followers_url":"https://api.github.com/users/codingteam/followers","following_url":"https://api.github.com/users/codingteam/following{/other_user}","gists_url":"https://api.github.com/users/codingteam/gists{/gist_id}","starred_url":"https://api.github.com/users/codingteam/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/codingteam/subscriptions","organizations_url":"https://api.github.com/users/codingteam/orgs","repos_url":"https://api.github.com/users/codingteam/repos","events_url":"https://api.github.com/users/codingteam/events{/privacy}","received_events_url":"https://api.github.com/users/codingteam/received_events","type":"Organization","site_admin":false},"repo":{"id":7502391,"name":"horta-hell","full_name":"codingteam/horta-hell","owner":{"login":"codingteam","id":6565747,"avatar_url":"https://avatars.githubusercontent.com/u/6565747?v=3","gravatar_id":"","url":"https://api.github.com/users/codingteam","html_url":"https://github.com/codingteam","followers_url":"https://api.github.com/users/codingteam/followers","following_url":"https://api.github.com/users/codingteam/following{/other_user}","gists_url":"https://api.github.com/users/codingteam/gists{/gist_id}","starred_url":"https://api.github.com/users/codingteam/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/codingteam/subscriptions","organizations_url":"https://api.github.com/users/codingteam/orgs","repos_url":"https://api.github.com/users/codingteam/repos","events_url":"https://api.github.com/users/codingteam/events{/privacy}","received_events_url":"https://api.github.com/users/codingteam/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/codingteam/horta-hell","description":"Configurable XMPP bot written in Scala based on the Akka framework.","fork":false,"url":"https://api.github.com/repos/codingteam/horta-hell","forks_url":"https://api.github.com/repos/codingteam/horta-hell/forks","keys_url":"https://api.github.com/repos/codingteam/horta-hell/keys{/key_id}","collaborators_url":"https://api.github.com/repos/codingteam/horta-hell/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/codingteam/horta-hell/teams","hooks_url":"https://api.github.com/repos/codingteam/horta-hell/hooks","issue_events_url":"https://api.github.com/repos/codingteam/horta-hell/issues/events{/number}","events_url":"https://api.github.com/repos/codingteam/horta-hell/events","assignees_url":"https://api.github.com/repos/codingteam/horta-hell/assignees{/user}","branches_url":"https://api.github.com/repos/codingteam/horta-hell/branches{/branch}","tags_url":"https://api.github.com/repos/codingteam/horta-hell/tags","blobs_url":"https://api.github.com/repos/codingteam/horta-hell/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/codingteam/horta-hell/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/codingteam/horta-hell/git/refs{/sha}","trees_url":"https://api.github.com/repos/codingteam/horta-hell/git/trees{/sha}","statuses_url":"https://api.github.com/repos/codingteam/horta-hell/statuses/{sha}","languages_url":"https://api.github.com/repos/codingteam/horta-hell/languages","stargazers_url":"https://api.github.com/repos/codingteam/horta-hell/stargazers","contributors_url":"https://api.github.com/repos/codingteam/horta-hell/contributors","subscribers_url":"https://api.github.com/repos/codingteam/horta-hell/subscribers","subscription_url":"https://api.github.com/repos/codingteam/horta-hell/subscription","commits_url":"https://api.github.com/repos/codingteam/horta-hell/commits{/sha}","git_commits_url":"https://api.github.com/repos/codingteam/horta-hell/git/commits{/sha}","comments_url":"https://api.github.com/repos/codingteam/horta-hell/comments{/number}","issue_comment_url":"https://api.github.com/repos/codingteam/horta-hell/issues/comments{/number}","contents_url":"https://api.github.com/repos/codingteam/horta-hell/contents/{+path}","compare_url":"https://api.github.com/repos/codingteam/horta-hell/compare/{base}...{head}","merges_url":"https://api.github.com/repos/codingteam/horta-hell/merges","archive_url":"https://api.github.com/repos/codingteam/horta-hell/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/codingteam/horta-hell/downloads","issues_url":"https://api.github.com/repos/codingteam/horta-hell/issues{/number}","pulls_url":"https://api.github.com/repos/codingteam/horta-hell/pulls{/number}","milestones_url":"https://api.github.com/repos/codingteam/horta-hell/milestones{/number}","notifications_url":"https://api.github.com/repos/codingteam/horta-hell/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/codingteam/horta-hell/labels{/name}","releases_url":"https://api.github.com/repos/codingteam/horta-hell/releases{/id}","created_at":"2013-01-08T14:06:29Z","updated_at":"2015-07-12T11:39:36Z","pushed_at":"2015-12-03T15:49:44Z","git_url":"git://github.com/codingteam/horta-hell.git","ssh_url":"git@github.com:codingteam/horta-hell.git","clone_url":"https://github.com/codingteam/horta-hell.git","svn_url":"https://github.com/codingteam/horta-hell","homepage":"","size":51846,"stargazers_count":12,"watchers_count":12,"language":"Scala","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":10,"mirror_url":null,"open_issues_count":113,"forks":10,"open_issues":113,"watchers":12,"default_branch":"develop"}},"base":{"label":"codingteam:develop","ref":"develop","sha":"9ff0a310a91df32fc93812d50d35e38840bccb8c","user":{"login":"codingteam","id":6565747,"avatar_url":"https://avatars.githubusercontent.com/u/6565747?v=3","gravatar_id":"","url":"https://api.github.com/users/codingteam","html_url":"https://github.com/codingteam","followers_url":"https://api.github.com/users/codingteam/followers","following_url":"https://api.github.com/users/codingteam/following{/other_user}","gists_url":"https://api.github.com/users/codingteam/gists{/gist_id}","starred_url":"https://api.github.com/users/codingteam/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/codingteam/subscriptions","organizations_url":"https://api.github.com/users/codingteam/orgs","repos_url":"https://api.github.com/users/codingteam/repos","events_url":"https://api.github.com/users/codingteam/events{/privacy}","received_events_url":"https://api.github.com/users/codingteam/received_events","type":"Organization","site_admin":false},"repo":{"id":7502391,"name":"horta-hell","full_name":"codingteam/horta-hell","owner":{"login":"codingteam","id":6565747,"avatar_url":"https://avatars.githubusercontent.com/u/6565747?v=3","gravatar_id":"","url":"https://api.github.com/users/codingteam","html_url":"https://github.com/codingteam","followers_url":"https://api.github.com/users/codingteam/followers","following_url":"https://api.github.com/users/codingteam/following{/other_user}","gists_url":"https://api.github.com/users/codingteam/gists{/gist_id}","starred_url":"https://api.github.com/users/codingteam/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/codingteam/subscriptions","organizations_url":"https://api.github.com/users/codingteam/orgs","repos_url":"https://api.github.com/users/codingteam/repos","events_url":"https://api.github.com/users/codingteam/events{/privacy}","received_events_url":"https://api.github.com/users/codingteam/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/codingteam/horta-hell","description":"Configurable XMPP bot written in Scala based on the Akka framework.","fork":false,"url":"https://api.github.com/repos/codingteam/horta-hell","forks_url":"https://api.github.com/repos/codingteam/horta-hell/forks","keys_url":"https://api.github.com/repos/codingteam/horta-hell/keys{/key_id}","collaborators_url":"https://api.github.com/repos/codingteam/horta-hell/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/codingteam/horta-hell/teams","hooks_url":"https://api.github.com/repos/codingteam/horta-hell/hooks","issue_events_url":"https://api.github.com/repos/codingteam/horta-hell/issues/events{/number}","events_url":"https://api.github.com/repos/codingteam/horta-hell/events","assignees_url":"https://api.github.com/repos/codingteam/horta-hell/assignees{/user}","branches_url":"https://api.github.com/repos/codingteam/horta-hell/branches{/branch}","tags_url":"https://api.github.com/repos/codingteam/horta-hell/tags","blobs_url":"https://api.github.com/repos/codingteam/horta-hell/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/codingteam/horta-hell/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/codingteam/horta-hell/git/refs{/sha}","trees_url":"https://api.github.com/repos/codingteam/horta-hell/git/trees{/sha}","statuses_url":"https://api.github.com/repos/codingteam/horta-hell/statuses/{sha}","languages_url":"https://api.github.com/repos/codingteam/horta-hell/languages","stargazers_url":"https://api.github.com/repos/codingteam/horta-hell/stargazers","contributors_url":"https://api.github.com/repos/codingteam/horta-hell/contributors","subscribers_url":"https://api.github.com/repos/codingteam/horta-hell/subscribers","subscription_url":"https://api.github.com/repos/codingteam/horta-hell/subscription","commits_url":"https://api.github.com/repos/codingteam/horta-hell/commits{/sha}","git_commits_url":"https://api.github.com/repos/codingteam/horta-hell/git/commits{/sha}","comments_url":"https://api.github.com/repos/codingteam/horta-hell/comments{/number}","issue_comment_url":"https://api.github.com/repos/codingteam/horta-hell/issues/comments{/number}","contents_url":"https://api.github.com/repos/codingteam/horta-hell/contents/{+path}","compare_url":"https://api.github.com/repos/codingteam/horta-hell/compare/{base}...{head}","merges_url":"https://api.github.com/repos/codingteam/horta-hell/merges","archive_url":"https://api.github.com/repos/codingteam/horta-hell/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/codingteam/horta-hell/downloads","issues_url":"https://api.github.com/repos/codingteam/horta-hell/issues{/number}","pulls_url":"https://api.github.com/repos/codingteam/horta-hell/pulls{/number}","milestones_url":"https://api.github.com/repos/codingteam/horta-hell/milestones{/number}","notifications_url":"https://api.github.com/repos/codingteam/horta-hell/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/codingteam/horta-hell/labels{/name}","releases_url":"https://api.github.com/repos/codingteam/horta-hell/releases{/id}","created_at":"2013-01-08T14:06:29Z","updated_at":"2015-07-12T11:39:36Z","pushed_at":"2015-12-03T15:49:44Z","git_url":"git://github.com/codingteam/horta-hell.git","ssh_url":"git@github.com:codingteam/horta-hell.git","clone_url":"https://github.com/codingteam/horta-hell.git","svn_url":"https://github.com/codingteam/horta-hell","homepage":"","size":51846,"stargazers_count":12,"watchers_count":12,"language":"Scala","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":10,"mirror_url":null,"open_issues_count":113,"forks":10,"open_issues":113,"watchers":12,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/codingteam/horta-hell/pulls/359"},"html":{"href":"https://github.com/codingteam/horta-hell/pull/359"},"issue":{"href":"https://api.github.com/repos/codingteam/horta-hell/issues/359"},"comments":{"href":"https://api.github.com/repos/codingteam/horta-hell/issues/359/comments"},"review_comments":{"href":"https://api.github.com/repos/codingteam/horta-hell/pulls/359/comments"},"review_comment":{"href":"https://api.github.com/repos/codingteam/horta-hell/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/codingteam/horta-hell/pulls/359/commits"},"statuses":{"href":"https://api.github.com/repos/codingteam/horta-hell/statuses/2b6e657f9e4f6dbfdb7436bc281ebd0fa9374da4"}}}}