From a08339059b06bcfb673b13a380b6f199abfb5983 Mon Sep 17 00:00:00 2001 From: Frederic Guillot Date: Sun, 5 Jun 2016 14:19:07 -0400 Subject: Improve background workers --- app/Job/HttpAsyncJob.php | 43 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) create mode 100644 app/Job/HttpAsyncJob.php (limited to 'app/Job') diff --git a/app/Job/HttpAsyncJob.php b/app/Job/HttpAsyncJob.php new file mode 100644 index 00000000..9e5cf107 --- /dev/null +++ b/app/Job/HttpAsyncJob.php @@ -0,0 +1,43 @@ +jobParams = array($method, $url, $content, $headers); + return $this; + } + + /** + * Set job parameters + * + * @access public + * @param string $method + * @param string $url + * @param string $content + * @param array $headers + * @return $this + */ + public function execute($method, $url, $content, array $headers) + { + $this->httpClient->doRequest($method, $url, $content, $headers); + } +} -- cgit v1.2.3