Skip to content

cacoos/django-channels-memory-leak

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Django Channels Tutorial

Want to learn how to build this?

Check out the tutorial.

Want to use this project?

  1. Fork/Clone

  2. Create and activate a virtual environment:

    $ python3 -m venv venv && source venv/bin/activate
  3. Install the requirements:

    (venv)$ pip install -r requirements.txt
  4. Start a Redis server for backing storage:

    (venv)$ docker run -p 6379:6379 -d redis:5
  5. Run the server with memory profiler:

    (venv)$ mprof run uvicorn core.asgi:application --port 8000 --lifespan off --host 0.0.0.0 --workers 1

Or run with memray for the report

(venv)$ memray run  --force -o output.bin -m uvicorn core.asgi:application --port 8000 --lifespan off --host 0.0.0.0 --workers 1

Show results:

(venv)$ memray flamegraph output.bin --force
  1. Navigate to http://localhost:8000/chat/. Reload the page many times or send messages..

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published