Why Gemfury? Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Debian packages RPM packages NuGet packages

Repository URL to install this package:

Details    
motor / doc / examples / aiohttp_gridfs_example.rst
Size: Mime:
AIOHTTPGridFS Example
=====================

Serve pre-compressed static content from GridFS over HTTP. Uses the `aiohttp`_
web framework and :class:`~motor.aiohttp.AIOHTTPGridFS`.

.. _aiohttp: https://aiohttp.readthedocs.io/

Instructions
------------

Start a MongoDB server on its default port and run this script. Then visit:

http://localhost:8080/fs/my_file

Serve compressed static content from GridFS
-------------------------------------------

.. literalinclude:: aiohttp_gridfs_example.py
  :language: python3
  :start-after: include-start