ThingWorx Model Definition and Composer > System > Subsystems > Audit Subsystem > Audit Archive, Export, and Clean-up Operations
Audit Archive, Export, and Clean-up Operations
The Audit Subsystem provides both online and offline storage for audit messages:
Online—Individual entries are displayed online and are searchable using the QueryAuditHistory service of the Audit Subsystem.
Offline—In the context of the Audit Subsystem, “offline” means that audit data is not available to be retrieved and seen in ThingWorx Composer, nor can it be retrieved using the QueryAuditHistory service. The data is archived in files that are stored in the File Repository of the Audit Subsystem, called AuditArchiveFileRepository. It is possible to export these files from the repository. Permissions to this repository can be set to restrict access to the data. The data is exported in JSON format and compressed.
To maintain a controlled amount of online data and maintain performance while searching and filtering online audit data, the Audit Subsystem provides archive operations, scheduled and manual. To allow administrators to monitor activities when troubleshooting or examining activity for purposes of reporting, the Audit Subsystem provides export operations for both online and offline data. The export operation pushes the requested data to a target destination on request.
The archive operation is run on a schedule and can also be invoked manually. The archive operation copies online data to the offline storage, ensures that the online data was copied, and then purges the online data that is outside of the retention criteria. For more information about the export operation, see Exporting Audit Data. That section includes a Sample Application for Exporting Audit Data.
For more information about archive operations, see Archiving Audit Data.
The Audit Subsystem provides a service that automatically cleans up the offline archive, based on a configured retention time and a scheduler. For more information, see Clean-up of the Audit Archives.