AppService.run() wakes up after EXECUTION_INTERVAL_IN_HOURS hours.
Calls HbfCoreService.getOrganizationsWithDataRetentionPolicy() — fetches all orgs from hbf-core, filters to those with dataRetentionPeriod set.
Calls HbfCoreService.getTenantsWithDataRetentionPolicy() — same pattern for tenants, returning full Tenant objects (needed for organizationId and dataRetentionPeriod).
Calls HbfCoreService.getOrganizationsWithAuditLogRetentionPolicy() — orgs with auditLogsRetentionPeriod set.
If none of the three lists has entries, skips the cycle and sleeps.
For each tenant: calls HbfCoreService.deleteDataTenant, then calls AttachmentsService.deleteOldAttachments(orgId, tenantId, retentionDays).
For each org: calls HbfCoreService.deleteData(orgId).
For each org with audit log policy: calls HbfCoreService.deleteAuditLogs(orgId).
Any item that fails is collected and retried up to THRESHOLD_OF_DELETION_RETIRES times. Remaining failures are logged as warnings.