Safe mode

About

New in Dashboard 5.3 is the ability to make changes, that before instantly was stored in database and affected other users, now is written to a file on S3 and can be applied at a later time.

How can I tell if i'm in safe mode?

Dashboard will display a bar in the top of the page containing information about the user currently working in safe mode.

Where can I find already created safe modes?

​ As a admin you are able to both create and see other peoples safe modes. With one distinction, only as a creator you are able to apply a safe mode you are owner to.

Under "Admin settings" you'll find a safe mode tab. Where you'll be able to select from all safe modes that have been created but yet not applied.

The list will contain the name of the safe mode file, which is either auto generated or named by the owner. To the right of the name you'll get a hint of your relation to the safe mode. If you are a owner or you just have rights to preview the changes.

How can I apply my safe mode?

After going to admin settings and choosing one of the items in the list you will be presented with a table containing the changes that the current safe mode contains. If you choose a safe mode to preview you'll only be able to apply it locally and test it out.

First step after you found a safe mode you want to apply is to hit the "Apply changes locally" button. This will load all changes into your local dashboard state and would not affect any other user. This way you can test out the intended changes works as expected.

There's a small difference in the views you'll be presented with depending if you are the owner or not. If you are applying a safe mode as an owner you will be presented with the ability to change the name of the safe mode file, delete it or apply it to all users.

If you are previewing a safe mode you will only be able to discard the changes and go back to current active dashboard setup.

Conflicts while applying local changes

Since safe mode files apply an asynchronous workflow there could be times where work is done in multiple safe mode files and if applying these above a newer state could cause a conflict. Example would be that UserA creates a profile and name it "newprofile". UserB creates a profile with the exact same name. UserA then applies its changes to all users, meanwhile UserB at a later time tries to apply its changes locally then would end up in a conflicting state.

When ending up in this case as an owner of the safe mode file you have the ability to remove the specific task that is conflicting in order to not throw away the whole changes file if it would contain other changes as well.

Apply for all users

After you done making all changes or loading an already created safe mode and applying it locally You will be presented with the button "Apply for all users" if you are eligible. By triggering this action the tasks written in the file will start executing on the server and will start applying changes to the database.

If everything goes according to plan, everything will be written to database and the safe mode file itself will get removed from S3.

Conflict while applying to all users

In some cases you might try to process a safe mode file that would not comply with the current database state. For example, UserA creates a safe mode where a profile is getting removed, meanwhile UserB also removes the same profile and applies it to all users. Since there is no live update of the state, UserA now thinks that it needs to apply the removal of the profile and tries to "Apply for all users". The server will then return back a conflicting state that he can't remove something that doesn't exist.

Preview limitations

While previewing a safe mode file you have some certain limitations.

  • Can't create/update/delete workspaces

  • Can't install/update/remove plugins

  • Can't update plugin configuration

  • Can't add/update/remove config key

  • Can't add/update/remove profiles

Safe mode prompt

If you ever leave or reload your dashboard while having an active safe mode, You will get prompted next time you visit again.

If you decide to not load the changes you will run dashboard with current active state and can always load your changes manually from Admin settings.

If you decided to load changes, all tasks from the file will get applied locally.

Last updated