BRANCH 4.2-105: added some hooks to restart every 20 transactions