{"comment":{"url":"https://api.github.com/repos/frascuchon/storm-rabbitmq/comments/10031842","html_url":"https://github.com/frascuchon/storm-rabbitmq/commit/bffc8ffaefc04ee595995d1453b35517bba0d877#commitcomment-10031842","id":10031842,"user":{"login":"ppat","id":1630635,"avatar_url":"https://avatars.githubusercontent.com/u/1630635?v=3","gravatar_id":"","url":"https://api.github.com/users/ppat","html_url":"https://github.com/ppat","followers_url":"https://api.github.com/users/ppat/followers","following_url":"https://api.github.com/users/ppat/following{/other_user}","gists_url":"https://api.github.com/users/ppat/gists{/gist_id}","starred_url":"https://api.github.com/users/ppat/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ppat/subscriptions","organizations_url":"https://api.github.com/users/ppat/orgs","repos_url":"https://api.github.com/users/ppat/repos","events_url":"https://api.github.com/users/ppat/events{/privacy}","received_events_url":"https://api.github.com/users/ppat/received_events","type":"User","site_admin":false},"position":null,"line":null,"path":"","commit_id":"bffc8ffaefc04ee595995d1453b35517bba0d877","created_at":"2015-03-04T15:33:52Z","updated_at":"2015-03-04T15:33:52Z","body":"Well you're not using the provided API, you're directly setting the parameters in the config.\r\n```java\r\n\t\tconfig.put(\"rabbitmq.autoRecovery\", true);\r\n\t\tconfig.put(\"rabbitmq.queueName\", \"testQueue\");\r\n\t\tconfig.put(\"rabbitmq.prefetchCount\", 2*BATCH_SIZE);\r\n```\r\n\r\nInstead you should have been using the provided API (or provide new API along those lines in your new feature).\r\n```java\r\nConsumerConfig spoutConfig = new ConsumerConfigBuilder().connection(connectionConfig)\r\n                                                        .queue(\"your.rabbitmq.queue\")\r\n                                                        .prefetch(200)\r\n                                                        .requeueOnFail()\r\n                                                        .build();\r\n```\r\n\r\nAnd then have the builder take of care of ensuring all the required fields are there. ConfigUtils is not the right place for defaults as it lacks context on what the right defaults should be. Different use cases may require different defaults."}}