Class IntegrationReportWriter
java.lang.Object
org.odpi.openmetadata.frameworks.integration.reports.IntegrationReportWriter
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 Summary
ConstructorDescriptionIntegrationReportWriter
(String serverName, String connectorId, String connectorName, String userId, OpenIntegrationClient openIntegrationClient, OpenMetadataClient openMetadataStore) Set up the integration report writer. -
Method Summary
Modifier and TypeMethodDescriptionvoid
Assemble the data collected and write out a report (if configured).void
reportElementCreation
(String elementGUID) Save information about a newly created element.void
reportElementDelete
(String elementGUID) Save information about a newly archived or deleted element.void
reportElementUpdate
(String elementGUID) Save information about a newly updated element.void
setActiveReportPublishing
(boolean flag) Set whether an integration report should be assembled and published.void
Save the relationship between an element and its anchor.void
Save the relationship between an element and its anchor.void
Attempt to use the parent's GUID to discover the relationship between an element and its anchor.void
Set up properties ready for a new 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 daemonconnectorId
- identifier of this running integration connector instanceconnectorName
- name of this integration connectoruserId
- calling useropenIntegrationClient
- 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
public void publishReport() throws InvalidParameterException, UserNotAuthorizedException, PropertyServerExceptionAssemble the data collected and write out a report (if configured).- Throws:
InvalidParameterException
- an invalid property has been passedUserNotAuthorizedException
- the user is not authorizedPropertyServerException
- 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 elementanchorGUID
- unique identifier of the associated anchor- Throws:
InvalidParameterException
- one of the parameters is invalidUserNotAuthorizedException
- the user is not authorized to issue this requestPropertyServerException
- there is a problem reported in the open metadata server(s)
-
setAnchor
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 elementanchorGUID
- unique identifier of the associated anchoranchorTypeName
- type of the associated anchor
-
setParent
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 elementparentGUID
- unique identifier of the associated parent
-
reportElementCreation
Save information about a newly created element.- Parameters:
elementGUID
- unique identifier of the element
-
reportElementUpdate
Save information about a newly updated element.- Parameters:
elementGUID
- unique identifier of the element
-
reportElementDelete
Save information about a newly archived or deleted element.- Parameters:
elementGUID
- unique identifier of the element
-