Adjust existing code base to not use hardcoded file path.
Instead use info from database and check all files which have references
to event objects.
Also add test to cover feature.
Properly cleanup system.
Delete further records when deleting everything.
Also respect further records when purging old entries.
Respect:
* sys_category_record_mm
* sys_file_reference
* sys_file_metadata