Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Api Health checks #342

Merged
merged 1 commit into from
May 10, 2021
Merged

Conversation

adrianiftode
Copy link
Contributor

  • VotingMonitor health check
  • Redis health check
  • Windows Azure health check
  • Firebase health check

Redis, Windows Azure, and Firebase are configured
to be checked only on specific conditions
that depends on their configuration settings

Runtime configuration changes are considered
so if you enable a health check while the
application is running, then this is executed
otherwise, the health check is tagged as not run

Health Check endpoint /health is customized to
include specific details for each health check

The health checks are published on Application Insights.

The /health endpoint is not protected, so it is publicly accessible. This could be a potential security issue as it exposes the API dependencies.

What does it fix?

Closes #211

How has it been tested?

Enabling/disabling a health check is unit-tested

I manually tested Redis and VotingContext checks only. I also tested the /health endpoint.
I did not test Firebase and Azure Blob Storage, so suggest someone that has these dependencies to test them.
I also did not test the integration with Application Insights. It should periodically push the health checks status to Application Insights

@adrianiftode
Copy link
Contributor Author

@aniri let me know if I should rebase, thanks

@aniri
Copy link
Member

aniri commented Apr 28, 2021

@aniri let me know if I should rebase, thanks

@adrianiftode yes, it would be great if you could! thanks

@idormenco could you please review this when you get some time? 🙏

- VotingMonitor health check
- Redis health check
- Windows Azure health check
- Firebase health check

Redis, Windows Azure and Firebase are configured
to be checked only on specific conditions
that depend on their configuration settings

Runtime configuration changes are considered
so if you enable a health check while the
application is running, then this is executed
otherwise the health check is tagged as not run

Health Check endpoint /health is customized to
include specific details for each health check

The health checks are published on Application Insights
@aniri aniri merged commit b0cb902 into code4romania:develop May 10, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Implement /health endpoint
3 participants