add transaction management
rename
use collections over primitives

Ok, I get array allocations. Now let's use something
nice.