Simplify the collector code. Also allow catching USR1 and USR2 signals