Sudheesh, I think you are right. Whenever a query is started, DrillOperatorTable is created again.
This setting has been there for a long time. One "possible" explanation I can think of is for query option. For example, if Decimal type is turned on, the behavior of some functions/ operators could be different. I agree this seems adding some overhead, but maybe there are some other reasons? On Mon, Apr 4, 2016 at 10:23 PM, Sudheesh Katkam <[email protected]> wrote: > Hey y’all, > > It seems an instance of DrillOperatorTable is created per query < > https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_apache_drill_blob_master_exec_java-2Dexec_src_main_java_org_apache_drill_exec_ops_QueryContext.java-23L89&d=CwIFaQ&c=clK7kQUTWtAVEOVIgvi0NU5BOUHhpN0H8p7CSfnc_gI&r=jUnl_PVGM7il9n5EkUTnEA&m=iZWEIm96V0s4T6zVJvwv3Z9sUhwYe7rAlifI8Th88Yw&s=5eJEEd_QfCObl-IeZJrTcKpYQJPxT8LLvCpVMkw_7Xo&e= > >. With type inference changes, this adds to the query startup time (not > part of query time, rather “run query” request handling time). This object > could be initialized once in DrillbitContext, and used across queries. So > is there anything query specific that requires this object to initialized > within QueryContext? > > Thank you, > Sudheesh
