The CAS Server calls endAcquisition() after all extensions in a acquisition have completed data acquisition and record processing. Your implementation of endAcquisition() can override PipelineComponentRuntime.endAcquisition() to perform any necessary cleanup for an extension.

The endAcquisition() method has an input parameter, an AcquisitionEndState object that indicates the state of the acquisition process when it ended. The AcquisitionEndState can have one of the following enumerated values:

Your implementation of endAcquisition() should account for each of the values of AcquisitionEndState that CAS might pass to the extension.

In general, this means if CAS passes endAcquisition() a value of SUCCESS, the extension typically maintains any state changes it made during the acquisition. For example, this could include a data source extension writing out timestamp information for a successful acquisition and later reading in that timestamp for a subsequent acquisition in order to determine the incremental difference between acquisitions.

If CAS passes endAcquisition() a value of FAILURE, the extension typically reverts any state changes it made during the acquisition. For example, this could include reverting timestamp information for a failed acquisition.

If CAS passes endAcquisition() a value of FULL_ACQUISITION_RECOVERY_REQUIRED, the extension could either maintain or revert state information. You want to do whatever is necessary to prepare for a new acquisition and also throw a FullAcquisitionRecoveryRequiredException exception.


Copyright © Legal Notices