Comments (7)
No, this is impossible right now. Celery-php currently only connects to AMQP backend.
from celery-php.
Ok ! thanks. :)
from celery-php.
Hi.
In my case I cannot have AMQP backend. I will have to use redis. So can you suggest any work around for fetching the result. I mean is their any way I can use PRedis to do this for me. Or maybe there is some other way.
from celery-php.
@lankesh Redis is supported now. See this for how to instantiate the object:
https://github.com/gjedeer/celery-php/blob/master/unittest/CeleryRedisTest.php
from celery-php.
Sorry if this is a stupid question. But actually I instantiated my celery object with these settings only. But still I am not able to get the result back. It keeps on throwing this exception:
'AMQP task proj.tasks.hello(["hello world"]) did not return after 10 seconds'
What am I doing wrong here?
Following is my celery.py file:
from future import absolute_import
from celery import Celery
app = Celery('proj',
broker='redis://localhost:6379/0',
backend='redis://',
include=['proj.tasks'])
app.conf.update(
CELERY_TASK_RESULT_EXPIRES=3600,
CELERY_ACCEPT_CONTENT = ['json']
)
if name == 'main':
app.start()
Following is my tasks.py file:
from future import absolute_import
from proj.celery import app
@app.task
def hello(helloWorld):
return helloWorld
from celery-php.
You're certainly missing serializer and the result backend has strange format too. See:
https://github.com/gjedeer/celery-php/blob/master/testscenario/celeryredisconfig.py
from celery-php.
Thanks a million. I cannot thank you more.
It is working now. Actually I am a total newbie to both celery and redis.
Thank you for your time.
cheers 👍
from celery-php.
Related Issues (20)
- Transport abstraction layer HOT 3
- Introduce CeleryConnectionException HOT 2
- Travis tests are installing celery 4.1 (latest), but the README says latest tested version is celery 3.1.19 HOT 2
- Is it possible to use the same Celery object for different queues HOT 1
- Missing Parameter in CONNECTING VIA SSL Example HOT 1
- How to install celery4-dev? HOT 2
- how to set timeout with connection redis or mq
- This project has plans to correspond to Amazon SQS? HOT 2
- request.retries comes in as null in the celery worker HOT 2
- Get result not working with amqp backend in Ubuntu 20.04 HOT 3
- API documentation page is blank HOT 8
- Composer warning on install: "Package videlalvaro/php-amqplib is abandoned, you should avoid using it. Use php-amqplib/php-amqplib instead." HOT 4
- How can i get var_dump HOT 10
- Broker connection still open HOT 4
- Port Celery4 v2 protocol to Redis and PECL-AMQP HOT 32
- celery queue always created HOT 1
- create unit test validating ETA support
- fix params/ETA support in celery4 branch HOT 1
- [help wanted] Make documentation comments work with latest PHPDocumentor HOT 1
- Packagist error HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from celery-php.