jazzband / django-silk

Silky smooth profiling for Django
MIT License
4.46k stars 335 forks source link

Allowing profiling outside of the request/response cycle #3

Open mtford90 opened 10 years ago

mtford90 commented 10 years ago

e.g. a profile should not have to be associated with a request, perhaps by detecting that no request is in process and then committing profile data on the fly if that's the case.

auvipy commented 7 years ago

How to that? what about profiling django-channels request with silk? @avelis @smaccona

avelis commented 7 years ago

@auvipy Not sure if django-channels is within the purview of this library. Not against it though. The issue becomes volume. Since channels is meant for websockets it will definitely be high-volume.

auvipy commented 7 years ago

OK. we can re think about django channels at a later stage.

fernandolins commented 7 years ago

+1

ociule commented 5 years ago

Silk is an awesome tool, it would be great to use it for profiling celery or other async tasks that happen outside the request/response cycle.

dralley commented 5 years ago

We have a use case where this feature would be extremely useful. Our application has a lot of long-running asynchronous "tasks" using RQ. Currently, django-silk can't help us because none of the hard work is being done within the scope of a request. Each individual task is very intensive but there are not that many of them, relatively speaking, so it's not a "high volume" problem.

A lot of applications use Celery, also. Same principle. I would love to be able to use Silk to debug our task performance.

auvipy commented 5 years ago

any prospective API wor workflow do you have in mind how should be the DevUX for the API of that profiler to profile celery/ etc with or outside of django req/resp cycle?

pranaysharma commented 5 years ago

Hi, Why not give an option in the plugin so that Celery/Rabbit MQ can be used to log the data in Database asynchronously. We face timeouts for requests which have large amounts of data. Is this a suggested strategy? if yes then my team can work on the feature and push it

jezeniel commented 1 year ago

Do not want to necro something, is there a way to achieve this somehow?

OscarVanL commented 7 months ago

FYI I found this GitHub gist that you can use to run django-silk against arbitrary functions not wrapped in APIs. This was a good-enough workaround for me to debug some performance challenges, although it would be fantastic to see something supported by django-silk in the future.