app-usage-worker OldDataDeleterJob fails with 'Transaction size exceed set threshold'
search cancel

app-usage-worker OldDataDeleterJob fails with 'Transaction size exceed set threshold'

book

Article ID: 423120

calendar_today

Updated On:

Products

VMware Tanzu Application Service

Issue/Introduction

The app-usage-worker, which is part of the App Usage Service, fails with a Mysql error.

The app-usage-worker logs show:

   2025-12-19T09:51:11.84-0500 [APP/PROC/WEB/0] OUT [Worker(host:xxxx pid:8)] Job Jobs::OldDataDeleterJob#delete_old_data_without_delay (id=999) FAILED (9 prior attempts) with ActiveRecord::StatementInvalid: Mysql2::Error: Got error 5 - 'Transaction size exceed set threshold' during COMMIT
   2025-12-19T09:51:11.84-0500 [APP/PROC/WEB/0] OUT E, [2025-11-19T14:51:11.841832 #8] ERROR -- : 2025-11-19T14:51:11+0000: [Worker(host:xxxx pid:8)] Job Jobs::OldDataDeleterJob#delete_old_data_without_delay (id=999) FAILED (9 prior attempts) with ActiveRecord::StatementInvalid: Mysql2::Error: Got error 5 - 'Transaction size exceed set threshold' during COMMIT

 

Environment

TPCF v6.0.17

Cause

Mysql Database server has a default transaction limit of 1GB.  The task_events table has at least 1GB of old data.  The OldDataDeleterJob fails to delete the records because the transaction size limit is being reached.

Resolution

This requires a database cleanup.  Please raise a support request for assistance.

There is a plan to permanently fix this in later versions by having the job delete the old records in batches.