@perses-dev/plugin-system 0.54.0-beta.1 → 0.54.0-beta.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/components/PluginRegistry/PluginRegistry.js +11 -15
- package/dist/cjs/components/PluginRegistry/getPluginSearchHelper.js +92 -0
- package/dist/cjs/components/PluginRegistry/plugin-indexes.js +16 -13
- package/dist/cjs/components/Variables/variable-model.js +115 -29
- package/dist/cjs/context/ValidationProvider.js +3 -3
- package/dist/cjs/model/alerts-queries.js +16 -0
- package/dist/cjs/model/index.js +2 -0
- package/dist/cjs/model/log-volume-utils.js +10 -10
- package/dist/cjs/model/plugin-loading.js +24 -8
- package/dist/cjs/model/plugins.js +10 -0
- package/dist/cjs/model/silences-queries.js +16 -0
- package/dist/cjs/remote/PluginRuntime.js +38 -9
- package/dist/cjs/remote/remotePluginLoader.js +28 -5
- package/dist/cjs/runtime/DataQueriesProvider/DataQueriesProvider.js +18 -2
- package/dist/cjs/runtime/DataQueriesProvider/model.js +30 -4
- package/dist/cjs/runtime/UsageMetricsProvider.js +2 -2
- package/dist/cjs/runtime/alerts-queries.js +101 -0
- package/dist/cjs/runtime/index.js +2 -0
- package/dist/cjs/runtime/item-actions.js +3 -3
- package/dist/cjs/runtime/log-queries.js +4 -1
- package/dist/cjs/runtime/plugin-registry.js +12 -3
- package/dist/cjs/runtime/profile-queries.js +4 -1
- package/dist/cjs/runtime/silences-queries.js +101 -0
- package/dist/cjs/runtime/time-series-queries.js +4 -1
- package/dist/cjs/runtime/trace-queries.js +4 -1
- package/dist/cjs/test/mock-data.js +51 -0
- package/dist/cjs/test/test-plugins/bert/index.js +9 -12
- package/dist/cjs/test/test-plugins/ernie/index.js +9 -12
- package/dist/cjs/test/test-plugins/index.js +2 -2
- package/dist/cjs/test-utils/mock-plugin-registry.js +8 -2
- package/dist/components/CalculationSelector/CalculationSelector.js +1 -1
- package/dist/components/CalculationSelector/CalculationSelector.js.map +1 -1
- package/dist/components/DatasourceEditorForm/DatasourceEditorForm.d.ts +1 -1
- package/dist/components/DatasourceEditorForm/DatasourceEditorForm.d.ts.map +1 -1
- package/dist/components/DatasourceEditorForm/DatasourceEditorForm.js +1 -1
- package/dist/components/DatasourceEditorForm/DatasourceEditorForm.js.map +1 -1
- package/dist/components/DatasourceSelect/DatasourceSelect.js +2 -2
- package/dist/components/DatasourceSelect/DatasourceSelect.js.map +1 -1
- package/dist/components/HTTPSettingsEditor/HTTPSettingsEditor.d.ts +1 -1
- package/dist/components/HTTPSettingsEditor/HTTPSettingsEditor.d.ts.map +1 -1
- package/dist/components/HTTPSettingsEditor/HTTPSettingsEditor.js +1 -1
- package/dist/components/HTTPSettingsEditor/HTTPSettingsEditor.js.map +1 -1
- package/dist/components/ItemSelectionActionsOptionsEditor/ItemSelectionActionsOptionsEditor.js +1 -1
- package/dist/components/ItemSelectionActionsOptionsEditor/ItemSelectionActionsOptionsEditor.js.map +1 -1
- package/dist/components/LegendOptionsEditor/LegendOptionsEditor.js +1 -1
- package/dist/components/LegendOptionsEditor/LegendOptionsEditor.js.map +1 -1
- package/dist/components/MetricLabelInput/MetricLabelInput.js +1 -1
- package/dist/components/MetricLabelInput/MetricLabelInput.js.map +1 -1
- package/dist/components/MultiQueryEditor/MultiQueryEditor.js +1 -1
- package/dist/components/MultiQueryEditor/MultiQueryEditor.js.map +1 -1
- package/dist/components/MultiQueryEditor/QueryEditorContainer.js +1 -1
- package/dist/components/MultiQueryEditor/QueryEditorContainer.js.map +1 -1
- package/dist/components/OptionsEditorRadios/OptionsEditorRadios.js +1 -1
- package/dist/components/OptionsEditorRadios/OptionsEditorRadios.js.map +1 -1
- package/dist/components/OptionsEditorTabPanel/OptionsEditorTabPanel.js +1 -1
- package/dist/components/OptionsEditorTabPanel/OptionsEditorTabPanel.js.map +1 -1
- package/dist/components/OptionsEditorTabs/OptionsEditorTabs.js +1 -1
- package/dist/components/OptionsEditorTabs/OptionsEditorTabs.js.map +1 -1
- package/dist/components/PanelSpecEditor/PanelSpecEditor.js +1 -1
- package/dist/components/PanelSpecEditor/PanelSpecEditor.js.map +1 -1
- package/dist/components/PluginEditor/PluginEditor.js +1 -1
- package/dist/components/PluginEditor/PluginEditor.js.map +1 -1
- package/dist/components/PluginKindSelect/PluginKindSelect.js +1 -1
- package/dist/components/PluginKindSelect/PluginKindSelect.js.map +1 -1
- package/dist/components/PluginRegistry/PluginRegistry.d.ts.map +1 -1
- package/dist/components/PluginRegistry/PluginRegistry.js +12 -16
- package/dist/components/PluginRegistry/PluginRegistry.js.map +1 -1
- package/dist/components/PluginRegistry/getPluginSearchHelper.d.ts +12 -0
- package/dist/components/PluginRegistry/getPluginSearchHelper.d.ts.map +1 -0
- package/dist/components/PluginRegistry/getPluginSearchHelper.js +88 -0
- package/dist/components/PluginRegistry/getPluginSearchHelper.js.map +1 -0
- package/dist/components/PluginRegistry/plugin-indexes.d.ts +4 -6
- package/dist/components/PluginRegistry/plugin-indexes.d.ts.map +1 -1
- package/dist/components/PluginRegistry/plugin-indexes.js +15 -13
- package/dist/components/PluginRegistry/plugin-indexes.js.map +1 -1
- package/dist/components/PluginSpecEditor/PluginSpecEditor.d.ts.map +1 -1
- package/dist/components/PluginSpecEditor/PluginSpecEditor.js +1 -1
- package/dist/components/PluginSpecEditor/PluginSpecEditor.js.map +1 -1
- package/dist/components/SelectionOptionsEditor/SelectionOptionsEditor.js +1 -1
- package/dist/components/SelectionOptionsEditor/SelectionOptionsEditor.js.map +1 -1
- package/dist/components/TimeRangeControls/TimeRangeControls.js +1 -1
- package/dist/components/TimeRangeControls/TimeRangeControls.js.map +1 -1
- package/dist/components/Variables/VariableEditorForm/VariableEditorForm.js +1 -1
- package/dist/components/Variables/VariableEditorForm/VariableEditorForm.js.map +1 -1
- package/dist/components/Variables/VariableEditorForm/VariablePreview.js +1 -1
- package/dist/components/Variables/VariableEditorForm/VariablePreview.js.map +1 -1
- package/dist/components/Variables/variable-model.d.ts +9 -1
- package/dist/components/Variables/variable-model.d.ts.map +1 -1
- package/dist/components/Variables/variable-model.js +117 -31
- package/dist/components/Variables/variable-model.js.map +1 -1
- package/dist/context/ValidationProvider.d.ts +1 -1
- package/dist/context/ValidationProvider.d.ts.map +1 -1
- package/dist/context/ValidationProvider.js +2 -2
- package/dist/context/ValidationProvider.js.map +1 -1
- package/dist/model/alerts-queries.d.ts +33 -0
- package/dist/model/alerts-queries.d.ts.map +1 -0
- package/dist/model/alerts-queries.js +15 -0
- package/dist/model/alerts-queries.js.map +1 -0
- package/dist/model/datasource.d.ts +1 -8
- package/dist/model/datasource.d.ts.map +1 -1
- package/dist/model/datasource.js +1 -1
- package/dist/model/datasource.js.map +1 -1
- package/dist/model/index.d.ts +2 -0
- package/dist/model/index.d.ts.map +1 -1
- package/dist/model/index.js +2 -0
- package/dist/model/index.js.map +1 -1
- package/dist/model/plugin-loading.d.ts.map +1 -1
- package/dist/model/plugin-loading.js +24 -8
- package/dist/model/plugin-loading.js.map +1 -1
- package/dist/model/plugins.d.ts +21 -0
- package/dist/model/plugins.d.ts.map +1 -1
- package/dist/model/plugins.js +4 -1
- package/dist/model/plugins.js.map +1 -1
- package/dist/model/silences-queries.d.ts +33 -0
- package/dist/model/silences-queries.d.ts.map +1 -0
- package/dist/model/silences-queries.js +15 -0
- package/dist/model/silences-queries.js.map +1 -0
- package/dist/remote/PersesPlugin.types.d.ts +2 -0
- package/dist/remote/PersesPlugin.types.d.ts.map +1 -1
- package/dist/remote/PersesPlugin.types.js.map +1 -1
- package/dist/remote/PluginLoaderComponent.js +1 -1
- package/dist/remote/PluginLoaderComponent.js.map +1 -1
- package/dist/remote/PluginRuntime.d.ts +7 -1
- package/dist/remote/PluginRuntime.d.ts.map +1 -1
- package/dist/remote/PluginRuntime.js +38 -9
- package/dist/remote/PluginRuntime.js.map +1 -1
- package/dist/remote/remotePluginLoader.d.ts.map +1 -1
- package/dist/remote/remotePluginLoader.js +28 -5
- package/dist/remote/remotePluginLoader.js.map +1 -1
- package/dist/runtime/DataQueriesProvider/DataQueriesProvider.d.ts.map +1 -1
- package/dist/runtime/DataQueriesProvider/DataQueriesProvider.js +19 -3
- package/dist/runtime/DataQueriesProvider/DataQueriesProvider.js.map +1 -1
- package/dist/runtime/DataQueriesProvider/model.d.ts.map +1 -1
- package/dist/runtime/DataQueriesProvider/model.js +30 -4
- package/dist/runtime/DataQueriesProvider/model.js.map +1 -1
- package/dist/runtime/QueryCountProvider.js +1 -1
- package/dist/runtime/QueryCountProvider.js.map +1 -1
- package/dist/runtime/RouterProvider.js +1 -1
- package/dist/runtime/RouterProvider.js.map +1 -1
- package/dist/runtime/TimeRangeProvider/TimeRangeProvider.js +1 -1
- package/dist/runtime/TimeRangeProvider/TimeRangeProvider.js.map +1 -1
- package/dist/runtime/TimeRangeProvider/TimeRangeSettingsProvider.js +1 -1
- package/dist/runtime/TimeRangeProvider/TimeRangeSettingsProvider.js.map +1 -1
- package/dist/runtime/UsageMetricsProvider.js +2 -2
- package/dist/runtime/UsageMetricsProvider.js.map +1 -1
- package/dist/runtime/alerts-queries.d.ts +11 -0
- package/dist/runtime/alerts-queries.d.ts.map +1 -0
- package/dist/runtime/alerts-queries.js +89 -0
- package/dist/runtime/alerts-queries.js.map +1 -0
- package/dist/runtime/index.d.ts +2 -0
- package/dist/runtime/index.d.ts.map +1 -1
- package/dist/runtime/index.js +2 -0
- package/dist/runtime/index.js.map +1 -1
- package/dist/runtime/item-actions.js +1 -1
- package/dist/runtime/item-actions.js.map +1 -1
- package/dist/runtime/log-queries.js +4 -1
- package/dist/runtime/log-queries.js.map +1 -1
- package/dist/runtime/plugin-registry.d.ts +2 -1
- package/dist/runtime/plugin-registry.d.ts.map +1 -1
- package/dist/runtime/plugin-registry.js +12 -3
- package/dist/runtime/plugin-registry.js.map +1 -1
- package/dist/runtime/profile-queries.js +4 -1
- package/dist/runtime/profile-queries.js.map +1 -1
- package/dist/runtime/silences-queries.d.ts +11 -0
- package/dist/runtime/silences-queries.d.ts.map +1 -0
- package/dist/runtime/silences-queries.js +89 -0
- package/dist/runtime/silences-queries.js.map +1 -0
- package/dist/runtime/time-series-queries.js +4 -1
- package/dist/runtime/time-series-queries.js.map +1 -1
- package/dist/runtime/trace-queries.js +4 -1
- package/dist/runtime/trace-queries.js.map +1 -1
- package/dist/test/mock-data.d.ts +3 -1
- package/dist/test/mock-data.d.ts.map +1 -1
- package/dist/test/mock-data.js +45 -0
- package/dist/test/mock-data.js.map +1 -1
- package/dist/test/render.js +1 -1
- package/dist/test/render.js.map +1 -1
- package/dist/test/test-plugins/bert/index.d.ts +12 -6
- package/dist/test/test-plugins/bert/index.d.ts.map +1 -1
- package/dist/test/test-plugins/bert/index.js +6 -2
- package/dist/test/test-plugins/bert/index.js.map +1 -1
- package/dist/test/test-plugins/ernie/index.d.ts +8 -6
- package/dist/test/test-plugins/ernie/index.d.ts.map +1 -1
- package/dist/test/test-plugins/ernie/index.js +6 -2
- package/dist/test/test-plugins/ernie/index.js.map +1 -1
- package/dist/test/test-plugins/index.js +2 -2
- package/dist/test/test-plugins/index.js.map +1 -1
- package/dist/test/utils.js +1 -1
- package/dist/test/utils.js.map +1 -1
- package/dist/test-utils/mock-plugin-registry.d.ts.map +1 -1
- package/dist/test-utils/mock-plugin-registry.js +8 -2
- package/dist/test-utils/mock-plugin-registry.js.map +1 -1
- package/package.json +6 -5
|
@@ -20,6 +20,7 @@ Object.defineProperty(exports, "remotePluginLoader", {
|
|
|
20
20
|
return remotePluginLoader;
|
|
21
21
|
}
|
|
22
22
|
});
|
|
23
|
+
const _pluginsystem = require("@perses-dev/plugin-system");
|
|
23
24
|
const _PluginRuntime = require("./PluginRuntime");
|
|
24
25
|
const isPluginMetadata = (plugin)=>{
|
|
25
26
|
return typeof plugin === 'object' && plugin !== null && 'kind' in plugin && 'spec' in plugin && typeof plugin.spec === 'object' && plugin.spec !== null && 'name' in plugin.spec;
|
|
@@ -59,17 +60,39 @@ function remotePluginLoader(options) {
|
|
|
59
60
|
return pluginModules;
|
|
60
61
|
},
|
|
61
62
|
importPluginModule: async (resource)=>{
|
|
62
|
-
const pluginModuleName = resource.metadata
|
|
63
|
+
const { name: pluginModuleName, version, registry } = resource.metadata;
|
|
63
64
|
const pluginModule = {};
|
|
64
|
-
|
|
65
|
-
const remotePluginModule = await (0, _PluginRuntime.loadPlugin)(
|
|
65
|
+
const loadPromises = resource.spec.plugins.map(async (plugin)=>{
|
|
66
|
+
const remotePluginModule = await (0, _PluginRuntime.loadPlugin)({
|
|
67
|
+
moduleName: pluginModuleName,
|
|
68
|
+
pluginName: plugin.spec.name,
|
|
69
|
+
registry,
|
|
70
|
+
version,
|
|
71
|
+
baseURL: pluginsAssetsPath
|
|
72
|
+
});
|
|
66
73
|
const remotePlugin = remotePluginModule?.[plugin.spec.name];
|
|
67
74
|
if (remotePlugin) {
|
|
68
|
-
|
|
75
|
+
return {
|
|
76
|
+
kind: plugin.kind,
|
|
77
|
+
name: plugin.spec.name,
|
|
78
|
+
remotePlugin
|
|
79
|
+
};
|
|
69
80
|
} else {
|
|
70
81
|
console.error(`RemotePluginLoader: Error loading plugin ${plugin.spec.name}`);
|
|
82
|
+
return null;
|
|
71
83
|
}
|
|
72
|
-
}
|
|
84
|
+
});
|
|
85
|
+
const loadedPlugins = await Promise.all(loadPromises);
|
|
86
|
+
loadedPlugins.forEach((item)=>{
|
|
87
|
+
if (item?.remotePlugin) {
|
|
88
|
+
pluginModule[(0, _pluginsystem.getPluginModuleCompoundKey)({
|
|
89
|
+
kind: item.kind,
|
|
90
|
+
name: item.name,
|
|
91
|
+
registry,
|
|
92
|
+
version
|
|
93
|
+
})] = item.remotePlugin;
|
|
94
|
+
}
|
|
95
|
+
});
|
|
73
96
|
return pluginModule;
|
|
74
97
|
}
|
|
75
98
|
};
|
|
@@ -39,6 +39,8 @@ const _react = require("react");
|
|
|
39
39
|
const _timeseriesqueries = require("../time-series-queries");
|
|
40
40
|
const _tracequeries = require("../trace-queries");
|
|
41
41
|
const _profilequeries = require("../profile-queries");
|
|
42
|
+
const _alertsqueries = require("../alerts-queries");
|
|
43
|
+
const _silencesqueries = require("../silences-queries");
|
|
42
44
|
const _UsageMetricsProvider = require("../UsageMetricsProvider");
|
|
43
45
|
const _logqueries = require("../log-queries");
|
|
44
46
|
const _model = require("./model");
|
|
@@ -89,23 +91,33 @@ function DataQueriesProvider(props) {
|
|
|
89
91
|
const profileResults = (0, _profilequeries.useProfileQueries)(profileQueries);
|
|
90
92
|
const logQueries = queryDefinitions.filter((definition)=>definition.kind === 'LogQuery');
|
|
91
93
|
const logResults = (0, _logqueries.useLogQueries)(logQueries);
|
|
94
|
+
const alertsQueries = queryDefinitions.filter((definition)=>definition.kind === 'AlertsQuery');
|
|
95
|
+
const alertsResults = (0, _alertsqueries.useAlertsQueries)(alertsQueries);
|
|
96
|
+
const silencesQueries = queryDefinitions.filter((definition)=>definition.kind === 'SilencesQuery');
|
|
97
|
+
const silencesResults = (0, _silencesqueries.useSilencesQueries)(silencesQueries);
|
|
92
98
|
const refetchAll = (0, _react.useCallback)(()=>{
|
|
93
99
|
timeSeriesResults.forEach((result)=>result.refetch());
|
|
94
100
|
traceResults.forEach((result)=>result.refetch());
|
|
95
101
|
profileResults.forEach((result)=>result.refetch());
|
|
96
102
|
logResults.forEach((result)=>result.refetch());
|
|
103
|
+
alertsResults.forEach((result)=>result.refetch());
|
|
104
|
+
silencesResults.forEach((result)=>result.refetch());
|
|
97
105
|
}, [
|
|
98
106
|
timeSeriesResults,
|
|
99
107
|
traceResults,
|
|
100
108
|
profileResults,
|
|
101
|
-
logResults
|
|
109
|
+
logResults,
|
|
110
|
+
alertsResults,
|
|
111
|
+
silencesResults
|
|
102
112
|
]);
|
|
103
113
|
const ctx = (0, _react.useMemo)(()=>{
|
|
104
114
|
const mergedQueryResults = [
|
|
105
115
|
...(0, _model.transformQueryResults)(timeSeriesResults, timeSeriesQueries),
|
|
106
116
|
...(0, _model.transformQueryResults)(traceResults, traceQueries),
|
|
107
117
|
...(0, _model.transformQueryResults)(profileResults, profileQueries),
|
|
108
|
-
...(0, _model.transformQueryResults)(logResults, logQueries)
|
|
118
|
+
...(0, _model.transformQueryResults)(logResults, logQueries),
|
|
119
|
+
...(0, _model.transformQueryResults)(alertsResults, alertsQueries),
|
|
120
|
+
...(0, _model.transformQueryResults)(silencesResults, silencesQueries)
|
|
109
121
|
];
|
|
110
122
|
if (queryOptions?.enabled) {
|
|
111
123
|
for (const result of mergedQueryResults){
|
|
@@ -134,6 +146,10 @@ function DataQueriesProvider(props) {
|
|
|
134
146
|
profileResults,
|
|
135
147
|
logQueries,
|
|
136
148
|
logResults,
|
|
149
|
+
alertsQueries,
|
|
150
|
+
alertsResults,
|
|
151
|
+
silencesQueries,
|
|
152
|
+
silencesResults,
|
|
137
153
|
refetchAll,
|
|
138
154
|
queryOptions?.enabled,
|
|
139
155
|
usageMetrics
|
|
@@ -55,13 +55,21 @@ function useQueryType() {
|
|
|
55
55
|
const { data: logQueries, isLoading: isLogQueryPluginLoading } = (0, _pluginregistry.useListPluginMetadata)([
|
|
56
56
|
'LogQuery'
|
|
57
57
|
]);
|
|
58
|
+
const { data: alertsQueryPlugins, isLoading: isAlertsQueryPluginLoading } = (0, _pluginregistry.useListPluginMetadata)([
|
|
59
|
+
'AlertsQuery'
|
|
60
|
+
]);
|
|
61
|
+
const { data: silencesQueryPlugins, isLoading: isSilencesQueryPluginLoading } = (0, _pluginregistry.useListPluginMetadata)([
|
|
62
|
+
'SilencesQuery'
|
|
63
|
+
]);
|
|
58
64
|
// For example, `map: {"TimeSeriesQuery":["PrometheusTimeSeriesQuery"],"TraceQuery":["TempoTraceQuery"]}`
|
|
59
65
|
const queryTypeMap = (0, _react.useMemo)(()=>{
|
|
60
66
|
const map = {
|
|
61
67
|
TimeSeriesQuery: [],
|
|
62
68
|
TraceQuery: [],
|
|
63
69
|
ProfileQuery: [],
|
|
64
|
-
LogQuery: []
|
|
70
|
+
LogQuery: [],
|
|
71
|
+
AlertsQuery: [],
|
|
72
|
+
SilencesQuery: []
|
|
65
73
|
};
|
|
66
74
|
if (timeSeriesQueryPlugins) {
|
|
67
75
|
timeSeriesQueryPlugins.forEach((plugin)=>{
|
|
@@ -83,12 +91,24 @@ function useQueryType() {
|
|
|
83
91
|
map[plugin.kind]?.push(plugin.spec.name);
|
|
84
92
|
});
|
|
85
93
|
}
|
|
94
|
+
if (alertsQueryPlugins) {
|
|
95
|
+
alertsQueryPlugins.forEach((plugin)=>{
|
|
96
|
+
map[plugin.kind]?.push(plugin.spec.name);
|
|
97
|
+
});
|
|
98
|
+
}
|
|
99
|
+
if (silencesQueryPlugins) {
|
|
100
|
+
silencesQueryPlugins.forEach((plugin)=>{
|
|
101
|
+
map[plugin.kind]?.push(plugin.spec.name);
|
|
102
|
+
});
|
|
103
|
+
}
|
|
86
104
|
return map;
|
|
87
105
|
}, [
|
|
88
106
|
timeSeriesQueryPlugins,
|
|
89
107
|
traceQueryPlugins,
|
|
90
108
|
profileQueryPlugins,
|
|
91
|
-
logQueries
|
|
109
|
+
logQueries,
|
|
110
|
+
alertsQueryPlugins,
|
|
111
|
+
silencesQueryPlugins
|
|
92
112
|
]);
|
|
93
113
|
const getQueryType = (0, _react.useCallback)((pluginKind)=>{
|
|
94
114
|
const isLoading = (pluginKind)=>{
|
|
@@ -101,8 +121,12 @@ function useQueryType() {
|
|
|
101
121
|
return isProfileQueryPluginLoading;
|
|
102
122
|
case 'LokiLogQuery':
|
|
103
123
|
return isLogQueryPluginLoading;
|
|
124
|
+
case 'AlertmanagerAlertsQuery':
|
|
125
|
+
return isAlertsQueryPluginLoading;
|
|
126
|
+
case 'AlertmanagerSilencesQuery':
|
|
127
|
+
return isSilencesQueryPluginLoading;
|
|
104
128
|
}
|
|
105
|
-
return isTraceQueryPluginLoading || isTimeSeriesQueryLoading || isProfileQueryPluginLoading || isLogQueryPluginLoading;
|
|
129
|
+
return isTraceQueryPluginLoading || isTimeSeriesQueryLoading || isProfileQueryPluginLoading || isLogQueryPluginLoading || isAlertsQueryPluginLoading || isSilencesQueryPluginLoading;
|
|
106
130
|
};
|
|
107
131
|
if (isLoading(pluginKind)) {
|
|
108
132
|
return undefined;
|
|
@@ -118,7 +142,9 @@ function useQueryType() {
|
|
|
118
142
|
isTimeSeriesQueryLoading,
|
|
119
143
|
isTraceQueryPluginLoading,
|
|
120
144
|
isProfileQueryPluginLoading,
|
|
121
|
-
isLogQueryPluginLoading
|
|
145
|
+
isLogQueryPluginLoading,
|
|
146
|
+
isAlertsQueryPluginLoading,
|
|
147
|
+
isSilencesQueryPluginLoading
|
|
122
148
|
]);
|
|
123
149
|
return getQueryType;
|
|
124
150
|
}
|
|
@@ -35,7 +35,7 @@ _export(exports, {
|
|
|
35
35
|
}
|
|
36
36
|
});
|
|
37
37
|
const _jsxruntime = require("react/jsx-runtime");
|
|
38
|
-
const
|
|
38
|
+
const _client = require("@perses-dev/client");
|
|
39
39
|
const _react = require("react");
|
|
40
40
|
const UsageMetricsContext = /*#__PURE__*/ (0, _react.createContext)(undefined);
|
|
41
41
|
const useUsageMetricsContext = ()=>{
|
|
@@ -70,7 +70,7 @@ const useUsageMetrics = ()=>{
|
|
|
70
70
|
};
|
|
71
71
|
};
|
|
72
72
|
const submitMetrics = async (stats)=>{
|
|
73
|
-
await (0,
|
|
73
|
+
await (0, _client.fetch)(`${stats.apiPrefix ?? ''}/api/v1/view`, {
|
|
74
74
|
method: 'POST',
|
|
75
75
|
headers: {
|
|
76
76
|
'Content-Type': 'application/json'
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
// Copyright The Perses Authors
|
|
2
|
+
// Licensed under the Apache License, Version 2.0 (the "License");
|
|
3
|
+
// you may not use this file except in compliance with the License.
|
|
4
|
+
// You may obtain a copy of the License at
|
|
5
|
+
//
|
|
6
|
+
// http://www.apache.org/licenses/LICENSE-2.0
|
|
7
|
+
//
|
|
8
|
+
// Unless required by applicable law or agreed to in writing, software
|
|
9
|
+
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
10
|
+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11
|
+
// See the License for the specific language governing permissions and
|
|
12
|
+
// limitations under the License.
|
|
13
|
+
"use strict";
|
|
14
|
+
Object.defineProperty(exports, "__esModule", {
|
|
15
|
+
value: true
|
|
16
|
+
});
|
|
17
|
+
function _export(target, all) {
|
|
18
|
+
for(var name in all)Object.defineProperty(target, name, {
|
|
19
|
+
enumerable: true,
|
|
20
|
+
get: Object.getOwnPropertyDescriptor(all, name).get
|
|
21
|
+
});
|
|
22
|
+
}
|
|
23
|
+
_export(exports, {
|
|
24
|
+
get ALERTS_QUERY_KEY () {
|
|
25
|
+
return ALERTS_QUERY_KEY;
|
|
26
|
+
},
|
|
27
|
+
get useAlertsQueries () {
|
|
28
|
+
return useAlertsQueries;
|
|
29
|
+
}
|
|
30
|
+
});
|
|
31
|
+
const _reactquery = require("@tanstack/react-query");
|
|
32
|
+
const _datasources = require("./datasources");
|
|
33
|
+
const _pluginregistry = require("./plugin-registry");
|
|
34
|
+
const _variables = require("./variables");
|
|
35
|
+
const _utils = require("./utils");
|
|
36
|
+
const ALERTS_QUERY_KEY = 'AlertsQuery';
|
|
37
|
+
function useAlertsQueries(definitions) {
|
|
38
|
+
const { getPlugin } = (0, _pluginregistry.usePluginRegistry)();
|
|
39
|
+
const context = useAlertsQueryContext();
|
|
40
|
+
const pluginLoaderResponse = (0, _pluginregistry.usePlugins)('AlertsQuery', definitions.map((d)=>({
|
|
41
|
+
kind: d.spec.plugin.kind
|
|
42
|
+
})));
|
|
43
|
+
return (0, _reactquery.useQueries)({
|
|
44
|
+
queries: definitions.map((definition, idx)=>{
|
|
45
|
+
const plugin = pluginLoaderResponse[idx]?.data;
|
|
46
|
+
const { queryEnabled, queryKey } = getQueryOptions({
|
|
47
|
+
context,
|
|
48
|
+
definition,
|
|
49
|
+
plugin
|
|
50
|
+
});
|
|
51
|
+
const alertsQueryKind = definition?.spec?.plugin?.kind;
|
|
52
|
+
return {
|
|
53
|
+
enabled: queryEnabled,
|
|
54
|
+
queryKey: queryKey,
|
|
55
|
+
refetchOnMount: false,
|
|
56
|
+
refetchOnWindowFocus: false,
|
|
57
|
+
refetchOnReconnect: false,
|
|
58
|
+
staleTime: 60_000,
|
|
59
|
+
queryFn: async ({ signal })=>{
|
|
60
|
+
const plugin = await getPlugin({
|
|
61
|
+
kind: ALERTS_QUERY_KEY,
|
|
62
|
+
name: alertsQueryKind
|
|
63
|
+
});
|
|
64
|
+
const data = await plugin.getAlertsData(definition.spec.plugin.spec, context, signal);
|
|
65
|
+
return data;
|
|
66
|
+
}
|
|
67
|
+
};
|
|
68
|
+
})
|
|
69
|
+
});
|
|
70
|
+
}
|
|
71
|
+
function getQueryOptions({ plugin, definition, context }) {
|
|
72
|
+
const { variableState } = context;
|
|
73
|
+
const dependencies = plugin?.dependsOn ? plugin.dependsOn(definition.spec.plugin.spec, context) : {};
|
|
74
|
+
const variableDependencies = dependencies?.variables;
|
|
75
|
+
const filteredVariabledState = (0, _utils.filterVariableStateMap)(variableState, variableDependencies);
|
|
76
|
+
const variablesValueKey = (0, _utils.getVariableValuesKey)(filteredVariabledState);
|
|
77
|
+
// Note: no absoluteTimeRange in query key since alerts are current state
|
|
78
|
+
const queryKey = [
|
|
79
|
+
'query',
|
|
80
|
+
ALERTS_QUERY_KEY,
|
|
81
|
+
definition,
|
|
82
|
+
variablesValueKey
|
|
83
|
+
];
|
|
84
|
+
let waitToLoad = false;
|
|
85
|
+
if (variableDependencies) {
|
|
86
|
+
waitToLoad = variableDependencies.some((v)=>variableState[v]?.loading);
|
|
87
|
+
}
|
|
88
|
+
const queryEnabled = plugin !== undefined && !waitToLoad;
|
|
89
|
+
return {
|
|
90
|
+
queryKey,
|
|
91
|
+
queryEnabled
|
|
92
|
+
};
|
|
93
|
+
}
|
|
94
|
+
function useAlertsQueryContext() {
|
|
95
|
+
const variableState = (0, _variables.useAllVariableValues)();
|
|
96
|
+
const datasourceStore = (0, _datasources.useDatasourceStore)();
|
|
97
|
+
return {
|
|
98
|
+
variableState,
|
|
99
|
+
datasourceStore
|
|
100
|
+
};
|
|
101
|
+
}
|
|
@@ -22,6 +22,8 @@ _export_star(require("./TimeRangeProvider"), exports);
|
|
|
22
22
|
_export_star(require("./time-series-queries"), exports);
|
|
23
23
|
_export_star(require("./trace-queries"), exports);
|
|
24
24
|
_export_star(require("./profile-queries"), exports);
|
|
25
|
+
_export_star(require("./alerts-queries"), exports);
|
|
26
|
+
_export_star(require("./silences-queries"), exports);
|
|
25
27
|
_export_star(require("./item-actions"), exports);
|
|
26
28
|
_export_star(require("./DataQueriesProvider"), exports);
|
|
27
29
|
_export_star(require("./QueryCountProvider"), exports);
|
|
@@ -21,7 +21,7 @@ Object.defineProperty(exports, "executeAction", {
|
|
|
21
21
|
}
|
|
22
22
|
});
|
|
23
23
|
const _components = require("@perses-dev/components");
|
|
24
|
-
const
|
|
24
|
+
const _client = require("@perses-dev/client");
|
|
25
25
|
const BODY_METHODS = new Set([
|
|
26
26
|
'POST',
|
|
27
27
|
'PUT',
|
|
@@ -174,7 +174,7 @@ function buildWebhookHeaders(action) {
|
|
|
174
174
|
body = bodyResult.text;
|
|
175
175
|
}
|
|
176
176
|
// Make the request
|
|
177
|
-
const response = await (0,
|
|
177
|
+
const response = await (0, _client.fetch)(urlResult.text, {
|
|
178
178
|
method: action.method,
|
|
179
179
|
headers: buildWebhookHeaders(action),
|
|
180
180
|
body: body
|
|
@@ -239,7 +239,7 @@ function buildWebhookHeaders(action) {
|
|
|
239
239
|
body = bodyResult.text;
|
|
240
240
|
}
|
|
241
241
|
// Make the request
|
|
242
|
-
const response = await (0,
|
|
242
|
+
const response = await (0, _client.fetch)(urlResult.text, {
|
|
243
243
|
method: action.method,
|
|
244
244
|
headers: buildWebhookHeaders(action),
|
|
245
245
|
body: body
|
|
@@ -62,7 +62,10 @@ function useLogQueries(definitions) {
|
|
|
62
62
|
refetchOnReconnect: false,
|
|
63
63
|
staleTime: Infinity,
|
|
64
64
|
queryFn: async ({ signal })=>{
|
|
65
|
-
const plugin = await getPlugin(
|
|
65
|
+
const plugin = await getPlugin({
|
|
66
|
+
kind: LOG_QUERY_KEY,
|
|
67
|
+
name: logQueryKind
|
|
68
|
+
});
|
|
66
69
|
const data = await plugin.getLogData(definition.spec.plugin.spec, context, signal);
|
|
67
70
|
return data;
|
|
68
71
|
},
|
|
@@ -63,7 +63,10 @@ function usePlugin(pluginType, kind, options) {
|
|
|
63
63
|
pluginType,
|
|
64
64
|
kind
|
|
65
65
|
],
|
|
66
|
-
queryFn: ()=>getPlugin(
|
|
66
|
+
queryFn: ()=>getPlugin({
|
|
67
|
+
kind: pluginType,
|
|
68
|
+
name: kind
|
|
69
|
+
}),
|
|
67
70
|
...options
|
|
68
71
|
});
|
|
69
72
|
}
|
|
@@ -84,7 +87,10 @@ function usePlugins(pluginType, plugins) {
|
|
|
84
87
|
pluginType,
|
|
85
88
|
kind
|
|
86
89
|
],
|
|
87
|
-
queryFn: ()=>getPlugin(
|
|
90
|
+
queryFn: ()=>getPlugin({
|
|
91
|
+
kind: pluginType,
|
|
92
|
+
name: kind
|
|
93
|
+
})
|
|
88
94
|
};
|
|
89
95
|
})
|
|
90
96
|
});
|
|
@@ -115,7 +121,10 @@ function usePluginBuiltinVariableDefinitions() {
|
|
|
115
121
|
const datasourceNames = new Set(datasources.map((datasource)=>datasource.spec.name));
|
|
116
122
|
const result = [];
|
|
117
123
|
for (const name of datasourceNames){
|
|
118
|
-
const plugin = await getPlugin(
|
|
124
|
+
const plugin = await getPlugin({
|
|
125
|
+
kind: 'Datasource',
|
|
126
|
+
name
|
|
127
|
+
});
|
|
119
128
|
if (plugin.getBuiltinVariableDefinitions) {
|
|
120
129
|
plugin.getBuiltinVariableDefinitions().forEach((definition)=>result.push(definition));
|
|
121
130
|
}
|
|
@@ -59,7 +59,10 @@ function useProfileQueries(definitions) {
|
|
|
59
59
|
refetchOnReconnect: false,
|
|
60
60
|
staleTime: Infinity,
|
|
61
61
|
queryFn: async ({ signal })=>{
|
|
62
|
-
const plugin = await getPlugin(
|
|
62
|
+
const plugin = await getPlugin({
|
|
63
|
+
kind: PROFILE_QUERY_KEY,
|
|
64
|
+
name: profileQueryKind
|
|
65
|
+
});
|
|
63
66
|
const data = await plugin.getProfileData(definition.spec.plugin.spec, context, signal);
|
|
64
67
|
return data;
|
|
65
68
|
},
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
// Copyright The Perses Authors
|
|
2
|
+
// Licensed under the Apache License, Version 2.0 (the "License");
|
|
3
|
+
// you may not use this file except in compliance with the License.
|
|
4
|
+
// You may obtain a copy of the License at
|
|
5
|
+
//
|
|
6
|
+
// http://www.apache.org/licenses/LICENSE-2.0
|
|
7
|
+
//
|
|
8
|
+
// Unless required by applicable law or agreed to in writing, software
|
|
9
|
+
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
10
|
+
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
11
|
+
// See the License for the specific language governing permissions and
|
|
12
|
+
// limitations under the License.
|
|
13
|
+
"use strict";
|
|
14
|
+
Object.defineProperty(exports, "__esModule", {
|
|
15
|
+
value: true
|
|
16
|
+
});
|
|
17
|
+
function _export(target, all) {
|
|
18
|
+
for(var name in all)Object.defineProperty(target, name, {
|
|
19
|
+
enumerable: true,
|
|
20
|
+
get: Object.getOwnPropertyDescriptor(all, name).get
|
|
21
|
+
});
|
|
22
|
+
}
|
|
23
|
+
_export(exports, {
|
|
24
|
+
get SILENCES_QUERY_KEY () {
|
|
25
|
+
return SILENCES_QUERY_KEY;
|
|
26
|
+
},
|
|
27
|
+
get useSilencesQueries () {
|
|
28
|
+
return useSilencesQueries;
|
|
29
|
+
}
|
|
30
|
+
});
|
|
31
|
+
const _reactquery = require("@tanstack/react-query");
|
|
32
|
+
const _datasources = require("./datasources");
|
|
33
|
+
const _pluginregistry = require("./plugin-registry");
|
|
34
|
+
const _variables = require("./variables");
|
|
35
|
+
const _utils = require("./utils");
|
|
36
|
+
const SILENCES_QUERY_KEY = 'SilencesQuery';
|
|
37
|
+
function useSilencesQueries(definitions) {
|
|
38
|
+
const { getPlugin } = (0, _pluginregistry.usePluginRegistry)();
|
|
39
|
+
const context = useSilencesQueryContext();
|
|
40
|
+
const pluginLoaderResponse = (0, _pluginregistry.usePlugins)('SilencesQuery', definitions.map((d)=>({
|
|
41
|
+
kind: d.spec.plugin.kind
|
|
42
|
+
})));
|
|
43
|
+
return (0, _reactquery.useQueries)({
|
|
44
|
+
queries: definitions.map((definition, idx)=>{
|
|
45
|
+
const plugin = pluginLoaderResponse[idx]?.data;
|
|
46
|
+
const { queryEnabled, queryKey } = getQueryOptions({
|
|
47
|
+
context,
|
|
48
|
+
definition,
|
|
49
|
+
plugin
|
|
50
|
+
});
|
|
51
|
+
const silencesQueryKind = definition?.spec?.plugin?.kind;
|
|
52
|
+
return {
|
|
53
|
+
enabled: queryEnabled,
|
|
54
|
+
queryKey: queryKey,
|
|
55
|
+
refetchOnMount: false,
|
|
56
|
+
refetchOnWindowFocus: false,
|
|
57
|
+
refetchOnReconnect: false,
|
|
58
|
+
staleTime: 60_000,
|
|
59
|
+
queryFn: async ({ signal })=>{
|
|
60
|
+
const plugin = await getPlugin({
|
|
61
|
+
kind: SILENCES_QUERY_KEY,
|
|
62
|
+
name: silencesQueryKind
|
|
63
|
+
});
|
|
64
|
+
const data = await plugin.getSilencesData(definition.spec.plugin.spec, context, signal);
|
|
65
|
+
return data;
|
|
66
|
+
}
|
|
67
|
+
};
|
|
68
|
+
})
|
|
69
|
+
});
|
|
70
|
+
}
|
|
71
|
+
function getQueryOptions({ plugin, definition, context }) {
|
|
72
|
+
const { variableState } = context;
|
|
73
|
+
const dependencies = plugin?.dependsOn ? plugin.dependsOn(definition.spec.plugin.spec, context) : {};
|
|
74
|
+
const variableDependencies = dependencies?.variables;
|
|
75
|
+
const filteredVariabledState = (0, _utils.filterVariableStateMap)(variableState, variableDependencies);
|
|
76
|
+
const variablesValueKey = (0, _utils.getVariableValuesKey)(filteredVariabledState);
|
|
77
|
+
// Note: no absoluteTimeRange in query key since silences are current state
|
|
78
|
+
const queryKey = [
|
|
79
|
+
'query',
|
|
80
|
+
SILENCES_QUERY_KEY,
|
|
81
|
+
definition,
|
|
82
|
+
variablesValueKey
|
|
83
|
+
];
|
|
84
|
+
let waitToLoad = false;
|
|
85
|
+
if (variableDependencies) {
|
|
86
|
+
waitToLoad = variableDependencies.some((v)=>variableState[v]?.loading);
|
|
87
|
+
}
|
|
88
|
+
const queryEnabled = plugin !== undefined && !waitToLoad;
|
|
89
|
+
return {
|
|
90
|
+
queryKey,
|
|
91
|
+
queryEnabled
|
|
92
|
+
};
|
|
93
|
+
}
|
|
94
|
+
function useSilencesQueryContext() {
|
|
95
|
+
const variableState = (0, _variables.useAllVariableValues)();
|
|
96
|
+
const datasourceStore = (0, _datasources.useDatasourceStore)();
|
|
97
|
+
return {
|
|
98
|
+
variableState,
|
|
99
|
+
datasourceStore
|
|
100
|
+
};
|
|
101
|
+
}
|
|
@@ -123,7 +123,10 @@ function useTimeSeriesQueries(definitions, options, queryOptions) {
|
|
|
123
123
|
staleTime: Infinity,
|
|
124
124
|
queryKey: queryKey,
|
|
125
125
|
queryFn: async ({ signal })=>{
|
|
126
|
-
const plugin = await getPlugin(
|
|
126
|
+
const plugin = await getPlugin({
|
|
127
|
+
kind: TIME_SERIES_QUERY_KEY,
|
|
128
|
+
name: definition.spec.plugin.kind
|
|
129
|
+
});
|
|
127
130
|
const data = await plugin.getTimeSeriesData(definition.spec.plugin.spec, context, signal);
|
|
128
131
|
return data;
|
|
129
132
|
}
|
|
@@ -60,7 +60,10 @@ function useTraceQueries(definitions) {
|
|
|
60
60
|
refetchOnReconnect: false,
|
|
61
61
|
staleTime: Infinity,
|
|
62
62
|
queryFn: async ({ signal })=>{
|
|
63
|
-
const plugin = await getPlugin(
|
|
63
|
+
const plugin = await getPlugin({
|
|
64
|
+
kind: TRACE_QUERY_KEY,
|
|
65
|
+
name: traceQueryKind
|
|
66
|
+
});
|
|
64
67
|
const data = await plugin.getTraceData(definition.spec.plugin.spec, context, signal);
|
|
65
68
|
return data;
|
|
66
69
|
}
|
|
@@ -21,6 +21,9 @@ function _export(target, all) {
|
|
|
21
21
|
});
|
|
22
22
|
}
|
|
23
23
|
_export(exports, {
|
|
24
|
+
get MOCK_ALERTS_DATA () {
|
|
25
|
+
return MOCK_ALERTS_DATA;
|
|
26
|
+
},
|
|
24
27
|
get MOCK_EMPTY_PLUGIN_MODULE () {
|
|
25
28
|
return MOCK_EMPTY_PLUGIN_MODULE;
|
|
26
29
|
},
|
|
@@ -45,6 +48,9 @@ _export(exports, {
|
|
|
45
48
|
get MOCK_REMOTE_PLUGIN_MODULE () {
|
|
46
49
|
return MOCK_REMOTE_PLUGIN_MODULE;
|
|
47
50
|
},
|
|
51
|
+
get MOCK_SILENCES_DATA () {
|
|
52
|
+
return MOCK_SILENCES_DATA;
|
|
53
|
+
},
|
|
48
54
|
get MOCK_TIME_SERIES_DATA () {
|
|
49
55
|
return MOCK_TIME_SERIES_DATA;
|
|
50
56
|
},
|
|
@@ -170,6 +176,51 @@ const MOCK_PROFILE_DATA = {
|
|
|
170
176
|
name: 'cpu'
|
|
171
177
|
}
|
|
172
178
|
};
|
|
179
|
+
const MOCK_ALERTS_DATA = {
|
|
180
|
+
alerts: [
|
|
181
|
+
{
|
|
182
|
+
id: 'abc123',
|
|
183
|
+
name: 'HighErrorRate',
|
|
184
|
+
state: 'firing',
|
|
185
|
+
labels: {
|
|
186
|
+
alertname: 'HighErrorRate',
|
|
187
|
+
severity: 'critical',
|
|
188
|
+
service: 'backend'
|
|
189
|
+
},
|
|
190
|
+
annotations: {
|
|
191
|
+
summary: 'High error rate detected'
|
|
192
|
+
},
|
|
193
|
+
severity: 'critical',
|
|
194
|
+
startsAt: '2024-01-01T00:00:00Z',
|
|
195
|
+
endsAt: '2024-01-02T00:00:00Z',
|
|
196
|
+
updatedAt: '2024-01-01T12:00:00Z',
|
|
197
|
+
receivers: [
|
|
198
|
+
'cluster-01'
|
|
199
|
+
]
|
|
200
|
+
}
|
|
201
|
+
]
|
|
202
|
+
};
|
|
203
|
+
const MOCK_SILENCES_DATA = {
|
|
204
|
+
silences: [
|
|
205
|
+
{
|
|
206
|
+
id: 'silence-1',
|
|
207
|
+
state: 'active',
|
|
208
|
+
matchers: [
|
|
209
|
+
{
|
|
210
|
+
name: 'alertname',
|
|
211
|
+
value: 'HighErrorRate',
|
|
212
|
+
isRegex: false,
|
|
213
|
+
isEqual: true
|
|
214
|
+
}
|
|
215
|
+
],
|
|
216
|
+
startsAt: '2024-01-01T00:00:00Z',
|
|
217
|
+
endsAt: '2024-01-02T00:00:00Z',
|
|
218
|
+
createdBy: 'admin',
|
|
219
|
+
comment: 'Maintenance window',
|
|
220
|
+
updatedAt: '2024-01-01T00:00:00Z'
|
|
221
|
+
}
|
|
222
|
+
]
|
|
223
|
+
};
|
|
173
224
|
const MOCK_VALID_PLUGIN_METADATA = {
|
|
174
225
|
kind: 'Panel',
|
|
175
226
|
spec: {
|
|
@@ -14,18 +14,10 @@
|
|
|
14
14
|
Object.defineProperty(exports, "__esModule", {
|
|
15
15
|
value: true
|
|
16
16
|
});
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
});
|
|
22
|
-
}
|
|
23
|
-
_export(exports, {
|
|
24
|
-
get BertPanel1 () {
|
|
25
|
-
return BertPanel1;
|
|
26
|
-
},
|
|
27
|
-
get BertPanel2 () {
|
|
28
|
-
return BertPanel2;
|
|
17
|
+
Object.defineProperty(exports, "plugins", {
|
|
18
|
+
enumerable: true,
|
|
19
|
+
get: function() {
|
|
20
|
+
return plugins;
|
|
29
21
|
}
|
|
30
22
|
});
|
|
31
23
|
const _jsxruntime = require("react/jsx-runtime");
|
|
@@ -48,6 +40,7 @@ function BertPanel1Editor({ value, onChange }) {
|
|
|
48
40
|
]
|
|
49
41
|
});
|
|
50
42
|
}
|
|
43
|
+
// Dummy plugins to test loading
|
|
51
44
|
const BertPanel1 = {
|
|
52
45
|
PanelComponent: ()=>null,
|
|
53
46
|
panelOptionsEditorComponents: [
|
|
@@ -100,3 +93,7 @@ const BertPanel2 = {
|
|
|
100
93
|
}),
|
|
101
94
|
hideQueryEditor: true
|
|
102
95
|
};
|
|
96
|
+
const plugins = {
|
|
97
|
+
'Panel:BertPanel1::1.0.0': BertPanel1,
|
|
98
|
+
'Panel:BertPanel2::1.0.0': BertPanel2
|
|
99
|
+
};
|