Class SurveyReportHandler<B>


public class SurveyReportHandler<B> extends OpenMetadataAPIGenericHandler<B>
SurveyReportHandler manages the storage and retrieval of metadata relating to survey reports as defined in the Survey Analysis Framework (SAF).
  • Constructor Details

    • SurveyReportHandler

      public SurveyReportHandler(OpenMetadataAPIGenericConverter<B> converter, Class<B> beanClass, String serviceName, String serverName, InvalidParameterHandler invalidParameterHandler, RepositoryHandler repositoryHandler, OMRSRepositoryHelper repositoryHelper, String localServerUserId, OpenMetadataServerSecurityVerifier securityVerifier, List<String> supportedZones, List<String> defaultZones, List<String> publishZones, AuditLog auditLog)
      Construct the handler with information needed to work with B objects.
      Parameters:
      converter - specific converter for this bean class
      beanClass - name of bean class that is represented by the generic class B
      serviceName - name of this service
      serverName - name of the local server
      invalidParameterHandler - handler for managing parameter errors
      repositoryHandler - manages calls to the repository services
      repositoryHelper - provides utilities for manipulating the repository services objects
      localServerUserId - userId for this server
      securityVerifier - open metadata security services verifier
      supportedZones - list of zones that the access service is allowed to serve B instances from.
      defaultZones - list of zones that the access service should set in all new B instances.
      publishZones - list of zones that the access service sets up in published B instances.
      auditLog - destination for audit log events.
  • Method Details

    • createSurveyReport

      public String createSurveyReport(String userId, String qualifiedName, String displayName, String description, Date creationDate, Map<String,String> analysisParameters, String assetGUID, String governanceEngineGUID, String governanceServiceGUID, Map<String,String> additionalProperties, Date effectiveFrom, Date effectiveTo, boolean forLineage, boolean forDuplicateProcessing, Date effectiveTime, String methodName) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
      Create a new survey analysis report and chain it to its asset, survey engine and survey service.
      Parameters:
      userId - calling user
      qualifiedName - unique name for the report
      displayName - short name for the report
      description - description of the report
      creationDate - data of the report
      analysisParameters - analysis parameters passed to the survey service
      assetGUID - unique identifier of the asset being analysed
      governanceEngineGUID - unique identifier of the survey engine that is running the survey service
      governanceServiceGUID - unique identifier of the survey service creating the report
      additionalProperties - additional properties for the report
      effectiveFrom - starting time for this relationship (null for all time)
      effectiveTo - ending time for this relationship (null for all time)
      forLineage - the request is to support lineage retrieval this means entities with the Memento classification can be returned
      forDuplicateProcessing - the request is for duplicate processing and so must not deduplicate
      effectiveTime - the time that the retrieved elements must be effective for (null for any time, new Date() for now)
      methodName - calling method
      Returns:
      The new survey report.
      Throws:
      InvalidParameterException - one of the parameters is invalid
      UserNotAuthorizedException - the user is not authorized to access the asset and/or report
      PropertyServerException - there was a problem in the store whether the asset/report properties are kept.
    • updateSurveyReport

      public void updateSurveyReport(String userId, String surveyReportGUID, String qualifiedName, String displayName, String description, Date creationDate, Map<String,String> analysisParameters, Map<String,String> additionalProperties, Date effectiveFrom, Date effectiveTo, boolean isMergeUpdate, boolean forLineage, boolean forDuplicateProcessing, Date effectiveTime, String methodName) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
      Update the properties of the survey analysis report.
      Parameters:
      userId - calling user.
      surveyReportGUID - identifier of the survey report
      qualifiedName - unique name for the report
      displayName - short name for the report
      description - description of the report
      creationDate - data of the report
      analysisParameters - analysis parameters passed to the survey service
      additionalProperties - additional properties for the report
      isMergeUpdate - should the supplied properties be merged with existing properties (true) only replacing the properties with matching names, or should the entire properties of the instance be replaced?
      effectiveFrom - starting time for this relationship (null for all time)
      effectiveTo - ending time for this relationship (null for all time)
      forLineage - the request is to support lineage retrieval this means entities with the Memento classification can be returned
      forDuplicateProcessing - the request is for duplicate processing and so must not deduplicate
      effectiveTime - the time that the retrieved elements must be effective for (null for any time, new Date() for now)
      methodName - calling method
      Throws:
      InvalidParameterException - one of the parameters is null or invalid.
      UserNotAuthorizedException - user not authorized to issue this request.
      PropertyServerException - there was a problem that occurred within the property server.
    • getSurveyReport

      public B getSurveyReport(String userId, String surveyReportGUID, boolean forLineage, boolean forDuplicateProcessing, Date effectiveTime, String methodName) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
      Request the survey report for a survey request that has completed.
      Parameters:
      userId - identifier of calling user
      surveyReportGUID - identifier of the survey request.
      forLineage - the request is to support lineage retrieval this means entities with the Memento classification can be returned
      forDuplicateProcessing - the request is for duplicate processing and so must not deduplicate
      effectiveTime - the time that the retrieved elements must be effective for (null for any time, new Date() for now)
      methodName - calling method
      Returns:
      survey report
      Throws:
      InvalidParameterException - one of the parameters is null or invalid.
      UserNotAuthorizedException - user not authorized to issue this request.
      PropertyServerException - there was a problem that occurred within the property server.
    • getSurveyReports

      public List<B> getSurveyReports(String userId, String assetGUID, int startingFrom, int maximumResults, boolean forLineage, boolean forDuplicateProcessing, Date effectiveTime, String methodName) throws InvalidParameterException, UserNotAuthorizedException, PropertyServerException
      Return the survey reports about the asset.
      Parameters:
      userId - calling user
      assetGUID - unique identifier of the asset
      startingFrom - position in the list (used when there are so many reports that paging is needed
      maximumResults - maximum number of elements to return on this call
      forLineage - the request is to support lineage retrieval this means entities with the Memento classification can be returned
      forDuplicateProcessing - the request is for duplicate processing and so must not deduplicate
      effectiveTime - the time that the retrieved elements must be effective for (null for any time, new Date() for now)
      methodName - calling method
      Returns:
      list of survey analysis reports
      Throws:
      InvalidParameterException - one of the parameters is null or invalid.
      UserNotAuthorizedException - user not authorized to issue this request.
      PropertyServerException - there was a problem that occurred within the property server.