[master] Made apf more reliable