-
Notifications
You must be signed in to change notification settings - Fork 263
feat(connector): add ClientId #6973
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
base: develop
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR adds ClientID support to the connector system, enabling isolated state management per DApp client (Dapp browser, Chrome extension, wallet-connect).
Key changes include:
- Database migration to add
client_idcolumn with composite PRIMARY KEY (url, client_id) - API updates to include
ClientIDfield in relevant structs and function signatures - Backward compatibility support for existing clients using empty string as default client ID
Reviewed Changes
Copilot reviewed 18 out of 18 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| walletdatabase/migrations/sql/1759312232_add_client_id_to_connector_dapps.up.sql | Migration script to add client_id column and composite primary key |
| signal/events_connector.go | Added ClientID field to ConnectorDApp struct |
| services/connector/database/persistence.go | Updated database operations to use URL+ClientID composite key |
| services/connector/database/persistence_test.go | Added comprehensive tests for multi-client scenarios |
| services/connector/commands/*.go | Updated all command handlers to use ClientID in database operations |
| services/connector/api.go | Modified API methods to accept and use ClientID parameter |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
Jenkins BuildsClick to see older builds (34)
|
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## develop #6973 +/- ##
============================================
+ Coverage 35.52% 59.48% +23.95%
============================================
Files 782 805 +23
Lines 112278 114767 +2489
============================================
+ Hits 39888 68268 +28380
+ Misses 67311 39489 -27822
- Partials 5079 7010 +1931
Flags with carried forward coverage won't be shown. Click here to find out more.
|
afae65c to
4b0b6d6
Compare
4b0b6d6 to
5aae232
Compare
5aae232 to
171db7e
Compare
171db7e to
07e9e68
Compare
fixes #6972
Allow isolated state management per dapp (Dapp browser, chrome extension, wallet-connect)
Database:
client_idcolumn with composite PRIMARY KEY (url, client_id). Existing records migrated with client_id = '' for backward compatibility.API:
ClientIDfield toRPCRequest,ConnectorDApp,DAppDefaultClientIDconstant for backward compatibility. Old clients(browser extension) automatically use empty string "".