Parallelize insert into gmf_agg table

See https://bugs.launchpad.net/oq-engine/+bug/1178054. By parallelizing the INSERT query I got a speedup of 5 times on Cobain. Notice that the implementation uses a simple map_reduce utility. Actually there is a similar utility in our code base (called distribute) but it is never used excepts in its tests so I assume it is experimental code. Should we remove it?