actually put the post in the xml param where we expecting it. also, throw the errors so we know in whats going on in resque
This commit is contained in:
parent
c55a867f61
commit
88aa67dba7
1 changed files with 3 additions and 2 deletions
|
|
@ -3,9 +3,10 @@ module Jobs
|
|||
@queue = :http
|
||||
def self.perform(url, body, tries_remaining)
|
||||
begin
|
||||
RestClient.post(url, body)
|
||||
rescue
|
||||
RestClient.post(url, :xml => body)
|
||||
rescue Exception => e
|
||||
Resque.enqueue(self, url, body, tries_remaining -1) unless tries_remaining <= 1
|
||||
raise e
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
|||
Loading…
Reference in a new issue