The new layouter implementation once again sent me on the quest for more performance.
I’m sure we all know the three basic principles of performant job execution:
(1) Cache: The best job is the job, where you don’t have to work at all.
(2) Algorithms: If you can’t aviod work, then do it as quick as possible, using the best algorithms available.
(3) Resources: Dont make a mess, while doing your job. You’ll have to clean up afterwards – and that costs time too.
After applying these priciples, the Layouter implementation is now three times faster than before (400 seconds pagination time vs. 120 seconds pagination time with the new layouter for 200.000 rows). However, this is still bad compared to the 75 seconds of the old layouter. But that lazy beast had mastered the art of caching – it avoided almost every real work by using its extensive caches.