Adding thread logic to auto-generate compresses files.