Resolve the conflicts and add support for top hash aggregate and local s...

...erial agg
Create a time box ticket to record your comment. ENG-6559
We should be able to optimize more group by queries.