Class AssetCatalogRESTService


  • public class AssetCatalogRESTService
    extends Object
    The AssetCatalogService provides the server-side implementation of the Asset Catalog Open Metadata Assess Service (OMAS). This service provide the functionality to fetch asset's header, classification and properties.
    • Constructor Detail

      • AssetCatalogRESTService

        public AssetCatalogRESTService()
    • Method Detail

      • getAssetDetailsByGUID

        public AssetDescriptionResponse getAssetDetailsByGUID​(String serverName,
                                                              String userId,
                                                              String assetGUID,
                                                              String assetTypeName)
        Fetch asset's header, classification and properties
        Parameters:
        serverName - unique identifier for requested server.
        userId - the unique identifier for the user
        assetGUID - the unique identifier for the asset
        assetTypeName - the type of the asset
        Returns:
        the asset with its header and the list of associated classifications and specific properties
      • getAssetUniverseByGUID

        public AssetDescriptionResponse getAssetUniverseByGUID​(String serverName,
                                                               String userId,
                                                               String assetGUID,
                                                               String assetTypeName)
        Fetch asset's header, classification, properties and relationships
        Parameters:
        serverName - unique identifier for requested server.
        userId - the unique identifier for the user
        assetGUID - the unique identifier for the asset
        assetTypeName - the asset type
        Returns:
        the asset with its header and the list of associated classifications and relationship
      • getClassificationByAssetGUID

        public ClassificationListResponse getClassificationByAssetGUID​(String serverName,
                                                                       String userId,
                                                                       String assetGUID,
                                                                       String assetTypeName,
                                                                       String classificationName)
        Fetch the classification for a specific asset
        Parameters:
        serverName - unique identifier for requested server.
        userId - the unique identifier for the user
        assetGUID - the unique identifier for the asset
        assetTypeName - the type of the asset
        classificationName - the name of the classification
        Returns:
        ClassificationsResponse the classification for the asset
      • getLinkingRelationships

        public RelationshipListResponse getLinkingRelationships​(String serverName,
                                                                String userId,
                                                                String startAssetGUID,
                                                                String endAssetGUID)
        Return a sub-graph of relationships that connect two assets
        Parameters:
        serverName - unique identifier for requested server.
        userId - the unique identifier for the user
        startAssetGUID - the starting asset identifier of the query
        endAssetGUID - the ending asset identifier of the query
        Returns:
        a list of relationships that connects the assets
      • getAssetsFromNeighborhood

        public AssetDescriptionListResponse getAssetsFromNeighborhood​(String serverName,
                                                                      String userId,
                                                                      String assetGUID,
                                                                      SearchParameters searchParameters)
        Returns the sub-graph that represents the returned linked relationships.
        Parameters:
        serverName - unique identifier for requested server.
        userId - the unique identifier for the user
        assetGUID - the starting asset identifier of the query
        searchParameters - constrains to make the assets's search results more precise
        Returns:
        a list of assets that in neighborhood of the given asset
      • searchByType

        public AssetListResponse searchByType​(String serverName,
                                              String userId,
                                              String searchCriteria,
                                              SearchParameters searchParameters)
        Return a list of assets/glossary terms/schema elements matching the search criteria without the full context. If the searchParameters have an empty list of entity types, the response contains Glossary Terms, Schema Elements, Assets
        Parameters:
        serverName - unique identifier for requested server.
        userId - the unique identifier for the user
        searchCriteria - a string expression of the characteristics of the required assets
        searchParameters - constrains to make the assets's search results more precise
        Returns:
        list of properties used to narrow the search
      • buildContext

        public AssetResponse buildContext​(String serverName,
                                          String userId,
                                          String assetGUID,
                                          String assetType)
        Return the full context of an asset/glossary term based on its identifier. The response contains the list of the connections assigned to the asset.
        Parameters:
        serverName - unique identifier for requested server.
        userId - the unique identifier for the user
        assetGUID - the global unique identifier of the asset
        assetType - the type of the asset
        Returns:
        the context of the given asset/glossary term/schema element
      • getSupportedTypes

        public AssetCatalogSupportedTypes getSupportedTypes​(String serverName,
                                                            String userId,
                                                            String type)
        Returns supported types for search with all sub-types. If type name is provided, it returns the type itself and the list of sub-types for it
        Parameters:
        serverName - unique identifier for requested server.
        userId - user identifier that issues the call
        type - optional type name
        Returns:
        supported types