Skip to content

Use API service health check for k8s deployments #1075

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

Merged
merged 1 commit into from
Aug 6, 2024
Merged

Use API service health check for k8s deployments #1075

merged 1 commit into from
Aug 6, 2024

Conversation

AlexeyPetroff
Copy link
Contributor

@AlexeyPetroff AlexeyPetroff commented Jul 30, 2024

Proposed changes

This pull request addresses an issue with the lowcoder deployment using the current Helm charts, where the api-service pod restarts due to the readiness probe returning a 404 NOT_FOUND error. The error occurs as follows:

2024-07-30 00:10:55.579 ERROR o.l.api.framework.exception.GlobalExceptionHandler#lambda$doLog$8:155 GET /actuator/health [parallel-1]: org.springframework.web.server.ResponseStatusException: 404 NOT_FOUND

To resolve this issue, this PR updates the readiness and liveness probes to use the health check endpoint as documented in the Lowcoder self-hosting setup guide.
This change ensures that the probes correctly check the health of the api-service and prevent unnecessary pod restarts.
Since health check endpoint was introduced in v2.4.1, previous lowcoder versions will not work.

Types of changes

What types of changes does your code introduce to Lowcoder?
Put an x in the boxes that apply.

  • Bugfix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation Update (if none of the other choices apply)

Checklist

You can also fill these out after creating the PR. If you're unsure about any of them, don't hesitate to ask. We're here to help!
This is simply a reminder of what we are going to look for before merging your code.
Put an x in the boxes that apply.

  • Lint and unit tests pass locally with my changes
  • I have added tests that prove my fix is effective or that my feature works
  • I have added necessary documentation (if appropriate)
  • Any dependent changes have been merged and published in downstream modules

Further comments

If this is a relatively large or complex change, kick off the discussion by explaining why you chose the solution you did and what alternatives you considered, etc.

Copy link

netlify bot commented Jul 30, 2024

👷 Deploy request for lowcoder-cloud pending review.

Visit the deploys page to approve it

Name Link
🔨 Latest commit 640522a

@AlexeyPetroff
Copy link
Contributor Author

#999

@AlexeyPetroff AlexeyPetroff changed the base branch from main to dev July 31, 2024 03:30
@AlexeyPetroff AlexeyPetroff changed the base branch from dev to main July 31, 2024 03:30
Copy link
Contributor

@FalkWolsky FalkWolsky left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you very much Alexey! A while ago we (FINALLY) introduced this endpoint at the API for ... pretty much exactly this reason! Now step by step we need to update the deployment files to make use of. Your contribution is much welcome!

@FalkWolsky FalkWolsky merged commit 90e4e81 into lowcoder-org:main Aug 6, 2024
2 checks passed
@AlexeyPetroff AlexeyPetroff deleted the bugfix/k8s-liveness-readiness-fix branch August 11, 2024 23:38
@adnanqaops adnanqaops mentioned this pull request Sep 9, 2024
1 task
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.

2 participants