-
@unateam @Michael Newton @Clubhouse @LeonidS
Timeline Cleanup Script - Success Report
Great news! We've successfully tested and deployed the timeline cleanup script discussed earlier in this thread.
Results:
The script performed flawlessly across multiple environments:
- ✅ Dev server: Clean deletions with proper media file removal
- ✅ Symlinked storage: Files correctly deleted from remote NFS mounts
- ✅ Production deployment: Zero orphaned records, zero failures
Key Validations:
✓ Database records properly removed
✓ Physical media files deleted from disk (verified storage size decrease)
✓ All dependent data cleaned up (comments, reactions, mappings)
✓ Works perfectly with symlinked remote storage
✓ No orphaned files or broken references
Technical Approach:
Used UNA's native BxDolModule::getInstance('bx_timeline')->deleteEvent() method, which ensured all storage hooks and cleanup processes fired correctly. This is the same deletion method UNA's admin interface uses internally.
For anyone needing similar cleanup:
The script safely handles timeline post deletion with proper media cleanup. Happy to share implementation details if others need similar functionality.
Thanks to everyone who provided input and validation during testing! 🙏