LearnNewsExamplesServices
Frontmatter
id7636
titleRefactor: Implement Robust Startup Sequence and Health Checks in Memory Core
stateClosed
labels
enhancementairefactoring
assigneestobiu
createdAtOct 24, 2025, 2:23 PM
updatedAtOct 24, 2025, 2:26 PM
githubUrlhttps://github.com/neomjs/neo/issues/7636
authortobiu
commentsCount0
parentIssuenull
subIssues[]
subIssuesCompleted0
subIssuesTotal0
blockedBy[]
blocking[]
closedAtOct 24, 2025, 2:26 PM

Refactor: Implement Robust Startup Sequence and Health Checks in Memory Core

Closed v11.0.0 enhancementairefactoring
tobiu
tobiu commented on Oct 24, 2025, 2:23 PM

The Memory Core MCP server entry point (mcp-stdio.mjs) has been refactored to implement a more robust and informative startup sequence, leveraging the recent enhancements to the HealthService.

Key Changes:

  1. Proactive Startup Health Check: The server now performs a comprehensive health check immediately upon starting.
  2. Detailed Status Logging: Based on the health status (healthy, degraded, unhealthy), the server logs detailed, user-friendly messages, including actionable tips for resolving issues (e.g., how to start the ChromaDB if it's not running).
  3. Automatic Session Summarization: If the health check passes and the GEMINI_API_KEY is configured, the server automatically triggers a background task to summarize any previously unsummarized sessions.
  4. Tool Execution Gatekeeper: The main tool handler now calls HealthService.ensureHealthy() before executing most tools. This prevents operations from failing with cryptic errors if a dependency is down.
  5. Precise Health Check Exemptions: The logic for skipping the health check has been refined from a broad string match (.includes('database')) to a specific allow-list (['healthcheck', 'start_database', 'stop_database']), making it safer and more explicit.

These changes improve the server's resilience, provide better feedback to the user, and automate routine maintenance tasks.

tobiu added the enhancement label on Oct 24, 2025, 2:23 PM
tobiu added the ai label on Oct 24, 2025, 2:23 PM
tobiu added the refactoring label on Oct 24, 2025, 2:23 PM
tobiu assigned to @tobiu on Oct 24, 2025, 2:25 PM
tobiu referenced in commit a0d5bbc - "Refactor: Implement Robust Startup Sequence and Health Checks in Memory Core #7636" on Oct 24, 2025, 2:25 PM
tobiu closed this issue on Oct 24, 2025, 2:26 PM