Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/aidenellis/djangorangemiddleware

A Django range middleware
https://github.com/aidenellis/djangorangemiddleware

aidenellis django middleware range range-middleware

Last synced: 3 months ago
JSON representation

A Django range middleware

Awesome Lists containing this project

README

        

# DjangoRangeMiddleware

Contributors

### A Django Middleware Service

* `Implements HTTP bytes-range requests`


#### When to use?
`If you have ever served video file with django you will see
that you can't rewind/forward the video, and thats because you
don't have bytes-range requests implemented.So if you want to
solve this problem you have to implement bytes-range requests.
And Using this package you can easily do it :)
`
#### `Bytes range:`
`
Byte-range requests occur when a client asks the server
for only a portion of the requested file.
The purpose of this is essentially to conserve bandwidth
usage by avoiding the need to download a complete file
when all that is required is a small section
`

## Installation

1. install the package using pip
```shell script
C:/User> pip install DjangoRangeMiddleware
```

2. Add this to middleware `settings.py`
```python
MIDDLEWARE = [
'.........',
'DjangoRangeMiddleware.middleware.RangesMiddleware',
]
```

* `And thats it.You're Done.Enjoy ;)`