-
Notifications
You must be signed in to change notification settings - Fork 6
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
[breaking] Prepare version 2.0 stable #232
Merged
Merged
Conversation
This file contains 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
Shiranuit
suggested changes
Oct 26, 2022
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.
I still have about 50% to review
@@ -37,6 +33,7 @@ export class DummyTempDecoder extends Decoder { | |||
const decodedPayload = new DecodedPayload<DummyTempDecoder>(this); | |||
|
|||
if (payload?.metadata?.color) { | |||
console.log(payload); |
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.
Debug leftover
…and Measure (#231) This PR add a `Model` module to manage - Asset: declare models and register metadata for them - Device: register metadata for device models - Measure: declare new measure types Models can be registered on the framework with one of the `plugin.models.registerXXXX` method or at runtime with the `ModelController`: - writeAsset|Device|Measure: upsert a model - deleteAsset|Device|Measure: delete a model - listAsset|Device|Measure: list models Decoder are now registered alongside with a Device model ``` deviceManager.models.registerDevice("DummyTemp", new DummyTempDecoder(), { color: { type: "keyword" }, }); ``` ---- Add default roles to manage plugin ressources. Admins roles can do everything and reader can only read. - `assets.admin` - `assets.reader` - `device.admin`: this role cannot attach and detach devices from engines - `device.reader` - `decoders.admin` - `measures.reader` - `measures.admin` - device and asset models now have `defaultValues` for their metadata. Those values will be copied into assets and devices upon creation - fix bug that prevented metadata to be propagated and saved in measures collection --- Changes: measures document remove measure unit embedded measures measure names measures definition in digital twin models Co-authored-by: Aschen <amaret@kuzzle.io>
Merged
Aschen
pushed a commit
that referenced
this pull request
Nov 16, 2022
## What does this PR do ? This release is a **major** rewrite of the plugin architecture, API and data model. The version is supposed to be very close of the final 2.0.0 stable version of the plugin. Very few breaking changes are expected until final release. Migration scripts may be provided as we are going forward this huge step. The documentation will be entirely rewritten when the 2.0.0 is release. More informations about the changes in this PR: #232
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.
What does this PR do ?
Asset metadata will now be stored simply as objects.
Assets only have a
model
and areference
as identifiers, like Devices.A lot of API action has been removed to keep the plugin as simple as possible.
From #231 (BREAKING)
This PR add a
Model
module to manageModels can be registered on the framework with one of the
plugin.models.registerXXXX
method or at runtime with theModelController
:Decoder are now registered alongside with a Device model
From #234
Add default roles to manage plugin ressources. Admins roles can do everything and reader can only read.
assets.admin
assets.reader
device.admin
: this role cannot attach and detach devices from enginesdevice.reader
decoders.admin
measures.reader
measures.admin
device and asset models now have
defaultValues
for their metadata. Those values will be copied into assets and devices upon creationfix bug that prevented metadata to be propagated and saved in measures collection
From #235 (BREAKING)