{"action":"created","issue":{"url":"https://api.github.com/repos/mariano/disque-php/issues/2","labels_url":"https://api.github.com/repos/mariano/disque-php/issues/2/labels{/name}","comments_url":"https://api.github.com/repos/mariano/disque-php/issues/2/comments","events_url":"https://api.github.com/repos/mariano/disque-php/issues/2/events","html_url":"https://github.com/mariano/disque-php/issues/2","id":100512054,"number":2,"title":"Add methods for working with the body, NACKs and additional deliveries to the JobInterface","user":{"login":"Revisor","id":550341,"avatar_url":"https://avatars.githubusercontent.com/u/550341?v=3","gravatar_id":"","url":"https://api.github.com/users/Revisor","html_url":"https://github.com/Revisor","followers_url":"https://api.github.com/users/Revisor/followers","following_url":"https://api.github.com/users/Revisor/following{/other_user}","gists_url":"https://api.github.com/users/Revisor/gists{/gist_id}","starred_url":"https://api.github.com/users/Revisor/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Revisor/subscriptions","organizations_url":"https://api.github.com/users/Revisor/orgs","repos_url":"https://api.github.com/users/Revisor/repos","events_url":"https://api.github.com/users/Revisor/events{/privacy}","received_events_url":"https://api.github.com/users/Revisor/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":8,"created_at":"2015-08-12T10:18:05Z","updated_at":"2015-08-26T09:28:15Z","closed_at":null,"body":"`GETJOB` returns at least the queue, the ID and the body:\r\n\r\n> Jobs are returned as a three elements array containing the queue name, the Job ID, and the job body itself.\r\n\r\nWhat's the point of a job without a body?\r\n\r\nCase in point:\r\n`Disque\\Queue\\Marshal\\JobMarshaler::marshal()` expects a `JobInterface` type, but it actually requires a `Job` type and even throws an exception, because it needs the `Job::getBody()` method.\r\n\r\nAnd subquestions:\r\n\r\n* Should we agree that there is no point of a Job without an ID and a body, shouldn't they be provided as soon as in the constructor so that the object can't be instantiated in an invalid state?\r\n* In case the ID and the body are provided in the constructor, wouldn't it be preferrable to remove their setters and make Job immutable? What would be the use case for changing the Job ID or the body on the fly, after it has been created?"},"comment":{"url":"https://api.github.com/repos/mariano/disque-php/issues/comments/134915590","html_url":"https://github.com/mariano/disque-php/issues/2#issuecomment-134915590","issue_url":"https://api.github.com/repos/mariano/disque-php/issues/2","id":134915590,"user":{"login":"Revisor","id":550341,"avatar_url":"https://avatars.githubusercontent.com/u/550341?v=3","gravatar_id":"","url":"https://api.github.com/users/Revisor","html_url":"https://github.com/Revisor","followers_url":"https://api.github.com/users/Revisor/followers","following_url":"https://api.github.com/users/Revisor/following{/other_user}","gists_url":"https://api.github.com/users/Revisor/gists{/gist_id}","starred_url":"https://api.github.com/users/Revisor/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Revisor/subscriptions","organizations_url":"https://api.github.com/users/Revisor/orgs","repos_url":"https://api.github.com/users/Revisor/repos","events_url":"https://api.github.com/users/Revisor/events{/privacy}","received_events_url":"https://api.github.com/users/Revisor/received_events","type":"User","site_admin":false},"created_at":"2015-08-26T09:28:15Z","updated_at":"2015-08-26T09:28:15Z","body":"I'm sorry for the delay. I have created a pull request."}}