refactor: create new queryopt package to target query plan optimizations
#2970
+588
−639
queryopt package to target query plan optimizations
#2970