Skip to main content

Manage cube assets

You can represent most multidimensional cube objects through a common set of multidimensional dataset assets. You can use this structure to create assets for any cube-oriented system you like:

In general, these should be:

  • Created in top-down order (connection, then cube, then dimension, and so on)
  • Deleted in bottom-up order (fields, then hierarchies, then dimensions, then cubes, then connection)1
Where do the icons come from?

Atlan will display icons for these assets based on the type of connector you define in the Connection. You can use API-first types like essbase, for example.

However, note that in all cases the same structure (and types) as illustrated above are used—there are no differences in types between these multidimensional dataset assets across different systems.

Asset structure

Connection

A connection requires a name and qualifiedName. As noted above, a specific setting is also required to determine the icons to use for assets in the connection. In addition, at least one of adminRoles, adminGroups, or adminUsers must be provided.

Create a cube connection
String adminRoleGuid = client.getRoleCache().getIdForName("$admin"); // (1)
Connection connection = Connection.creator( // (2)
"cube-connection", // (3)
AtlanConnectorType.ESSBASE, // (4)
List.of(adminRoleGuid), // (5)
List.of("group2"), // (6)
List.of("jsmith")) // (7)
.build();
AssetMutationResponse response = connection.save(client); // (8)
String connectionQualifiedName = response.getCreatedAssets().get(0).getQualifiedName(); // (9)
  1. Retrieve the GUID for the admin role, to use later for defining the roles that can administer the connection.

  2. Build up the minimum request to create a connection.

  3. Provide a human-readable name for your connection, such as production or development.

  4. Set the type of connection.

    Determines the icon

This determines the icon that Atlan will use for all the assets in the connection. ::: 5. List the workspace roles that should be able to administer the connection (or null if none). All users with that workspace role (current and future) will be administrators of the connection. Note that the values here need to be the GUIDs of the workspace roles. At least one of adminRoles, adminGroups, or adminUsers must be provided. 6. List the group names that can administer this connection (or null if none). All users within that group (current and future) will be administrators of the connection. Note that the values here are the names of the groups. At least one of adminRoles, adminGroups, or adminUsers must be provided. 7. List the user names that can administer this connection (or null if none). Note that the values here are the usernames of the users. At least one of adminRoles, adminGroups, or adminUsers must be provided. 8. Actually call Atlan to create the connection. Because this operation will persist the asset in Atlan, you must provide it an AtlanClient through which to connect to the tenant. 9. Retrieve the qualifiedName for use in subsequent creation calls. (You'd probably want to do some null checking first.)

Cube

A cube requires a name and a qualifiedName. For creation, you also need to specify the connectionQualifiedName of the connection for the cube.

Create a cube
Cube cube = Cube.creator( // (1)
"cube_name", // (2)
connectionQualifiedName) // (3)
.cubeDimensionCount(10) // (4)
.build();
AssetMutationResponse response = cube.save(client); // (5)
cube = response.getResult(cube); // (6)
  1. Build up the minimum request to create a cube.
  2. Provide a human-readable name for your cube.
  3. Provide the qualifiedName of the connection for this cube.
  4. (Optional) To make sure the UI displays the correct count of CubeDimensions's, set the cubeDimensionCount directly on the cube instance.
  5. Actually call Atlan to create the cube. Because this operation will persist the asset in Atlan, you must provide it an AtlanClient through which to connect to the tenant.
  6. Retrieve the created cube for use in subsequent creation calls.

CubeDimension

A dimension requires a name and a qualifiedName. For creation, you also need to specify the connectionQualifiedName of the connection for the dimension, and the names and qualifiedNames of the dimension's ancestors.

Create a cube dimension
CubeDimension dimension = CubeDimension.creator( // (1)
"dimension_name", // (2)
cube) // (3)
.cubeHierarchyCount(10) // (4)
.build();
AssetMutationResponse response = dimension.save(client); // (5)
dimension = response.getResult(dimension); // (6)
  1. Build up the minimum request to create a dimension.
  2. Provide a human-readable name for your dimension.
  3. Provide the cube for this dimension. If you didn't already have the object, you could also use Cube.refByGuid() with the GUID of the cube, or Cube.refByQualifiedName() with the qualifiedName of the cube.
  4. (Optional) To make sure the UI displays the correct count of CubeHierarchy's, set the cubeHierarchyCount directly on the CubeHierarchy instance.
  5. Actually call Atlan to create the dimension. Because this operation will persist the asset in Atlan, you must provide it an AtlanClient through which to connect to the tenant.
  6. Retrieve the created dimension for use in subsequent creation calls.

CubeHierarchy

A hierarchy requires a name and a qualifiedName. For creation, you also need to specify the connectionQualifiedName of the connection for the hierarchy, and the names and qualifiedNames of the hierarchy's ancestors.

Create a cube hierarchy
CubeHierarchy hierarchy = CubeHierarchy.creator( // (1)
"hierarchy_name", // (2)
dimension) // (3)
.cubeFieldCount(10) // (4)
.build();
AssetMutationResponse response = hierarchy.save(client); // (5)
hierarchy = response.getResult(hierarchy); // (6)
  1. Build up the minimum request to create a hierarchy.
  2. Provide a human-readable name for your hierarchy.
  3. Provide the dimension for this hierarchy. If you didn't already have the object, you could also use CubeDimension.refByGuid() with the GUID of the dimension, or CubeDimension.refByQualifiedName() with the qualifiedName of the dimension.
  4. (Optional) To make sure the UI displays the correct count of CubeField's, set the cubeFieldCount directly on the CubeHierarchy instance.
  5. Actually call Atlan to create the hierarchy. Because this operation will persist the asset in Atlan, you must provide it an AtlanClient through which to connect to the tenant.
  6. Retrieve the created hierarchy for use in subsequent creation calls.

CubeField

A field requires a name and a qualifiedName. For creation, you also need to specify the connectionQualifiedName of the connection for the field, and the names and qualifiedNames of the fields's ancestors.

Create a cube field
CubeField field = CubeField.creator( // (1)
"field1", // (2)
hierarchy) // (3)
.build();
AssetMutationResponse response = field.save(client); // (4)
  1. Build up the minimum request to create a field.
  2. Provide a human-readable name for your field.
  3. Provide the parent for this field. If you didn't already have the object, you could also use CubeHierarchy.refByGuid() with the GUID of a hierarchy (or CubeField.refByGuid() if this is a nested field), or CubeHierarchy.refByQualifiedName() with the qualifiedName of a hierarchy (or CubeField.refByQualifiedName() if this is a nested field).
  4. Actually call Atlan to create the field. Because this operation will persist the asset in Atlan, you must provide it an AtlanClient through which to connect to the tenant.

Available relationships

Every level of the cube structure is an Asset, and can therefore be related to the following other assets.

Footnotes

  1. Although if you want to delete everything in a connection, your better avenue is the packaged connection delete utility in the UI.

Was this page helpful?