[FEATURE] Add plugin versioning support + dashboard lock mode - #243
[FEATURE] Add plugin versioning support + dashboard lock mode#243Gladorme wants to merge 11 commits into
Conversation
|
I see this PR is still in draft mode. Are you still working on this? |
No, the PR is ready, but it's depending on other PRs, so can't be merged |
d101a63 to
7802d79
Compare
Signed-off-by: Guillaume LADORME <Gladorme@users.noreply.github.com>
Signed-off-by: Guillaume LADORME <Gladorme@users.noreply.github.com>
Signed-off-by: Guillaume LADORME <Gladorme@users.noreply.github.com>
Signed-off-by: Guillaume LADORME <Gladorme@users.noreply.github.com>
Signed-off-by: Guillaume LADORME <Gladorme@users.noreply.github.com>
Signed-off-by: Guillaume LADORME <Gladorme@users.noreply.github.com>
Signed-off-by: Guillaume LADORME <Gladorme@users.noreply.github.com>
Signed-off-by: Guillaume LADORME <gladorme@gmail.com>
de61b8c to
d7496e4
Compare
| {isLinksEnabled && <EditDashboardLinksButton />} | ||
| <AddPanelButton /> | ||
| <AddGroupButton /> | ||
| <UpdatePluginsButton /> |
There was a problem hiding this comment.
It seems this button also locks the version to the latest one. Should the update options allow to "unset" the version so always the latest is used?
There was a problem hiding this comment.
Well to set "unset", the best would be to use "Unlock" button. But it make me think it's better to enable this button/feature only if lock mode is available.
| {isLinksEnabled && <EditDashboardLinksButton />} | ||
| <AddPanelButton /> | ||
| <AddGroupButton /> | ||
| <UpdatePluginsButton /> |
There was a problem hiding this comment.
Admins might want to prevent unintended updates, I think we should add configuration so this can be disabled/hidden
There was a problem hiding this comment.
Like in previous comment, I will make this feature only available if lock mode is available. If admin don't want to allow user to upgrade version, it will need a change in back, because user can easily change version json directly
There was a problem hiding this comment.
In embedded usage, people can enable or disable the button separately (I added a new condition)
Signed-off-by: Guillaume LADORME <Gladorme@users.noreply.github.com>
Signed-off-by: Guillaume LADORME <Gladorme@users.noreply.github.com>
| return optionValue; | ||
| } | ||
| // The definition is not pinned (or is pinned to something we don't list): fall back to the first entry of that | ||
| // plugin kind, which is the one that will actually be used, so the Select has a matching value. |
There was a problem hiding this comment.
The first option in the dropdown might not be the latest version installed, which is the one it should fallback if there is no version installed. I wonder if we should flag the current latest inside the dropdown, I see a problem when you want to create a dashboard that uses the latest plugin version. If we just allow pinned versions from the dropdown this wont be possible.
There was a problem hiding this comment.
My main concern is that you pin a plugin version in your dashboard, then update perses and then the dropdown will select that version, but your dashboard still continues to be pinned to the older version.
| /** | ||
| * When true, offers the button that locks/unlocks the dashboard, i.e. pins every plugin it uses to an exact version. | ||
| * It only makes the action available: whether the dashboard is actually locked is derived from its plugin | ||
| * definitions. Not available by default. Plugin versioning itself is always on: the button that updates | ||
| * already-pinned plugins is shown regardless of this flag. | ||
| */ |
There was a problem hiding this comment.
I got lost on this comment, it says a lot of things but it seems contradictory in the button that updates already-pinned plugins is shown regardless of this flag. as the button is gated behind the isUpdateButtonAvailable.
Description
The goal of this PR is to improve the handling of plugin versioning in dashboard:
What is doing the lock mode?
Lock will enforce versioning on all plugins. It will use latest version installed. When a new version is available, it will show a button to update, with a nice diff based on the first panel using the plugin (only for panel plugin). If the plugin version pinned is no longer available, it will show a error.
Blocked, need
specrelease v0.3.0-beta.4 fixed (token expired, need @Nexucis back :p) and need perses/plugins#773 tooScreenshots
Checklist
[<catalog_entry>] <commit message>naming convention using one of thefollowing
catalog_entryvalues:FEATURE,ENHANCEMENT,BUGFIX,BREAKINGCHANGE,DOC,IGNORE.UI Changes
See e2e docs for more details. Common issues include: