Class IntegrationReportWriter

java.lang.Object
org.odpi.openmetadata.frameworks.integration.reports.IntegrationReportWriter

public class IntegrationReportWriter extends Object
IntegrationReportWriter is responsible for managing the assembly and production of IntegrationReports. It offers methods to turn reporting on and off, define the time span (start capturing data/publish report) of a report; to record information that should be included in the report.
  • Constructor Details

    • IntegrationReportWriter

      public IntegrationReportWriter(String serverName, String connectorId, String connectorName, String userId, OpenIntegrationClient openIntegrationClient, OpenMetadataClient openMetadataStore)
      Set up the integration report writer.
      Parameters:
      serverName - name of this integration daemon
      connectorId - identifier of this running integration connector instance
      connectorName - name of this integration connector
      userId - calling user
      openIntegrationClient - client used to publish reports.
      openMetadataStore - client used to find out about metadata elements.
  • Method Details

    • startRecording

      public void startRecording()
      Set up properties ready for a new report.
    • publishReport

      Assemble the data collected and write out a report (if configured).
      Throws:
      InvalidParameterException - an invalid property has been passed
      UserNotAuthorizedException - the user is not authorized
      PropertyServerException - there is a problem communicating with the metadata server (or it has a logic error).
    • setActiveReportPublishing

      public void setActiveReportPublishing(boolean flag)
      Set whether an integration report should be assembled and published.
      Parameters:
      flag - required behaviour
    • setAnchor

      public void setAnchor(String elementGUID, String anchorGUID) throws InvalidParameterException, PropertyServerException, UserNotAuthorizedException
      Save the relationship between an element and its anchor. This is used to identify which report that the element should be reported under.
      Parameters:
      elementGUID - unique identifier of the element
      anchorGUID - unique identifier of the associated anchor
      Throws:
      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)
    • setAnchor

      public void setAnchor(String elementGUID, String anchorGUID, String anchorTypeName)
      Save the relationship between an element and its anchor. This is used to identify which report that the element should be reported under.
      Parameters:
      elementGUID - unique identifier of the element
      anchorGUID - unique identifier of the associated anchor
      anchorTypeName - type of the associated anchor
    • setParent

      public void setParent(String elementGUID, String parentGUID)
      Attempt to use the parent's GUID to discover the relationship between an element and its anchor. This is used to identify which report that the element should be reported under.
      Parameters:
      elementGUID - unique identifier of the element
      parentGUID - unique identifier of the associated parent
    • reportElementCreation

      public void reportElementCreation(String elementGUID)
      Save information about a newly created element.
      Parameters:
      elementGUID - unique identifier of the element
    • reportElementUpdate

      public void reportElementUpdate(String elementGUID)
      Save information about a newly updated element.
      Parameters:
      elementGUID - unique identifier of the element
    • reportElementDelete

      public void reportElementDelete(String elementGUID)
      Save information about a newly archived or deleted element.
      Parameters:
      elementGUID - unique identifier of the element