k8s healthcheck#53
Merged
Merged
Conversation
aniket-s-kulkarni
requested changes
Aug 27, 2025
Contributor
aniket-s-kulkarni
left a comment
There was a problem hiding this comment.
@eduardo-munoz-dremio Changes look good, but can you pl add a unit test like this -
diff --git a/tests/e2e/test_mcp_e2e.py b/tests/e2e/test_mcp_e2e.py
index f3255ab..0df3a57 100644
--- a/tests/e2e/test_mcp_e2e.py
+++ b/tests/e2e/test_mcp_e2e.py
@@ -19,6 +19,8 @@ from conftest import http_streamable_client_server, http_streamable_mcp_server
from dremioai.tools.tools import get_tools
from dremioai.config import settings
+from urllib.parse import urlparse
+from httpx import AsyncClient
@pytest.mark.asyncio
@@ -30,3 +32,15 @@ async def test_basic(mock_config_dir, logging_server, logging_level):
assert tr == {
t.__name__ for t in get_tools(For=settings.instance().tools.server_mode)
}
+
+
+@pytest.mark.asyncio
+async def test_basic(mock_config_dir, logging_server, logging_level):
+ async with http_streamable_mcp_server(logging_server, logging_level) as sf:
+ async with AsyncClient() as client:
+ r = await client.get(
+ urlparse(sf.mcp_server.url)._replace(path="/healthz").geturl()
+ )
+ assert (
+ r.status_code == 200
+ ), f"/healthz failed with {r.text}, {r.status_code}"
aniket-s-kulkarni
approved these changes
Aug 28, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add a k8s like healthcheck