forked from opensearch-project/OpenSearch-Dashboards
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[MQL] support different query languages
Only adds the quick startup for OpenSearch cluster with a SQL plugin and observability with: ``` yarn opensearch snapshot --sql ``` Also, adds SQL to the language selector stolen shamelessly from opensearch-project#5623 Next steps to intercept and send to SQL API or just transform basic syntax to DSL Signed-off-by: Kawika Avilla <kavilla414@gmail.com> Working query enhance Signed-off-by: Kawika Avilla <kavilla414@gmail.com> Reget search enhance Signed-off-by: Kawika Avilla <kavilla414@gmail.com> data frames Signed-off-by: Kawika Avilla <kavilla414@gmail.com> temp state need to pass df Signed-off-by: Kawika Avilla <kavilla414@gmail.com> sending data frame Signed-off-by: Kawika Avilla <kavilla414@gmail.com> gets df type Signed-off-by: Kawika Avilla <kavilla414@gmail.com> add some small ui things Signed-off-by: Kawika Avilla <kavilla414@gmail.com> move back query language switcher Signed-off-by: Kawika Avilla <kavilla414@gmail.com> updating side panel Signed-off-by: Kawika Avilla <kavilla414@gmail.com> add ui config on query enhancement Signed-off-by: Kawika Avilla <kavilla414@gmail.com> support query string input Signed-off-by: Kawika Avilla <kavilla414@gmail.com> update to say search bar Signed-off-by: Kawika Avilla <kavilla414@gmail.com> update ppl to call once Signed-off-by: Kawika Avilla <kavilla414@gmail.com> update when fields update Signed-off-by: Kawika Avilla <kavilla414@gmail.com> add unknown Signed-off-by: Kawika Avilla <kavilla414@gmail.com>
- Loading branch information
Showing
59 changed files
with
1,051 additions
and
164 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
/* | ||
* SPDX-License-Identifier: Apache-2.0 | ||
* | ||
* The OpenSearch Contributors require contributions made to | ||
* this file be licensed under the Apache-2.0 license or a | ||
* compatible open source license. | ||
* | ||
* Any modifications Copyright OpenSearch Contributors. See | ||
* GitHub history for details. | ||
*/ | ||
|
||
import { IDataFrame } from '..'; | ||
|
||
export interface DfCache { | ||
get: () => IDataFrame | undefined; | ||
set: (value: IDataFrame) => IDataFrame; | ||
clear: () => void; | ||
} | ||
|
||
export function createDataFrameCache(): DfCache { | ||
let df: IDataFrame | undefined; | ||
const cache: DfCache = { | ||
get: () => { | ||
return df; | ||
}, | ||
set: (prom: IDataFrame) => { | ||
df = prom; | ||
return prom; | ||
}, | ||
clear: () => { | ||
df = undefined; | ||
}, | ||
}; | ||
return cache; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
/* | ||
* SPDX-License-Identifier: Apache-2.0 | ||
* | ||
* The OpenSearch Contributors require contributions made to | ||
* this file be licensed under the Apache-2.0 license or a | ||
* compatible open source license. | ||
* | ||
* Any modifications Copyright OpenSearch Contributors. See | ||
* GitHub history for details. | ||
*/ | ||
|
||
export * from './types'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
/* | ||
* SPDX-License-Identifier: Apache-2.0 | ||
* | ||
* The OpenSearch Contributors require contributions made to | ||
* this file be licensed under the Apache-2.0 license or a | ||
* compatible open source license. | ||
* | ||
* Any modifications Copyright OpenSearch Contributors. See | ||
* GitHub history for details. | ||
*/ | ||
|
||
export interface IFieldType { | ||
name: string; | ||
type: string; | ||
values: any[]; | ||
count?: number; | ||
aggregatable?: boolean; | ||
filterable?: boolean; | ||
searchable?: boolean; | ||
sortable?: boolean; | ||
visualizable?: boolean; | ||
displayName?: string; | ||
format?: any; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
/* | ||
* SPDX-License-Identifier: Apache-2.0 | ||
* | ||
* The OpenSearch Contributors require contributions made to | ||
* this file be licensed under the Apache-2.0 license or a | ||
* compatible open source license. | ||
* | ||
* Any modifications Copyright OpenSearch Contributors. See | ||
* GitHub history for details. | ||
*/ | ||
|
||
export * from './types'; | ||
export * from './utils'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
/* | ||
* SPDX-License-Identifier: Apache-2.0 | ||
* | ||
* The OpenSearch Contributors require contributions made to | ||
* this file be licensed under the Apache-2.0 license or a | ||
* compatible open source license. | ||
* | ||
* Any modifications Copyright OpenSearch Contributors. See | ||
* GitHub history for details. | ||
*/ | ||
|
||
import { IFieldType } from './fields'; | ||
|
||
export * from './_df_cache'; | ||
|
||
export interface IDataFrame { | ||
name?: string; | ||
schema?: Array<Partial<IFieldType>>; | ||
fields: IFieldType[]; | ||
size: number; | ||
} | ||
|
||
export interface DataFrameAgg { | ||
key: string; | ||
value: number; | ||
} | ||
|
||
export interface PartialDataFrame extends Omit<IDataFrame, 'fields' | 'size'> { | ||
fields: Array<Partial<IFieldType>>; | ||
} | ||
|
||
/** | ||
* To be utilize with aggregations and will map to buckets | ||
* Plugins can get the aggreted value by their own logic | ||
* Setting to null will disable the aggregation if plugin wishes | ||
* In future, if the plugin doesn't intentionally set the value to null, | ||
* we can calculate the value based on the fields. | ||
*/ | ||
export interface IDataFrameWithAggs extends IDataFrame { | ||
aggs: DataFrameAgg[] | null; | ||
} |
Oops, something went wrong.