Database Cleanup Inquiry for Kill Bill

40 views
Skip to first unread message

Pardos Dedondo

unread,
Apr 24, 2026, 6:48:52 AMApr 24
to Kill Bill users mailing-list

Good morning,

We are currently experiencing high operational activity and extensive usage of Kill Bill. As a result, the database size is growing significantly.

We would like to ask whether it is possible to perform cleanup operations on the following tables:

  • audit_log
  • bus_events_history
  • invoice_billing_events
  • bus_ext_events_history
  • payment_attempt_history
  • payment_attempts
  • subscription_events
  • invoice_items
  • subscription_event_history
  • subscriptions
  • subscription_history
  • payment_transaction_history

From our understanding, the *_history tables may be easier to clear, although we would appreciate your confirmation on this point. For the other tables, the process appears to be more complex.

If it is confirmed that a full cleanup is not feasible, could you please advise on how to safely perform data retention or archival strategies to reduce table sizes without compromising Kill Bill’s functionality?

Thank you in advance for your support.

Best regards,

Pardos

karan bansal

unread,
Apr 27, 2026, 2:18:42 AMApr 27
to Kill Bill users mailing-list
Hi Pardos,

Let me find more details about history tables and get back to you. 

In the meantime, could you confirm if you have any old accounts that can be removed. We do have an available Db proc to clear out old accounts. 

Regards
Karan

Pardos Dedondo

unread,
Apr 27, 2026, 6:44:28 AMApr 27
to Kill Bill users mailing-list
Hi,

Thanks for your reply. Unfortunately, we cannot deleted old accounts. We'll wait for your check about other tables.

Best regards,

Pardos

karan bansal

unread,
May 6, 2026, 1:47:33 AMMay 6
to Kill Bill users mailing-list
Hi Pardos,

Thank you for waiting patiently. I discussed this with the Dev team as well. They also confirmed that you can prune the history tables and audit_log table. This is in line with the proc that I shared earlier. Other than the history tables and audit log, please do not touch any of other tables mentioned in your initial email : 

invoice_billing_events
payment_attempts
subscription_events
invoice_items
subscriptions

Also, some API's have the option to query audit history, for example https://killbill.github.io/slate/account.html#retrieve-bundles-for-account. When you remove the audit log, this will also get affected. 

Regards
Karan

Reply all
Reply to author
Forward
0 new messages