Class ExternalLinksRESTServices

java.lang.Object
org.odpi.openmetadata.tokencontroller.TokenController
org.odpi.openmetadata.viewservices.externallinks.server.ExternalLinksRESTServices

public class ExternalLinksRESTServices extends TokenController
The ExternalLinksRESTServices provides the server-side implementation of the External Links Open Metadata View Service (OMVS). This interface provides access to a person's profile, roles and network.
  • Constructor Details

    • ExternalLinksRESTServices

      public ExternalLinksRESTServices()
      Default constructor
  • Method Details

    • createExternalReference

      public GUIDResponse createExternalReference(String serverName, String urlMarker, NewElementRequestBody requestBody)
      Create an external reference.
      Parameters:
      serverName - name of called server.
      urlMarker - view service URL marker
      requestBody - properties for the external reference.
      Returns:
      unique identifier of the newly created element InvalidParameterException one of the parameters is invalid. PropertyServerException a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
    • createExternalReferenceFromTemplate

      public GUIDResponse createExternalReferenceFromTemplate(String serverName, String urlMarker, TemplateRequestBody requestBody)
      Create a new metadata element to represent an external reference using an existing metadata element as a template. The template defines additional classifications and relationships that should be added to the new element.
      Parameters:
      serverName - calling user
      urlMarker - view service URL marker
      requestBody - properties that override the template
      Returns:
      unique identifier of the new metadata element InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException a problem reported in the open metadata server(s)
    • updateExternalReference

      public BooleanResponse updateExternalReference(String serverName, String urlMarker, String externalReferenceGUID, UpdateElementRequestBody requestBody)
      Update the properties of an external reference.
      Parameters:
      serverName - name of called server.
      urlMarker - view service URL marker
      externalReferenceGUID - unique identifier of the external reference (returned from create)
      requestBody - properties for the new element.
      Returns:
      boolean or InvalidParameterException one of the parameters is invalid. PropertyServerException a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
    • linkExternalReference

      public GUIDResponse linkExternalReference(String serverName, String urlMarker, String elementGUID, String externalReferenceGUID, NewRelationshipRequestBody requestBody)
      Attach an external reference to an element.
      Parameters:
      serverName - name of called server
      urlMarker - view service URL marker
      elementGUID - unique identifier of the element
      externalReferenceGUID - unique identifier of the external reference
      requestBody - description of the relationship.
      Returns:
      unique identifier of the new relationship or InvalidParameterException one of the parameters is null or invalid. PropertyServerException a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
    • updateExternalReferenceLink

      public VoidResponse updateExternalReferenceLink(String serverName, String urlMarker, String externalReferenceLinkRelationshipGUID, UpdateRelationshipRequestBody requestBody)
      Update the properties of a external reference link relationship.
      Parameters:
      serverName - name of the server to route the request to
      urlMarker - view service URL marker
      externalReferenceLinkRelationshipGUID - unique identifier of the relationship
      requestBody - properties for the relationship
      Returns:
      void or InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException a problem reported in the open metadata server(s)
    • detachExternalReference

      public VoidResponse detachExternalReference(String serverName, String urlMarker, String externalReferenceLinkRelationshipGUID, DeleteRelationshipRequestBody requestBody)
      Remove a external reference link relationship.
      Parameters:
      serverName - name of the server to route the request to
      urlMarker - view service URL marker
      externalReferenceLinkRelationshipGUID - unique identifier of the relationship
      requestBody - delete options
      Returns:
      void or InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException a problem reported in the open metadata server(s)
    • linkMediaReference

      public GUIDResponse linkMediaReference(String serverName, String urlMarker, String elementGUID, String externalReferenceGUID, NewRelationshipRequestBody requestBody)
      Attach an external media reference to an element.
      Parameters:
      serverName - name of called server
      urlMarker - view service URL marker
      elementGUID - unique identifier of the element
      externalReferenceGUID - unique identifier of the external reference
      requestBody - description of the relationship.
      Returns:
      unique identifier of the new relationship or InvalidParameterException one of the parameters is null or invalid. PropertyServerException a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
    • updateMediaReference

      public VoidResponse updateMediaReference(String serverName, String urlMarker, String mediaReferenceRelationshipGUID, UpdateRelationshipRequestBody requestBody)
      Update the properties of a media reference relationship.
      Parameters:
      serverName - name of the server to route the request to
      urlMarker - view service URL marker
      mediaReferenceRelationshipGUID - unique identifier of the relationship
      requestBody - properties for the relationship
      Returns:
      void or InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException a problem reported in the open metadata server(s)
    • detachMediaReference

      public VoidResponse detachMediaReference(String serverName, String urlMarker, String mediaReferenceRelationshipGUID, DeleteRelationshipRequestBody requestBody)
      Remove a media reference relationship.
      Parameters:
      serverName - name of the server to route the request to
      urlMarker - view service URL marker
      mediaReferenceRelationshipGUID - unique identifier of the relationship
      requestBody - delete options
      Returns:
      void or InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException a problem reported in the open metadata server(s)
    • linkCitedDocumentReference

      public GUIDResponse linkCitedDocumentReference(String serverName, String urlMarker, String elementGUID, String externalReferenceGUID, NewRelationshipRequestBody requestBody)
      Attach an element to its external document reference.
      Parameters:
      serverName - name of called server
      urlMarker - view service URL marker
      elementGUID - unique identifier of the element
      externalReferenceGUID - unique identifier of the external reference
      requestBody - description of the relationship.
      Returns:
      unique identifier of the new relationship or InvalidParameterException one of the parameters is null or invalid. PropertyServerException a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
    • updateCitedDocumentReference

      public VoidResponse updateCitedDocumentReference(String serverName, String urlMarker, String citedDocumentLinkRelationshipGUID, UpdateRelationshipRequestBody requestBody)
      Update the properties of a cited document link relationship.
      Parameters:
      serverName - name of the server to route the request to
      urlMarker - view service URL marker
      citedDocumentLinkRelationshipGUID - unique identifier of the relationship
      requestBody - properties for the relationship
      Returns:
      void or InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException a problem reported in the open metadata server(s)
    • detachCitedDocumentReference

      public VoidResponse detachCitedDocumentReference(String serverName, String urlMarker, String citedDocumentLinkRelationshipGUID, DeleteRelationshipRequestBody requestBody)
      Remove a cited document link relationship.
      Parameters:
      serverName - name of the server to route the request to
      urlMarker - view service URL marker
      citedDocumentLinkRelationshipGUID - unique identifier of the relationship
      requestBody - delete options
      Returns:
      void or InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException a problem reported in the open metadata server(s)
    • deleteExternalReference

      public VoidResponse deleteExternalReference(String serverName, String urlMarker, String externalReferenceGUID, DeleteElementRequestBody requestBody)
      Delete an external reference.
      Parameters:
      serverName - name of called server
      urlMarker - view service URL marker
      externalReferenceGUID - unique identifier of the element to delete
      requestBody - description of the relationship.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
    • getExternalReferencesByName

      public OpenMetadataRootElementsResponse getExternalReferencesByName(String serverName, String urlMarker, FilterRequestBody requestBody)
      Retrieve the list of external reference metadata elements that contain the search string.
      Parameters:
      serverName - name of the service to route the request to
      urlMarker - view service URL marker
      requestBody - string to find in the properties
      Returns:
      list of matching metadata elements or InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException a problem reported in the open metadata server(s)
    • getExternalReferenceByGUID

      public OpenMetadataRootElementResponse getExternalReferenceByGUID(String serverName, String urlMarker, String externalReferenceGUID, GetRequestBody requestBody)
      Retrieve the list of external reference metadata elements that contain the search string.
      Parameters:
      serverName - name of the service to route the request to
      urlMarker - view service URL marker
      externalReferenceGUID - unique identifier of the required element
      requestBody - string to find in the properties
      Returns:
      list of matching metadata elements or InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException a problem reported in the open metadata server(s)
    • findExternalReferences

      public OpenMetadataRootElementsResponse findExternalReferences(String serverName, String urlMarker, SearchStringRequestBody requestBody)
      Retrieve the list of external reference metadata elements that contain the search string.
      Parameters:
      serverName - name of the service to route the request to
      urlMarker - view service URL marker
      requestBody - string to find in the properties
      Returns:
      list of matching metadata elements or InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException a problem reported in the open metadata server(s)
    • addExternalIdentifier

      public VoidResponse addExternalIdentifier(String serverName, String urlMarker, String elementGUID, NewExternalIdRequestBody requestBody)
      Add the description of a specific external identifier.
      Parameters:
      serverName - name of the service to route the request to.
      urlMarker - view service URL marker
      elementGUID - unique identifier (GUID) of the element in the open metadata ecosystem
      requestBody - unique identifier of this element in the external asset manager plus additional mapping properties
      Returns:
      void or InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException problem accessing the property server
    • updateExternalIdentifier

      public BooleanResponse updateExternalIdentifier(String serverName, String urlMarker, String externalIdGUID, UpdateElementRequestBody requestBody)
      Update the description of a specific external identifier.
      Parameters:
      serverName - name of the service to route the request to.
      urlMarker - view service URL marker
      externalIdGUID - unique identifier (GUID) of the externalId in the open metadata ecosystem
      requestBody - unique identifier of this element in the external system plus additional mapping properties
      Returns:
      boolean or InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException problem accessing the property server
    • deleteExternalIdentifier

      public VoidResponse deleteExternalIdentifier(String serverName, String urlMarker, String externalIdGUID, DeleteElementRequestBody requestBody)
      Remove an external identifier from an existing open metadata element. The open metadata element is not affected.
      Parameters:
      serverName - name of the service to route the request to.
      urlMarker - view service URL marker
      externalIdGUID - unique identifier (GUID) of the element in the open metadata ecosystem
      requestBody - unique identifier of this element in the external asset manager plus additional mapping properties
      Returns:
      void or InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException problem accessing the property server
    • confirmSynchronization

      public VoidResponse confirmSynchronization(String serverName, String urlMarker, String externalIdLinkGUID, UpdateRelationshipRequestBody requestBody)
      Confirm that the values of a particular metadata element have been synchronized. This is important from an audit point of view, and to allow bidirectional updates of metadata using optimistic locking.
      Parameters:
      serverName - name of the service to route the request to.
      urlMarker - view service URL marker
      externalIdLinkGUID - unique identifier (GUID) of this element in open metadata
      requestBody - details of the external identifier and its scope
      Returns:
      void or InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException problem accessing the property server
    • getExternalIdsByName

      public OpenMetadataRootElementsResponse getExternalIdsByName(String serverName, String urlMarker, FilterRequestBody requestBody)
      Retrieve the list of external id metadata elements that contain the search string.
      Parameters:
      serverName - name of the service to route the request to
      urlMarker - view service URL marker
      requestBody - string to find in the properties
      Returns:
      list of matching metadata elements or InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException a problem reported in the open metadata server(s)
    • getExternalIdByGUID

      public OpenMetadataRootElementResponse getExternalIdByGUID(String serverName, String urlMarker, String externalIdGUID, GetRequestBody requestBody)
      Retrieve the list of external id metadata elements that contain the search string.
      Parameters:
      serverName - name of the service to route the request to
      urlMarker - view service URL marker
      externalIdGUID - unique identifier of the required element
      requestBody - string to find in the properties
      Returns:
      list of matching metadata elements or InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException a problem reported in the open metadata server(s)
    • findExternalIds

      public OpenMetadataRootElementsResponse findExternalIds(String serverName, String urlMarker, SearchStringRequestBody requestBody)
      Retrieve the list of external id metadata elements that contain the search string.
      Parameters:
      serverName - name of the service to route the request to
      urlMarker - view service URL marker
      requestBody - string to find in the properties
      Returns:
      list of matching metadata elements or InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException a problem reported in the open metadata server(s)
    • linkExternalIdToElement

      public VoidResponse linkExternalIdToElement(String serverName, String urlMarker, String elementGUID, String externalIdGUID, NewRelationshipRequestBody requestBody)
      Attach an existing external identifier to the element that it identifies.
      Parameters:
      serverName - name of the server to route the request to
      urlMarker - view service URL marker
      elementGUID - unique identifier of the element
      externalIdGUID - unique identifier of the external identifier
      requestBody - properties for the relationship
      Returns:
      void or InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException a problem reported in the open metadata server(s)
    • detachExternalIdFromElement

      public VoidResponse detachExternalIdFromElement(String serverName, String urlMarker, String elementGUID, String externalIdGUID, DeleteRelationshipRequestBody requestBody)
      Detach an external identifier from the element that it identifies.
      Parameters:
      serverName - name of the server to route the request to
      urlMarker - view service URL marker
      elementGUID - unique identifier of the element
      externalIdGUID - unique identifier of the external identifier
      requestBody - delete options
      Returns:
      void or InvalidParameterException one of the parameters is invalid UserNotAuthorizedException the user is not authorized to issue this request PropertyServerException a problem reported in the open metadata server(s)
    • detachCitedDocumentReference

      public VoidResponse detachCitedDocumentReference(String serverName, String urlMarker, String elementGUID, String externalReferenceGUID, DeleteRelationshipRequestBody requestBody)
      Detach an element from its external document reference.
      Parameters:
      serverName - name of called server
      urlMarker - view service URL marker
      elementGUID - unique identifier of the element
      externalReferenceGUID - unique identifier of the external reference
      requestBody - description of the relationship.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request. This is a multi-link relationship, so this request removes every cited document link relationship between the two elements. Use the request that takes the relationship's own unique identifier to remove just one of them.
    • detachExternalReference

      public VoidResponse detachExternalReference(String serverName, String urlMarker, String elementGUID, String externalReferenceGUID, DeleteRelationshipRequestBody requestBody)
      Detach an external reference from an element.
      Parameters:
      serverName - name of called server
      urlMarker - view service URL marker
      elementGUID - unique identifier of the element
      externalReferenceGUID - unique identifier of the external reference
      requestBody - description of the relationship.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request. This is a multi-link relationship, so this request removes every external reference link relationship between the two elements. Use the request that takes the relationship's own unique identifier to remove just one of them.
    • detachMediaReference

      public VoidResponse detachMediaReference(String serverName, String urlMarker, String elementGUID, String externalReferenceGUID, DeleteRelationshipRequestBody requestBody)
      Detach an external media reference from an element.
      Parameters:
      serverName - name of called server
      urlMarker - view service URL marker
      elementGUID - unique identifier of the element
      externalReferenceGUID - unique identifier of the external reference
      requestBody - description of the relationship.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request. This is a multi-link relationship, so this request removes every media reference relationship between the two elements. Use the request that takes the relationship's own unique identifier to remove just one of them.