type as parameter for gson
moved behaviour from commandHandler to  aggregate