0

I have a long (aprox. 1sec) diagnostic method to call for every user's request. This is perfectly fine to call this method after rendering and sending output to the user. How can I do that in Django? Any guidelines where I can find info about it? Unfortunately using any queue system cannot be considered.

2
  • "using any queue system cannot be considered" - why not? Commented Jul 28, 2012 at 21:35
  • @Daniel - now when I know more about request_finished it is possible. If I decided to do that before I would force me to update 30 action one by one - not very efficient. Commented Jul 28, 2012 at 22:11

1 Answer 1

1

You could use a request_finished signal and start your function at the end of every request. Look at https://docs.djangoproject.com/en/dev/ref/signals/#django.core.signals.request_finished

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.