Hello!
We are running a self-hosted version of Retool and ran into a problem when backing up the database. Two tables, page_saves and audit_trail_events, are surprisingly big (see the screenshot below).
Page: You can delete old or unnecessary page versions that are no longer relevant.
Audit Log: You can configure the system to only store events for a certain period(10 day or 30 days). Regularly purge old audit trail events that are no longer needed.
Thank you—but how? I can't see it in Settings, and there are no mentions in Docs. Or do you mean that Retool does not have retention policies? Do you mean a general concept?
You can delete audit logs (entries on audit_trail_events) that are older than a time period of your choosing (e.g., 30 days, 90 days, a year), you can decide the appropriate retention length based on your needs. You can also delete records from the pages_saves table, but please note that this table stores all changes made to your apps. If you delete records older than 30 days, for example, you'll lose the ability to revert the app to any state prior to that timeframe.
In order to manage deleting data from these tables, you could set up a scheduled Workflow to automatically delete records from the tables that meet specific criteria on a recurring basis (e.g., every day, week, or month).