New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Running zappa.async tasks outside of Lambda [DOCUMENTATION] #1124

Open
glassresistor opened this Issue Sep 22, 2017 · 6 comments

Comments

Projects
None yet
3 participants
@glassresistor

glassresistor commented Sep 22, 2017

Currently porting over some Celery tasks to Zappa ones. One concern I have is that celery has a setting called ALWAYS_EAGER which causes it to skip the queue and run immediately, this is useful when testing simple cases and during simple local development.

I've looked but haven't found a out of the box way to to do this with Zappa. I'm considering implementing a ZAPPA_TASK_ALWAYS_EAGER toggle in my own code which would swap out the decorator for no decorator which should do the trick but it seems generally useful.

So I'm happy to fork and PR something if folks thinks its useful.

@Miserlou

This comment has been minimized.

Show comment
Hide comment
@Miserlou

Miserlou Sep 23, 2017

Owner

It's a good idea and I'd be happy for a PR, but don't call it ALWAYS_EAGER since we're not gunning for Celery compatibility/cloning. remote_async maybe? @mcrowson

Owner

Miserlou commented Sep 23, 2017

It's a good idea and I'd be happy for a PR, but don't call it ALWAYS_EAGER since we're not gunning for Celery compatibility/cloning. remote_async maybe? @mcrowson

@mcrowson

This comment has been minimized.

Show comment
Hide comment
@mcrowson

mcrowson Sep 23, 2017

Collaborator
Collaborator

mcrowson commented Sep 23, 2017

@glassresistor

This comment has been minimized.

Show comment
Hide comment
@glassresistor

glassresistor Sep 25, 2017

@Miserlou agreed about always eager name. maybe RUN_INLINE

@mcrowson the desire is to be able to run a function decorated with zappa.task outside of lambda for development and testing. what is the current behaviour for zappa.task in local devlepment?
If what your saying is that it works like a normal function outside of zappa then thats exactly what I would like. For reference this would be django's runserver and tests.

glassresistor commented Sep 25, 2017

@Miserlou agreed about always eager name. maybe RUN_INLINE

@mcrowson the desire is to be able to run a function decorated with zappa.task outside of lambda for development and testing. what is the current behaviour for zappa.task in local devlepment?
If what your saying is that it works like a normal function outside of zappa then thats exactly what I would like. For reference this would be django's runserver and tests.

@mcrowson

This comment has been minimized.

Show comment
Hide comment
@mcrowson

mcrowson Sep 25, 2017

Collaborator
Collaborator

mcrowson commented Sep 25, 2017

@glassresistor

This comment has been minimized.

Show comment
Hide comment
@glassresistor

glassresistor Sep 25, 2017

@mcrowson awesome. it would be good to document that. its a good feature I totally missed. its probably good to figure out how to make it all work in the long run. thanks again.

glassresistor commented Sep 25, 2017

@mcrowson awesome. it would be good to document that. its a good feature I totally missed. its probably good to figure out how to make it all work in the long run. thanks again.

@Miserlou Miserlou changed the title from Running zappa.async tasks outside of Lambda to Running zappa.async tasks outside of Lambda [DOCUMENTATION] Sep 26, 2017

@Miserlou

This comment has been minimized.

Show comment
Hide comment
@Miserlou

Miserlou Sep 26, 2017

Owner

Leaving open, treating as documentation bug.

Owner

Miserlou commented Sep 26, 2017

Leaving open, treating as documentation bug.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment