DRILL-5868: Support SQL syntax highlighting of queries
Based on the commit for DRILL-5981 (PR #1043), this commit further leverages the Ace JavaScript library with customizations specific to Drill.
This commit introduces the following to the Query Editor (including the Edit Query tab within an existing profile to rerunning the query).
1. Syntax highlighting (This is supported for submitted query profiles
2. Autocomplete supported in editors
3. Specifying Drill specific keywords and functions in visible autocomplete
4. Key snippets (template SQLs) allowing for rapid writing of syntax:
i. Query System Tables
ii. CView, CTAS and CTempTAS
iii. Alter Session
iv. Explain and Select * queries
NOTE: The lists for #3 and #4 are not exhaustive. As more features are added to Drill, these lists can be expanded.
Updates based on review comments
1. Disabled warning message
2. Extended reserved keyword list
3. Fixed bugs
List:
Update 1: Bug fix for when Impersonation is enabled
Update 2: Remove the duplicate editor that might get injected
Update 3: Removed trailing whitespaces in Javascripts
close apache/drill#1084