Skip to main content

Manage data products

Create new data product

To create a new data product:

Create a data product
FluentSearch assets = Table.select(client) // (1)
.where(Table.CERTIFICATE_STATUS.eq(CertificateStatus.VERIFIED))
.where(Table.ATLAN_TAGS.eq("Marketing"))
.build();
DataProduct dp = DataProduct.creator("Marketing Influence", // (2)
DataDomain.refByQualifiedName("default/domain/marketing"), // (3)
assets) // (4)
.build(); // (5)
AssetMutationResponse response = dp.save(client); // (6)
  1. When defining a data product, you must define the assets within it. These are defined through a search, so that the assets included can be automatically managed. In this example, we're selecting all verified tables that have a tag of Marketing.
  2. You must provide a human-readable name for your data product.
  3. You must also provide the domain in which the data product should exist.
  4. And finally the search that was defined earlier, to define which assets to include in the data product.
  5. You then need to build the object.
  6. And then you can save() the object you've built to create the new data product in Atlan. Because this operation will persist the asset in Atlan, you must provide it an AtlanClient through which to connect to the tenant.

Retrieve data product

To retrieve a data product by its human-readable name:

Retrieve a data product by its human-readable name
DataProduct product = DataProduct.findByName( // (1)
client, "marketingInfluence", List.of("certificateStatus")
).get(0);
  1. Use DataProduct.findByName() method to retrieve a data product by its human-readable name:

    • client through which to access a tenant.
    • name of the data product.
    • (optional) a list of attributes to retrieve for the data product, for example certificateStatus.

Retrieve all assets linked to data product

To retrieve list of all assets associated with a data product:

Retrieve list of all assets linked to a data product
DataProduct dp = DataProduct.get(client, 
"49abc625-9a03-4733-bdfb-ec0cb5315cac", true); // (1)
IndexSearchResponse response = dp.getAssets(client); // (2)
for (Asset result : response)
  1. Use DataProduct.get() method to retrieve the data product by its GUID.
  2. Use DataProduct.getAssets() method to retrieve all assets linked to the data product, providing the client used to access the tenant.

Update data product

To update a data product:

Update a data product
FluentSearch assets = Table.select(client)
.where(Table.CERTIFICATE_STATUS.eq(CertificateStatus.VERIFIED))
.where(Table.ATLAN_TAGS.eq("Digital Marketing"))
.build(); // (1)

DataProduct dp = DataProduct.updater("default/product/marketingInfluence", // (2)
"Marketing Influence")
.userDescription("Now with a description!") // (3)
.assetSelection(Atlan.getDefaultClient(), assets)
.build(); // (4)
AssetMutationResponse response = dp.save(client); // (5)
  1. (Optional) You can also update the assets within an existing product. These assets are defined through a search, allowing for automatic management. In this example, we select all verified tables that are tagged with Digital Marketing.
  2. Use the updater() method to update a data product, providing the qualifiedName and name of the data product.
  3. You can chain additional enrichments onto the updater, such as:
    • userDescription: updating the product's description.
    • assetSelection: modifying the assets within the product.
  4. You then need to build the object.
  5. You can then save() the object you've built to update the data product in Atlan. Because this operation will persist the asset in Atlan, you must provide it an AtlanClient through which to connect to the tenant.

Delete data product

Soft-delete (archive)

To soft-delete, or archive, a data product:

Delete a data product
AssetDeletionResponse response = DataProduct.delete(client, "218c8144-dc39-43a5-b0c0-9eeb4d11e74a"); // (1)
  1. To archive a data product in Atlan, call the DataProduct.delete() method with the GUID of the data product. Because this operation will archive the asset in Atlan, you must provide it an AtlanClient through which to connect to the tenant.

Hard-delete (purge)

To permanently delete (purge) a data product:

Delete a data product
AssetDeletionResponse response = DataProduct.purge(client, "218c8144-dc39-43a5-b0c0-9eeb4d11e74a"); // (1)
  1. To permanently delete a data product in Atlan, call the DataProduct.purge() method with the GUID of the data product. Because this operation will remove the asset from Atlan, you must provide it an AtlanClient through which to connect to the tenant.
Was this page helpful?