I think I solved the problem with bufferjam.