Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Auto Suggest] DQL autosuggest with ANTLR (opensearch-project#7391)
* Antlr autocomplete (opensearch-project#7159) * dql grammar with rudamentary testing parser Signed-off-by: Paul Sebastian <[email protected]> * show suggestion of fields depending on current index pattern Signed-off-by: Paul Sebastian <[email protected]> * basic code completion with fields populated Signed-off-by: Paul Sebastian <[email protected]> * updated grammar and generated for better group handling Signed-off-by: Paul Sebastian <[email protected]> * add ignored tokens Signed-off-by: Paul Sebastian <[email protected]> * remove console logs Signed-off-by: Paul Sebastian <[email protected]> --------- Signed-off-by: Paul Sebastian <[email protected]> * dql Antlr autocomplete (opensearch-project#7160) * re-add provider for sql Signed-off-by: Paul Sebastian <[email protected]> * added temporary fix for language providor to appear for more than one language Signed-off-by: Paul Sebastian <[email protected]> --------- Signed-off-by: Paul Sebastian <[email protected]> * remove EOF in parser to fix suggestions Signed-off-by: Paul Sebastian <[email protected]> * use custom version of cursor token index for dql Signed-off-by: Paul Sebastian <[email protected]> * implemented value suggestions based on field Signed-off-by: Paul Sebastian <[email protected]> * set param type Signed-off-by: Paul Sebastian <[email protected]> * update grouping grammar Signed-off-by: Paul Sebastian <[email protected]> * fix grammar for dots in field and value term search with spaces Signed-off-by: Paul Sebastian <[email protected]> * value suggestions match field to avoid failing api call and to find assc keyword field Signed-off-by: Paul Sebastian <[email protected]> * update value suggestions from partially formed value Signed-off-by: Paul Sebastian <[email protected]> * refactor value suggestions and change fieldval listener to visitor Signed-off-by: Paul Sebastian <[email protected]> * implement value suggestions within phrases Signed-off-by: Paul Sebastian <[email protected]> * make grammar more readable Signed-off-by: Paul Sebastian <[email protected]> * rename grammar parser rules Signed-off-by: Paul Sebastian <[email protected]> * bring back minimal autocomplete optimized grammar Signed-off-by: Paul Sebastian <[email protected]> * enable partially complete value suggestion for value groups Signed-off-by: Paul Sebastian <[email protected]> * remove number as lexer rule Signed-off-by: Paul Sebastian <[email protected]> * fix cursor import and clean up Signed-off-by: Paul Sebastian <[email protected]> * fix completion item range to be current word Signed-off-by: Paul Sebastian <[email protected]> * update cursor to use monaco position Signed-off-by: Paul Sebastian <[email protected]> * cursor index to use position directly Signed-off-by: Paul Sebastian <[email protected]> * move language registration into render function to handle new languages Signed-off-by: Paul Sebastian <[email protected]> * include auto closing quotes and parenthesis for dql Signed-off-by: Paul Sebastian <[email protected]> * rename generated file Signed-off-by: Paul Sebastian <[email protected]> * Changeset file for PR opensearch-project#7391 created/updated * add license and fix linting Signed-off-by: Paul Sebastian <[email protected]> * modify grammar Signed-off-by: Paul Sebastian <[email protected]> * add tests for fields and keywords Signed-off-by: Paul Sebastian <[email protected]> * move dql test constants to separate file Signed-off-by: Paul Sebastian <[email protected]> * pass core setup from autocomplete constructor to query sugg provider and utilize selectionEnd if no position Signed-off-by: Paul Sebastian <[email protected]> * update an import Signed-off-by: Paul Sebastian <[email protected]> * use updated dataset for index pattern Signed-off-by: Paul Sebastian <[email protected]> * remove console log Signed-off-by: Paul Sebastian <[email protected]> * [Auto Suggest] DQL Updates (opensearch-project#7498) * update code completion to not return for visualize Signed-off-by: Paul Sebastian <[email protected]> * update types to match completionitemkind Signed-off-by: Paul Sebastian <[email protected]> --------- Signed-off-by: Paul Sebastian <[email protected]> * update saved object test flyout snap Signed-off-by: Paul Sebastian <[email protected]> * update tests to match changes Signed-off-by: Paul Sebastian <[email protected]> * updated editor Signed-off-by: Paul Sebastian <[email protected]> * insert colon and space after selecting suggested field Signed-off-by: Paul Sebastian <[email protected]> * fix suggestions after colon without space Signed-off-by: Paul Sebastian <[email protected]> * update test Signed-off-by: Paul Sebastian <[email protected]> * typing update Signed-off-by: Paul Sebastian <[email protected]> * updated dataset name Signed-off-by: Paul Sebastian <[email protected]> * remove connection service based lines and rely on service Signed-off-by: Paul Sebastian <[email protected]> * add debouncer for index pattern calls Signed-off-by: Paul Sebastian <[email protected]> * use index pattern service rather than debounce Signed-off-by: Paul Sebastian <[email protected]> * update mock index for test Signed-off-by: Paul Sebastian <[email protected]> --------- Signed-off-by: Paul Sebastian <[email protected]> Co-authored-by: opensearch-changeset-bot[bot] <154024398+opensearch-changeset-bot[bot]@users.noreply.github.com>
- Loading branch information