Replies: 2 comments 1 reply
-
Having the exact same use case where I need to use OAuth in order to get an access token, which is used for authentication. @zenoran , did you manage to fix this? Could you please share what you have so far? Thanks! |
Beta Was this translation helpful? Give feedback.
1 reply
-
I am trying to do the exact same thing as you did with the workers (dont need beats) but im having some issues with the events queue. Could you share your solution perhaps? @zenoran |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I'm trying to integrate celery with a RabbitMQ server which uses Oauth on the backend to auth users. We have to get a token and use that as the password for logging in to RabbitMQ, but it expires every 60 minutes. This presents a problem for worker processes which I'm trying to isolate and fix.
Initially we created a custom transport based on pyamqp.SSLTransport which overrides the establish_connection and verify_connection functions to get a new token if it's expired. This works fine for celery workers, but beat doesn't appear to be calling those same functions prior to publishing messages.
I've attempted to create a custom scheduler based on celery.beat.PersistentScheduler with a modified apply_entry() to call the verify_connection prior to creating the task, but this doesn't appear to be working either. I can see it's actually executing the verify_connection via the logs, but the password for beat doesn't appear to be using the same one stored in the transport.client (which gets updated via verify_connection).
Does anyone know why beat would be using different cached credentials and if so where I should be updating them? Also, if I'm going about this all wrong and someone has a better suggestion on how to accomplish this I would greatly appreciate the feedback.
Beta Was this translation helpful? Give feedback.
All reactions