Corregido error en health check del servidor hapi

This commit is contained in:
Alejandro Gomez Auad 2026-05-05 11:31:31 +00:00
parent 17ab0cdf03
commit 14e0284cd9
2 changed files with 13 additions and 9 deletions

View File

@ -100,7 +100,17 @@ Los parámetros del servidor FHIR se ajustan en [hapi-config/application.yaml](h
docker compose up -d
```
HAPI FHIR tarda aproximadamente **3040 segundos** en inicializar. El `bus-gateway` espera activamente a que el servidor FHIR esté listo antes de aceptar conexiones (hasta ~3 minutos de reintentos).
HAPI FHIR tarda aproximadamente **3040 segundos** en inicializar. El `bus-gateway` espera a que el contenedor `hapi-fhir` esté iniciado, pero no verifica que el servidor FHIR haya completado su arranque. Antes de usar los servicios, verificar que HAPI FHIR inicializó correctamente:
```bash
docker compose logs -f hapi-fhir
```
Buscar la línea que confirma el inicio exitoso:
```
Started Application in XX seconds
```
## Verificar el despliegue

View File

@ -15,12 +15,6 @@ services:
SPRING_DATASOURCE_PASSWORD: ${SPRING_DATASOURCE_PASSWORD}
SPRING_DATASOURCE_DRIVERCLASSNAME: ${SPRING_DATASOURCE_DRIVERCLASSNAME}
SPRING_JPA_PROPERTIES_HIBERNATE_DIALECT: ${SPRING_JPA_PROPERTIES_HIBERNATE_DIALECT}
healthcheck:
test: ["CMD-SHELL", "curl -sf http://localhost:8080/fhir/metadata > /dev/null"]
interval: 30s
timeout: 10s
retries: 5
start_period: 60s
networks:
- hapi-network
hapi-db:
@ -48,7 +42,7 @@ services:
container_name: bus-gateway
depends_on:
hapi-fhir:
condition: service_healthy
condition: service_started
build:
context: ./bus-gateway
environment:
@ -74,7 +68,7 @@ services:
image: nginx:alpine
depends_on:
hapi-fhir:
condition: service_healthy
condition: service_started
bus-gateway:
condition: service_started
environment: