Skip to content

feat: add /health check and modernize public endpoints#552

Merged
Jayprakash-SE merged 2 commits into
hatnote:masterfrom
ayushshukla1807:feat/health-check-and-modernize-public
Jun 7, 2026
Merged

feat: add /health check and modernize public endpoints#552
Jayprakash-SE merged 2 commits into
hatnote:masterfrom
ayushshukla1807:feat/health-check-and-modernize-public

Conversation

@ayushshukla1807

Copy link
Copy Markdown
Contributor

This PR introduces several production-grade enhancements to the public API layer.

Changes:

  • Health Check Endpoint: Added GET /health to verify database connectivity. This is essential for modern container orchestration and uptime monitoring.
  • Security Hardening: Removed insecure hardcoded debug impersonation logic. Replaced with a structured allow_impersonation config flag that only functions in the dev environment.
  • Modernization: Added comprehensive type hints to public_endpoints.py and updated path handling using os.path.join for better cross-platform compatibility.
  • Refactoring: Cleaned up legacy TODO comments and unused logic in the login flow.

These changes significantly improve the security posture and maintainability of the public entry points.

@lgelauff

lgelauff commented May 3, 2026

Copy link
Copy Markdown
Collaborator

According to the docs, /meta seems to fulfill mostly the same functionality. Could you verify for duplication?

…s purpose vs /meta

Signed-off-by: Ayush Shukla <ayushshukla1807@gmail.com>
@ayushshukla1807

Copy link
Copy Markdown
Contributor Author

I've updated /health to return a 503 Service Unavailable on DB failure. While /meta provides app internals, this endpoint serves as a dedicated, public-facing probe for load balancers and external monitoring. All commits are now DCO-signed as well.

1 similar comment
@ayushshukla1807

Copy link
Copy Markdown
Contributor Author

I've updated /health to return a 503 Service Unavailable on DB failure. While /meta provides app internals, this endpoint serves as a dedicated, public-facing probe for load balancers and external monitoring. All commits are now DCO-signed as well.

@Jayprakash-SE Jayprakash-SE merged commit 706ef20 into hatnote:master Jun 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants