-
Notifications
You must be signed in to change notification settings - Fork 78
Client node round 4 #2200
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
Client node round 4 #2200
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.
Code Review
This pull request includes several updates and refactorings, including new error classes, improvements to network simulation, and refactoring of the storage layer. The changes look good overall, but there are a few areas that could be improved, such as error handling and code comments. The style guide was followed.
packages/node/src/behavior/system/commissioning/CommissioningClient.ts
Outdated
Show resolved
Hide resolved
And please add some Changelog entries :-) |
This is a large round of changes that fleshes out the Node API for client usage. Finishes off the controller features for ServerNode and fleshes out ClientNode to the point where it is largely functional. Tests cover commissioning, syncing of attributes and endpoint structure, invoking a commands and reloading from cached attributes. Other areas of improvement include: * Upgrades to network simulation * A new equivalent to the old "IntegrationTest" that performs in-process test of a matter.js controller against a matter.js device * Refactoring of the storage layer for `@matter/node` which has always been a bit convoluted * Misc. test harness fixes and upgrades * A new protocol-level client implementation in ClientInteractable and ClientSubscriptions * Improved support for IDs or names for keys in persisted Datasource values * Datasource features to support underlying mutated externally rather than via ValueSupervisor * Adds `commands` and `commandsFor` to allow for invocation directly from `Endpoint` API without creating a behavior * Standard implementations of individual error classes for each `Status` code, and logic to automatically throw correct subclass based on a status code * Proper support for suppressed errors generated by `using` * Elimination of cyclical imports in @matter/node * Tweaks to behavior generation to reduce the number of redundant types injected into declaration files
This is a large round of changes that fleshes out the Node API for client usage.
Finishes off the controller features for ServerNode and fleshes out ClientNode to the point where it is largely functional. Tests cover commissioning, syncing of attributes and endpoint structure, invoking a commands and reloading from cached attributes.
Other areas of improvement include:
Upgrades to network simulation
A new equivalent to the old "IntegrationTest" that performs in-process test of a matter.js controller against a matter.js device
Refactoring of the storage layer for
@matter/node
which has always been a bit convolutedMisc. test harness fixes and upgrades
A new protocol-level client implementation in ClientInteractable and ClientSubscriptions
Improved support for IDs or names for keys in persisted Datasource values
Datasource features to support underlying mutated externally rather than via ValueSupervisor
Adds
commands
andcommandsFor
to allow for invocation directly fromEndpoint
API without creating a behaviorStandard implementations of individual error classes for each
Status
code, and logic to automatically throw correct subclass based on a status codeProper support for suppressed errors generated by
using
Elimination of cyclical imports in @matter/node
Tweaks to behavior generation to reduce the number of redundant types injected into declaration files