Class AssetLineageRestServices


public class AssetLineageRestServices extends Object
The AssetLineageRESTServices provides the server-side implementation of the Asset Lineage Open Metadata Assess Service (OMAS). This interface provides connections to assets and APIs for adding feedback on the asset.
  • Constructor Details

    • AssetLineageRestServices

      public AssetLineageRestServices()
      Default constructor
  • Method Details

    • publishEntities

      public GUIDListResponse publishEntities(String serverName, String userId, String entityType, FindEntitiesParameters findEntitiesParameters)
      //TODO: To be renamed to publishLineage() publishLineage interface is used to request lineage related metadata to be sent out on-demand for scenarios such as initial load of metadata or pull based changes. The method provides non-blocking like, async interface for executing time/resource intensive tasks in background thread (i.e. building lineage context for collection of entities). It is implemented using concurrent processing APIs based on CompletableFuture How it works: Based on the findEntitiesParameters provided, scans the cohort for the given type and finds list of matching entities. Providing updatedAfter filed in findEntitiesParameters will retrieve only the entities that were changed from that point in time. Once entities are found, it spins up *asynchronous* background task that will build the lineage context and publish respective output as events on the asset-lineage output topic. Note that only single background task can be active at given time (per server instance controlled by `publishLineageTaskActive`). All subsequent requests will result in empty response until the task if finished. At the end lineage sync event is published to notify the external systems sending summary of the work completed.
      serverName - name of server instance to call
      userId - the name of the calling user
      entityType - the type of the entity to search for
      findEntitiesParameters - filtering used to reduce the scope of the search
      a collection of unique identifiers (guids) of the available entities that will produce lineage events. OR empty collection in case there is noting to be processed or the background task is already busy (active).
    • publishEntity

      public GUIDListResponse publishEntity(String serverName, String userId, String entityType, String guid)
      Find the entity the element with the provided guid and the given type Publish the context for the entity on the AL OMAS out Topic
      serverName - name of server instance to call
      userId - the name of the calling user
      entityType - the type of the entity to search for
      guid - the guid of the searched entity
      the unique identifier (guid) of the entity that was processed
    • publishAssetContext

      public GUIDListResponse publishAssetContext(String serverName, String userId, String entityType, String guid)
      Publish asset context on the Out Topic. Provides a list with asset context entities' GUIDs.
      serverName - the server name
      userId - the user id
      entityType - the entity type
      guid - the GUID of the entity for which the context is published
      a list with asset context entities' GUIDs
    • getOutTopicConnection

      public ConnectionResponse getOutTopicConnection(String serverName, String userId, String callerId)
      Return the client side connection object for the Asset Lineage OMAS's out topic.
      serverName - name of the service to route the request to.
      userId - identifier of calling user.
      callerId - unique identifier of the caller
      connection object for the out topic or InvalidParameterException one of the parameters is null or invalid or UserNotAuthorizedException user not authorized to issue this request or PropertyServerException problem retrieving the discovery engine definition.