{"action":"created","issue":{"url":"https://api.github.com/repos/swarrot/SwarrotBundle/issues/62","labels_url":"https://api.github.com/repos/swarrot/SwarrotBundle/issues/62/labels{/name}","comments_url":"https://api.github.com/repos/swarrot/SwarrotBundle/issues/62/comments","events_url":"https://api.github.com/repos/swarrot/SwarrotBundle/issues/62/events","html_url":"https://github.com/swarrot/SwarrotBundle/pull/62","id":103518879,"number":62,"title":"use extra from config.yml as default value for options","user":{"login":"metfan","id":1121867,"avatar_url":"https://avatars.githubusercontent.com/u/1121867?v=3","gravatar_id":"","url":"https://api.github.com/users/metfan","html_url":"https://github.com/metfan","followers_url":"https://api.github.com/users/metfan/followers","following_url":"https://api.github.com/users/metfan/following{/other_user}","gists_url":"https://api.github.com/users/metfan/gists{/gist_id}","starred_url":"https://api.github.com/users/metfan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/metfan/subscriptions","organizations_url":"https://api.github.com/users/metfan/orgs","repos_url":"https://api.github.com/users/metfan/repos","events_url":"https://api.github.com/users/metfan/events{/privacy}","received_events_url":"https://api.github.com/users/metfan/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-08-27T14:07:16Z","updated_at":"2015-08-28T08:55:33Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/swarrot/SwarrotBundle/pulls/62","html_url":"https://github.com/swarrot/SwarrotBundle/pull/62","diff_url":"https://github.com/swarrot/SwarrotBundle/pull/62.diff","patch_url":"https://github.com/swarrot/SwarrotBundle/pull/62.patch"},"body":"fix bug where config from config.yml is unused in the command.\r\nmy config:\r\n\r\n    processors_stack:\r\n        ack: 'Swarrot\\Processor\\Ack\\AckProcessor'\r\n        max_messages: 'Swarrot\\Processor\\MaxMessages\\MaxMessagesProcessor'\r\n        exception_catcher: 'Swarrot\\Processor\\ExceptionCatcher\\ExceptionCatcherProcessor'\r\n        max_execution_time: 'Swarrot\\Processor\\MaxExecutionTime\\MaxExecutionTimeProcessor'\r\n    consumers:\r\n        esign_start:\r\n            processor: async_esignature.processors.validator_message.esign_start\r\n            extras:\r\n                requeue_on_error: 1\r\n                max_execution_time: 1000\r\n\r\nI call consumer with command line:\r\n\r\n    php app/console swarrot:consume:esign_start esign_start -m 1\r\n\r\nWithout override requeue_on_error and max_execution_time on command line I get requeue_on_error = false and max_execute_time = 300 as arguments ofprocessor.\r\n\r\nI modified to use value in $extras coming from config.yml as default value if the option exists.\r\nChange the same way for retry-attemps and clean deplicate code."},"comment":{"url":"https://api.github.com/repos/swarrot/SwarrotBundle/issues/comments/135690409","html_url":"https://github.com/swarrot/SwarrotBundle/pull/62#issuecomment-135690409","issue_url":"https://api.github.com/repos/swarrot/SwarrotBundle/issues/62","id":135690409,"user":{"login":"metfan","id":1121867,"avatar_url":"https://avatars.githubusercontent.com/u/1121867?v=3","gravatar_id":"","url":"https://api.github.com/users/metfan","html_url":"https://github.com/metfan","followers_url":"https://api.github.com/users/metfan/followers","following_url":"https://api.github.com/users/metfan/following{/other_user}","gists_url":"https://api.github.com/users/metfan/gists{/gist_id}","starred_url":"https://api.github.com/users/metfan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/metfan/subscriptions","organizations_url":"https://api.github.com/users/metfan/orgs","repos_url":"https://api.github.com/users/metfan/repos","events_url":"https://api.github.com/users/metfan/events{/privacy}","received_events_url":"https://api.github.com/users/metfan/received_events","type":"User","site_admin":false},"created_at":"2015-08-28T08:55:33Z","updated_at":"2015-08-28T08:55:33Z","body":"ah yes I understood, you right I break the original behavior.\r\nwith my change you will have to set option value in command line.\r\n\r\nI'll change my code to use $extra as base config that can be override by options and not $extra as default value for options like I did."}}