[Feature Request] Graceful handling & stale-data fallback for HTTP data sources
Los mantenedores suelen responder en 2 días
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 5/5
- Tiempo estimado
- Más de una semana
- Aptitud para principiantes
- 25/100
- Tipo de issue
- Nueva funcionalidad
- Claridad
- Bastante claro
- Estado de actividad
- Estancado
- Stack tecnológico
- go
- Área
- backend-api-design
Línea de trabajo
Start by tracing how remote source_url downloads, dest_file handling, and the cscli hub update/upgrade flow interact. The issue does not name files or tests, so locate those entry points and check how fetch failures affect reloads and notifications. Done means failed downloads use an available local copy, do not block updates or reloads, and notify administrators.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
What would you like to be added?
Thanks a lot for the awesome project crowdsec.
Currently, when using a data source with a source_url in a parser or whitelist, a failure to fetch the remote file (e.g., 404, DNS issues, or timeout) causes the CrowdSec Hupupdate Service process to fail.
This is problematic for automated updates (cscli hub update && cscli hub upgrade), as it can leave the engine in an inconsistent state or prevent a restart.
Proposed Solution: I propose a more resilient approach for remote data sources:
-
Stale Data Fallback: If the HTTP download fails, CrowdSec should log a warning but continue to use the existing local version of the file (dest_file) if it exists.
-
Non-Blocking Update: The hub update or service reload should not return an error code if the failure is limited to a remote data source fetch and a local copy is available.
-
Notification Support: Trigger an alert (which can then be handled by the existing notification system, e.g., email, Slack, HTTP plugin) to inform the administrator that the data source update failed and stale data is being used.
Thanks a lot.
Why is this needed?
This is problematic for automated updates (cscli hub update && cscli hub upgrade), as it can leave the engine in an inconsistent state or prevent a restart.
- Lenguaje dominante
- Go
- Estrellas
- 15.1k
- Forks
- 726
- Merge medio
- 2 d 51 min
- PR fusionados (30 d)
- 18
Preparar el entorno
Este proyecto no incluye contenedor de desarrollo, Dockerfile ni guía de contribución, así que la configuración corre por tu cuenta: empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de crowdsecurity/crowdsec
-
[docker] Align build and debian releasePosiblemente ocupada @albundy83 la tomó hace 2 días. Abiertokind/enhancement needs/triage
Dificultad 2/5 1-3 horas Aptitud para principiantes 68/100
crowdsecurity/crowdsec#4803 · 3 comentarios ·
Los mantenedores suelen responder en 2 días
-
Bucket queues preallocate all their slots when the bucket is createdPosiblemente ocupada @AdzerKI la tomó hace 4 días. Abiertokind/bug needs/triage os/linux
Dificultad 2/5 1-3 horas Aptitud para principiantes 83/100
crowdsecurity/crowdsec#4799 · 3 comentarios ·
Los mantenedores suelen responder en 2 días
-
kind/bug needs/triage os/linux
Dificultad 3/5 1-2 días Aptitud para principiantes 25/100
crowdsecurity/crowdsec#4797 · 1 comentario ·
Los mantenedores suelen responder en 2 días
-
needs/kind needs/triage
Dificultad 5/5 Más de una semana Aptitud para principiantes 38/100
crowdsecurity/crowdsec#4795 · 2 comentarios ·
Los mantenedores suelen responder en 2 días
-
kind/bug needs/triage os/linux
Dificultad 4/5 3-5 días Aptitud para principiantes 45/100
crowdsecurity/crowdsec#4790 · 1 comentario ·
Los mantenedores suelen responder en 2 días
Todos los issues de crowdsecurity/crowdsec
Issues similares
-
govulncheck reports 7 reachable vulnerabilities in dependenciesPosiblemente ocupada @dwisiswant0 la tomó hoy. AbiertoType: Bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
projectdiscovery/rawhttp#558 ·
-
govulncheck reports 8 vulnerabilities in called codePosiblemente ocupada @dwisiswant0 la tomó hoy. AbiertoType: Bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 73/100
projectdiscovery/vulnx#517 ·
-
routing: the tray panel's stage stands still with motion reduced while a request is in flightAbierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 66/100
-
Type: Bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 67/100
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 77/100
rubys/roundhouse#1946 ·