feat: Add support for websocket cluster connection
Description
Adds support for WebSocket cluster connections, following a similar approach to what was attempted in Draft: Add support for websocket cluster connec... (gitlab-org/gitlab!168399 - closed). This implementation removes the need for a cache wrapper by directly returning the data object. It also allows for easy throttling of data updates, reducing unnecessary operations.
GitLab DUO description:
The main change introduced in this merge request is the addition of a WebSocket-based watch manager, which enables real-time updates and event handling for specific resources. This enhancement improves the responsiveness and efficiency of the application by allowing it to receive and process data changes as they occur, without the need for constant polling or manual refresh.
Additionally, the codebase has been restructured and optimized, with the introduction of new modules and classes, such as
WebSocketWatchManager
,WatchEvent
, andEventType
. These changes enhance the modularity and maintainability of the code, making it easier to understand, extend, and modify in the future.
Closes #10 (closed)