Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

190
Vistas
Where to check swarm load balancer logs?

I have docker compose file as

---
version: '3.7'
services:
  myapi:
    image: tiangolo/uwsgi-nginx-flask:python3.7
    env_file: apivars.env
    logging:
      driver: syslog
      options:
        syslog-address: "udp://127.0.0.1:514"
        tag: tags
        labels: labels
    ports:
      - "8080:80"
    deploy:
      placement:
        constraints:
          - node.role != manager
      mode: replicated
      replicas: 32
      update_config:
        parallelism: 4
        delay: 5s
        order: start-first
...

I have load balancer which will redirect request to this swarm manager.

My understanding is, if I hit www.myapi.com, it will got to LoadBalancer and then request will go to swarm manager, then swarm manager send that request to on of the 32 replicas.

Now issue is, LoadBalancer logs report some of the 502 errors.

# head -n1 /var/log/haproxy.log
Apr 28 09:35:28 localhost haproxy[43117]: 172.19.9.1:50220 [28/Apr/2020:09:35:08.549] main~ API_Production/swarmnode5 0/0/1/19952/19953 502 309 - - ---- 97/97/10/1/0 0/0 "GET /v2/students/?includeFields=name,id&per_page=1000&page=88 HTTP/1.1"

I have to check its reaching to swarm manager or swarmnode5 ?

I check the logs for nginx, but its not report any 502 errors. There are some exceptions, but not sure if exception is there in code, then why nginx not logs that api call and response?

over 4 years ago · Santiago Trujillo
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda