What is gunicorn frontend?

Questions, comments, discussions. Over time certain topics might be moved to their own category.
Post Reply
Posts: 3
Joined: Mon Sep 14, 2020 2:49 pm

What is gunicorn frontend?

Post by VPC »

I have instability in my indexes and have to rebuild them daily in order to get the correct documents. I have been looking at the docker-compose sample for improvements I can make in my own setup.

What is gunicorn?

Does it replace something I already have or is it in addition to?

What considerations should I have for using gunicorn or not.

Thank you!

https://gitlab.com/mayan-edms/mayan-edm ... ompose.yml

Code: Select all

  # Enable to run frontend gunicorn
  # frontend:
  #   command:
  #     - run_frontend
  #   depends_on:
  #     - postgresql
  #     - redis
  #     # Enable to use RabbitMQ
  #     # - rabbitmq
  #   environment:
  #     <<: *mayan_env
  #   image: mayanedms/mayanedms:3
  #   networks:
  #     - bridge
  #   ports:
  #     - "81:8000"
  #   restart: unless-stopped
  #   volumes:
  #     - ${MAYAN_APP_VOLUME:-app}:/var/lib/mayan
User avatar
Posts: 651
Joined: Tue Aug 21, 2018 3:28 am
Location: Puerto Rico

Re: What is gunicorn frontend?

Post by rosarior »

Mayan doesn't speak HTTP directly, it uses WSGI. Gunicorn is a Python package that translates between HTTP and WSGI so that browsers can talk to Mayan.
In 2003, Python web frameworks were typically written against only CGI, FastCGI, mod_python, or some other custom API of a specific web server.[6] To quote PEP 333:

Python currently boasts a wide variety of web application frameworks, such as Zope, Quixote, Webware, SkunkWeb, PSO, and Twisted Web -- to name just a few. This wide variety of choices can be a problem for new Python users, because generally speaking, their choice of web framework will limit their choice of usable web servers, and vice versa... By contrast, although Java has just as many web application frameworks available, Java's "servlet" API makes it possible for applications written with any Java web application framework to run in any web server that supports the servlet API.

WSGI was thus created as an implementation-agnostic interface between web servers and web applications or frameworks to promote common ground for portable web application development.[4]
https://en.wikipedia.org/wiki/Web_Serve ... _Interface

Gunicorn runs independently from the background workers that update the indexes, one does not affect the other. Check the logs for messages that might give a hint about the indexes update issue.
Post Reply