Some cleaning up and added option to enable instrumenting query