{"action":"created","comment":{"url":"https://api.github.com/repos/symfony/symfony/pulls/comments/186036954","pull_request_review_id":117548663,"id":186036954,"diff_hunk":"@@ -0,0 +1,58 @@\n+<?php\n+\n+/*\n+ * This file is part of the Symfony package.\n+ *\n+ * (c) Fabien Potencier <fabien@symfony.com>\n+ *\n+ * For the full copyright and license information, please view the LICENSE\n+ * file that was distributed with this source code.\n+ */\n+\n+namespace Symfony\\Component\\Amqp\\RetryStrategy;\n+\n+use Symfony\\Component\\Amqp\\Exception\\InvalidArgumentException;\n+\n+/**\n+ * @author Fabien Potencier <fabien@symfony.com>\n+ * @author Grégoire Pineau <lyrixx@lyrixx.info>\n+ */\n+class ConstantRetryStrategy implements RetryStrategyInterface\n+{\n+    private $time;\n+    private $max;\n+\n+    /**\n+     * @param int $time Time to wait in the queue in seconds\n+     * @param int $max  The maximum number of attempts (0 means no limit)\n+     */\n+    public function __construct(int $time, int $max = 0)\n+    {\n+        $time = (int) $time;\n+\n+        if ($time < 1) {\n+            throw new InvalidArgumentException('\"time\" should be at least 1.');","path":"src/Symfony/Component/Amqp/RetryStrategy/ConstantRetryStrategy.php","position":34,"original_position":34,"commit_id":"42fe5d747c1cb8dc85683d6c33b281abceb76214","original_commit_id":"42fe5d747c1cb8dc85683d6c33b281abceb76214","user":{"login":"lyrixx","id":408368,"avatar_url":"https://avatars1.githubusercontent.com/u/408368?v=4","gravatar_id":"","url":"https://api.github.com/users/lyrixx","html_url":"https://github.com/lyrixx","followers_url":"https://api.github.com/users/lyrixx/followers","following_url":"https://api.github.com/users/lyrixx/following{/other_user}","gists_url":"https://api.github.com/users/lyrixx/gists{/gist_id}","starred_url":"https://api.github.com/users/lyrixx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lyrixx/subscriptions","organizations_url":"https://api.github.com/users/lyrixx/orgs","repos_url":"https://api.github.com/users/lyrixx/repos","events_url":"https://api.github.com/users/lyrixx/events{/privacy}","received_events_url":"https://api.github.com/users/lyrixx/received_events","type":"User","site_admin":false},"body":"If you don't want to wait, there is no need to use a retry strategy. A simple nack + requeue is enough (I guess)","created_at":"2018-05-04T09:53:45Z","updated_at":"2018-05-04T09:53:45Z","html_url":"https://github.com/symfony/symfony/pull/27140#discussion_r186036954","pull_request_url":"https://api.github.com/repos/symfony/symfony/pulls/27140","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/symfony/symfony/pulls/comments/186036954"},"html":{"href":"https://github.com/symfony/symfony/pull/27140#discussion_r186036954"},"pull_request":{"href":"https://api.github.com/repos/symfony/symfony/pulls/27140"}},"in_reply_to_id":186031073},"pull_request":{"url":"https://api.github.com/repos/symfony/symfony/pulls/27140","id":185738413,"html_url":"https://github.com/symfony/symfony/pull/27140","diff_url":"https://github.com/symfony/symfony/pull/27140.diff","patch_url":"https://github.com/symfony/symfony/pull/27140.patch","issue_url":"https://api.github.com/repos/symfony/symfony/issues/27140","number":27140,"state":"open","locked":false,"title":"Added AMQP component","user":{"login":"lyrixx","id":408368,"avatar_url":"https://avatars1.githubusercontent.com/u/408368?v=4","gravatar_id":"","url":"https://api.github.com/users/lyrixx","html_url":"https://github.com/lyrixx","followers_url":"https://api.github.com/users/lyrixx/followers","following_url":"https://api.github.com/users/lyrixx/following{/other_user}","gists_url":"https://api.github.com/users/lyrixx/gists{/gist_id}","starred_url":"https://api.github.com/users/lyrixx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lyrixx/subscriptions","organizations_url":"https://api.github.com/users/lyrixx/orgs","repos_url":"https://api.github.com/users/lyrixx/repos","events_url":"https://api.github.com/users/lyrixx/events{/privacy}","received_events_url":"https://api.github.com/users/lyrixx/received_events","type":"User","site_admin":false},"body":"| Q             | A\n| ------------- | ---\n| Branch?       | master\n| Bug fix?      | no\n| New feature?  | yes\n| BC breaks?    | no\n| Deprecations? | no\n| Tests pass?   | yes\n| Fixed tickets |\n| License       | MIT\n| Doc PR        |","created_at":"2018-05-03T14:39:45Z","updated_at":"2018-05-04T09:53:45Z","closed_at":null,"merged_at":null,"merge_commit_sha":"8014315d06a4257529789eb8ccc11cabc10b81b0","assignee":null,"assignees":[],"requested_reviewers":[{"login":"fabpot","id":47313,"avatar_url":"https://avatars3.githubusercontent.com/u/47313?v=4","gravatar_id":"","url":"https://api.github.com/users/fabpot","html_url":"https://github.com/fabpot","followers_url":"https://api.github.com/users/fabpot/followers","following_url":"https://api.github.com/users/fabpot/following{/other_user}","gists_url":"https://api.github.com/users/fabpot/gists{/gist_id}","starred_url":"https://api.github.com/users/fabpot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/fabpot/subscriptions","organizations_url":"https://api.github.com/users/fabpot/orgs","repos_url":"https://api.github.com/users/fabpot/repos","events_url":"https://api.github.com/users/fabpot/events{/privacy}","received_events_url":"https://api.github.com/users/fabpot/received_events","type":"User","site_admin":false},{"login":"sroze","id":804625,"avatar_url":"https://avatars0.githubusercontent.com/u/804625?v=4","gravatar_id":"","url":"https://api.github.com/users/sroze","html_url":"https://github.com/sroze","followers_url":"https://api.github.com/users/sroze/followers","following_url":"https://api.github.com/users/sroze/following{/other_user}","gists_url":"https://api.github.com/users/sroze/gists{/gist_id}","starred_url":"https://api.github.com/users/sroze/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sroze/subscriptions","organizations_url":"https://api.github.com/users/sroze/orgs","repos_url":"https://api.github.com/users/sroze/repos","events_url":"https://api.github.com/users/sroze/events{/privacy}","received_events_url":"https://api.github.com/users/sroze/received_events","type":"User","site_admin":false}],"requested_teams":[],"labels":[{"id":100378,"url":"https://api.github.com/repos/symfony/symfony/labels/Feature","name":"Feature","color":"02e10c","default":false},{"id":237003792,"url":"https://api.github.com/repos/symfony/symfony/labels/Status:%20Needs%20Review","name":"Status: Needs Review","color":"ededed","default":false}],"milestone":{"url":"https://api.github.com/repos/symfony/symfony/milestones/18","html_url":"https://github.com/symfony/symfony/milestone/18","labels_url":"https://api.github.com/repos/symfony/symfony/milestones/18/labels","id":3234645,"number":18,"title":"next","description":"https://symfony.com/roadmap?version=4.2#checker","creator":{"login":"nicolas-grekas","id":243674,"avatar_url":"https://avatars3.githubusercontent.com/u/243674?v=4","gravatar_id":"","url":"https://api.github.com/users/nicolas-grekas","html_url":"https://github.com/nicolas-grekas","followers_url":"https://api.github.com/users/nicolas-grekas/followers","following_url":"https://api.github.com/users/nicolas-grekas/following{/other_user}","gists_url":"https://api.github.com/users/nicolas-grekas/gists{/gist_id}","starred_url":"https://api.github.com/users/nicolas-grekas/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nicolas-grekas/subscriptions","organizations_url":"https://api.github.com/users/nicolas-grekas/orgs","repos_url":"https://api.github.com/users/nicolas-grekas/repos","events_url":"https://api.github.com/users/nicolas-grekas/events{/privacy}","received_events_url":"https://api.github.com/users/nicolas-grekas/received_events","type":"User","site_admin":false},"open_issues":120,"closed_issues":6,"state":"open","created_at":"2018-04-02T12:03:21Z","updated_at":"2018-05-03T20:21:15Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/symfony/symfony/pulls/27140/commits","review_comments_url":"https://api.github.com/repos/symfony/symfony/pulls/27140/comments","review_comment_url":"https://api.github.com/repos/symfony/symfony/pulls/comments{/number}","comments_url":"https://api.github.com/repos/symfony/symfony/issues/27140/comments","statuses_url":"https://api.github.com/repos/symfony/symfony/statuses/42fe5d747c1cb8dc85683d6c33b281abceb76214","head":{"label":"lyrixx:amqp","ref":"amqp","sha":"42fe5d747c1cb8dc85683d6c33b281abceb76214","user":{"login":"lyrixx","id":408368,"avatar_url":"https://avatars1.githubusercontent.com/u/408368?v=4","gravatar_id":"","url":"https://api.github.com/users/lyrixx","html_url":"https://github.com/lyrixx","followers_url":"https://api.github.com/users/lyrixx/followers","following_url":"https://api.github.com/users/lyrixx/following{/other_user}","gists_url":"https://api.github.com/users/lyrixx/gists{/gist_id}","starred_url":"https://api.github.com/users/lyrixx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lyrixx/subscriptions","organizations_url":"https://api.github.com/users/lyrixx/orgs","repos_url":"https://api.github.com/users/lyrixx/repos","events_url":"https://api.github.com/users/lyrixx/events{/privacy}","received_events_url":"https://api.github.com/users/lyrixx/received_events","type":"User","site_admin":false},"repo":{"id":3148495,"name":"symfony","full_name":"lyrixx/symfony","owner":{"login":"lyrixx","id":408368,"avatar_url":"https://avatars1.githubusercontent.com/u/408368?v=4","gravatar_id":"","url":"https://api.github.com/users/lyrixx","html_url":"https://github.com/lyrixx","followers_url":"https://api.github.com/users/lyrixx/followers","following_url":"https://api.github.com/users/lyrixx/following{/other_user}","gists_url":"https://api.github.com/users/lyrixx/gists{/gist_id}","starred_url":"https://api.github.com/users/lyrixx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lyrixx/subscriptions","organizations_url":"https://api.github.com/users/lyrixx/orgs","repos_url":"https://api.github.com/users/lyrixx/repos","events_url":"https://api.github.com/users/lyrixx/events{/privacy}","received_events_url":"https://api.github.com/users/lyrixx/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/lyrixx/symfony","description":"The Symfony2 PHP framework","fork":true,"url":"https://api.github.com/repos/lyrixx/symfony","forks_url":"https://api.github.com/repos/lyrixx/symfony/forks","keys_url":"https://api.github.com/repos/lyrixx/symfony/keys{/key_id}","collaborators_url":"https://api.github.com/repos/lyrixx/symfony/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/lyrixx/symfony/teams","hooks_url":"https://api.github.com/repos/lyrixx/symfony/hooks","issue_events_url":"https://api.github.com/repos/lyrixx/symfony/issues/events{/number}","events_url":"https://api.github.com/repos/lyrixx/symfony/events","assignees_url":"https://api.github.com/repos/lyrixx/symfony/assignees{/user}","branches_url":"https://api.github.com/repos/lyrixx/symfony/branches{/branch}","tags_url":"https://api.github.com/repos/lyrixx/symfony/tags","blobs_url":"https://api.github.com/repos/lyrixx/symfony/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/lyrixx/symfony/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/lyrixx/symfony/git/refs{/sha}","trees_url":"https://api.github.com/repos/lyrixx/symfony/git/trees{/sha}","statuses_url":"https://api.github.com/repos/lyrixx/symfony/statuses/{sha}","languages_url":"https://api.github.com/repos/lyrixx/symfony/languages","stargazers_url":"https://api.github.com/repos/lyrixx/symfony/stargazers","contributors_url":"https://api.github.com/repos/lyrixx/symfony/contributors","subscribers_url":"https://api.github.com/repos/lyrixx/symfony/subscribers","subscription_url":"https://api.github.com/repos/lyrixx/symfony/subscription","commits_url":"https://api.github.com/repos/lyrixx/symfony/commits{/sha}","git_commits_url":"https://api.github.com/repos/lyrixx/symfony/git/commits{/sha}","comments_url":"https://api.github.com/repos/lyrixx/symfony/comments{/number}","issue_comment_url":"https://api.github.com/repos/lyrixx/symfony/issues/comments{/number}","contents_url":"https://api.github.com/repos/lyrixx/symfony/contents/{+path}","compare_url":"https://api.github.com/repos/lyrixx/symfony/compare/{base}...{head}","merges_url":"https://api.github.com/repos/lyrixx/symfony/merges","archive_url":"https://api.github.com/repos/lyrixx/symfony/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/lyrixx/symfony/downloads","issues_url":"https://api.github.com/repos/lyrixx/symfony/issues{/number}","pulls_url":"https://api.github.com/repos/lyrixx/symfony/pulls{/number}","milestones_url":"https://api.github.com/repos/lyrixx/symfony/milestones{/number}","notifications_url":"https://api.github.com/repos/lyrixx/symfony/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/lyrixx/symfony/labels{/name}","releases_url":"https://api.github.com/repos/lyrixx/symfony/releases{/id}","deployments_url":"https://api.github.com/repos/lyrixx/symfony/deployments","created_at":"2012-01-10T20:46:58Z","updated_at":"2018-05-03T08:37:42Z","pushed_at":"2018-05-04T09:13:31Z","git_url":"git://github.com/lyrixx/symfony.git","ssh_url":"git@github.com:lyrixx/symfony.git","clone_url":"https://github.com/lyrixx/symfony.git","svn_url":"https://github.com/lyrixx/symfony","homepage":"symfony.com","size":112022,"stargazers_count":2,"watchers_count":2,"language":"PHP","has_issues":false,"has_projects":true,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":3,"mirror_url":null,"archived":false,"open_issues_count":1,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit"},"forks":3,"open_issues":1,"watchers":2,"default_branch":"master"}},"base":{"label":"symfony:master","ref":"master","sha":"47da23c7cb2e1a4209810ed48ecc615a35b34877","user":{"login":"symfony","id":143937,"avatar_url":"https://avatars3.githubusercontent.com/u/143937?v=4","gravatar_id":"","url":"https://api.github.com/users/symfony","html_url":"https://github.com/symfony","followers_url":"https://api.github.com/users/symfony/followers","following_url":"https://api.github.com/users/symfony/following{/other_user}","gists_url":"https://api.github.com/users/symfony/gists{/gist_id}","starred_url":"https://api.github.com/users/symfony/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/symfony/subscriptions","organizations_url":"https://api.github.com/users/symfony/orgs","repos_url":"https://api.github.com/users/symfony/repos","events_url":"https://api.github.com/users/symfony/events{/privacy}","received_events_url":"https://api.github.com/users/symfony/received_events","type":"Organization","site_admin":false},"repo":{"id":458058,"name":"symfony","full_name":"symfony/symfony","owner":{"login":"symfony","id":143937,"avatar_url":"https://avatars3.githubusercontent.com/u/143937?v=4","gravatar_id":"","url":"https://api.github.com/users/symfony","html_url":"https://github.com/symfony","followers_url":"https://api.github.com/users/symfony/followers","following_url":"https://api.github.com/users/symfony/following{/other_user}","gists_url":"https://api.github.com/users/symfony/gists{/gist_id}","starred_url":"https://api.github.com/users/symfony/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/symfony/subscriptions","organizations_url":"https://api.github.com/users/symfony/orgs","repos_url":"https://api.github.com/users/symfony/repos","events_url":"https://api.github.com/users/symfony/events{/privacy}","received_events_url":"https://api.github.com/users/symfony/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/symfony/symfony","description":"The Symfony PHP framework","fork":false,"url":"https://api.github.com/repos/symfony/symfony","forks_url":"https://api.github.com/repos/symfony/symfony/forks","keys_url":"https://api.github.com/repos/symfony/symfony/keys{/key_id}","collaborators_url":"https://api.github.com/repos/symfony/symfony/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/symfony/symfony/teams","hooks_url":"https://api.github.com/repos/symfony/symfony/hooks","issue_events_url":"https://api.github.com/repos/symfony/symfony/issues/events{/number}","events_url":"https://api.github.com/repos/symfony/symfony/events","assignees_url":"https://api.github.com/repos/symfony/symfony/assignees{/user}","branches_url":"https://api.github.com/repos/symfony/symfony/branches{/branch}","tags_url":"https://api.github.com/repos/symfony/symfony/tags","blobs_url":"https://api.github.com/repos/symfony/symfony/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/symfony/symfony/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/symfony/symfony/git/refs{/sha}","trees_url":"https://api.github.com/repos/symfony/symfony/git/trees{/sha}","statuses_url":"https://api.github.com/repos/symfony/symfony/statuses/{sha}","languages_url":"https://api.github.com/repos/symfony/symfony/languages","stargazers_url":"https://api.github.com/repos/symfony/symfony/stargazers","contributors_url":"https://api.github.com/repos/symfony/symfony/contributors","subscribers_url":"https://api.github.com/repos/symfony/symfony/subscribers","subscription_url":"https://api.github.com/repos/symfony/symfony/subscription","commits_url":"https://api.github.com/repos/symfony/symfony/commits{/sha}","git_commits_url":"https://api.github.com/repos/symfony/symfony/git/commits{/sha}","comments_url":"https://api.github.com/repos/symfony/symfony/comments{/number}","issue_comment_url":"https://api.github.com/repos/symfony/symfony/issues/comments{/number}","contents_url":"https://api.github.com/repos/symfony/symfony/contents/{+path}","compare_url":"https://api.github.com/repos/symfony/symfony/compare/{base}...{head}","merges_url":"https://api.github.com/repos/symfony/symfony/merges","archive_url":"https://api.github.com/repos/symfony/symfony/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/symfony/symfony/downloads","issues_url":"https://api.github.com/repos/symfony/symfony/issues{/number}","pulls_url":"https://api.github.com/repos/symfony/symfony/pulls{/number}","milestones_url":"https://api.github.com/repos/symfony/symfony/milestones{/number}","notifications_url":"https://api.github.com/repos/symfony/symfony/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/symfony/symfony/labels{/name}","releases_url":"https://api.github.com/repos/symfony/symfony/releases{/id}","deployments_url":"https://api.github.com/repos/symfony/symfony/deployments","created_at":"2010-01-04T14:21:21Z","updated_at":"2018-05-04T09:20:24Z","pushed_at":"2018-05-04T09:43:38Z","git_url":"git://github.com/symfony/symfony.git","ssh_url":"git@github.com:symfony/symfony.git","clone_url":"https://github.com/symfony/symfony.git","svn_url":"https://github.com/symfony/symfony","homepage":"https://symfony.com","size":116716,"stargazers_count":17449,"watchers_count":17449,"language":"PHP","has_issues":true,"has_projects":true,"has_downloads":false,"has_wiki":false,"has_pages":false,"forks_count":6183,"mirror_url":null,"archived":false,"open_issues_count":811,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit"},"forks":6183,"open_issues":811,"watchers":17449,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/symfony/symfony/pulls/27140"},"html":{"href":"https://github.com/symfony/symfony/pull/27140"},"issue":{"href":"https://api.github.com/repos/symfony/symfony/issues/27140"},"comments":{"href":"https://api.github.com/repos/symfony/symfony/issues/27140/comments"},"review_comments":{"href":"https://api.github.com/repos/symfony/symfony/pulls/27140/comments"},"review_comment":{"href":"https://api.github.com/repos/symfony/symfony/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/symfony/symfony/pulls/27140/commits"},"statuses":{"href":"https://api.github.com/repos/symfony/symfony/statuses/42fe5d747c1cb8dc85683d6c33b281abceb76214"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"lyrixx"}}