Class AssetCatalogEntityResource


  • @RestController
    @RequestMapping("/servers/{serverName}/open-metadata/access-services/asset-catalog/users/{userId}")
    public class AssetCatalogEntityResource
    extends Object
    The AssetCatalogEntityResource provides the server-side implementation of the Asset Catalog Open Metadata Assess Service (OMAS). This interface facilitates the searching for assets, provides details about specific assets.
    • Constructor Detail

      • AssetCatalogEntityResource

        public AssetCatalogEntityResource()
    • Method Detail

      • getAssetDetail

        @GetMapping(path="/asset-details/{assetGUID}",
                    produces="application/json")
        public AssetCatalogResponse getAssetDetail​(@PathVariable("serverName")
                                                   String serverName,
                                                   @PathVariable("userId")
                                                   String userId,
                                                   @PathVariable("assetGUID") @NotBlank
                                                   @NotBlank String assetGUID,
                                                   @RequestParam(name="assetType",required=false) @NotNull
                                                   @NotNull String assetType)
        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
        assetType - the type of the asset
        Returns:
        the asset with its header and the list of associated classifications and specific properties
      • getAssetUniverse

        @GetMapping(path="/asset-universe/{assetGUID}",
                    produces="application/json")
        public AssetCatalogResponse getAssetUniverse​(@PathVariable("serverName")
                                                     String serverName,
                                                     @PathVariable("userId")
                                                     String userId,
                                                     @PathVariable("assetGUID") @NotBlank
                                                     @NotBlank String assetGUID,
                                                     @RequestParam(name="assetType",required=false) @NotNull
                                                     @NotNull String assetType)
        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
        assetType - the asset type
        Returns:
        the asset with its header and the list of associated classifications and relationship
      • getAssetRelationships

        @GetMapping(path="/asset-relationships/{assetGUID}",
                    produces="application/json")
        public RelationshipListResponse getAssetRelationships​(@PathVariable("serverName")
                                                              String serverName,
                                                              @PathVariable("userId")
                                                              String userId,
                                                              @PathVariable("assetGUID") @NotBlank
                                                              @NotBlank String assetGUID,
                                                              @RequestParam(name="assetType",required=false)
                                                              String assetType,
                                                              @RequestParam(name="relationshipType",required=false)
                                                              String relationshipType,
                                                              @RequestParam(name="from",required=false,defaultValue="0") @PositiveOrZero
                                                              @PositiveOrZero Integer from,
                                                              @RequestParam(name="pageSize",required=false,defaultValue="100") @PositiveOrZero
                                                              @PositiveOrZero Integer pageSize)
        Fetch the relationships 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
        assetType - the type of the asset
        relationshipType - the type of the relationship
        from - offset
        pageSize - limit the number of the assets returned
        Returns:
        list of relationships for the given asset
      • getClassificationsForAsset

        @GetMapping(path="/asset-classifications/{assetGUID}",
                    produces="application/json")
        public ClassificationListResponse getClassificationsForAsset​(@PathVariable("serverName")
                                                                     String serverName,
                                                                     @PathVariable("userId")
                                                                     String userId,
                                                                     @PathVariable("assetGUID") @NotBlank
                                                                     @NotBlank String assetGUID,
                                                                     @RequestParam(name="assetType",required=false)
                                                                     String assetType,
                                                                     @RequestParam(name="classificationName",required=false)
                                                                     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
        assetType - the type of the asset
        classificationName - the name of the classification
        Returns:
        ClassificationsResponse the classification for the asset
      • getLinkingAssets

        @GetMapping(path="/linking-assets/from/{assetGUID}/to/{endAssetGUID}",
                    produces="application/json")
        public AssetCatalogListResponse getLinkingAssets​(@PathVariable("serverName")
                                                         String serverName,
                                                         @PathVariable("userId")
                                                         String userId,
                                                         @PathVariable("assetGUID") @NotBlank
                                                         @NotBlank String startAssetGUID,
                                                         @PathVariable("endAssetGUID") @NotBlank
                                                         @NotBlank String endAssetGUID)
        Returns a sub-graph of intermediate assets that connected 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 assets between the given assets
      • getLinkingRelationships

        @GetMapping(path="/linking-assets-relationships/from/{assetGUID}/to/{endAssetGUID}",
                    produces="application/json")
        public RelationshipListResponse getLinkingRelationships​(@PathVariable("serverName")
                                                                String serverName,
                                                                @PathVariable("userId")
                                                                String userId,
                                                                @PathVariable("assetGUID")
                                                                String startAssetGUID,
                                                                @PathVariable("endAssetGUID")
                                                                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

        @PostMapping(path="/assets-from-neighborhood/{assetGUID}",
                     produces="application/json")
        public AssetCatalogListResponse getAssetsFromNeighborhood​(@PathVariable("serverName")
                                                                  String serverName,
                                                                  @PathVariable("userId")
                                                                  String userId,
                                                                  @PathVariable("assetGUID") @NotBlank
                                                                  @NotBlank String assetGUID,
                                                                  @RequestBody
                                                                  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

        @PostMapping(path="/search",
                     produces="application/json")
        public AssetListResponse searchByType​(@PathVariable("serverName")
                                              String serverName,
                                              @PathVariable("userId")
                                              String userId,
                                              @RequestParam("searchCriteria") @NotBlank
                                              @NotBlank String searchCriteria,
                                              @RequestBody
                                              SearchParameters searchParameters)
        Return a list of assets matching the search criteria without the full context
        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
      • getAssetContext

        @GetMapping(path="/asset-context/{assetGUID}",
                    produces="application/json")
        public AssetResponse getAssetContext​(@PathVariable("serverName")
                                             String serverName,
                                             @PathVariable("userId")
                                             String userId,
                                             @PathVariable("assetGUID") @NotBlank
                                             @NotBlank String assetGUID,
                                             @RequestParam(name="assetType",required=false)
                                             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:
        list of properties used to narrow the search
      • getSupportedTypes

        @GetMapping(path="/supportedTypes",
                    produces="application/json")
        public AssetCatalogSupportedTypes getSupportedTypes​(@PathVariable("serverName")
                                                            String serverName,
                                                            @PathVariable("userId")
                                                            String userId,
                                                            @RequestParam(name="type",required=false) @Nullable
                                                            String type)
        Returns the list with supported types for search, including the sub-types supported
        Parameters:
        serverName - unique identifier for requested server
        userId - the unique identifier for the user
        type - the type
        Returns:
        list of types and sub-types supported for search
      • getOutTopicConnection

        @GetMapping(path="/topics/out-topic-connection/{callerId}",
                    produces="application/json")
        public ConnectionResponse getOutTopicConnection​(@PathVariable("serverName")
                                                        String serverName,
                                                        @PathVariable("userId")
                                                        String userId,
                                                        @PathVariable("callerId")
                                                        String callerId)