Infinite redraw loop with DataTables 3+ ColumnControl server-side
Infinite redraw loop with DataTables 3+ ColumnControl server-side

Link to test case:
Debugger code (debug.datatables.net):
Error messages shown:
Description of problem:
Hi everyone, has anyone encountered an infinite loop issue with DataTables 3.0.1 + ColumnControl 2.0.0 in server-side mode?
The symptoms occur when the table uses ColumnControl with searchDatetime: DataTables continuously re-triggers the Ajax call (the draw count climbs into the hundreds, hitting 6–7 requests per second, with server CPU usage exceeding 90%).
According to Claude:
The cause lies in dataTables.columnControl.mjs (specifically the searchDateTime section):
dt.on('columnTypes', () => { resolveFormats(); searchInput.runSearch(true); });
runSearch(true) acts as a force command → it always re-triggers the search function, even if the filter input hasn't changed.
The server-side branch of the search function concludes with if (!loadingState) dt.draw()
→ this triggers a new Ajax request → once data loads, DataTables recalculates column types → it emits
the columnTypes event → resulting in an infinite loop.
Replies
Hi,
Thanks for the report.
There is another thread on this topic with a fix.
As noted there the nightly has the fix. I'll tag the release next week
.
Allan