{"action":"created","comment":{"url":"https://api.github.com/repos/kodi-pvr/pvr.hts/pulls/comments/42500608","id":42500608,"diff_hunk":"@@ -71,14 +72,19 @@ namespace tvheadend\n     uint32_t          GetWeight() const;\n     int32_t           GetSpeed() const;\n     eSubsriptionState GetState() const;\n+    std::string       GetProfile() const;\n \n     /**\n      * Subscribe to a channel on the backend\n      * @param channelId the channel to subscribe to\n      * @param weight the desired subscription weight\n+     * @param profile the profile to use for the subscription\n      * @param restart restart the current subscription (i.e. after lost connection), other parameters will be ignored\n      */\n-    void SendSubscribe(uint32_t channelId = 0, uint32_t weight = SUBSCRIPTION_WEIGHT_NORMAL, bool restart = false);\n+    void SendSubscribe(uint32_t channelId = 0,\n+                       uint32_t weight = SUBSCRIPTION_WEIGHT_NORMAL,\n+                       const std::string &profile = \"\",\n+                       bool restart = false);\n ","path":"src/tvheadend/Subscription.h","position":26,"original_position":26,"commit_id":"36973b4157072e5c7a920bfbd2ce911028689ba6","original_commit_id":"36973b4157072e5c7a920bfbd2ce911028689ba6","user":{"login":"Jalle19","id":1106133,"avatar_url":"https://avatars.githubusercontent.com/u/1106133?v=3","gravatar_id":"","url":"https://api.github.com/users/Jalle19","html_url":"https://github.com/Jalle19","followers_url":"https://api.github.com/users/Jalle19/followers","following_url":"https://api.github.com/users/Jalle19/following{/other_user}","gists_url":"https://api.github.com/users/Jalle19/gists{/gist_id}","starred_url":"https://api.github.com/users/Jalle19/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Jalle19/subscriptions","organizations_url":"https://api.github.com/users/Jalle19/orgs","repos_url":"https://api.github.com/users/Jalle19/repos","events_url":"https://api.github.com/users/Jalle19/events{/privacy}","received_events_url":"https://api.github.com/users/Jalle19/received_events","type":"User","site_admin":false},"body":"Technically it should be but currently no since an addon restart is triggered if you change the setting. I'm perfectly fine with requiring a restart and feeding the desired profile through the constructor instead, anything to keep the parameter count on this method down is good in by book. @ksooo thoughts?","created_at":"2015-10-20T14:17:09Z","updated_at":"2015-10-20T14:17:09Z","html_url":"https://github.com/kodi-pvr/pvr.hts/pull/119#discussion_r42500608","pull_request_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/pulls/119","_links":{"self":{"href":"https://api.github.com/repos/kodi-pvr/pvr.hts/pulls/comments/42500608"},"html":{"href":"https://github.com/kodi-pvr/pvr.hts/pull/119#discussion_r42500608"},"pull_request":{"href":"https://api.github.com/repos/kodi-pvr/pvr.hts/pulls/119"}}},"pull_request":{"url":"https://api.github.com/repos/kodi-pvr/pvr.hts/pulls/119","id":48005891,"html_url":"https://github.com/kodi-pvr/pvr.hts/pull/119","diff_url":"https://github.com/kodi-pvr/pvr.hts/pull/119.diff","patch_url":"https://github.com/kodi-pvr/pvr.hts/pull/119.patch","issue_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/issues/119","number":119,"state":"open","locked":false,"title":"Add support for streaming profiles","user":{"login":"Jalle19","id":1106133,"avatar_url":"https://avatars.githubusercontent.com/u/1106133?v=3","gravatar_id":"","url":"https://api.github.com/users/Jalle19","html_url":"https://github.com/Jalle19","followers_url":"https://api.github.com/users/Jalle19/followers","following_url":"https://api.github.com/users/Jalle19/following{/other_user}","gists_url":"https://api.github.com/users/Jalle19/gists{/gist_id}","starred_url":"https://api.github.com/users/Jalle19/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Jalle19/subscriptions","organizations_url":"https://api.github.com/users/Jalle19/orgs","repos_url":"https://api.github.com/users/Jalle19/repos","events_url":"https://api.github.com/users/Jalle19/events{/privacy}","received_events_url":"https://api.github.com/users/Jalle19/received_events","type":"User","site_admin":false},"body":"See #40 \r\n\r\n@ksooo for review. I've split the feature into three commits for easier review, we can squash it before merging if you want to.\r\n\r\nI'm thinking whether we should add another boolean option to disable predictive tuning if a streaming profile is set. Having multiple transcoded subscriptions can easily overwhelm a low-powered server.\r\n\r\nSince this touches settings I'd like to get #116 merged before this one. #79 would be nice to get in before as well since it refactors `Subscription` into a class (if the feature is not ready we could opt for just merging that particular part).\r\n\r\n@TheTroll can you test this?","created_at":"2015-10-18T10:40:01Z","updated_at":"2015-10-20T14:17:10Z","closed_at":null,"merged_at":null,"merge_commit_sha":"73952d1dd4c261f09b8444d90746d5b3f913fd99","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/pulls/119/commits","review_comments_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/pulls/119/comments","review_comment_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/pulls/comments{/number}","comments_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/issues/119/comments","statuses_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/statuses/36973b4157072e5c7a920bfbd2ce911028689ba6","head":{"label":"Jalle19:selectable-profile","ref":"selectable-profile","sha":"36973b4157072e5c7a920bfbd2ce911028689ba6","user":{"login":"Jalle19","id":1106133,"avatar_url":"https://avatars.githubusercontent.com/u/1106133?v=3","gravatar_id":"","url":"https://api.github.com/users/Jalle19","html_url":"https://github.com/Jalle19","followers_url":"https://api.github.com/users/Jalle19/followers","following_url":"https://api.github.com/users/Jalle19/following{/other_user}","gists_url":"https://api.github.com/users/Jalle19/gists{/gist_id}","starred_url":"https://api.github.com/users/Jalle19/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Jalle19/subscriptions","organizations_url":"https://api.github.com/users/Jalle19/orgs","repos_url":"https://api.github.com/users/Jalle19/repos","events_url":"https://api.github.com/users/Jalle19/events{/privacy}","received_events_url":"https://api.github.com/users/Jalle19/received_events","type":"User","site_admin":false},"repo":{"id":31707392,"name":"pvr.hts","full_name":"Jalle19/pvr.hts","owner":{"login":"Jalle19","id":1106133,"avatar_url":"https://avatars.githubusercontent.com/u/1106133?v=3","gravatar_id":"","url":"https://api.github.com/users/Jalle19","html_url":"https://github.com/Jalle19","followers_url":"https://api.github.com/users/Jalle19/followers","following_url":"https://api.github.com/users/Jalle19/following{/other_user}","gists_url":"https://api.github.com/users/Jalle19/gists{/gist_id}","starred_url":"https://api.github.com/users/Jalle19/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Jalle19/subscriptions","organizations_url":"https://api.github.com/users/Jalle19/orgs","repos_url":"https://api.github.com/users/Jalle19/repos","events_url":"https://api.github.com/users/Jalle19/events{/privacy}","received_events_url":"https://api.github.com/users/Jalle19/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/Jalle19/pvr.hts","description":"Kodi's Tvheadend HTSP client addon","fork":true,"url":"https://api.github.com/repos/Jalle19/pvr.hts","forks_url":"https://api.github.com/repos/Jalle19/pvr.hts/forks","keys_url":"https://api.github.com/repos/Jalle19/pvr.hts/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Jalle19/pvr.hts/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Jalle19/pvr.hts/teams","hooks_url":"https://api.github.com/repos/Jalle19/pvr.hts/hooks","issue_events_url":"https://api.github.com/repos/Jalle19/pvr.hts/issues/events{/number}","events_url":"https://api.github.com/repos/Jalle19/pvr.hts/events","assignees_url":"https://api.github.com/repos/Jalle19/pvr.hts/assignees{/user}","branches_url":"https://api.github.com/repos/Jalle19/pvr.hts/branches{/branch}","tags_url":"https://api.github.com/repos/Jalle19/pvr.hts/tags","blobs_url":"https://api.github.com/repos/Jalle19/pvr.hts/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Jalle19/pvr.hts/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Jalle19/pvr.hts/git/refs{/sha}","trees_url":"https://api.github.com/repos/Jalle19/pvr.hts/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Jalle19/pvr.hts/statuses/{sha}","languages_url":"https://api.github.com/repos/Jalle19/pvr.hts/languages","stargazers_url":"https://api.github.com/repos/Jalle19/pvr.hts/stargazers","contributors_url":"https://api.github.com/repos/Jalle19/pvr.hts/contributors","subscribers_url":"https://api.github.com/repos/Jalle19/pvr.hts/subscribers","subscription_url":"https://api.github.com/repos/Jalle19/pvr.hts/subscription","commits_url":"https://api.github.com/repos/Jalle19/pvr.hts/commits{/sha}","git_commits_url":"https://api.github.com/repos/Jalle19/pvr.hts/git/commits{/sha}","comments_url":"https://api.github.com/repos/Jalle19/pvr.hts/comments{/number}","issue_comment_url":"https://api.github.com/repos/Jalle19/pvr.hts/issues/comments{/number}","contents_url":"https://api.github.com/repos/Jalle19/pvr.hts/contents/{+path}","compare_url":"https://api.github.com/repos/Jalle19/pvr.hts/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Jalle19/pvr.hts/merges","archive_url":"https://api.github.com/repos/Jalle19/pvr.hts/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Jalle19/pvr.hts/downloads","issues_url":"https://api.github.com/repos/Jalle19/pvr.hts/issues{/number}","pulls_url":"https://api.github.com/repos/Jalle19/pvr.hts/pulls{/number}","milestones_url":"https://api.github.com/repos/Jalle19/pvr.hts/milestones{/number}","notifications_url":"https://api.github.com/repos/Jalle19/pvr.hts/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Jalle19/pvr.hts/labels{/name}","releases_url":"https://api.github.com/repos/Jalle19/pvr.hts/releases{/id}","created_at":"2015-03-05T09:55:19Z","updated_at":"2015-03-05T09:55:19Z","pushed_at":"2015-10-20T14:12:52Z","git_url":"git://github.com/Jalle19/pvr.hts.git","ssh_url":"git@github.com:Jalle19/pvr.hts.git","clone_url":"https://github.com/Jalle19/pvr.hts.git","svn_url":"https://github.com/Jalle19/pvr.hts","homepage":null,"size":1269,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"kodi-pvr:master","ref":"master","sha":"631916bea3d7bb4330f43152de781e50416fdf63","user":{"login":"kodi-pvr","id":11259403,"avatar_url":"https://avatars.githubusercontent.com/u/11259403?v=3","gravatar_id":"","url":"https://api.github.com/users/kodi-pvr","html_url":"https://github.com/kodi-pvr","followers_url":"https://api.github.com/users/kodi-pvr/followers","following_url":"https://api.github.com/users/kodi-pvr/following{/other_user}","gists_url":"https://api.github.com/users/kodi-pvr/gists{/gist_id}","starred_url":"https://api.github.com/users/kodi-pvr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kodi-pvr/subscriptions","organizations_url":"https://api.github.com/users/kodi-pvr/orgs","repos_url":"https://api.github.com/users/kodi-pvr/repos","events_url":"https://api.github.com/users/kodi-pvr/events{/privacy}","received_events_url":"https://api.github.com/users/kodi-pvr/received_events","type":"Organization","site_admin":false},"repo":{"id":31268331,"name":"pvr.hts","full_name":"kodi-pvr/pvr.hts","owner":{"login":"kodi-pvr","id":11259403,"avatar_url":"https://avatars.githubusercontent.com/u/11259403?v=3","gravatar_id":"","url":"https://api.github.com/users/kodi-pvr","html_url":"https://github.com/kodi-pvr","followers_url":"https://api.github.com/users/kodi-pvr/followers","following_url":"https://api.github.com/users/kodi-pvr/following{/other_user}","gists_url":"https://api.github.com/users/kodi-pvr/gists{/gist_id}","starred_url":"https://api.github.com/users/kodi-pvr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kodi-pvr/subscriptions","organizations_url":"https://api.github.com/users/kodi-pvr/orgs","repos_url":"https://api.github.com/users/kodi-pvr/repos","events_url":"https://api.github.com/users/kodi-pvr/events{/privacy}","received_events_url":"https://api.github.com/users/kodi-pvr/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/kodi-pvr/pvr.hts","description":"Kodi's Tvheadend HTSP client addon","fork":false,"url":"https://api.github.com/repos/kodi-pvr/pvr.hts","forks_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/forks","keys_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/keys{/key_id}","collaborators_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/teams","hooks_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/hooks","issue_events_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/issues/events{/number}","events_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/events","assignees_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/assignees{/user}","branches_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/branches{/branch}","tags_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/tags","blobs_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/git/refs{/sha}","trees_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/git/trees{/sha}","statuses_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/statuses/{sha}","languages_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/languages","stargazers_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/stargazers","contributors_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/contributors","subscribers_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/subscribers","subscription_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/subscription","commits_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/commits{/sha}","git_commits_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/git/commits{/sha}","comments_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/comments{/number}","issue_comment_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/issues/comments{/number}","contents_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/contents/{+path}","compare_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/compare/{base}...{head}","merges_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/merges","archive_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/downloads","issues_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/issues{/number}","pulls_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/pulls{/number}","milestones_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/milestones{/number}","notifications_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/labels{/name}","releases_url":"https://api.github.com/repos/kodi-pvr/pvr.hts/releases{/id}","created_at":"2015-02-24T16:07:43Z","updated_at":"2015-10-19T17:50:21Z","pushed_at":"2015-10-20T14:12:52Z","git_url":"git://github.com/kodi-pvr/pvr.hts.git","ssh_url":"git@github.com:kodi-pvr/pvr.hts.git","clone_url":"https://github.com/kodi-pvr/pvr.hts.git","svn_url":"https://github.com/kodi-pvr/pvr.hts","homepage":null,"size":2438,"stargazers_count":23,"watchers_count":23,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":24,"mirror_url":null,"open_issues_count":10,"forks":24,"open_issues":10,"watchers":23,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/kodi-pvr/pvr.hts/pulls/119"},"html":{"href":"https://github.com/kodi-pvr/pvr.hts/pull/119"},"issue":{"href":"https://api.github.com/repos/kodi-pvr/pvr.hts/issues/119"},"comments":{"href":"https://api.github.com/repos/kodi-pvr/pvr.hts/issues/119/comments"},"review_comments":{"href":"https://api.github.com/repos/kodi-pvr/pvr.hts/pulls/119/comments"},"review_comment":{"href":"https://api.github.com/repos/kodi-pvr/pvr.hts/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/kodi-pvr/pvr.hts/pulls/119/commits"},"statuses":{"href":"https://api.github.com/repos/kodi-pvr/pvr.hts/statuses/36973b4157072e5c7a920bfbd2ce911028689ba6"}}}}