Asset Translation and Management
This section covers:
- Conversion Strategy
- Managing Assigned Assets
- Deleting Assets
- Ownership Checks
- Non-tracked Entities
- Browsing the Assets List
Conversion Strategy
To improve performance and enhance the visibility of changes being made, Sisense assets (such as Data Models and Dashboards) are converted, or translated, into decomposed sets of child files in the JSON format.
The conversion process is performed automatically in both directions. This means that when the asset is changed in the Sisense application - the project JSON files are updated, and when there are changes in the project JSON files (changes pulled from a remote repository) the Sisense assets are updated in the application.
On a high level this can be described as follows:
- When changes are made in the application data model/dashboard (Sisense application):
- Changes are saved in the Sisense application database
- The state of the asset in the application database is compared with the state in the Git project (file system project folder). If differences are found they are reflected in the uncommitted changes section. Changes in the corresponding converted JSON file can be discarded or committed and saved in the Git project (on the file system).
- When changes are made in the Git project (file system):
- Changes in the JSON files are saved in the FS
- Set of decomposed JSON files in the checked-out state are converted into Sisense assets and saved in the Sisense application database. Checkout to commit, branch, revert, discard, etc., will automatically trigger overriding the state in the Sisense application database so that they are available for the end analytical consumers in the Sisense application.
Each of the supported Sisense assets has its own translation strategy.
Naming Convention
Since release L2023.11, JSON files that represent decomposed assets, (such as data models and dashboards) now include the actual name of the asset - concatenated with the unique OID, which is essential for Git tracking.
This naming convention enables out-of-the-box understanding of what asset in the application was changed, as well as making it easy to navigate on the remote repository when conducting code reviews, etc.
Renaming an asset in the application will lead to the renaming of the actual file folder, and recursively, all of its child folders. This operation is done with the use of the git mv
command, (see Git - git-mv Documentation).
In the file system, the file OID and its name are connected using
(the non-breaking space character). This character also serves as the separator for the UI representation in Sisense Git projects.
The same approach should be used when specifying files in the API calls, for example:
dashboards/65363add391852002a17a203 Sample Healthcare/widgets/65363add391852002a17a204 TOTAL PATIENTS ADMITTED/widget.json
Data Models
Here is the schema and files hierarchy that is used for translating data models from the Sisense application (DB) to the project (FS):
An example of how a data model is added to a project is reflected in the following set of files:
Dashboards
Here is the schema and files hierarchy that is used for translating dashboards from the Sisense application (DB) to the project (FS):
An example of a dashboard added to the project is reflected in the following set of files:
Managing Assigned Assets
In order to maintain consistency in the changes history, we always add and use the owner's copy of the asset. As result, different users can select different files to be added to the project:
- Admins (Super Admin, Admin) can see and select all of the owner's copies of the available assets on the system level
- Non-admins (Data Admin, Data Designer, Dashboard Designer) can only see and select copies of the assets owned by them
- Data Admin can see and select all of the data models on the instance, as this is consistent with its permissions when working with regular data models
Shared copies of assets are not available for selection.
Assets can only be assigned to one project
One of the core concepts in Git Integration is that an asset can only be included in a single project. Therefore, once an asset has been added to a project, it will no longer be displayed in the list of available assets for other projects. This rule is not dependent on the user's role.
Assets can be added to a project in two ways:
- On the third step (Assign Assets) of the New Project wizard:
- Via the Manage Assets section of a project. This is accessible directly from the project view or in the project settings menu of the project in the list.
Deleting Assets
Deleting a tracked asset from the Sisense application (for example, deleting a dashboard) will be reflected in the corresponding uncommitted changes in the Git project that includes that asset.
Deleting assets from the list of tracked assets in a project:
- Will untrack it and further changes of this asset in the application will not be reflected in the uncommitted changes for the project.
- The deleted assets will be available for selection in another project.
- The latest version of the asset in the Sisense application will remain in its current state and will not be affected in any way.
It is possible to delete assets from a project:
- On the third step (Assign Assets) of the New Project wizard.
- Via the Manage Assets section of the project. This is accessible directly from the project view or in the project settings menu of the project in the list.
Ownership Checks
Giving asset owners access to a project when adding their assets to the project
Because we always use the owner's copy of an asset, the asset owner must have access to any project that is using their assets.
If the admin adds an asset owned by a designer to a project, but the designer does not already have access to the project, then the corresponding ownership modal dialog will be displayed to the admin:
- [ Add assets & Contributors ] - Select to share the project with the new user(s) and add the assets to the project.
- [ Cancel ] - Discards the operation. The asset will not be added to the project.
Revoking access to a project for users that own assets in the project
A similar validation happens when the admin tries to revoke access to a project from a user who owns assets included in the project. The asset ownership must be changed first in such cases.
Deleting all assets owned by a user in a project
At the same time, deleting all of the assets in a project owned by a user does not require the removal of the user's access to the project. They will continue to have the same rights as the rest of the project contributors, but they simply no longer own any of the assets in the project.
When assets are added to a project by pulling a commit
Pulling a commit which includes additional assets that already exist on the Sisense server will automatically add them to the project:
- If the owner of this asset has access to the project then nothing changes
- If the owner does not have access to the project, then the project is automatically shared with them. Such automatically shared requests will be pending and admins will have to approve/decline them in the project shares. See Working with Git Integration Projects for more information.
Non-tracked Entities
Git Integration is focused on tracking the changes in the actual assets and those parts of them which do not depend on the environment. As a result, some asset properties and entities are excluded when they are added to a project, (so they are not tracked).
Data Models
Data model properties and entities that are not included in projects:
- Shares
- Data security - Groups and users are dependent on the environment
- Build schedule - Dependent on the environment
- Protected parameters of the managed connection (see Data Source Connection Management > Git Integration Promotion):
Different environments might require explicit database connections to different Sisense deployments (dev, stage, prod, etc.)
To prevent sensitive information from being placed on third-party services, like GitLab, GitHub, Azure, etc.
Dashboards
Dashboard properties and entities that are not included in projects:
- Shares
- Email reporting settings
- Pulse notifications - Groups and users are dependent on the environment
- Parent folder:
- Dependent on the environment
- Parent folder can be added later on to the target Sisense deployment if needed
- Plugin configuration - Dependent on the environment
Browsing the Assets List
The assets list provides the ability to sort and filter assets according to your needs. It can be used to browse for assets to add to a project or to see the assets already assigned to it.
The search field enables finding all of the assets available for the currently logged-in user that match the query in any position of the asset name. Search uses the same logic as the LIKE%% operator in SQL statements and is not case-sensitive.