Sign inSign up

antonmilev979/js-alert-ai-approuter

By antonmilev979

•Updated about 5 hours ago

SAP approuter gateway — authentication, routing for the Joule AI Alert Monitoring dashboard.

Image
Security
0

288

antonmilev979/js-alert-ai-approuter repository overview

⁠js-alert-ai-approuter

Node.js-based SAP approuter serving as the authentication gateway and reverse proxy for the Joule AI Alert Monitoring system. Every request from a browser or external client passes through this component before reaching the FastAPI backend.

⁠Role in the architecture

Internet / Kubernetes Ingress ↓ js-alert-ai-approuter ← you are here [XSUAA auth · routing · WebSocket proxy] ↓ js-alert-ai-backend (port 5001) [FastAPI · REST API · AI pipeline]

The approuter is the sole public entry point — the backend is never exposed directly outside the cluster.

⁠What it does

  • Authenticates users via SAP XSUAA (OAuth 2.0) before any protected resource is served.
  • Routes HTTP requests to the backend based on URL path patterns (/api/*, /alerts/*, /static/*, /healthz).
  • Proxies WebSocket connections for the real-time dashboard streams (/ws/alerts, /ws/ask, /ws/summary, /ws/cluster-analysis).
  • Forwards the auth token to the backend so it can verify user identity without an extra hop.
  • Serves static assets (/static/*) without requiring authentication.
  • Exposes /healthz unauthenticated for Kubernetes liveness and readiness probes.

⁠Route summary

PatternAuthDescription
/ws/*XSUAAWebSocket streams (alerts, Q&A, summary, cluster analysis)
/static/*NoneCSS, JS, images — cached with no-store policy
/healthzNoneKubernetes health probe
/* (catch-all)XSUAAAll HTML pages and /api/* REST endpoints

⁠Tech stack

  • Node.js 20 slim
  • @sap/approuter v20 — SAP's open-source routing middleware

Tag summary

Content type

Image

Digest

sha256:582fedf13…

Size

87 MB

Last updated

about 5 hours ago

docker pull antonmilev979/js-alert-ai-approuter:build-173