Conversation
feat: improve client error reporting from server
feat: improve client error reporting from server
feat: improve client error reporting from server
feat: improve client error reporting from server
feat: send wsID and clientVersion with client requests
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.
This pull request introduces workspace/client identification and improved error handling across the sync and subscription flows. The main changes are the addition of a persistent workspace ID (
wsID) and client version tracking, which are now sent to the server for all sync and subscription operations. Additionally, error messages for WebSocket connections are now more detailed and user-friendly.Workspace/client identification and tracking:
wsIDfield to the defaults config (DefaultsConfig), generated as a combination of hostname and UUID, and ensured it is saved and loaded automatically (client/config.go,client/auth/config.go). [1] [2] [3] [4]wsIDandClientVersionin all major configuration structs (CoordinatorConfig,ManagerConfig, andConfigin sync, subscription, and remote client logic) for consistent propagation throughout the client codebase (client/sync/coordinator.go,client/subscription/manager.go,client/remote/client.go). [1] [2] [3]Propagation of identification to server:
X-ClientID(workspace ID) andX-ClientVersionheaders, both for sync and subscription operations. Connections now fail ifwsIDis missing, ensuring every client is uniquely identified (client/remote/client.go,client/subscription/manager.go). [1] [2]Improved error handling:
client/remote/client.go,client/subscription/manager.go). [1] [2]Version bump and dependency update:
0.0.5and added thegithub.com/google/uuiddependency for workspace ID generation (client/main.go,client/go.mod). [1] [2]Integration throughout sync and subscription flows:
wsIDandClientVersionare passed into all coordinator and manager constructors and used in all sync/pull/push/subscribe operations (client/main.go,client/sync/coordinator.go). [1] [2] [3] [4] [5]These changes ensure every client instance is uniquely tracked and identified by the server, and users receive clearer feedback when connection issues occur.