-
Notifications
You must be signed in to change notification settings - Fork 6
feat: Implement WebSocket-based real-time communication for orchestrator hosts with intelligent fallback #330
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
Conversation
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
cjlapao
reviewed
Nov 25, 2025
…tor hosts This commit introduces a comprehensive WebSocket infrastructure for orchestrator hosts, enabling real-time event streaming and health monitoring with intelligent fallback to polling for hosts that don't support WebSockets.
f2bd2a7 to
80aa9a9
Compare
Collaborator
Author
|
These requirements are still pending from #330 . I will implement them in next PR
|
…tHost - Added periodic ping routine (every 30s) to keep WebSocket connections alive - Fixed race condition in persistHost() where ping/pong updates would prevent HTTP health check data from being saved - Now uses newer UpdatedAt timestamp while still persisting all health check data
…onnection for disconnected hosts.
cjlapao
reviewed
Nov 28, 2025
…dd unit tests - Added read and write locks using dataMutex in orchestrator.go to ensure thread safety for database operations. - Introduced helper methods for unsafe operations to separate concerns and maintain clean code. - Created a comprehensive test suite in orchestrator_test.go to validate the functionality of orchestrator host management, including creation, retrieval, updating, and deletion. - Implemented tests for error scenarios, including duplicate hosts and not found cases. - Verified resource management functions to ensure accurate calculations of available, total, in-use, and reserved resources.
f44b9ab to
0108352
Compare
cjlapao
approved these changes
Nov 28, 2025
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.
Description
Part of #321
Type of change
Checklist