java.lang.Object
org.odpi.openmetadata.viewservices.datadiscovery.server.spring.DataDiscoveryResource

@RestController @RequestMapping("/servers/{serverName}/api/open-metadata/data-discovery") public class DataDiscoveryResource extends Object
The DataDiscoveryResource provides part of the server-side implementation of the Data Discovery OMVS. =
  • Constructor Details

    • DataDiscoveryResource

      public DataDiscoveryResource()
      Default constructor
  • Method Details

    • createAnnotation

      @PostMapping(path="/annotations") public GUIDResponse createAnnotation(@PathVariable String serverName, @RequestBody(required=false) NewElementRequestBody requestBody)
      Create an annotation.
      Parameters:
      serverName - name of called server.
      requestBody - properties for the annotation.
      Returns:
      unique identifier of the newly created element InvalidParameterException one of the parameters is invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
    • createAnnotationFromTemplate

      @PostMapping(path="/annotations/from-template") public GUIDResponse createAnnotationFromTemplate(@PathVariable String serverName, @RequestBody(required=false) TemplateRequestBody requestBody)
      Create a new metadata element to represent an annotation 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
      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 there is a problem reported in the open metadata server(s)
    • updateAnnotation

      @PostMapping(path="/annotations/{annotationGUID}/update") public VoidResponse updateAnnotation(@PathVariable String serverName, @PathVariable String annotationGUID, @RequestBody(required=false) UpdateElementRequestBody requestBody)
      Update the properties of an annotation.
      Parameters:
      serverName - name of called server.
      annotationGUID - unique identifier of the annotation (returned from create)
      requestBody - properties for the new element.
      Returns:
      void or InvalidParameterException one of the parameters is invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
    • attachAnnotationToReport

      @PostMapping(path="/survey-reports/{surveyReportGUID}/new-annotations/{newAnnotationGUID}/attach") public VoidResponse attachAnnotationToReport(@PathVariable String serverName, @PathVariable String surveyReportGUID, @PathVariable String newAnnotationGUID, @RequestBody(required=false) NewRelationshipRequestBody requestBody)
      Create a relationship that links a new annotation to its survey report. This relationship is typically established during the createAnnotation as the parent relationship. It is included for completeness.
      Parameters:
      serverName - name of called server
      surveyReportGUID - unique identifier of the report
      newAnnotationGUID - unique identifier of the annotation
      requestBody - description of the relationship.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
    • detachAnnotationFromReport

      @PostMapping(path="/survey-reports/{surveyReportGUID}/new-annotations/{newAnnotationGUID}/detach") public VoidResponse detachAnnotationFromReport(@PathVariable String serverName, @PathVariable String surveyReportGUID, @PathVariable String newAnnotationGUID, @RequestBody(required=false) DeleteRelationshipRequestBody requestBody)
      Detach an annotation from its report (ReportedAnnotation relationship).
      Parameters:
      serverName - name of called server
      surveyReportGUID - unique identifier of the report
      newAnnotationGUID - unique identifier of the annotation
      requestBody - description of the relationship.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
    • linkAnnotationToDescribedElement

      @PostMapping(path="/elements/{elementGUID}/associated-annotations/{annotationGUID}/attach") public VoidResponse linkAnnotationToDescribedElement(@PathVariable String serverName, @PathVariable String elementGUID, @PathVariable String annotationGUID, @RequestBody(required=false) NewRelationshipRequestBody requestBody)
      Attach an annotation to the element that it is describing (via AssociatedAnnotation relationship).
      Parameters:
      serverName - name of called server
      elementGUID - unique identifier of the described element
      annotationGUID - unique identifier of the annotation
      requestBody - description of the relationship.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
    • detachAnnotationFromDescribedElement

      @PostMapping(path="/elements/{elementGUID}/associated-annotations/{annotationGUID}/detach") public VoidResponse detachAnnotationFromDescribedElement(@PathVariable String serverName, @PathVariable String elementGUID, @PathVariable String annotationGUID, @RequestBody(required=false) DeleteRelationshipRequestBody requestBody)
      Detach an annotation from the element that it is describing (via AssociatedAnnotation relationship).
      Parameters:
      serverName - name of called server
      elementGUID - unique identifier of the described element
      annotationGUID - unique identifier of the annotation
      requestBody - description of the relationship.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
    • linkAnnotationToItsPredecessor

      @PostMapping(path="/annotations/{previousAnnotationGUID}/later-annotations/{newAnnotationGUID}/attach") public VoidResponse linkAnnotationToItsPredecessor(@PathVariable String serverName, @PathVariable String previousAnnotationGUID, @PathVariable String newAnnotationGUID, @RequestBody(required=false) NewRelationshipRequestBody requestBody)
      Attach an annotation to the equivalent annotation from the previous run of the survey.
      Parameters:
      serverName - name of called server
      previousAnnotationGUID - unique identifier of the annotation from the previous run of the survey
      newAnnotationGUID - unique identifier of the annotation from this run of the survey
      requestBody - description of the relationship.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
    • detachAnnotationFromItsPredecessor

      @PostMapping(path="/annotations/{previousAnnotationGUID}/later-annotations/{newAnnotationGUID}/detach") public VoidResponse detachAnnotationFromItsPredecessor(@PathVariable String serverName, @PathVariable String previousAnnotationGUID, @PathVariable String newAnnotationGUID, @RequestBody(required=false) DeleteRelationshipRequestBody requestBody)
      Detach an annotation from an annotation from the previous run of the survey.
      Parameters:
      serverName - name of called server
      previousAnnotationGUID - unique identifier of the annotation from the previous run of the survey
      newAnnotationGUID - unique identifier of the annotation from this run of the survey
      requestBody - description of the relationship.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
    • linkDiscoveredSchemaType

      @PostMapping(path="/annotations/{annotationGUID}/discovered-schema-type/{schemaTypeGUID}/attach") public VoidResponse linkDiscoveredSchemaType(@PathVariable String serverName, @PathVariable String annotationGUID, @PathVariable String schemaTypeGUID, @RequestBody(required=false) NewRelationshipRequestBody requestBody)
      Attach a schema analysis annotation to a matching schema type.
      Parameters:
      serverName - name of called server
      annotationGUID - unique identifier of the annotation
      schemaTypeGUID - unique identifier of the schema type
      requestBody - description of the relationship.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
    • detachDiscoveredSchemaType

      @PostMapping(path="/annotations/{annotationGUID}/discovered-schema-type/{schemaTypeGUID}/detach") public VoidResponse detachDiscoveredSchemaType(@PathVariable String serverName, @PathVariable String annotationGUID, @PathVariable String schemaTypeGUID, @RequestBody(required=false) DeleteRelationshipRequestBody requestBody)
      Detach a schema analysis annotation from a matching schema type.
      Parameters:
      serverName - name of called server
      annotationGUID - unique identifier of the annotation
      schemaTypeGUID - unique identifier of the schema type
      requestBody - description of the relationship.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
    • linkResourceProfileData

      @PostMapping(path="/annotations/{annotationGUID}/resource-profile-data-assets/{assetGUID}/attach") public VoidResponse linkResourceProfileData(@PathVariable String serverName, @PathVariable String annotationGUID, @PathVariable String assetGUID, @RequestBody(required=false) NewRelationshipRequestBody requestBody)
      Attach a resource profile log annotation to an asset where the profile data is stored.
      Parameters:
      serverName - name of called server
      annotationGUID - unique identifier of the annotation
      assetGUID - unique identifier of the associated asset
      requestBody - description of the relationship.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
    • detachResourceProfileData

      @PostMapping(path="/annotations/{annotationGUID}/resource-profile-data-assets/{assetGUID}/detach") public VoidResponse detachResourceProfileData(@PathVariable String serverName, @PathVariable String annotationGUID, @PathVariable String assetGUID, @RequestBody(required=false) DeleteRelationshipRequestBody requestBody)
      Detach a resource profile log annotation from an asset where the profile data is stored.
      Parameters:
      serverName - name of called server
      annotationGUID - unique identifier of the annotation
      assetGUID - unique identifier of the associated asset
      requestBody - description of the relationship.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
    • linkDataClassMatch

      @PostMapping(path="/annotations/{annotationGUID}/matched-data-classes/{dataClassGUID}/attach") public VoidResponse linkDataClassMatch(@PathVariable String serverName, @PathVariable String annotationGUID, @PathVariable String dataClassGUID, @RequestBody(required=false) NewRelationshipRequestBody requestBody)
      Attach a data class annotation to a data class.
      Parameters:
      serverName - name of called server
      annotationGUID - unique identifier of the annotation
      dataClassGUID - unique identifier of the associated data class
      requestBody - description of the relationship.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
    • detachDataClassMatch

      @PostMapping(path="/annotations/{annotationGUID}/matched-data-classes/{dataClassGUID}/detach") public VoidResponse detachDataClassMatch(@PathVariable String serverName, @PathVariable String annotationGUID, @PathVariable String dataClassGUID, @RequestBody(required=false) DeleteRelationshipRequestBody requestBody)
      Detach a data class annotation from a data class.
      Parameters:
      serverName - name of called server
      annotationGUID - unique identifier of the annotation
      dataClassGUID - unique identifier of the associated data class
      requestBody - description of the relationship.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
    • linkRequestForActionTarget

      @PostMapping(path="/annotations/{annotationGUID}/request-for-action-targets/{elementGUID}/attach") public VoidResponse linkRequestForActionTarget(@PathVariable String serverName, @PathVariable String annotationGUID, @PathVariable String elementGUID, @RequestBody(required=false) NewRelationshipRequestBody requestBody)
      Attach a request for action annotation to the element that needs attention.
      Parameters:
      serverName - name of called server
      annotationGUID - unique identifier of the annotation
      elementGUID - unique identifier of the associated element
      requestBody - description of the relationship.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
    • detachRequestForActionTarget

      @PostMapping(path="/annotations/{annotationGUID}/request-for-action-targets/{elementGUID}/detach") public VoidResponse detachRequestForActionTarget(@PathVariable String serverName, @PathVariable String annotationGUID, @PathVariable String elementGUID, @RequestBody(required=false) DeleteRelationshipRequestBody requestBody)
      Detach a request for action annotation from its intended target element.
      Parameters:
      serverName - name of called server
      annotationGUID - unique identifier of the annotation
      elementGUID - unique identifier of the associated element
      requestBody - description of the relationship.
      Returns:
      void or InvalidParameterException one of the parameters is null or invalid. PropertyServerException there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
    • deleteAnnotation

      @PostMapping(path="/annotations/{annotationGUID}/delete") public VoidResponse deleteAnnotation(@PathVariable String serverName, @PathVariable String annotationGUID, @RequestBody(required=false) DeleteElementRequestBody requestBody)
      Delete an annotation.
      Parameters:
      serverName - name of called server
      annotationGUID - 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 there is a problem retrieving information from the property server(s). UserNotAuthorizedException the requesting user is not authorized to issue this request.
    • getAnnotationsByName

      @PostMapping(path="/annotations/by-name") public OpenMetadataRootElementsResponse getAnnotationsByName(@PathVariable String serverName, @RequestBody(required=false) FilterRequestBody requestBody)
      Returns the list of annotations with a particular name.
      Parameters:
      serverName - name of the service to route the request to
      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 there is a problem reported in the open metadata server(s)
    • getAnnotationsByAnalysisStep

      @PostMapping(path="/annotations/by-analysis-step") public OpenMetadataRootElementsResponse getAnnotationsByAnalysisStep(@PathVariable String serverName, @RequestBody(required=false) FilterRequestBody requestBody)
      Returns the list of annotations associated with a particular analysis step.
      Parameters:
      serverName - name of the service to route the request to
      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 there is a problem reported in the open metadata server(s)
    • getAnnotationsByAnnotationType

      @PostMapping(path="/annotations/by-annotation-type") public OpenMetadataRootElementsResponse getAnnotationsByAnnotationType(@PathVariable String serverName, @RequestBody(required=false) FilterRequestBody requestBody)
      Returns the list of annotations with a particular annotation type property.
      Parameters:
      serverName - name of the service to route the request to
      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 there is a problem reported in the open metadata server(s)
    • getAnnotationsForElement

      @PostMapping(path="/elements/{elementGUID}/associated-annotations") public OpenMetadataRootElementsResponse getAnnotationsForElement(@PathVariable String serverName, @PathVariable String elementGUID, @RequestBody(required=false) ResultsRequestBody requestBody)
      Returns the list of annotations that describe the supplied element (AssociatedAnnotation relationship).
      Parameters:
      serverName - name of the service to route the request to
      elementGUID - unique identifier of the starting 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 there is a problem reported in the open metadata server(s)
    • getNewAnnotations

      @PostMapping(path="/survey-reports/{surveyReportGUID}/new-annotations") public OpenMetadataRootElementsResponse getNewAnnotations(@PathVariable String serverName, @PathVariable String surveyReportGUID, @RequestBody(required=false) ResultsRequestBody requestBody)
      Returns the annotations created under the supplied survey report.
      Parameters:
      serverName - name of the service to route the request to
      surveyReportGUID - unique identifier of the starting 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 there is a problem reported in the open metadata server(s)
    • getAnnotationExtensions

      @PostMapping(path="/annotations/{annotationGUID}/annotation-extensions") public OpenMetadataRootElementsResponse getAnnotationExtensions(@PathVariable String serverName, @PathVariable String annotationGUID, @RequestBody(required=false) ResultsRequestBody requestBody)
      Returns the list of annotations that extend the supplied annotation (AnnotationExtension relationship).
      Parameters:
      serverName - name of the service to route the request to
      annotationGUID - unique identifier of the starting 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 there is a problem reported in the open metadata server(s)
    • getPreviousAnnotations

      @PostMapping(path="/annotations/{annotationGUID}/previous-annotations") public OpenMetadataRootElementsResponse getPreviousAnnotations(@PathVariable String serverName, @PathVariable String annotationGUID, @RequestBody(required=false) ResultsRequestBody requestBody)
      Returns the list of annotations that are extended by the supplied annotation (AnnotationExtension relationship).
      Parameters:
      serverName - name of the service to route the request to
      annotationGUID - unique identifier of the starting 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 there is a problem reported in the open metadata server(s)
    • findAnnotations

      @PostMapping(path="/annotations/by-search-string") public OpenMetadataRootElementsResponse findAnnotations(@PathVariable String serverName, @RequestBody(required=false) SearchStringRequestBody requestBody)
      Retrieve the list of annotation metadata elements that contain the search string.
      Parameters:
      serverName - name of the service to route the request to
      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 there is a problem reported in the open metadata server(s)
    • getAnnotationByGUID

      @PostMapping(path="/annotations/{annotationGUID}/retrieve") public OpenMetadataRootElementResponse getAnnotationByGUID(@PathVariable String serverName, @PathVariable String annotationGUID, @RequestBody(required=false) GetRequestBody requestBody)
      Return the properties of a specific annotation.
      Parameters:
      serverName - name of the service to route the request to
      annotationGUID - 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 there is a problem reported in the open metadata server(s)