diff --git a/.betterer.eslint.config.js b/.betterer.eslint.config.js index 349ee612837..32f06b160a4 100644 --- a/.betterer.eslint.config.js +++ b/.betterer.eslint.config.js @@ -112,7 +112,16 @@ module.exports = [ files: ['public/**/*.tsx', 'packages/grafana-ui/**/*.tsx'], ignores: ['public/app/plugins/**', '**/*.story.tsx', '**/*.{test,spec}.{ts,tsx}', '**/__mocks__/', 'public/test'], rules: { - '@grafana/no-untranslated-strings': 'error', + '@grafana/no-untranslated-strings': [ + 'error', + { + forceFix: [ + // Add paths here that are happy to be auto fixed by this rule, + // for example + // 'public/app/features/alerting' + ], + }, + ], '@grafana/no-translation-top-level': 'error', }, }, diff --git a/.betterer.results b/.betterer.results index b03dac144aa..52b3e8a45c2 100644 --- a/.betterer.results +++ b/.betterer.results @@ -555,11 +555,6 @@ exports[`better eslint`] = { [0, 0, 0, "Unexpected any. Specify a different type.", "0"], [0, 0, 0, "Unexpected any. Specify a different type.", "1"] ], - "packages/grafana-ui/src/components/DataSourceSettings/DataSourceHttpSettings.tsx:5381": [ - [0, 0, 0, "Do not use the t() function outside of a component or function", "0"], - [0, 0, 0, "Do not use the t() function outside of a component or function", "1"], - [0, 0, 0, "Do not use the t() function outside of a component or function", "2"] - ], "packages/grafana-ui/src/components/DataSourceSettings/types.ts:5381": [ [0, 0, 0, "Unexpected any. Specify a different type.", "0"], [0, 0, 0, "Unexpected any. Specify a different type.", "1"] @@ -892,7 +887,8 @@ exports[`better eslint`] = { "public/app/app.ts:5381": [ [0, 0, 0, "\'@grafana/runtime/src/components/PanelDataErrorView\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], [0, 0, 0, "\'@grafana/runtime/src/components/PanelRenderer\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], - [0, 0, 0, "\'@grafana/runtime/src/components/PluginPage\' import is restricted from being used by a pattern. Import from the public export instead.", "2"] + [0, 0, 0, "\'@grafana/runtime/src/components/PluginPage\' import is restricted from being used by a pattern. Import from the public export instead.", "2"], + [0, 0, 0, "\'@grafana/runtime/src/unstable\' import is restricted from being used by a pattern. Import from the public export instead.", "3"] ], "public/app/core/TableModel.ts:5381": [ [0, 0, 0, "Unexpected any. Specify a different type.", "0"], @@ -939,9 +935,6 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"] ], - "public/app/core/components/AppChrome/TopBar/TopSearchBarCommandPaletteTrigger.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/themes/mixins\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/core/components/Breadcrumbs/Breadcrumbs.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] ], @@ -970,26 +963,18 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] ], "public/app/core/components/GraphNG/GraphNG.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/Plot\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/config/UPlotAxisBuilder\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/config/UPlotConfigBuilder\' import is restricted from being used by a pattern. Import from the public export instead.", "2"], - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/config/UPlotScaleBuilder\' import is restricted from being used by a pattern. Import from the public export instead.", "3"], - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/utils\' import is restricted from being used by a pattern. Import from the public export instead.", "4"], - [0, 0, 0, "Do not use any type assertions.", "5"], - [0, 0, 0, "Do not use any type assertions.", "6"], - [0, 0, 0, "Do not use any type assertions.", "7"], - [0, 0, 0, "Do not use any type assertions.", "8"], - [0, 0, 0, "Unexpected any. Specify a different type.", "9"], - [0, 0, 0, "Unexpected any. Specify a different type.", "10"] + [0, 0, 0, "Do not use any type assertions.", "0"], + [0, 0, 0, "Do not use any type assertions.", "1"], + [0, 0, 0, "Do not use any type assertions.", "2"], + [0, 0, 0, "Do not use any type assertions.", "3"], + [0, 0, 0, "Unexpected any. Specify a different type.", "4"], + [0, 0, 0, "Unexpected any. Specify a different type.", "5"] ], "public/app/core/components/GraphNG/utils.ts:5381": [ [0, 0, 0, "\'@grafana/data/src/transformations/transformers/joinDataFrames\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], [0, 0, 0, "\'@grafana/data/src/transformations/transformers/nulls/nullInsertThreshold\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], [0, 0, 0, "\'@grafana/data/src/transformations/transformers/nulls/nullToUndefThreshold\' import is restricted from being used by a pattern. Import from the public export instead.", "2"] ], - "public/app/core/components/Indent/Indent.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Layout/utils/responsiveness\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/core/components/Layers/LayerDragDropList.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], @@ -1006,25 +991,14 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"] ], - "public/app/core/components/NestedFolderPicker/NestedFolderList.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Text/Text\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], - "public/app/core/components/NestedFolderPicker/Trigger.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/themes/mixins\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/core/components/OptionsUI/color.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/ColorPicker/ColorSwatch\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"] + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] ], "public/app/core/components/OptionsUI/fieldColor.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] ], "public/app/core/components/OptionsUI/registry.tsx:5381": [ - [0, 0, 0, "\'@grafana/data/src/field/overrides/processors\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/MatchersUI/FieldNamePicker\' import is restricted from being used by a pattern. Import from the public export instead.", "1"] - ], - "public/app/core/components/OptionsUI/slider.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Slider/styles\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] + [0, 0, 0, "\'@grafana/data/src/field/overrides/processors\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] ], "public/app/core/components/OptionsUI/units.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] @@ -1036,9 +1010,6 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"] ], - "public/app/core/components/PasswordField/PasswordField.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Input/Input\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/core/components/PluginHelp/PluginHelp.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] ], @@ -1046,23 +1017,16 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] ], "public/app/core/components/RolePicker/RoleMenuGroupOption.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Select/getSelectStyles\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"] + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] ], "public/app/core/components/RolePicker/RoleMenuOption.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Select/getSelectStyles\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"] - ], - "public/app/core/components/RolePicker/RolePickerInput.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/themes/mixins\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] ], "public/app/core/components/RolePicker/RolePickerMenu.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Select/getSelectStyles\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"] + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] ], "public/app/core/components/RolePicker/RolePickerSubMenu.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Select/getSelectStyles\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"] + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] ], "public/app/core/components/RolePickerDrawer/RolePickerBadges.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] @@ -1112,19 +1076,10 @@ exports[`better eslint`] = { "public/app/core/components/TagFilter/TagOption.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] ], - "public/app/core/components/TimeSeries/TimeSeries.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/PlotLegend\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/config/UPlotConfigBuilder\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], - [0, 0, 0, "\'@grafana/ui/src/themes/ThemeContext\' import is restricted from being used by a pattern. Import from the public export instead.", "2"] - ], "public/app/core/components/TimeSeries/utils.ts:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/config/UPlotConfigBuilder\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/config/gradientFills\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/internal\' import is restricted from being used by a pattern. Import from the public export instead.", "2"], - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/utils\' import is restricted from being used by a pattern. Import from the public export instead.", "3"], - [0, 0, 0, "Do not use any type assertions.", "4"], - [0, 0, 0, "Unexpected any. Specify a different type.", "5"], - [0, 0, 0, "Unexpected any. Specify a different type.", "6"] + [0, 0, 0, "Do not use any type assertions.", "0"], + [0, 0, 0, "Unexpected any. Specify a different type.", "1"], + [0, 0, 0, "Unexpected any. Specify a different type.", "2"] ], "public/app/core/components/TimelineChart/timeline.ts:5381": [ [0, 0, 0, "\'@grafana/data/src/themes/colorManipulator\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] @@ -1132,16 +1087,12 @@ exports[`better eslint`] = { "public/app/core/components/TimelineChart/utils.ts:5381": [ [0, 0, 0, "\'@grafana/data/src/transformations/transformers/joinDataFrames\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], [0, 0, 0, "\'@grafana/data/src/transformations/transformers/nulls/nullInsertThreshold\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], - [0, 0, 0, "\'@grafana/data/src/transformations/transformers/nulls/nullToValue\' import is restricted from being used by a pattern. Import from the public export instead.", "2"], - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/utils\' import is restricted from being used by a pattern. Import from the public export instead.", "3"] + [0, 0, 0, "\'@grafana/data/src/transformations/transformers/nulls/nullToValue\' import is restricted from being used by a pattern. Import from the public export instead.", "2"] ], "public/app/core/config.ts:5381": [ [0, 0, 0, "Do not re-export imported variable (\`Settings\`)", "0"], [0, 0, 0, "Do not re-export imported variable (\`config\`)", "1"] ], - "public/app/core/context/ModalsContextProvider.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Modal/ModalsContext\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/core/core.ts:5381": [ [0, 0, 0, "Do not re-export imported variable (\`JsonExplorer\`)", "0"], [0, 0, 0, "Do not re-export imported variable (\`TimeSeries\`)", "1"], @@ -1259,32 +1210,16 @@ exports[`better eslint`] = { [0, 0, 0, "Do not use any type assertions.", "1"] ], "public/app/features/actions/ActionEditor.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Forms/Field\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/Forms/InlineField\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], - [0, 0, 0, "\'@grafana/ui/src/components/Forms/InlineFieldRow\' import is restricted from being used by a pattern. Import from the public export instead.", "2"], - [0, 0, 0, "\'@grafana/ui/src/components/Forms/RadioButtonGroup/RadioButtonGroup\' import is restricted from being used by a pattern. Import from the public export instead.", "3"], - [0, 0, 0, "\'@grafana/ui/src/components/JSONFormatter/JSONFormatter\' import is restricted from being used by a pattern. Import from the public export instead.", "4"], - [0, 0, 0, "\'@grafana/ui/src/themes\' import is restricted from being used by a pattern. Import from the public export instead.", "5"], - [0, 0, 0, "\'@grafana/ui/src/utils/i18n\' import is restricted from being used by a pattern. Import from the public export instead.", "6"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "7"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "8"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "9"] - ], - "public/app/features/actions/ActionEditorModalContent.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Button\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/Modal/Modal\' import is restricted from being used by a pattern. Import from the public export instead.", "1"] + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"] ], "public/app/features/actions/ParamsEditor.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/IconButton/IconButton\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/Input/Input\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], - [0, 0, 0, "\'@grafana/ui/src/components/Layout/Stack/Stack\' import is restricted from being used by a pattern. Import from the public export instead.", "2"], - [0, 0, 0, "\'@grafana/ui/src/components/Select/Select\' import is restricted from being used by a pattern. Import from the public export instead.", "3"], - [0, 0, 0, "\'@grafana/ui/src/themes\' import is restricted from being used by a pattern. Import from the public export instead.", "4"], - [0, 0, 0, "Do not use any type assertions.", "5"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "6"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "7"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "8"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "9"] + [0, 0, 0, "Do not use any type assertions.", "0"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "3"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "4"] ], "public/app/features/admin/AdminEditOrgPage.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -1297,12 +1232,8 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] ], "public/app/features/admin/AdminOrgsTable.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/unstable\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"] - ], - "public/app/features/admin/AdminSettingsTable.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/unstable\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"] ], "public/app/features/admin/OrgRolePicker.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] @@ -1492,10 +1423,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "6"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "7"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "4"] ], "public/app/features/alerting/unified/Settings.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -1511,8 +1439,7 @@ exports[`better eslint`] = { ], "public/app/features/alerting/unified/components/AlertLabels.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] ], "public/app/features/alerting/unified/components/AnnotationDetailsField.tsx:5381": [ [0, 0, 0, "Do not use any type assertions.", "0"] @@ -1528,15 +1455,11 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] ], "public/app/features/alerting/unified/components/InvalidIntervalWarning.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] ], "public/app/features/alerting/unified/components/MoreButton.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -1551,9 +1474,7 @@ exports[`better eslint`] = { "public/app/features/alerting/unified/components/Provisioning.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] ], "public/app/features/alerting/unified/components/RuleLocation.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] @@ -1594,10 +1515,7 @@ exports[`better eslint`] = { "public/app/features/alerting/unified/components/alert-groups/MatcherFilter.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] ], "public/app/features/alerting/unified/components/alertmanager-entities/MuteTimingsSelector.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -1677,10 +1595,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "6"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "7"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "4"] ], "public/app/features/alerting/unified/components/export/GrafanaModifyExport.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -1731,8 +1646,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "9"], [0, 0, 0, "No untranslated strings. Wrap text with ", "10"], [0, 0, 0, "No untranslated strings. Wrap text with ", "11"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "12"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "13"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "12"] ], "public/app/features/alerting/unified/components/extensions/AlertInstanceExtensionPoint.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] @@ -1858,8 +1772,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "6"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "5"] ], "public/app/features/alerting/unified/components/panel-alerts-tab/NewRuleFromPanelButton.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -1903,9 +1816,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "7"], [0, 0, 0, "No untranslated strings. Wrap text with ", "8"], [0, 0, 0, "No untranslated strings. Wrap text with ", "9"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "10"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "11"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "12"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "10"] ], "public/app/features/alerting/unified/components/receivers/TemplateForm.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -1986,9 +1897,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "6"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "4"] ], "public/app/features/alerting/unified/components/receivers/form/fields/KeyValueMapInput.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], @@ -2041,8 +1950,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "4"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "5"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "6"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "7"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "8"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "7"] ], "public/app/features/alerting/unified/components/rule-editor/AnnotationKeyInput.tsx:5381": [ [0, 0, 0, "Do not use any type assertions.", "0"] @@ -2085,11 +1993,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "8"], [0, 0, 0, "No untranslated strings. Wrap text with ", "9"], [0, 0, 0, "No untranslated strings. Wrap text with ", "10"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "11"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "12"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "13"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "14"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "15"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "11"] ], "public/app/features/alerting/unified/components/rule-editor/ExpressionEditor.tsx:5381": [ [0, 0, 0, "Do not use any type assertions.", "0"], @@ -2103,9 +2007,6 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"] ], - "public/app/features/alerting/unified/components/rule-editor/GrafanaAlertStatePicker.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Select/types\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/features/alerting/unified/components/rule-editor/GrafanaEvaluationBehavior.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], @@ -2138,12 +2039,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], [0, 0, 0, "No untranslated strings. Wrap text with ", "6"], [0, 0, 0, "No untranslated strings. Wrap text with ", "7"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "8"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "9"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "10"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "11"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "12"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "13"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "8"] ], "public/app/features/alerting/unified/components/rule-editor/PreviewRule.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -2174,9 +2070,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "6"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "4"] ], "public/app/features/alerting/unified/components/rule-editor/RecordingRuleEditor.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] @@ -2193,9 +2087,7 @@ exports[`better eslint`] = { [0, 0, 0, "Do not use any type assertions.", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] ], "public/app/features/alerting/unified/components/rule-editor/VizWrapper.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] @@ -2226,18 +2118,13 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"] ], "public/app/features/alerting/unified/components/rule-editor/alert-rule-form/simplifiedRouting/route-settings/RouteSettings.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Select/MultiValue\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "3"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "4"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "5"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "6"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "7"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "8"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "9"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "10"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "11"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], + [0, 0, 0, "No untranslated strings. Wrap text with ", "6"] ], "public/app/features/alerting/unified/components/rule-editor/dag.test.ts:5381": [ [0, 0, 0, "\'@grafana/runtime/src/utils/DataSourceWithBackend\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] @@ -2322,16 +2209,13 @@ exports[`better eslint`] = { [0, 0, 0, "\'@grafana/runtime/src/services/__mocks__/dataSourceSrv\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] ], "public/app/features/alerting/unified/components/rule-editor/rule-types/GrafanaManagedAlert.tsx:5381": [ - [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] ], "public/app/features/alerting/unified/components/rule-editor/rule-types/MimirOrLokiAlert.tsx:5381": [ - [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] ], "public/app/features/alerting/unified/components/rule-editor/rule-types/MimirOrLokiRecordingRule.tsx:5381": [ - [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] ], "public/app/features/alerting/unified/components/rule-editor/rule-types/RuleTypePicker.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] @@ -2381,16 +2265,12 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] ], "public/app/features/alerting/unified/components/rules/CloudRules.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], + [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] ], "public/app/features/alerting/unified/components/rules/EditRuleGroupModal.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -2458,9 +2338,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"] ], "public/app/features/alerting/unified/components/rules/RuleConfigStatus.tsx:5381": [ - [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] ], "public/app/features/alerting/unified/components/rules/RuleDetails.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -2490,10 +2368,7 @@ exports[`better eslint`] = { ], "public/app/features/alerting/unified/components/rules/RuleDetailsMatchingInstances.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] ], "public/app/features/alerting/unified/components/rules/RuleHealth.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] @@ -2506,13 +2381,10 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], [0, 0, 0, "No untranslated strings. Wrap text with ", "6"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "7"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "8"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "9"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "7"] ], "public/app/features/alerting/unified/components/rules/RuleListStateSection.tsx:5381": [ - [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] ], "public/app/features/alerting/unified/components/rules/RuleState.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], @@ -2552,18 +2424,14 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "20"], [0, 0, 0, "No untranslated strings. Wrap text with ", "21"], [0, 0, 0, "No untranslated strings. Wrap text with ", "22"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "23"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "24"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "25"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "26"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "23"] ], "public/app/features/alerting/unified/components/rules/central-state-history/utils.ts:5381": [ [0, 0, 0, "\'@grafana/data/src/field/fieldComparers\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] ], "public/app/features/alerting/unified/components/rules/state-history/LogRecordViewer.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] ], "public/app/features/alerting/unified/components/rules/state-history/LokiStateHistory.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -2573,16 +2441,14 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], [0, 0, 0, "No untranslated strings. Wrap text with ", "6"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "7"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "8"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "7"] ], "public/app/features/alerting/unified/components/rules/state-history/StateHistory.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "4"] ], "public/app/features/alerting/unified/components/rules/state-history/useRuleHistoryRecords.tsx:5381": [ [0, 0, 0, "\'@grafana/data/src/field/fieldComparers\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] @@ -2676,8 +2542,7 @@ exports[`better eslint`] = { "public/app/features/alerting/unified/components/silences/SilencesFilter.tsx:5381": [ [0, 0, 0, "Do not use any type assertions.", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] ], "public/app/features/alerting/unified/components/silences/SilencesTable.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -2704,11 +2569,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "12"], [0, 0, 0, "No untranslated strings. Wrap text with ", "13"], [0, 0, 0, "No untranslated strings. Wrap text with ", "14"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "15"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "16"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "17"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "18"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "19"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "15"] ], "public/app/features/alerting/unified/home/Home.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -2717,8 +2578,7 @@ exports[`better eslint`] = { ], "public/app/features/alerting/unified/home/Insights.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] ], "public/app/features/alerting/unified/home/PluginIntegrations.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] @@ -2759,9 +2619,6 @@ exports[`better eslint`] = { [0, 0, 0, "Do not use any type assertions.", "4"], [0, 0, 0, "Unexpected any. Specify a different type.", "5"] ], - "public/app/features/alerting/unified/plugins/PluginOriginBadge.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Icon/utils\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/features/alerting/unified/rule-editor/CloneRuleEditor.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], @@ -2861,8 +2718,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "4"] ], "public/app/features/annotations/events_processing.ts:5381": [ [0, 0, 0, "Unexpected any. Specify a different type.", "0"] @@ -2914,16 +2770,12 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "6"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "7"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "8"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "6"] ], "public/app/features/auth-config/AuthProvidersListPage.tsx:5381": [ [0, 0, 0, "\'@grafana/data/src/types/config\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] ], "public/app/features/auth-config/ProviderConfigForm.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -2950,11 +2802,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "6"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "7"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "8"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "4"] ], "public/app/features/auth-config/index.ts:5381": [ [0, 0, 0, "Do not use export all (\`export * from ...\`)", "0"] @@ -2962,6 +2810,9 @@ exports[`better eslint`] = { "public/app/features/auth-config/utils/data.ts:5381": [ [0, 0, 0, "Do not use any type assertions.", "0"] ], + "public/app/features/bookmarks/BookmarksPage.tsx:5381": [ + [0, 0, 0, "\'@grafana/runtime/src/unstable\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] + ], "public/app/features/browse-dashboards/api/browseDashboardsAPI.ts:5381": [ [0, 0, 0, "Do not re-export imported variable (\`@reduxjs/toolkit/query/react\`)", "0"] ], @@ -2972,8 +2823,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] ], "public/app/features/browse-dashboards/components/NameCell.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Icon/utils\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] ], "public/app/features/browse-dashboards/state/index.ts:5381": [ [0, 0, 0, "Do not use export all (\`export * from ...\`)", "0"], @@ -2983,10 +2833,6 @@ exports[`better eslint`] = { "public/app/features/canvas/element.ts:5381": [ [0, 0, 0, "\'@grafana/data/src/panel/PanelPlugin\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] ], - "public/app/features/canvas/elements/metricValue.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/MatchersUI/FieldNamePicker\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/MatchersUI/utils\' import is restricted from being used by a pattern. Import from the public export instead.", "1"] - ], "public/app/features/canvas/elements/notFound.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] ], @@ -3009,11 +2855,7 @@ exports[`better eslint`] = { [0, 0, 0, "Do not use export all (\`export * from ...\`)", "0"] ], "public/app/features/connections/pages/DataSourceDetailsPage.tsx:5381": [ - [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] ], "public/app/features/connections/pages/index.tsx:5381": [ [0, 0, 0, "Do not re-export imported variable (\`./AddNewConnectionPage\`)", "0"], @@ -3037,9 +2879,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "6"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "4"] ], "public/app/features/connections/tabs/ConnectData/NoAccessModal/index.tsx:5381": [ [0, 0, 0, "Do not use export all (\`export * from ...\`)", "0"] @@ -3101,11 +2941,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "13"], [0, 0, 0, "No untranslated strings. Wrap text with ", "14"], [0, 0, 0, "No untranslated strings. Wrap text with ", "15"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "16"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "17"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "18"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "19"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "20"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "16"] ], "public/app/features/dashboard-scene/inspect/HelpWizard/utils.ts:5381": [ [0, 0, 0, "Do not use any type assertions.", "0"] @@ -3185,8 +3021,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "6"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "7"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "6"] ], "public/app/features/dashboard-scene/saving/DashboardPrompt.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -3222,7 +3057,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "9"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "10"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "11"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "12"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "12"], [0, 0, 0, "No untranslated strings. Wrap text with ", "13"], [0, 0, 0, "No untranslated strings. Wrap text with ", "14"], [0, 0, 0, "No untranslated strings. Wrap text with ", "15"], @@ -3233,11 +3068,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "6"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "7"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] ], "public/app/features/dashboard-scene/saving/getDashboardChanges.ts:5381": [ [0, 0, 0, "Do not use any type assertions.", "0"], @@ -3245,7 +3076,8 @@ exports[`better eslint`] = { [0, 0, 0, "Do not use any type assertions.", "2"], [0, 0, 0, "Do not use any type assertions.", "3"], [0, 0, 0, "Do not use any type assertions.", "4"], - [0, 0, 0, "Unexpected any. Specify a different type.", "5"] + [0, 0, 0, "Do not use any type assertions.", "5"], + [0, 0, 0, "Unexpected any. Specify a different type.", "6"] ], "public/app/features/dashboard-scene/saving/shared.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -3293,10 +3125,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "6"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] ], "public/app/features/dashboard-scene/settings/JsonModelEditView.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -3304,9 +3133,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "6"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "7"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "5"] ], "public/app/features/dashboard-scene/settings/annotations/AnnotationSettingsEdit.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -3406,9 +3233,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] ], "public/app/features/dashboard-scene/settings/variables/components/GroupByVariableForm.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -3434,10 +3259,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "6"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "7"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "4"] ], "public/app/features/dashboard-scene/settings/variables/components/SelectionOptionsForm.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -3465,8 +3287,7 @@ exports[`better eslint`] = { ], "public/app/features/dashboard-scene/settings/version-history/RevertDashboardModal.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] ], "public/app/features/dashboard-scene/settings/version-history/VersionHistoryButtons.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], @@ -3476,9 +3297,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] ], "public/app/features/dashboard-scene/settings/version-history/VersionHistoryHeader.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -3503,24 +3322,14 @@ exports[`better eslint`] = { "public/app/features/dashboard-scene/sharing/ShareButton/ShareButton.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] ], - "public/app/features/dashboard-scene/sharing/ShareButton/share-externally/EmailShare/ConfigEmailSharing/ConfigEmailSharing.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Input/Input\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/features/dashboard-scene/sharing/ShareButton/share-externally/EmailShare/ConfigEmailSharing/EmailListConfiguration.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] ], - "public/app/features/dashboard-scene/sharing/ShareButton/share-externally/ShareConfiguration.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Switch/Switch\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/features/dashboard-scene/sharing/ShareButton/share-snapshot/ShareSnapshot.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] ], "public/app/features/dashboard-scene/sharing/ShareButton/share-snapshot/UpsertSnapshot.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Input/Input\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"] - ], - "public/app/features/dashboard-scene/sharing/ShareDrawer/ShareDrawerConfirmAction.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/ConfirmModal/ConfirmContent\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] ], "public/app/features/dashboard-scene/sharing/public-dashboards/ConfigPublicDashboard.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] @@ -3650,9 +3459,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] ], "public/app/features/dashboard/components/DashboardRow/index.ts:5381": [ [0, 0, 0, "Do not re-export imported variable (\`./DashboardRow\`)", "0"] @@ -3675,8 +3482,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] ], "public/app/features/dashboard/components/GenAI/MinimalisticPagination.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -3697,9 +3503,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "10"], [0, 0, 0, "No untranslated strings. Wrap text with ", "11"], [0, 0, 0, "No untranslated strings. Wrap text with ", "12"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "13"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "14"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "15"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "13"] ], "public/app/features/dashboard/components/Inspector/PanelInspector.tsx:5381": [ [0, 0, 0, "Do not use any type assertions.", "0"] @@ -3723,10 +3527,9 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] ], "public/app/features/dashboard/components/PanelEditor/OverrideCategoryTitle.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/MatchersUI/types\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'HorizontalGroup\' import from \'@grafana/ui\' is restricted from being used by a pattern. Use Stack component instead.", "1"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "3"] + [0, 0, 0, "\'HorizontalGroup\' import from \'@grafana/ui\' is restricted from being used by a pattern. Use Stack component instead.", "0"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"] ], "public/app/features/dashboard/components/PanelEditor/PanelEditor.tsx:5381": [ [0, 0, 0, "\'HorizontalGroup\' import from \'@grafana/ui\' is restricted from being used by a pattern. Use Stack component instead.", "0"], @@ -3747,20 +3550,16 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] ], "public/app/features/dashboard/components/PanelEditor/PanelNotSupported.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Layout/Layout\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'Layout\' import from \'@grafana/ui/src/components/Layout/Layout\' is restricted from being used by a pattern. Use Stack component instead.", "1"], - [0, 0, 0, "\'VerticalGroup\' import from \'@grafana/ui\' is restricted from being used by a pattern. Use Stack component instead.", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] ], "public/app/features/dashboard/components/PanelEditor/VisualizationButton.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"] ], "public/app/features/dashboard/components/PanelEditor/VisualizationSelectPane.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Forms/Field\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], - [0, 0, 0, "Use data-testid for E2E selectors instead of aria-label", "3"] + [0, 0, 0, "Use data-testid for E2E selectors instead of aria-label", "2"] ], "public/app/features/dashboard/components/PanelEditor/getFieldOverrideElements.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -3808,8 +3607,9 @@ exports[`better eslint`] = { ], "public/app/features/dashboard/components/SaveDashboard/SaveDashboardDiff.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], + [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], + [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] ], "public/app/features/dashboard/components/SaveDashboard/SaveDashboardDrawer.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -3823,12 +3623,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], [0, 0, 0, "No untranslated strings. Wrap text with ", "6"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "7"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "8"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "9"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "10"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "11"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "12"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "7"] ], "public/app/features/dashboard/components/SaveDashboard/UnsavedChangesModal.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -3862,11 +3657,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "6"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "7"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "8"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "4"] ], "public/app/features/dashboard/components/SaveDashboard/useDashboardSave.tsx:5381": [ [0, 0, 0, "Unexpected any. Specify a different type.", "0"] @@ -3875,21 +3666,17 @@ exports[`better eslint`] = { [0, 0, 0, "Unexpected any. Specify a different type.", "0"] ], "public/app/features/dashboard/components/ShareModal/SharePublicDashboard/ConfigPublicDashboard/ConfigPublicDashboard.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Layout/Layout\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'HorizontalGroup\' import from \'@grafana/ui/src\' is restricted from being used by a pattern. Use Stack component instead.", "1"], - [0, 0, 0, "\'Layout\' import from \'@grafana/ui/src/components/Layout/Layout\' is restricted from being used by a pattern. Use Stack component instead.", "2"] + [0, 0, 0, "\'HorizontalGroup\' import from \'@grafana/ui\' is restricted from being used by a pattern. Use Stack component instead.", "0"] ], "public/app/features/dashboard/components/ShareModal/SharePublicDashboard/ConfigPublicDashboard/Configuration.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Layout/Layout\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'Layout\' import from \'@grafana/ui/src/components/Layout/Layout\' is restricted from being used by a pattern. Use Stack component instead.", "1"], - [0, 0, 0, "\'VerticalGroup\' import from \'@grafana/ui/src\' is restricted from being used by a pattern. Use Stack component instead.", "2"] + [0, 0, 0, "\'VerticalGroup\' import from \'@grafana/ui\' is restricted from being used by a pattern. Use Stack component instead.", "0"] ], "public/app/features/dashboard/components/ShareModal/SharePublicDashboard/ConfigPublicDashboard/EmailSharingConfiguration.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] ], "public/app/features/dashboard/components/ShareModal/SharePublicDashboard/CreatePublicDashboard/AcknowledgeCheckboxes.tsx:5381": [ - [0, 0, 0, "\'HorizontalGroup\' import from \'@grafana/ui/src\' is restricted from being used by a pattern. Use Stack component instead.", "0"], - [0, 0, 0, "\'VerticalGroup\' import from \'@grafana/ui/src\' is restricted from being used by a pattern. Use Stack component instead.", "1"] + [0, 0, 0, "\'HorizontalGroup\' import from \'@grafana/ui\' is restricted from being used by a pattern. Use Stack component instead.", "0"], + [0, 0, 0, "\'VerticalGroup\' import from \'@grafana/ui\' is restricted from being used by a pattern. Use Stack component instead.", "1"] ], "public/app/features/dashboard/components/ShareModal/SharePublicDashboard/SharePublicDashboard.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] @@ -3900,18 +3687,14 @@ exports[`better eslint`] = { "public/app/features/dashboard/components/ShareModal/ViewJsonModal.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] ], - "public/app/features/dashboard/components/SubMenu/AnnotationPicker.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/PanelChrome/LoadingIndicator\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/features/dashboard/components/SubMenu/DashboardLinks.tsx:5381": [ [0, 0, 0, "\'@grafana/data/src/text/sanitize\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] ], "public/app/features/dashboard/components/SubMenu/DashboardLinksDashboard.tsx:5381": [ [0, 0, 0, "\'@grafana/data/src/text/sanitize\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/Button\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], - [0, 0, 0, "Do not use any type assertions.", "2"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "3"], - [0, 0, 0, "Unexpected any. Specify a different type.", "4"] + [0, 0, 0, "Do not use any type assertions.", "1"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], + [0, 0, 0, "Unexpected any. Specify a different type.", "3"] ], "public/app/features/dashboard/components/SubMenu/SubMenu.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] @@ -3938,9 +3721,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "6"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "4"] ], "public/app/features/dashboard/components/TransformationsEditor/TransformationPickerNg.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -3959,16 +3740,13 @@ exports[`better eslint`] = { ], "public/app/features/dashboard/components/VersionHistory/RevertDashboardModal.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] ], "public/app/features/dashboard/components/VersionHistory/VersionHistoryComparison.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] ], "public/app/features/dashboard/components/VersionHistory/VersionHistoryTable.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -3994,8 +3772,7 @@ exports[`better eslint`] = { [0, 0, 0, "Do not use any type assertions.", "0"] ], "public/app/features/dashboard/containers/NewDashboardWithDS.tsx:5381": [ - [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] ], "public/app/features/dashboard/containers/PublicDashboardPage.tsx:5381": [ [0, 0, 0, "Do not use any type assertions.", "0"] @@ -4004,9 +3781,6 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] ], - "public/app/features/dashboard/dashgrid/PanelHeader/PanelHeaderNotice.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/themes/mixins\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/features/dashboard/dashgrid/PanelLinks.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] ], @@ -4035,11 +3809,11 @@ exports[`better eslint`] = { "public/app/features/dashboard/state/DashboardMigrator.ts:5381": [ [0, 0, 0, "\'@grafana/data/src/transformations/transformers/labelsToFields\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], [0, 0, 0, "\'@grafana/data/src/transformations/transformers/merge\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], - [0, 0, 0, "\'@grafana/ui/src/components/Table/utils\' import is restricted from being used by a pattern. Import from the public export instead.", "2"], + [0, 0, 0, "Do not use any type assertions.", "2"], [0, 0, 0, "Do not use any type assertions.", "3"], [0, 0, 0, "Do not use any type assertions.", "4"], [0, 0, 0, "Do not use any type assertions.", "5"], - [0, 0, 0, "Do not use any type assertions.", "6"], + [0, 0, 0, "Unexpected any. Specify a different type.", "6"], [0, 0, 0, "Unexpected any. Specify a different type.", "7"], [0, 0, 0, "Unexpected any. Specify a different type.", "8"], [0, 0, 0, "Unexpected any. Specify a different type.", "9"], @@ -4062,8 +3836,7 @@ exports[`better eslint`] = { [0, 0, 0, "Unexpected any. Specify a different type.", "26"], [0, 0, 0, "Unexpected any. Specify a different type.", "27"], [0, 0, 0, "Unexpected any. Specify a different type.", "28"], - [0, 0, 0, "Unexpected any. Specify a different type.", "29"], - [0, 0, 0, "Unexpected any. Specify a different type.", "30"] + [0, 0, 0, "Unexpected any. Specify a different type.", "29"] ], "public/app/features/dashboard/state/DashboardModel.repeat.test.ts:5381": [ [0, 0, 0, "Unexpected any. Specify a different type.", "0"], @@ -4179,11 +3952,7 @@ exports[`better eslint`] = { [0, 0, 0, "\'@grafana/data/src/types/config\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "6"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "7"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] ], "public/app/features/datasources/components/DashboardsTable.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -4261,9 +4030,6 @@ exports[`better eslint`] = { [0, 0, 0, "Do not use any type assertions.", "0"], [0, 0, 0, "Do not use any type assertions.", "1"] ], - "public/app/features/dimensions/editors/ColorDimensionEditor.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/MatchersUI/utils\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/features/dimensions/editors/FileUploader.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] @@ -4273,17 +4039,15 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"] ], "public/app/features/dimensions/editors/ResourceDimensionEditor.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/MatchersUI/FieldNamePicker\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "Do not use any type assertions.", "1"], + [0, 0, 0, "Do not use any type assertions.", "0"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "3"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "4"] ], "public/app/features/dimensions/editors/ResourcePicker.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/utils/closePopover\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], + [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] ], "public/app/features/dimensions/editors/ResourcePickerPopover.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], @@ -4292,24 +4056,21 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] ], "public/app/features/dimensions/editors/ScalarDimensionEditor.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/MatchersUI/utils\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"] + ], + "public/app/features/dimensions/editors/ScaleDimensionEditor.tsx:5381": [ + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"] ], - "public/app/features/dimensions/editors/ScaleDimensionEditor.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/MatchersUI/utils\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "3"] - ], "public/app/features/dimensions/editors/TextDimensionEditor.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/MatchersUI/FieldNamePicker\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], + [0, 0, 0, "Do not use any type assertions.", "0"], [0, 0, 0, "Do not use any type assertions.", "1"], - [0, 0, 0, "Do not use any type assertions.", "2"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "3"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "4"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "5"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "6"] + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "5"] ], "public/app/features/dimensions/editors/ThresholdsEditor/ThresholdsEditor.tsx:5381": [ [0, 0, 0, "Do not use any type assertions.", "0"], @@ -4342,9 +4103,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "6"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "4"] ], "public/app/features/dimensions/editors/ValueMappingsEditor/ValueMappingsEditorModal.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -4384,8 +4143,7 @@ exports[`better eslint`] = { [0, 0, 0, "Do not use any type assertions.", "0"] ], "public/app/features/explore/ContentOutline/ContentOutlineItemButton.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Tooltip\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"] + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] ], "public/app/features/explore/CorrelationEditorModeBar.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], @@ -4402,8 +4160,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "7"], [0, 0, 0, "No untranslated strings. Wrap text with ", "8"], [0, 0, 0, "No untranslated strings. Wrap text with ", "9"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "10"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "11"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "10"] ], "public/app/features/explore/CorrelationTransformationAddModal.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -4424,7 +4181,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] ], "public/app/features/explore/Explore.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Table/types\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "3"], @@ -4432,8 +4189,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "5"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "6"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "7"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "8"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "9"] + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "8"] ], "public/app/features/explore/ExploreRunQueryButton.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -4444,8 +4200,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] ], "public/app/features/explore/FeatureTogglePage.tsx:5381": [ - [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] ], "public/app/features/explore/LiveTailButton.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], @@ -4455,14 +4210,13 @@ exports[`better eslint`] = { "public/app/features/explore/Logs/LiveLogs.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] ], "public/app/features/explore/Logs/Logs.test.tsx:5381": [ [0, 0, 0, "\'@grafana/data/src/transformations/transformers/organize\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] ], "public/app/features/explore/Logs/Logs.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/VizLegend/utils\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "3"], @@ -4471,9 +4225,8 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "6"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "7"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "8"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "9"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "10"], - [0, 0, 0, "Unexpected any. Specify a different type.", "11"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "9"], + [0, 0, 0, "Unexpected any. Specify a different type.", "10"] ], "public/app/features/explore/Logs/LogsColumnSearch.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] @@ -4505,9 +4258,6 @@ exports[`better eslint`] = { "public/app/features/explore/Logs/LogsTable.test.tsx:5381": [ [0, 0, 0, "\'@grafana/data/src/transformations/transformers/organize\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] ], - "public/app/features/explore/Logs/LogsTable.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Table/types\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/features/explore/Logs/LogsTableAvailableFields.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] ], @@ -4516,8 +4266,7 @@ exports[`better eslint`] = { ], "public/app/features/explore/Logs/LogsTableMultiSelect.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] ], "public/app/features/explore/Logs/LogsTableNavField.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -4551,8 +4300,7 @@ exports[`better eslint`] = { ], "public/app/features/explore/NodeGraph/NodeGraphContainer.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] ], "public/app/features/explore/PrometheusListView/RawListContainer.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -4561,8 +4309,7 @@ exports[`better eslint`] = { ], "public/app/features/explore/PrometheusListView/RawListItem.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] ], "public/app/features/explore/PrometheusListView/RawListItemAttributes.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], @@ -4599,26 +4346,23 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] ], "public/app/features/explore/TraceView/components/TracePageHeader/SearchBar/NextPrevResult.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Button\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], + [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], [0, 0, 0, "No untranslated strings. Wrap text with ", "6"], [0, 0, 0, "No untranslated strings. Wrap text with ", "7"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "8"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "9"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "10"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "8"] ], "public/app/features/explore/TraceView/components/TracePageHeader/SearchBar/TracePageSearchBar.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Button\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "3"], + [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "6"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "5"] ], "public/app/features/explore/TraceView/components/TracePageHeader/SpanFilters/SpanFilters.tsx:5381": [ [0, 0, 0, "\'HorizontalGroup\' import from \'@grafana/ui\' is restricted from being used by a pattern. Use Stack component instead.", "0"], @@ -4659,16 +4403,13 @@ exports[`better eslint`] = { "public/app/features/explore/TraceView/components/TracePageHeader/TracePageHeader.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] ], "public/app/features/explore/TraceView/components/TracePageHeader/index.tsx:5381": [ [0, 0, 0, "Do not re-export imported variable (\`./TracePageHeader\`)", "0"] ], "public/app/features/explore/TraceView/components/TraceTimelineViewer/SpanBar.tsx:5381": [ - [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] ], "public/app/features/explore/TraceView/components/TraceTimelineViewer/SpanDetail/AccordianKeyValues.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] @@ -4676,21 +4417,16 @@ exports[`better eslint`] = { "public/app/features/explore/TraceView/components/TraceTimelineViewer/SpanDetail/AccordianLogs.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] ], "public/app/features/explore/TraceView/components/TraceTimelineViewer/SpanDetail/AccordianReferences.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] ], "public/app/features/explore/TraceView/components/TraceTimelineViewer/SpanDetail/AccordianText.tsx:5381": [ - [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] ], "public/app/features/explore/TraceView/components/TraceTimelineViewer/SpanDetail/SpanFlameGraph.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] @@ -4865,12 +4601,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "11"], [0, 0, 0, "No untranslated strings. Wrap text with ", "12"], [0, 0, 0, "No untranslated strings. Wrap text with ", "13"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "14"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "15"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "16"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "17"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "18"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "19"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "14"] ], "public/app/features/expressions/components/Reduce.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -4894,8 +4625,7 @@ exports[`better eslint`] = { ], "public/app/features/geo/editor/GazetteerPathEditor.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] ], "public/app/features/geo/editor/locationModeEditor.tsx:5381": [ [0, 0, 0, "\'HorizontalGroup\' import from \'@grafana/ui\' is restricted from being used by a pattern. Use Stack component instead.", "0"] @@ -4935,9 +4665,7 @@ exports[`better eslint`] = { "public/app/features/inspector/InspectErrorTab.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] ], "public/app/features/inspector/InspectJSONTab.tsx:5381": [ [0, 0, 0, "Do not use the t() function outside of a component or function", "0"], @@ -4963,8 +4691,7 @@ exports[`better eslint`] = { [0, 0, 0, "Use data-testid for E2E selectors instead of aria-label", "7"] ], "public/app/features/invites/InviteeRow.tsx:5381": [ - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] ], "public/app/features/invites/InviteesTable.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], @@ -4981,9 +4708,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "7"], [0, 0, 0, "No untranslated strings. Wrap text with ", "8"], [0, 0, 0, "No untranslated strings. Wrap text with ", "9"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "10"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "11"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "12"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "10"] ], "public/app/features/library-panels/components/AddLibraryPanelModal/AddLibraryPanelModal.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] @@ -4997,12 +4722,10 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "5"] ], "public/app/features/library-panels/components/LibraryPanelCard/LibraryPanelCard.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/unstable\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] ], "public/app/features/library-panels/components/LibraryPanelInfo/LibraryPanelInfo.tsx:5381": [ - [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] ], "public/app/features/library-panels/components/LibraryPanelsSearch/LibraryPanelsSearch.tsx:5381": [ [0, 0, 0, "\'VerticalGroup\' import from \'@grafana/ui\' is restricted from being used by a pattern. Use Stack component instead.", "0"], @@ -5019,8 +4742,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "6"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "7"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "6"] ], "public/app/features/live/LiveConnectionWarning.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] @@ -5078,9 +4800,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "5"] ], "public/app/features/logs/components/LogLabelStats.tsx:5381": [ - [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] ], "public/app/features/logs/components/LogRowMenuCell.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -5135,15 +4855,11 @@ exports[`better eslint`] = { "public/app/features/manage-dashboards/components/ImportDashboardOverview.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] ], "public/app/features/manage-dashboards/components/SnapshotListTable.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] ], - "public/app/features/manage-dashboards/components/SnapshotListTableRow.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/unstable\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/features/manage-dashboards/state/actions.ts:5381": [ [0, 0, 0, "Do not use any type assertions.", "0"], [0, 0, 0, "Unexpected any. Specify a different type.", "1"], @@ -5166,13 +4882,9 @@ exports[`better eslint`] = { [0, 0, 0, "Do not use export all (\`export * from ...\`)", "0"] ], "public/app/features/migrate-to-cloud/onprem/NameCell.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Icon/utils\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], + [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] - ], - "public/app/features/migrate-to-cloud/shared/AlertWithTraceID.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Alert/Alert\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] ], "public/app/features/notifications/StoredNotifications.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -5201,9 +4913,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], [0, 0, 0, "No untranslated strings. Wrap text with ", "6"], [0, 0, 0, "No untranslated strings. Wrap text with ", "7"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "8"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "9"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "10"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "8"] ], "public/app/features/org/UserInvitePage.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] @@ -5221,8 +4931,7 @@ exports[`better eslint`] = { "public/app/features/panel/components/PanelPluginError.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] ], "public/app/features/panel/components/PanelRenderer.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], @@ -5231,10 +4940,9 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] ], "public/app/features/panel/components/VizTypePicker/PanelTypeCard.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/unstable\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], - [0, 0, 0, "Use data-testid for E2E selectors instead of aria-label", "3"] + [0, 0, 0, "Use data-testid for E2E selectors instead of aria-label", "2"] ], "public/app/features/panel/components/VizTypePicker/VisualizationSuggestions.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], @@ -5249,16 +4957,10 @@ exports[`better eslint`] = { "public/app/features/panel/panellinks/link_srv.ts:5381": [ [0, 0, 0, "Unexpected any. Specify a different type.", "0"] ], - "public/app/features/playlist/PlaylistCard.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/unstable\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/features/playlist/PlaylistForm.tsx:5381": [ [0, 0, 0, "Use data-testid for E2E selectors instead of aria-label", "0"], [0, 0, 0, "Use data-testid for E2E selectors instead of aria-label", "1"] ], - "public/app/features/playlist/PlaylistPageList.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/unstable\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/features/playlist/PlaylistTableRows.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], @@ -5341,9 +5043,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "5"], [0, 0, 0, "No untranslated strings. Wrap text with ", "6"], [0, 0, 0, "No untranslated strings. Wrap text with ", "7"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "8"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "9"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "10"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "8"] ], "public/app/features/plugins/admin/components/InstallControls/index.tsx:5381": [ [0, 0, 0, "Do not re-export imported variable (\`./InstallControlsButton\`)", "0"], @@ -5360,15 +5060,11 @@ exports[`better eslint`] = { [0, 0, 0, "\'@grafana/runtime/src/components/PluginPage\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], [0, 0, 0, "Do not use any type assertions.", "1"], [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] ], "public/app/features/plugins/admin/components/PluginDetailsDeprecatedWarning.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] ], "public/app/features/plugins/admin/components/PluginDetailsDisabledError.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -5386,10 +5082,7 @@ exports[`better eslint`] = { "public/app/features/plugins/admin/components/PluginDetailsPage.tsx:5381": [ [0, 0, 0, "Do not use any type assertions.", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] ], "public/app/features/plugins/admin/components/PluginDetailsPanel.tsx:5381": [ [0, 0, 0, "\'@grafana/runtime/src/components/PluginPage\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], @@ -5401,20 +5094,17 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] ], "public/app/features/plugins/admin/components/PluginListItem.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/unstable\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], + [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] ], "public/app/features/plugins/admin/components/PluginSignatureDetailsBadge.tsx:5381": [ - [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] ], "public/app/features/plugins/admin/components/PluginUsage.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] ], "public/app/features/plugins/admin/components/SearchField.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] @@ -5440,9 +5130,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "6"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "7"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "8"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "9"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "10"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "11"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "9"] ], "public/app/features/plugins/admin/state/actions.ts:5381": [ [0, 0, 0, "Do not use any type assertions.", "0"] @@ -5529,8 +5217,7 @@ exports[`better eslint`] = { [0, 0, 0, "Do not use any type assertions.", "3"] ], "public/app/features/profile/FeatureTogglePage.tsx:5381": [ - [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] ], "public/app/features/profile/UserOrganizations.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] @@ -5559,12 +5246,10 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "Use data-testid for E2E selectors instead of aria-label", "4"] + [0, 0, 0, "Use data-testid for E2E selectors instead of aria-label", "3"] ], "public/app/features/query/components/QueryErrorAlert.tsx:5381": [ - [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] ], "public/app/features/query/components/QueryGroup.tsx:5381": [ [0, 0, 0, "\'HorizontalGroup\' import from \'@grafana/ui\' is restricted from being used by a pattern. Use Stack component instead.", "0"], @@ -5604,27 +5289,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "22"], [0, 0, 0, "No untranslated strings. Wrap text with ", "23"], [0, 0, 0, "No untranslated strings. Wrap text with ", "24"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "25"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "26"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "27"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "28"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "29"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "30"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "31"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "32"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "33"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "34"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "35"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "36"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "37"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "38"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "39"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "40"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "41"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "42"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "43"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "44"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "45"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "25"] ], "public/app/features/query/state/DashboardQueryRunner/AnnotationsQueryRunner.ts:5381": [ [0, 0, 0, "Do not use any type assertions.", "0"] @@ -5673,9 +5338,6 @@ exports[`better eslint`] = { "public/app/features/query/state/updateQueries.ts:5381": [ [0, 0, 0, "\'@grafana/runtime/src/utils/DataSourceWithBackend\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] ], - "public/app/features/sandbox/BenchmarksPage.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/ThemeDemos/EmotionPerfTest\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/features/sandbox/TestStuffPage.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], @@ -5686,10 +5348,8 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] ], "public/app/features/search/page/components/SearchResultsTable.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Table/TableCell\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/Table/styles\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], + [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] ], "public/app/features/search/page/components/columns.tsx:5381": [ [0, 0, 0, "Do not use any type assertions.", "0"], @@ -5785,14 +5445,13 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "7"] ], "public/app/features/serviceaccounts/components/ServiceAccountsListItem.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/unstable\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "3"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "4"], + [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "6"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "7"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "6"] ], "public/app/features/serviceaccounts/state/reducers.ts:5381": [ [0, 0, 0, "Do not use any type assertions.", "0"] @@ -5924,9 +5583,6 @@ exports[`better eslint`] = { [0, 0, 0, "\'@grafana/data/src/datetime/rangeutil\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] ], - "public/app/features/trails/DataTrailsHome.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Text/Text\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/features/trails/MetricScene.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], @@ -5942,8 +5598,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "4"], [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], [0, 0, 0, "No untranslated strings. Wrap text with ", "6"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "7"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "8"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "7"] ], "public/app/features/trails/MetricsHeader.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], @@ -5954,8 +5609,7 @@ exports[`better eslint`] = { ], "public/app/features/trails/TrailStore/utils.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "1"] ], "public/app/features/trails/banners/NativeHistogramBanner.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"] @@ -6009,8 +5663,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"] ], "public/app/features/transformers/calculateHeatmap/editor/helper.ts:5381": [ - [0, 0, 0, "\'@grafana/ui/src/options/builder\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "Unexpected any. Specify a different type.", "1"] + [0, 0, 0, "Unexpected any. Specify a different type.", "0"] ], "public/app/features/transformers/calculateHeatmap/heatmap.test.ts:5381": [ [0, 0, 0, "\'@grafana/data/src/dataframe/processDataFrame\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] @@ -6085,9 +5738,9 @@ exports[`better eslint`] = { ], "public/app/features/transformers/editors/ConvertFieldTypeTransformerEditor.tsx:5381": [ [0, 0, 0, "\'@grafana/data/src/transformations/transformers/convertFieldType\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/MatchersUI/FieldNamePicker\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], - [0, 0, 0, "\'@grafana/ui/src/components/MatchersUI/FieldTypeMatcherEditor\' import is restricted from being used by a pattern. Import from the public export instead.", "2"], - [0, 0, 0, "Do not use any type assertions.", "3"], + [0, 0, 0, "Do not use any type assertions.", "1"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "3"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "4"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "5"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "6"], @@ -6101,9 +5754,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "14"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "15"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "16"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "17"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "18"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "19"] + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "17"] ], "public/app/features/transformers/editors/EnumMappingEditor.tsx:5381": [ [0, 0, 0, "\'@grafana/data/src/transformations/transformers/convertFieldType\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], @@ -6132,10 +5783,9 @@ exports[`better eslint`] = { ], "public/app/features/transformers/editors/FormatStringTransformerEditor.tsx:5381": [ [0, 0, 0, "\'@grafana/data/src/transformations/transformers/formatString\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/MatchersUI/FieldNamePicker\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "3"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "4"] + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "3"] ], "public/app/features/transformers/editors/FormatTimeTransformerEditor.tsx:5381": [ [0, 0, 0, "\'@grafana/data/src/transformations/transformers/formatTime\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], @@ -6144,9 +5794,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "3"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "4"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "5"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "6"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "7"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "8"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "6"] ], "public/app/features/transformers/editors/GroupByTransformerEditor.tsx:5381": [ [0, 0, 0, "\'@grafana/data/src/transformations/transformers/groupBy\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], @@ -6178,10 +5826,9 @@ exports[`better eslint`] = { ], "public/app/features/transformers/editors/JoinByFieldTransformerEditor.tsx:5381": [ [0, 0, 0, "\'@grafana/data/src/transformations/transformers/joinByField\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/MatchersUI/utils\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "3"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "4"] + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "3"] ], "public/app/features/transformers/editors/LabelsToFieldsTransformerEditor.tsx:5381": [ [0, 0, 0, "\'@grafana/data/src/transformations/transformers/labelsToFields\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], @@ -6241,9 +5888,9 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "5"] ], "public/app/features/transformers/extractFields/ExtractFieldsTransformerEditor.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/MatchersUI/FieldNamePicker\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], + [0, 0, 0, "Do not use any type assertions.", "0"], [0, 0, 0, "Do not use any type assertions.", "1"], - [0, 0, 0, "Do not use any type assertions.", "2"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "3"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "4"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "5"], @@ -6253,9 +5900,8 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "9"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "10"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "11"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "12"], - [0, 0, 0, "Unexpected any. Specify a different type.", "13"], - [0, 0, 0, "Unexpected any. Specify a different type.", "14"] + [0, 0, 0, "Unexpected any. Specify a different type.", "12"], + [0, 0, 0, "Unexpected any. Specify a different type.", "13"] ], "public/app/features/transformers/extractFields/components/JSONPathEditor.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -6264,8 +5910,7 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "3"], [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "6"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "7"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "6"] ], "public/app/features/transformers/extractFields/extractFields.test.ts:5381": [ [0, 0, 0, "\'@grafana/data/src/dataframe/processDataFrame\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], @@ -6310,10 +5955,9 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings. Wrap text with ", "9"] ], "public/app/features/transformers/lookupGazetteer/FieldLookupTransformerEditor.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/MatchersUI/FieldNamePicker\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "Do not use any type assertions.", "1"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "3"] + [0, 0, 0, "Do not use any type assertions.", "0"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"] ], "public/app/features/transformers/lookupGazetteer/fieldLookup.test.ts:5381": [ [0, 0, 0, "\'@grafana/data/src/dataframe/processDataFrame\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], @@ -6323,15 +5967,14 @@ exports[`better eslint`] = { [0, 0, 0, "Unexpected any. Specify a different type.", "0"] ], "public/app/features/transformers/partitionByValues/PartitionByValuesEditor.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/MatchersUI/utils\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'HorizontalGroup\' import from \'@grafana/ui\' is restricted from being used by a pattern. Use Stack component instead.", "1"], + [0, 0, 0, "\'HorizontalGroup\' import from \'@grafana/ui\' is restricted from being used by a pattern. Use Stack component instead.", "0"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "3"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "4"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "5"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "6"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "7"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "8"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "7"] ], "public/app/features/transformers/partitionByValues/partitionByValues.ts:5381": [ [0, 0, 0, "\'@grafana/data/src/transformations/transformers/filterByName\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], @@ -6363,13 +6006,12 @@ exports[`better eslint`] = { [0, 0, 0, "Unexpected any. Specify a different type.", "1"] ], "public/app/features/transformers/regression/regressionEditor.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/MatchersUI/FieldNamePicker\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "2"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "3"], [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "4"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "5"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "6"] + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "5"] ], "public/app/features/transformers/spatial/optionsHelper.tsx:5381": [ [0, 0, 0, "\'@grafana/data/src/panel/PanelPlugin\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], @@ -6386,12 +6028,10 @@ exports[`better eslint`] = { [0, 0, 0, "\'@grafana/data/src/transformations/transformers/ids\' import is restricted from being used by a pattern. Import from the public export instead.", "1"] ], "public/app/features/transformers/suggestionsInput/SuggestionsInput.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/DataLinks/DataLinkSuggestions\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/Input/Input\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], + [0, 0, 0, "Do not use any type assertions.", "0"], + [0, 0, 0, "Do not use any type assertions.", "1"], [0, 0, 0, "Do not use any type assertions.", "2"], - [0, 0, 0, "Do not use any type assertions.", "3"], - [0, 0, 0, "Do not use any type assertions.", "4"], - [0, 0, 0, "Do not use any type assertions.", "5"] + [0, 0, 0, "Do not use any type assertions.", "3"] ], "public/app/features/transformers/timeSeriesTable/TimeSeriesTableTransformEditor.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -6400,13 +6040,10 @@ exports[`better eslint`] = { [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "3"] ], "public/app/features/users/TokenRevokedModal.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Modal/getModalStyles\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "1"], + [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], + [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "3"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "4"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "5"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "6"] + [0, 0, 0, "No untranslated strings. Wrap text with ", "3"] ], "public/app/features/users/UsersActionBar.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], @@ -6540,14 +6177,10 @@ exports[`better eslint`] = { "public/app/features/variables/pickers/index.ts:5381": [ [0, 0, 0, "Do not re-export imported variable (\`./OptionsPicker/OptionsPicker\`)", "0"] ], - "public/app/features/variables/pickers/shared/VariableLink.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/PanelChrome/LoadingIndicator\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/features/variables/pickers/shared/VariableOptions.tsx:5381": [ [0, 0, 0, "No untranslated strings in text props. Wrap text with or use t()", "0"], [0, 0, 0, "No untranslated strings. Wrap text with ", "1"], - [0, 0, 0, "No untranslated strings. Wrap text with ", "2"], - [0, 0, 0, "Use data-testid for E2E selectors instead of aria-label", "3"] + [0, 0, 0, "Use data-testid for E2E selectors instead of aria-label", "2"] ], "public/app/features/variables/query/QueryVariableEditor.tsx:5381": [ [0, 0, 0, "Unexpected any. Specify a different type.", "0"], @@ -6668,9 +6301,6 @@ exports[`better eslint`] = { "public/app/features/visualization/data-hover/DataHoverView.tsx:5381": [ [0, 0, 0, "No untranslated strings. Wrap text with ", "0"] ], - "public/app/features/visualization/data-hover/ExemplarHoverView.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/VizTooltipRow\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/plugins/datasource/alertmanager/DataSource.ts:5381": [ [0, 0, 0, "Unexpected any. Specify a different type.", "0"] ], @@ -6718,9 +6348,6 @@ exports[`better eslint`] = { "public/app/plugins/datasource/azuremonitor/components/VariableEditor/VariableEditor.test.tsx:5381": [ [0, 0, 0, "* import is invalid because \'Layout,HorizontalGroup,VerticalGroup\' from \'@grafana/ui\' is restricted from being used by a pattern. Use Stack component instead.", "0"] ], - "public/app/plugins/datasource/azuremonitor/components/shared/Field.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Forms/InlineField\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/plugins/datasource/azuremonitor/types/index.ts:5381": [ [0, 0, 0, "Do not use export all (\`export * from ...\`)", "0"], [0, 0, 0, "Do not use export all (\`export * from ...\`)", "1"], @@ -6828,12 +6455,6 @@ exports[`better eslint`] = { [0, 0, 0, "Do not re-export imported variable (\`./thirdArgAfterSearchQuery\`)", "4"], [0, 0, 0, "Do not re-export imported variable (\`./withinStringQuery\`)", "5"] ], - "public/app/plugins/datasource/cloudwatch/components/CheatSheet/LogsCheatSheet.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/slate-plugins/slate-prism\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], - "public/app/plugins/datasource/cloudwatch/components/QueryEditor/LogsQueryEditor/code-editors/PPLQueryEditor.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Monaco/types\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/plugins/datasource/cloudwatch/components/QueryEditor/MetricsQueryEditor/MetricsQueryEditor.test.tsx:5381": [ [0, 0, 0, "* import is invalid because \'Layout,HorizontalGroup,VerticalGroup\' from \'@grafana/ui\' is restricted from being used by a pattern. Use Stack component instead.", "0"] ], @@ -6843,9 +6464,6 @@ exports[`better eslint`] = { "public/app/plugins/datasource/cloudwatch/components/QueryEditor/QueryEditor.test.tsx:5381": [ [0, 0, 0, "Do not re-export imported variable (\`./MetricsQueryEditor/SQLCodeEditor\`)", "0"] ], - "public/app/plugins/datasource/cloudwatch/components/shared/LogGroups/LegacyLogGroupSelector.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Select/types\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/plugins/datasource/cloudwatch/components/shared/MetricStatEditor/index.ts:5381": [ [0, 0, 0, "Do not re-export imported variable (\`./MetricStatEditor\`)", "0"] ], @@ -7027,10 +6645,6 @@ exports[`better eslint`] = { [0, 0, 0, "Do not use any type assertions.", "1"], [0, 0, 0, "Unexpected any. Specify a different type.", "2"] ], - "public/app/plugins/datasource/grafana/components/TimeRegionEditor.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/DateTimePickers/TimeZonePicker/TimeZoneOffset\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/DateTimePickers/TimeZonePicker/TimeZoneTitle\' import is restricted from being used by a pattern. Import from the public export instead.", "1"] - ], "public/app/plugins/datasource/grafana/datasource.ts:5381": [ [0, 0, 0, "Do not use any type assertions.", "0"], [0, 0, 0, "Do not use any type assertions.", "1"], @@ -7203,15 +6817,6 @@ exports[`better eslint`] = { [0, 0, 0, "Do not re-export imported variable (\`Datasource\`)", "0"], [0, 0, 0, "Do not re-export imported variable (\`MixedDatasource\`)", "1"] ], - "public/app/plugins/datasource/mssql/azureauth/AzureAuthSettings.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/DataSourceSettings/types\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], - "public/app/plugins/datasource/mssql/azureauth/AzureCredentialsForm.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], - "public/app/plugins/datasource/mssql/types.ts:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/DataSourceSettings/types\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/plugins/datasource/opentsdb/datasource.d.ts:5381": [ [0, 0, 0, "Unexpected any. Specify a different type.", "0"] ], @@ -7238,12 +6843,6 @@ exports[`better eslint`] = { "public/app/plugins/datasource/parca/webpack.config.ts:5381": [ [0, 0, 0, "Do not re-export imported variable (\`config\`)", "0"] ], - "public/app/plugins/datasource/prometheus/configuration/AzureAuthSettings.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/DataSourceSettings/types\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], - "public/app/plugins/datasource/prometheus/configuration/DataSourceHttpSettingsOverhaulPackage.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/DataSourceSettings/types\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/plugins/datasource/tempo/QueryField.tsx:5381": [ [0, 0, 0, "\'HorizontalGroup\' import from \'@grafana/ui\' is restricted from being used by a pattern. Use Stack component instead.", "0"] ], @@ -7308,47 +6907,24 @@ exports[`better eslint`] = { [0, 0, 0, "Do not re-export imported variable (\`config\`)", "0"] ], "public/app/plugins/panel/annolist/AnnoListPanel.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/List/AbstractList\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "Do not use any type assertions.", "1"] - ], - "public/app/plugins/panel/barchart/BarChartLegend.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/utils\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], - "public/app/plugins/panel/barchart/BarChartPanel.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/plugins/TooltipPlugin2\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] + [0, 0, 0, "Do not use any type assertions.", "0"] ], "public/app/plugins/panel/barchart/TickSpacingEditor.tsx:5381": [ [0, 0, 0, "\'HorizontalGroup\' import from \'@grafana/ui\' is restricted from being used by a pattern. Use Stack component instead.", "0"] ], "public/app/plugins/panel/barchart/bars.ts:5381": [ [0, 0, 0, "\'@grafana/data/src/themes/colorManipulator\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/config/UPlotAxisBuilder\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/utils\' import is restricted from being used by a pattern. Import from the public export instead.", "2"], - [0, 0, 0, "Do not use any type assertions.", "3"] - ], - "public/app/plugins/panel/barchart/module.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/options/builder/tooltip\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] + [0, 0, 0, "Do not use any type assertions.", "1"] ], "public/app/plugins/panel/barchart/quadtree.ts:5381": [ [0, 0, 0, "Unexpected any. Specify a different type.", "0"] ], "public/app/plugins/panel/barchart/utils.ts:5381": [ - [0, 0, 0, "\'@grafana/data/src/field/fieldState\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/config/UPlotAxisBuilder\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/utils\' import is restricted from being used by a pattern. Import from the public export instead.", "2"] - ], - "public/app/plugins/panel/bargauge/BarGaugeLegend.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/utils\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], - "public/app/plugins/panel/bargauge/BarGaugePanel.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/DataLinks/DataLinksContextMenu\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] + [0, 0, 0, "\'@grafana/data/src/field/fieldState\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] ], "public/app/plugins/panel/candlestick/CandlestickPanel.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/config/UPlotAxisBuilder\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/config/UPlotScaleBuilder\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/plugins/TooltipPlugin2\' import is restricted from being used by a pattern. Import from the public export instead.", "2"], - [0, 0, 0, "Do not use any type assertions.", "3"], - [0, 0, 0, "Unexpected any. Specify a different type.", "4"] + [0, 0, 0, "Do not use any type assertions.", "0"], + [0, 0, 0, "Unexpected any. Specify a different type.", "1"] ], "public/app/plugins/panel/candlestick/fields.ts:5381": [ [0, 0, 0, "\'@grafana/data/src/transformations/transformers/joinDataFrames\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] @@ -7364,12 +6940,7 @@ exports[`better eslint`] = { [0, 0, 0, "Do not re-export imported variable (\`defaultCandlestickColors\`)", "7"] ], "public/app/plugins/panel/canvas/components/CanvasTooltip.tsx:5381": [ - [0, 0, 0, "\'@grafana/data/src/types/action\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/VizTooltipContent\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/VizTooltipFooter\' import is restricted from being used by a pattern. Import from the public export instead.", "2"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/VizTooltipHeader\' import is restricted from being used by a pattern. Import from the public export instead.", "3"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/types\' import is restricted from being used by a pattern. Import from the public export instead.", "4"], - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/plugins/CloseButton\' import is restricted from being used by a pattern. Import from the public export instead.", "5"] + [0, 0, 0, "\'@grafana/data/src/types/action\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] ], "public/app/plugins/panel/canvas/editor/connectionEditor.tsx:5381": [ [0, 0, 0, "\'@grafana/data/src/utils/OptionsUIBuilders\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] @@ -7388,8 +6959,7 @@ exports[`better eslint`] = { [0, 0, 0, "\'@grafana/data/src/panel/PanelPlugin\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] ], "public/app/plugins/panel/datagrid/components/DatagridContextMenu.tsx:5381": [ - [0, 0, 0, "\'@grafana/data/src/transformations/transformers/convertFieldType\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/Menu/MenuDivider\' import is restricted from being used by a pattern. Import from the public export instead.", "1"] + [0, 0, 0, "\'@grafana/data/src/transformations/transformers/convertFieldType\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] ], "public/app/plugins/panel/debug/CursorView.tsx:5381": [ [0, 0, 0, "Do not use any type assertions.", "0"], @@ -7402,18 +6972,12 @@ exports[`better eslint`] = { "public/app/plugins/panel/gauge/GaugeMigrations.ts:5381": [ [0, 0, 0, "Unexpected any. Specify a different type.", "0"] ], - "public/app/plugins/panel/gauge/GaugePanel.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/DataLinks/DataLinksContextMenu\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/plugins/panel/geomap/components/MarkersLegend.tsx:5381": [ [0, 0, 0, "\'@grafana/data/src/field/scale\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], [0, 0, 0, "Do not use any type assertions.", "1"], [0, 0, 0, "Do not use any type assertions.", "2"], [0, 0, 0, "Unexpected any. Specify a different type.", "3"] ], - "public/app/plugins/panel/geomap/editor/FrameSelectionEditor.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/MatchersUI/FieldsByFrameRefIdMatcher\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/plugins/panel/geomap/editor/GeomapStyleRulesEditor.tsx:5381": [ [0, 0, 0, "Do not use any type assertions.", "0"] ], @@ -7436,8 +7000,7 @@ exports[`better eslint`] = { [0, 0, 0, "Do not use any type assertions.", "12"] ], "public/app/plugins/panel/geomap/editor/StyleRuleEditor.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/MatchersUI/FieldValueMatcher\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "Do not use any type assertions.", "1"] + [0, 0, 0, "Do not use any type assertions.", "0"] ], "public/app/plugins/panel/geomap/editor/layerEditor.tsx:5381": [ [0, 0, 0, "\'@grafana/data/src/utils/OptionsUIBuilders\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] @@ -7473,23 +7036,12 @@ exports[`better eslint`] = { [0, 0, 0, "Do not use any type assertions.", "0"] ], "public/app/plugins/panel/heatmap/HeatmapPanel.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/plugins/TooltipPlugin2\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "Do not use any type assertions.", "1"], - [0, 0, 0, "Unexpected any. Specify a different type.", "2"] - ], - "public/app/plugins/panel/heatmap/HeatmapTooltip.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/VizTooltipContent\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/VizTooltipFooter\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/VizTooltipHeader\' import is restricted from being used by a pattern. Import from the public export instead.", "2"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/VizTooltipWrapper\' import is restricted from being used by a pattern. Import from the public export instead.", "3"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/types\' import is restricted from being used by a pattern. Import from the public export instead.", "4"] + [0, 0, 0, "Do not use any type assertions.", "0"], + [0, 0, 0, "Unexpected any. Specify a different type.", "1"] ], "public/app/plugins/panel/heatmap/migrations.ts:5381": [ [0, 0, 0, "Unexpected any. Specify a different type.", "0"] ], - "public/app/plugins/panel/heatmap/module.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/options/builder\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/plugins/panel/heatmap/palettes.ts:5381": [ [0, 0, 0, "Do not use any type assertions.", "0"], [0, 0, 0, "Unexpected any. Specify a different type.", "1"] @@ -7518,24 +7070,13 @@ exports[`better eslint`] = { [0, 0, 0, "Do not use any type assertions.", "16"] ], "public/app/plugins/panel/histogram/Histogram.tsx:5381": [ - [0, 0, 0, "\'@grafana/data/src/transformations/transformers/histogram\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/utils\' import is restricted from being used by a pattern. Import from the public export instead.", "1"] + [0, 0, 0, "\'@grafana/data/src/transformations/transformers/histogram\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] ], "public/app/plugins/panel/histogram/HistogramPanel.tsx:5381": [ - [0, 0, 0, "\'@grafana/data/src/transformations/transformers/histogram\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/plugins/TooltipPlugin2\' import is restricted from being used by a pattern. Import from the public export instead.", "1"] - ], - "public/app/plugins/panel/histogram/HistogramTooltip.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/VizTooltipContent\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/VizTooltipFooter\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/VizTooltipHeader\' import is restricted from being used by a pattern. Import from the public export instead.", "2"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/VizTooltipWrapper\' import is restricted from being used by a pattern. Import from the public export instead.", "3"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/types\' import is restricted from being used by a pattern. Import from the public export instead.", "4"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/utils\' import is restricted from being used by a pattern. Import from the public export instead.", "5"] + [0, 0, 0, "\'@grafana/data/src/transformations/transformers/histogram\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] ], "public/app/plugins/panel/histogram/module.tsx:5381": [ - [0, 0, 0, "\'@grafana/data/src/transformations/transformers/histogram\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/options/builder\' import is restricted from being used by a pattern. Import from the public export instead.", "1"] + [0, 0, 0, "\'@grafana/data/src/transformations/transformers/histogram\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] ], "public/app/plugins/panel/histogram/utils.ts:5381": [ [0, 0, 0, "\'@grafana/data/src/transformations/transformers/histogram\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] @@ -7552,9 +7093,6 @@ exports[`better eslint`] = { "public/app/plugins/panel/logs/types.ts:5381": [ [0, 0, 0, "Do not re-export imported variable (\`./panelcfg.gen\`)", "0"] ], - "public/app/plugins/panel/news/component/News.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/unstable\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/plugins/panel/nodeGraph/Edge.tsx:5381": [ [0, 0, 0, "Do not use any type assertions.", "0"] ], @@ -7569,9 +7107,6 @@ exports[`better eslint`] = { [0, 0, 0, "\'VerticalGroup\' import from \'@grafana/ui\' is restricted from being used by a pattern. Use Stack component instead.", "1"], [0, 0, 0, "Unexpected any. Specify a different type.", "2"] ], - "public/app/plugins/panel/nodeGraph/editor/ArcOptionsEditor.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/MatchersUI/FieldNamePicker\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/plugins/panel/nodeGraph/index.ts:5381": [ [0, 0, 0, "Do not re-export imported variable (\`./NodeGraph\`)", "0"] ], @@ -7581,48 +7116,22 @@ exports[`better eslint`] = { "public/app/plugins/panel/nodeGraph/types.ts:5381": [ [0, 0, 0, "Do not re-export imported variable (\`./panelcfg.gen\`)", "0"] ], - "public/app/plugins/panel/piechart/PieChart.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/themes/mixins\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/utils/useComponetInstanceId\' import is restricted from being used by a pattern. Import from the public export instead.", "1"] - ], "public/app/plugins/panel/piechart/migrations.ts:5381": [ [0, 0, 0, "Unexpected any. Specify a different type.", "0"], [0, 0, 0, "Unexpected any. Specify a different type.", "1"] ], - "public/app/plugins/panel/piechart/module.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/options/builder/tooltip\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/plugins/panel/stat/StatMigrations.ts:5381": [ [0, 0, 0, "Unexpected any. Specify a different type.", "0"] ], "public/app/plugins/panel/stat/StatPanel.tsx:5381": [ - [0, 0, 0, "\'@grafana/data/src/field/fieldOverrides\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/DataLinks/DataLinksContextMenu\' import is restricted from being used by a pattern. Import from the public export instead.", "1"] - ], - "public/app/plugins/panel/state-timeline/StateTimelinePanel.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/plugins/TooltipPlugin2\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], - "public/app/plugins/panel/state-timeline/StateTimelineTooltip2.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/VizTooltipContent\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/VizTooltipFooter\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/VizTooltipHeader\' import is restricted from being used by a pattern. Import from the public export instead.", "2"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/VizTooltipWrapper\' import is restricted from being used by a pattern. Import from the public export instead.", "3"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/types\' import is restricted from being used by a pattern. Import from the public export instead.", "4"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/utils\' import is restricted from being used by a pattern. Import from the public export instead.", "5"] + [0, 0, 0, "\'@grafana/data/src/field/fieldOverrides\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] ], "public/app/plugins/panel/state-timeline/migrations.ts:5381": [ [0, 0, 0, "Unexpected any. Specify a different type.", "0"], [0, 0, 0, "Unexpected any. Specify a different type.", "1"] ], - "public/app/plugins/panel/status-history/StatusHistoryPanel.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/plugins/TooltipPlugin2\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], - "public/app/plugins/panel/table/TablePanel.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Table/types\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/plugins/panel/table/cells/SparklineCellOptionsEditor.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/Table/SparklineCell\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'VerticalGroup\' import from \'@grafana/ui\' is restricted from being used by a pattern. Use Stack component instead.", "1"] + [0, 0, 0, "\'VerticalGroup\' import from \'@grafana/ui\' is restricted from being used by a pattern. Use Stack component instead.", "0"] ], "public/app/plugins/panel/table/migrations.ts:5381": [ [0, 0, 0, "\'@grafana/data/src/transformations/transformers/reduce\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], @@ -7643,17 +7152,6 @@ exports[`better eslint`] = { "public/app/plugins/panel/timeseries/SpanNullsEditor.tsx:5381": [ [0, 0, 0, "\'HorizontalGroup\' import from \'@grafana/ui\' is restricted from being used by a pattern. Use Stack component instead.", "0"] ], - "public/app/plugins/panel/timeseries/TimeSeriesPanel.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/plugins/TooltipPlugin2\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], - "public/app/plugins/panel/timeseries/TimeSeriesTooltip.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/VizTooltipContent\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/VizTooltipFooter\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/VizTooltipHeader\' import is restricted from being used by a pattern. Import from the public export instead.", "2"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/VizTooltipWrapper\' import is restricted from being used by a pattern. Import from the public export instead.", "3"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/types\' import is restricted from being used by a pattern. Import from the public export instead.", "4"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/utils\' import is restricted from being used by a pattern. Import from the public export instead.", "5"] - ], "public/app/plugins/panel/timeseries/migrations.ts:5381": [ [0, 0, 0, "Do not use any type assertions.", "0"], [0, 0, 0, "Do not use any type assertions.", "1"], @@ -7666,15 +7164,9 @@ exports[`better eslint`] = { [0, 0, 0, "Unexpected any. Specify a different type.", "8"], [0, 0, 0, "Unexpected any. Specify a different type.", "9"] ], - "public/app/plugins/panel/timeseries/module.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/options/builder/tooltip\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/plugins/panel/timeseries/plugins/AnnotationsPlugin2.tsx:5381": [ [0, 0, 0, "Unexpected any. Specify a different type.", "0"] ], - "public/app/plugins/panel/timeseries/plugins/ThresholdControlsPlugin.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/internal\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] - ], "public/app/plugins/panel/timeseries/plugins/annotations2/AnnotationEditor2.tsx:5381": [ [0, 0, 0, "Unexpected any. Specify a different type.", "0"] ], @@ -7688,42 +7180,29 @@ exports[`better eslint`] = { "public/app/plugins/panel/timeseries/utils.ts:5381": [ [0, 0, 0, "\'@grafana/data/src/transformations/transformers/convertFieldType\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], [0, 0, 0, "\'@grafana/data/src/transformations/transformers/nulls/nullInsertThreshold\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], - [0, 0, 0, "\'@grafana/data/src/transformations/transformers/nulls/nullToValue\' import is restricted from being used by a pattern. Import from the public export instead.", "2"], - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/internal\' import is restricted from being used by a pattern. Import from the public export instead.", "3"] + [0, 0, 0, "\'@grafana/data/src/transformations/transformers/nulls/nullToValue\' import is restricted from being used by a pattern. Import from the public export instead.", "2"] ], "public/app/plugins/panel/trend/TrendPanel.tsx:5381": [ - [0, 0, 0, "\'@grafana/data/src/transformations/transformers/joinDataFrames\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/plugins/TooltipPlugin2\' import is restricted from being used by a pattern. Import from the public export instead.", "1"] - ], - "public/app/plugins/panel/trend/module.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/options/builder/tooltip\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] + [0, 0, 0, "\'@grafana/data/src/transformations/transformers/joinDataFrames\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] ], "public/app/plugins/panel/xychart/SeriesEditor.tsx:5381": [ - [0, 0, 0, "\'@grafana/ui/src/components/MatchersUI/FieldNamePicker\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], + [0, 0, 0, "Do not use any type assertions.", "0"], [0, 0, 0, "Do not use any type assertions.", "1"], [0, 0, 0, "Do not use any type assertions.", "2"], - [0, 0, 0, "Do not use any type assertions.", "3"], - [0, 0, 0, "Do not use any type assertions.", "4"] + [0, 0, 0, "Do not use any type assertions.", "3"] ], "public/app/plugins/panel/xychart/XYChartPanel.tsx:5381": [ - [0, 0, 0, "\'@grafana/data/src/themes/colorManipulator\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/plugins/TooltipPlugin2\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/utils\' import is restricted from being used by a pattern. Import from the public export instead.", "2"] + [0, 0, 0, "\'@grafana/data/src/themes/colorManipulator\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] ], "public/app/plugins/panel/xychart/XYChartTooltip.tsx:5381": [ - [0, 0, 0, "\'@grafana/data/src/themes/colorManipulator\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/VizTooltipContent\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/VizTooltipFooter\' import is restricted from being used by a pattern. Import from the public export instead.", "2"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/VizTooltipHeader\' import is restricted from being used by a pattern. Import from the public export instead.", "3"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/VizTooltipWrapper\' import is restricted from being used by a pattern. Import from the public export instead.", "4"], - [0, 0, 0, "\'@grafana/ui/src/components/VizTooltip/types\' import is restricted from being used by a pattern. Import from the public export instead.", "5"] + [0, 0, 0, "\'@grafana/data/src/themes/colorManipulator\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] ], "public/app/plugins/panel/xychart/migrations.ts:5381": [ [0, 0, 0, "Do not use any type assertions.", "0"] ], "public/app/plugins/panel/xychart/scatter.ts:5381": [ [0, 0, 0, "\'@grafana/data/src/themes/colorManipulator\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/components/uPlot/types\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], + [0, 0, 0, "Do not use any type assertions.", "1"], [0, 0, 0, "Do not use any type assertions.", "2"], [0, 0, 0, "Do not use any type assertions.", "3"], [0, 0, 0, "Do not use any type assertions.", "4"], @@ -7737,11 +7216,10 @@ exports[`better eslint`] = { [0, 0, 0, "Do not use any type assertions.", "12"], [0, 0, 0, "Do not use any type assertions.", "13"], [0, 0, 0, "Do not use any type assertions.", "14"], - [0, 0, 0, "Do not use any type assertions.", "15"], + [0, 0, 0, "Unexpected any. Specify a different type.", "15"], [0, 0, 0, "Unexpected any. Specify a different type.", "16"], [0, 0, 0, "Unexpected any. Specify a different type.", "17"], - [0, 0, 0, "Unexpected any. Specify a different type.", "18"], - [0, 0, 0, "Unexpected any. Specify a different type.", "19"] + [0, 0, 0, "Unexpected any. Specify a different type.", "18"] ], "public/app/plugins/panel/xychart/utils.ts:5381": [ [0, 0, 0, "\'@grafana/data/src/field/fieldState\' import is restricted from being used by a pattern. Import from the public export instead.", "0"] @@ -7877,11 +7355,6 @@ exports[`better eslint`] = { [0, 0, 0, "Unexpected any. Specify a different type.", "2"], [0, 0, 0, "Unexpected any. Specify a different type.", "3"], [0, 0, 0, "Unexpected any. Specify a different type.", "4"] - ], - "scripts/cli/generateSassVariableFiles.ts:5381": [ - [0, 0, 0, "\'@grafana/ui/src/themes/_variables.dark.scss.tmpl\' import is restricted from being used by a pattern. Import from the public export instead.", "0"], - [0, 0, 0, "\'@grafana/ui/src/themes/_variables.light.scss.tmpl\' import is restricted from being used by a pattern. Import from the public export instead.", "1"], - [0, 0, 0, "\'@grafana/ui/src/themes/_variables.scss.tmpl\' import is restricted from being used by a pattern. Import from the public export instead.", "2"] ] }` }; @@ -7953,12 +7426,6 @@ exports[`no undocumented stories`] = { exports[`no gf-form usage`] = { value: `{ - "e2e/old-arch/utils/flows/addDataSource.ts:5381": [ - [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"] - ], - "e2e/utils/flows/addDataSource.ts:5381": [ - [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"] - ], "packages/grafana-prometheus/src/components/PromExploreExtraField.tsx:5381": [ [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"], [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"], @@ -8021,29 +7488,6 @@ exports[`no gf-form usage`] = { [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"], [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"] ], - "packages/grafana-ui/src/components/DataSourceSettings/DataSourceHttpSettings.tsx:5381": [ - [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"], - [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"], - [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"], - [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"], - [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"], - [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"], - [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"], - [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"], - [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"], - [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"], - [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"], - [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"], - [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"], - [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"], - [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"], - [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"] - ], - "packages/grafana-ui/src/components/DataSourceSettings/HttpProxySettings.tsx:5381": [ - [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"], - [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"], - [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"] - ], "packages/grafana-ui/src/components/DataSourceSettings/SecureSocksProxySettings.tsx:5381": [ [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"], [0, 0, 0, "gf-form usage has been deprecated. Use a component from @grafana/ui or custom CSS instead.", "5381"], diff --git a/.bra.toml b/.bra.toml index e3b7510804f..6572f9a6afb 100644 --- a/.bra.toml +++ b/.bra.toml @@ -1,6 +1,6 @@ [run] init_cmds = [ - ["GO_BUILD_DEV=1", "make", "build-go"], + ["make","GO_BUILD_DEV=1", "build-go"], ["make", "gen-jsonnet"], ["./bin/grafana", "server", "-profile", "-profile-addr=127.0.0.1", "-profile-port=6000", "-profile-block-rate=1", "-profile-mutex-rate=5", "-packaging=dev", "cfg:app_mode=development"] ] @@ -17,7 +17,7 @@ watch_exts = [".go", ".ini", ".toml", ".template.html"] ignore_files = [".*_gen.go"] build_delay = 1500 cmds = [ - ["GO_BUILD_DEV=1", "make", "build-go-fast"], + ["make", "GO_BUILD_DEV=1", "build-go-fast"], ["make", "gen-jsonnet"], ["./bin/grafana", "server", "-profile", "-profile-addr=127.0.0.1", "-profile-port=6000", "-profile-block-rate=1", "-profile-mutex-rate=5", "-packaging=dev", "cfg:app_mode=development"] ] diff --git a/.drone.yml b/.drone.yml index dbcc1662f84..6340d739fd6 100644 --- a/.drone.yml +++ b/.drone.yml @@ -25,7 +25,7 @@ steps: depends_on: [] environment: CGO_ENABLED: 0 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: compile-build-cmd - commands: - ./bin/build verify-drone @@ -75,7 +75,7 @@ steps: - go install github.com/bazelbuild/buildtools/buildifier@latest - buildifier --lint=warn -mode=check -r . depends_on: [] - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: lint-starlark trigger: event: @@ -437,7 +437,7 @@ steps: - apk add --update make - CODEGEN_VERIFY=1 make gen-cue depends_on: [] - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: verify-gen-cue - commands: - '# It is required that generated jsonnet is committed and in sync with its inputs.' @@ -446,21 +446,21 @@ steps: - apk add --update make - CODEGEN_VERIFY=1 make gen-jsonnet depends_on: [] - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: verify-gen-jsonnet - commands: - apk add --update make - make gen-go depends_on: - verify-gen-cue - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: wire-install - commands: - apk add --update build-base shared-mime-info shared-mime-info-lang - go list -f '{{.Dir}}/...' -m | xargs go test -short -covermode=atomic -timeout=5m depends_on: - wire-install - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: test-backend - commands: - apk add --update build-base @@ -469,7 +469,7 @@ steps: | grep -o '\(.*\)/' | sort -u) depends_on: - wire-install - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: test-backend-integration trigger: event: @@ -524,7 +524,7 @@ steps: depends_on: [] environment: CGO_ENABLED: 0 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: compile-build-cmd - commands: - echo $(/usr/bin/github-app-external-token) > /github-app/token @@ -569,16 +569,16 @@ steps: - apk add --update make - make gen-go depends_on: [] - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: wire-install - commands: - go run scripts/modowners/modowners.go check go.mod - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: validate-modfile - commands: - apk add --update make - make swagger-validate - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: validate-openapi-spec trigger: event: @@ -655,7 +655,7 @@ steps: depends_on: [] environment: CGO_ENABLED: 0 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: compile-build-cmd - commands: - '# It is required that code generated from Thema/CUE be committed and in sync @@ -665,7 +665,7 @@ steps: - apk add --update make - CODEGEN_VERIFY=1 make gen-cue depends_on: [] - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: verify-gen-cue - commands: - '# It is required that generated jsonnet is committed and in sync with its inputs.' @@ -674,7 +674,7 @@ steps: - apk add --update make - CODEGEN_VERIFY=1 make gen-jsonnet depends_on: [] - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: verify-gen-jsonnet - commands: - yarn install --immutable || yarn install --immutable @@ -712,7 +712,7 @@ steps: - /src/grafana-build artifacts -a targz:grafana:linux/amd64 -a targz:grafana:linux/arm64 -a targz:grafana:linux/arm/v7 -a docker:grafana:linux/amd64 -a docker:grafana:linux/amd64:ubuntu -a docker:grafana:linux/arm64 -a docker:grafana:linux/arm64:ubuntu -a docker:grafana:linux/arm/v7 - -a docker:grafana:linux/arm/v7:ubuntu --go-version=1.23.7 --yarn-cache=$$YARN_CACHE_FOLDER + -a docker:grafana:linux/arm/v7:ubuntu --go-version=1.24.1 --yarn-cache=$$YARN_CACHE_FOLDER --build-id=$$DRONE_BUILD_NUMBER --ubuntu-base=ubuntu:22.04 --alpine-base=alpine:3.21.3 --tag-format='{{ .version_base }}-{{ .buildID }}-{{ .arch }}' --ubuntu-tag-format='{{ .version_base }}-{{ .buildID }}-ubuntu-{{ .arch }}' --verify='false' --grafana-dir=$$PWD @@ -1110,7 +1110,7 @@ steps: depends_on: [] environment: CGO_ENABLED: 0 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: compile-build-cmd - commands: - echo $DRONE_RUNNER_NAME @@ -1124,7 +1124,7 @@ steps: - apk add --update make - CODEGEN_VERIFY=1 make gen-cue depends_on: [] - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: verify-gen-cue - commands: - '# It is required that generated jsonnet is committed and in sync with its inputs.' @@ -1133,14 +1133,14 @@ steps: - apk add --update make - CODEGEN_VERIFY=1 make gen-jsonnet depends_on: [] - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: verify-gen-jsonnet - commands: - apk add --update make - make gen-go depends_on: - verify-gen-cue - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: wire-install - commands: - dockerize -wait tcp://postgres:5432 -timeout 120s @@ -1161,7 +1161,7 @@ steps: GRAFANA_TEST_DB: postgres PGPASSWORD: grafanatest POSTGRES_HOST: postgres - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: postgres-integration-tests - commands: - dockerize -wait tcp://mysql80:3306 -timeout 120s @@ -1182,7 +1182,7 @@ steps: environment: GRAFANA_TEST_DB: mysql MYSQL_HOST: mysql80 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: mysql-8.0-integration-tests - commands: - dockerize -wait tcp://redis:6379 -timeout 120s @@ -1198,7 +1198,7 @@ steps: - wait-for-redis environment: REDIS_URL: redis://redis:6379/0 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: redis-integration-tests - commands: - dockerize -wait tcp://memcached:11211 -timeout 120s @@ -1214,7 +1214,7 @@ steps: - wait-for-memcached environment: MEMCACHED_HOSTS: memcached:11211 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: memcached-integration-tests - commands: - dockerize -wait tcp://mimir_backend:8080 -timeout 120s @@ -1230,7 +1230,7 @@ steps: environment: AM_TENANT_ID: test AM_URL: http://mimir_backend:8080 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: remote-alertmanager-integration-tests trigger: event: @@ -1312,7 +1312,7 @@ steps: - apk add --update make - CODEGEN_VERIFY=1 make gen-cue depends_on: [] - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: verify-gen-cue trigger: event: @@ -1433,7 +1433,7 @@ steps: && return 1; fi depends_on: - clone-enterprise - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: swagger-gen trigger: event: @@ -1538,7 +1538,7 @@ steps: depends_on: [] environment: CGO_ENABLED: 0 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: compile-build-cmd - commands: - '# It is required that code generated from Thema/CUE be committed and in sync @@ -1549,7 +1549,7 @@ steps: - CODEGEN_VERIFY=1 make gen-cue depends_on: - clone-enterprise - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: verify-gen-cue - commands: - '# It is required that generated jsonnet is committed and in sync with its inputs.' @@ -1559,14 +1559,14 @@ steps: - CODEGEN_VERIFY=1 make gen-jsonnet depends_on: - clone-enterprise - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: verify-gen-jsonnet - commands: - apk add --update make - make gen-go depends_on: - verify-gen-cue - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: wire-install - commands: - apk add --update build-base @@ -1574,7 +1574,7 @@ steps: - go test -v -run=^$ -benchmem -timeout=1h -count=8 -bench=. ${GO_PACKAGES} depends_on: - wire-install - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: sqlite-benchmark-integration-tests - commands: - apk add --update build-base @@ -1586,7 +1586,7 @@ steps: GRAFANA_TEST_DB: postgres PGPASSWORD: grafanatest POSTGRES_HOST: postgres - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: postgres-benchmark-integration-tests - commands: - apk add --update build-base @@ -1597,7 +1597,7 @@ steps: environment: GRAFANA_TEST_DB: mysql MYSQL_HOST: mysql80 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: mysql-8.0-benchmark-integration-tests trigger: event: @@ -1669,7 +1669,7 @@ steps: - apk add --update make - CODEGEN_VERIFY=1 make gen-cue depends_on: [] - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: verify-gen-cue trigger: branch: main @@ -1852,7 +1852,7 @@ steps: - apk add --update make - CODEGEN_VERIFY=1 make gen-cue depends_on: [] - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: verify-gen-cue - commands: - '# It is required that generated jsonnet is committed and in sync with its inputs.' @@ -1861,21 +1861,21 @@ steps: - apk add --update make - CODEGEN_VERIFY=1 make gen-jsonnet depends_on: [] - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: verify-gen-jsonnet - commands: - apk add --update make - make gen-go depends_on: - verify-gen-cue - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: wire-install - commands: - apk add --update build-base shared-mime-info shared-mime-info-lang - go list -f '{{.Dir}}/...' -m | xargs go test -short -covermode=atomic -timeout=5m depends_on: - wire-install - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: test-backend - commands: - apk add --update build-base @@ -1884,7 +1884,7 @@ steps: | grep -o '\(.*\)/' | sort -u) depends_on: - wire-install - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: test-backend-integration trigger: branch: main @@ -1929,22 +1929,22 @@ steps: depends_on: [] environment: CGO_ENABLED: 0 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: compile-build-cmd - commands: - apk add --update make - make gen-go depends_on: [] - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: wire-install - commands: - go run scripts/modowners/modowners.go check go.mod - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: validate-modfile - commands: - apk add --update make - make swagger-validate - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: validate-openapi-spec - commands: - ./bin/build verify-drone @@ -2076,7 +2076,7 @@ steps: depends_on: [] environment: CGO_ENABLED: 0 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: compile-build-cmd - commands: - '# It is required that code generated from Thema/CUE be committed and in sync @@ -2086,7 +2086,7 @@ steps: - apk add --update make - CODEGEN_VERIFY=1 make gen-cue depends_on: [] - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: verify-gen-cue - commands: - '# It is required that generated jsonnet is committed and in sync with its inputs.' @@ -2095,7 +2095,7 @@ steps: - apk add --update make - CODEGEN_VERIFY=1 make gen-jsonnet depends_on: [] - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: verify-gen-jsonnet - commands: - yarn install --immutable || yarn install --immutable @@ -2132,7 +2132,7 @@ steps: - /src/grafana-build artifacts -a targz:grafana:linux/amd64 -a targz:grafana:linux/arm64 -a targz:grafana:linux/arm/v7 -a docker:grafana:linux/amd64 -a docker:grafana:linux/amd64:ubuntu -a docker:grafana:linux/arm64 -a docker:grafana:linux/arm64:ubuntu -a docker:grafana:linux/arm/v7 - -a docker:grafana:linux/arm/v7:ubuntu --go-version=1.23.7 --yarn-cache=$$YARN_CACHE_FOLDER + -a docker:grafana:linux/arm/v7:ubuntu --go-version=1.24.1 --yarn-cache=$$YARN_CACHE_FOLDER --build-id=$$DRONE_BUILD_NUMBER --ubuntu-base=ubuntu:22.04 --alpine-base=alpine:3.21.3 --tag-format='{{ .version_base }}-{{ .buildID }}-{{ .arch }}' --ubuntu-tag-format='{{ .version_base }}-{{ .buildID }}-ubuntu-{{ .arch }}' --verify='false' --grafana-dir=$$PWD @@ -2607,7 +2607,7 @@ steps: depends_on: [] environment: CGO_ENABLED: 0 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: compile-build-cmd - commands: - echo $DRONE_RUNNER_NAME @@ -2621,7 +2621,7 @@ steps: - apk add --update make - CODEGEN_VERIFY=1 make gen-cue depends_on: [] - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: verify-gen-cue - commands: - '# It is required that generated jsonnet is committed and in sync with its inputs.' @@ -2630,14 +2630,14 @@ steps: - apk add --update make - CODEGEN_VERIFY=1 make gen-jsonnet depends_on: [] - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: verify-gen-jsonnet - commands: - apk add --update make - make gen-go depends_on: - verify-gen-cue - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: wire-install - commands: - dockerize -wait tcp://postgres:5432 -timeout 120s @@ -2658,7 +2658,7 @@ steps: GRAFANA_TEST_DB: postgres PGPASSWORD: grafanatest POSTGRES_HOST: postgres - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: postgres-integration-tests - commands: - dockerize -wait tcp://mysql80:3306 -timeout 120s @@ -2679,7 +2679,7 @@ steps: environment: GRAFANA_TEST_DB: mysql MYSQL_HOST: mysql80 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: mysql-8.0-integration-tests - commands: - dockerize -wait tcp://redis:6379 -timeout 120s @@ -2695,7 +2695,7 @@ steps: - wait-for-redis environment: REDIS_URL: redis://redis:6379/0 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: redis-integration-tests - commands: - dockerize -wait tcp://memcached:11211 -timeout 120s @@ -2711,7 +2711,7 @@ steps: - wait-for-memcached environment: MEMCACHED_HOSTS: memcached:11211 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: memcached-integration-tests - commands: - dockerize -wait tcp://mimir_backend:8080 -timeout 120s @@ -2727,7 +2727,7 @@ steps: environment: AM_TENANT_ID: test AM_URL: http://mimir_backend:8080 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: remote-alertmanager-integration-tests trigger: branch: main @@ -2996,7 +2996,7 @@ steps: - apk add --update make - CODEGEN_VERIFY=1 make gen-cue depends_on: [] - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: verify-gen-cue - commands: - '# It is required that generated jsonnet is committed and in sync with its inputs.' @@ -3005,21 +3005,21 @@ steps: - apk add --update make - CODEGEN_VERIFY=1 make gen-jsonnet depends_on: [] - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: verify-gen-jsonnet - commands: - apk add --update make - make gen-go depends_on: - verify-gen-cue - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: wire-install - commands: - apk add --update build-base shared-mime-info shared-mime-info-lang - go list -f '{{.Dir}}/...' -m | xargs go test -short -covermode=atomic -timeout=5m depends_on: - wire-install - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: test-backend - commands: - apk add --update build-base @@ -3028,7 +3028,7 @@ steps: | grep -o '\(.*\)/' | sort -u) depends_on: - wire-install - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: test-backend-integration trigger: branch: @@ -3071,22 +3071,22 @@ steps: depends_on: [] environment: CGO_ENABLED: 0 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: compile-build-cmd - commands: - apk add --update make - make gen-go depends_on: [] - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: wire-install - commands: - go run scripts/modowners/modowners.go check go.mod - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: validate-modfile - commands: - apk add --update make - make swagger-validate - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: validate-openapi-spec trigger: branch: @@ -3165,7 +3165,7 @@ steps: depends_on: [] environment: CGO_ENABLED: 0 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: compile-build-cmd - commands: - echo $DRONE_RUNNER_NAME @@ -3179,7 +3179,7 @@ steps: - apk add --update make - CODEGEN_VERIFY=1 make gen-cue depends_on: [] - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: verify-gen-cue - commands: - '# It is required that generated jsonnet is committed and in sync with its inputs.' @@ -3188,14 +3188,14 @@ steps: - apk add --update make - CODEGEN_VERIFY=1 make gen-jsonnet depends_on: [] - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: verify-gen-jsonnet - commands: - apk add --update make - make gen-go depends_on: - verify-gen-cue - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: wire-install - commands: - dockerize -wait tcp://postgres:5432 -timeout 120s @@ -3216,7 +3216,7 @@ steps: GRAFANA_TEST_DB: postgres PGPASSWORD: grafanatest POSTGRES_HOST: postgres - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: postgres-integration-tests - commands: - dockerize -wait tcp://mysql80:3306 -timeout 120s @@ -3237,7 +3237,7 @@ steps: environment: GRAFANA_TEST_DB: mysql MYSQL_HOST: mysql80 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: mysql-8.0-integration-tests - commands: - dockerize -wait tcp://redis:6379 -timeout 120s @@ -3253,7 +3253,7 @@ steps: - wait-for-redis environment: REDIS_URL: redis://redis:6379/0 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: redis-integration-tests - commands: - dockerize -wait tcp://memcached:11211 -timeout 120s @@ -3269,7 +3269,7 @@ steps: - wait-for-memcached environment: MEMCACHED_HOSTS: memcached:11211 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: memcached-integration-tests - commands: - dockerize -wait tcp://mimir_backend:8080 -timeout 120s @@ -3285,7 +3285,7 @@ steps: environment: AM_TENANT_ID: test AM_URL: http://mimir_backend:8080 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: remote-alertmanager-integration-tests trigger: branch: @@ -3385,7 +3385,7 @@ steps: depends_on: [] environment: CGO_ENABLED: 0 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: compile-build-cmd - commands: - ./bin/build artifacts docker fetch --edition oss @@ -3517,7 +3517,7 @@ steps: depends_on: [] environment: CGO_ENABLED: 0 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: compile-build-cmd - commands: - ./bin/build artifacts docker fetch --edition oss @@ -3658,7 +3658,7 @@ steps: depends_on: [] environment: CGO_ENABLED: 0 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: compile-build-cmd - commands: - ./bin/build artifacts packages --artifacts-editions=oss --tag $${DRONE_TAG} --src-bucket @@ -3750,7 +3750,7 @@ steps: depends_on: [] environment: CGO_ENABLED: 0 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: compile-build-cmd - commands: - yarn install --immutable || yarn install --immutable @@ -3850,7 +3850,7 @@ steps: depends_on: [] environment: CGO_ENABLED: 0 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: compile-build-cmd - depends_on: - compile-build-cmd @@ -3947,7 +3947,7 @@ steps: depends_on: [] environment: CGO_ENABLED: 0 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: compile-build-cmd - commands: - ./bin/build publish grafana-com --edition oss ${DRONE_TAG} @@ -4009,7 +4009,7 @@ steps: from_secret: grafana_api_key GCP_KEY_BASE64: from_secret: gcp_key_base64 - GO_VERSION: 1.23.7 + GO_VERSION: 1.24.1 GPG_PASSPHRASE: from_secret: packages_gpg_passphrase GPG_PRIVATE_KEY: @@ -4084,7 +4084,7 @@ steps: from_secret: grafana_api_key GCP_KEY_BASE64: from_secret: gcp_key_base64 - GO_VERSION: 1.23.7 + GO_VERSION: 1.24.1 GPG_PASSPHRASE: from_secret: packages_gpg_passphrase GPG_PRIVATE_KEY: @@ -4201,7 +4201,7 @@ steps: from_secret: grafana_api_key GCP_KEY_BASE64: from_secret: gcp_key_base64 - GO_VERSION: 1.23.7 + GO_VERSION: 1.24.1 GPG_PASSPHRASE: from_secret: packages_gpg_passphrase GPG_PRIVATE_KEY: @@ -4352,7 +4352,7 @@ steps: - apk add --update make - CODEGEN_VERIFY=1 make gen-cue depends_on: [] - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: verify-gen-cue - commands: - '# It is required that generated jsonnet is committed and in sync with its inputs.' @@ -4361,21 +4361,21 @@ steps: - apk add --update make - CODEGEN_VERIFY=1 make gen-jsonnet depends_on: [] - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: verify-gen-jsonnet - commands: - apk add --update make - make gen-go depends_on: - verify-gen-cue - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: wire-install - commands: - apk add --update build-base shared-mime-info shared-mime-info-lang - go list -f '{{.Dir}}/...' -m | xargs go test -short -covermode=atomic -timeout=5m depends_on: - wire-install - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: test-backend - commands: - apk add --update build-base @@ -4384,7 +4384,7 @@ steps: | grep -o '\(.*\)/' | sort -u) depends_on: - wire-install - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: test-backend-integration trigger: cron: @@ -4438,7 +4438,7 @@ steps: from_secret: grafana_api_key GCP_KEY_BASE64: from_secret: gcp_key_base64 - GO_VERSION: 1.23.7 + GO_VERSION: 1.24.1 GPG_PASSPHRASE: from_secret: packages_gpg_passphrase GPG_PRIVATE_KEY: @@ -4582,7 +4582,7 @@ steps: from_secret: grafana_api_key GCP_KEY_BASE64: from_secret: gcp_key_base64 - GO_VERSION: 1.23.7 + GO_VERSION: 1.24.1 GPG_PASSPHRASE: from_secret: packages_gpg_passphrase GPG_PRIVATE_KEY: @@ -4689,7 +4689,7 @@ steps: - export GITHUB_TOKEN=$(cat /github-app/token) - dagger run --silent /src/grafana-build artifacts -a $${ARTIFACTS} --grafana-ref=$${GRAFANA_REF} --enterprise-ref=$${ENTERPRISE_REF} --grafana-repo=$${GRAFANA_REPO} --version=$${VERSION} - --go-version=1.23.7 + --go-version=1.24.1 depends_on: - github-app-generate-token environment: @@ -4710,7 +4710,7 @@ steps: from_secret: grafana_api_key GCP_KEY_BASE64: from_secret: gcp_key_base64 - GO_VERSION: 1.23.7 + GO_VERSION: 1.24.1 GPG_PASSPHRASE: from_secret: packages_gpg_passphrase GPG_PRIVATE_KEY: @@ -4848,7 +4848,7 @@ steps: - apk add --update make - CODEGEN_VERIFY=1 make gen-cue depends_on: [] - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: verify-gen-cue - commands: - '# It is required that generated jsonnet is committed and in sync with its inputs.' @@ -4857,14 +4857,14 @@ steps: - apk add --update make - CODEGEN_VERIFY=1 make gen-jsonnet depends_on: [] - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: verify-gen-jsonnet - commands: - apk add --update make - make gen-go depends_on: - verify-gen-cue - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: wire-install - commands: - dockerize -wait tcp://postgres:5432 -timeout 120s @@ -4885,7 +4885,7 @@ steps: GRAFANA_TEST_DB: postgres PGPASSWORD: grafanatest POSTGRES_HOST: postgres - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: postgres-integration-tests - commands: - dockerize -wait tcp://mysql80:3306 -timeout 120s @@ -4906,7 +4906,7 @@ steps: environment: GRAFANA_TEST_DB: mysql MYSQL_HOST: mysql80 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: mysql-8.0-integration-tests - commands: - dockerize -wait tcp://redis:6379 -timeout 120s @@ -4922,7 +4922,7 @@ steps: - wait-for-redis environment: REDIS_URL: redis://redis:6379/0 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: redis-integration-tests - commands: - dockerize -wait tcp://memcached:11211 -timeout 120s @@ -4938,7 +4938,7 @@ steps: - wait-for-memcached environment: MEMCACHED_HOSTS: memcached:11211 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: memcached-integration-tests - commands: - dockerize -wait tcp://mimir_backend:8080 -timeout 120s @@ -4954,7 +4954,7 @@ steps: environment: AM_TENANT_ID: test AM_URL: http://mimir_backend:8080 - image: golang:1.23.7-alpine + image: golang:1.24.1-alpine name: remote-alertmanager-integration-tests trigger: event: @@ -5257,7 +5257,7 @@ steps: - commands: - trivy --exit-code 0 --severity UNKNOWN,LOW,MEDIUM docker:27-cli - trivy --exit-code 0 --severity UNKNOWN,LOW,MEDIUM alpine/git:2.40.1 - - trivy --exit-code 0 --severity UNKNOWN,LOW,MEDIUM golang:1.23.7-alpine + - trivy --exit-code 0 --severity UNKNOWN,LOW,MEDIUM golang:1.24.1-alpine - trivy --exit-code 0 --severity UNKNOWN,LOW,MEDIUM node:22.11.0-alpine - trivy --exit-code 0 --severity UNKNOWN,LOW,MEDIUM node:22-bookworm - trivy --exit-code 0 --severity UNKNOWN,LOW,MEDIUM google/cloud-sdk:431.0.0 @@ -5295,7 +5295,7 @@ steps: - commands: - trivy --exit-code 1 --severity HIGH,CRITICAL docker:27-cli - trivy --exit-code 1 --severity HIGH,CRITICAL alpine/git:2.40.1 - - trivy --exit-code 1 --severity HIGH,CRITICAL golang:1.23.7-alpine + - trivy --exit-code 1 --severity HIGH,CRITICAL golang:1.24.1-alpine - trivy --exit-code 1 --severity HIGH,CRITICAL node:22.11.0-alpine - trivy --exit-code 1 --severity HIGH,CRITICAL node:22-bookworm - trivy --exit-code 1 --severity HIGH,CRITICAL google/cloud-sdk:431.0.0 @@ -5564,6 +5564,6 @@ kind: secret name: gcr_credentials --- kind: signature -hmac: 33f2e5615dfd7889899f9f8f16f7716190fa637fe98f1efd7e29607f8946be7d +hmac: f55fddb4c6faf30b232ae778ec6c022c9f3d32955879e8a764c715642712c5ea ... diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 7ff10207c35..c8fd9fe2158 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -79,6 +79,7 @@ /pkg/apis/ @grafana/grafana-app-platform-squad /pkg/apis/query @grafana/grafana-datasources-core-services /pkg/apis/userstorage @grafana/grafana-app-platform-squad @grafana/plugins-platform-backend +/pkg/apis/secret @grafana/grafana-operator-experience-squad /pkg/bus/ @grafana/grafana-search-and-storage /pkg/cmd/ @grafana/grafana-backend-group /pkg/cmd/grafana-cli/commands/install_command.go @grafana/plugins-platform-backend @@ -756,6 +757,7 @@ embed.go @grafana/grafana-as-code /.github/pr-checks.json @tolzhabayev /.github/pr-commands.json @tolzhabayev /.github/renovate.json5 @grafana/frontend-ops +/.github/actions/setup-enterprise/action.yml @grafana/grafana-backend-group /.github/actions/test-coverage-processor/action.yml @grafana/grafana-backend-group /.github/actions/setup-grafana-bench/ @Proximyst /.github/workflows/add-to-whats-new.yml @grafana/docs-tooling @@ -790,14 +792,18 @@ embed.go @grafana/grafana-as-code /.github/workflows/pr-codeql-analysis-javascript.yml @DanCech /.github/workflows/pr-codeql-analysis-python.yml @DanCech /.github/workflows/pr-commands.yml @tolzhabayev +/.github/workflows/pr-lint-build-docs.yml @grafana/docs-tooling /.github/workflows/pr-patch-check.yml @grafana/grafana-developer-enablement-squad +/.github/workflows/pr-test-integration.yml @grafana/grafana-backend-group /.github/workflows/pr-backend-unit-tests.yml @grafana/grafana-backend-group +/.github/workflows/pr-backend-coverage.yml @grafana/grafana-backend-group /.github/workflows/sync-mirror.yml @grafana/grafana-developer-enablement-squad /.github/workflows/publish-technical-documentation-next.yml @grafana/docs-tooling /.github/workflows/publish-technical-documentation-release.yml @grafana/docs-tooling /.github/workflows/remove-milestone.yml @grafana/grafana-developer-enablement-squad /.github/workflows/scripts/json-file-to-job-output.js @grafana/plugins-platform-frontend /.github/workflows/stale.yml @grafana/grafana-developer-enablement-squad +/.github/workflows/storybook-verification.yml @grafana/grafana-frontend-platform /.github/workflows/update-changelog.yml @grafana/grafana-developer-enablement-squad /.github/workflows/update-make-docs.yml @grafana/docs-tooling /.github/workflows/scripts/kinds/verify-kinds.go @grafana/platform-monitoring diff --git a/.github/actions/setup-enterprise/action.yml b/.github/actions/setup-enterprise/action.yml new file mode 100644 index 00000000000..e87d3d7bae9 --- /dev/null +++ b/.github/actions/setup-enterprise/action.yml @@ -0,0 +1,48 @@ +name: 'Setup Grafana Enterprise' +description: 'Clones and sets up Grafana Enterprise repository for testing' + +inputs: + github-app-name: + description: 'Name of the GitHub App in Vault' + required: false + default: 'grafana-ci-bot' + +runs: + using: "composite" + steps: + - name: Retrieve GitHub App secrets + id: get-secrets + uses: grafana/shared-workflows/actions/get-vault-secrets@get-vault-secrets-v1.0.1 + with: + repo_secrets: | + APP_ID=${{ inputs.github-app-name }}:app-id + APP_INSTALLATION_ID=${{ inputs.github-app-name }}:app-installation-id + PRIVATE_KEY=${{ inputs.github-app-name }}:private-key + + - name: Generate GitHub App token + id: generate_token + uses: actions/create-github-app-token@v1 + with: + app-id: ${{ env.APP_ID }} + private-key: ${{ env.PRIVATE_KEY }} + repositories: "grafana-enterprise" + owner: "grafana" + + - name: Setup Enterprise + shell: bash + env: + GH_TOKEN: ${{ steps.generate_token.outputs.token }} + run: | + git clone https://x-access-token:${GH_TOKEN}@github.com/grafana/grafana-enterprise.git ../grafana-enterprise; + + cd ../grafana-enterprise + + if git checkout ${GITHUB_HEAD_REF}; then + echo "checked out ${GITHUB_HEAD_REF}" + elif git checkout ${GITHUB_BASE_REF}; then + echo "checked out ${GITHUB_BASE_REF}" + else + git checkout main + fi + + ./build.sh diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 0de94ce207d..dd2c234e3ff 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -11,6 +11,7 @@ updates: - "/apps/investigations" - "/pkg/aggregator" - "/pkg/apimachinery" + - "/pkg/apis/secret" - "/pkg/apiserver" - "/pkg/build" - "/pkg/build/wire" diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml index c1f90ceb831..8c8b1abde50 100644 --- a/.github/workflows/codeql-analysis.yml +++ b/.github/workflows/codeql-analysis.yml @@ -8,7 +8,7 @@ name: "CodeQL" on: workflow_dispatch: push: - branches: [main, v1.8.x, v2.0.x, v2.1.x, v2.6.x, v3.0.x, v3.1.x, v4.0.x, v4.1.x, v4.2.x, v4.3.x, v4.4.x, v4.5.x, v4.6.x, v4.7.x, v5.0.x, v5.1.x, v5.2.x, v5.3.x, v5.4.x, v6.0.x, v6.1.x, v6.2.x, v6.3.x, v6.4.x, v6.5.x, v6.6.x, v6.7.x, v7.0.x, v7.1.x, v7.2.x] + branches: [main, v*.*.*] paths-ignore: - '**/*.cue' - '**/*.json' diff --git a/.github/workflows/pr-backend-coverage.yml b/.github/workflows/pr-backend-coverage.yml new file mode 100644 index 00000000000..7935860c798 --- /dev/null +++ b/.github/workflows/pr-backend-coverage.yml @@ -0,0 +1,69 @@ +name: Coverage + +on: + workflow_dispatch: + push: + branches: + - main + paths-ignore: + - 'docs/**' + - '**/*.md' + +permissions: + contents: read + id-token: write + +env: + EDITION: 'oss' + WIRE_TAGS: 'oss' + +jobs: + main: + name: Backend Unit Tests + runs-on: ubuntu-latest-8-cores + steps: + - name: Checkout code + uses: actions/checkout@v4 + - name: Setup Go + uses: actions/setup-go@v5 + with: + go-version-file: go.mod + cache: true + - name: Install dependencies + run: | + sudo apt-get update + sudo apt-get install -y build-essential shared-mime-info + go install github.com/mfridman/tparse@c1754a1f484ac5cd422697b0fec635177ddc8507 # v0.17.0 + - name: Generate Go code + run: make gen-go + - name: Run unit tests + run: COVER_OPTS="-coverprofile=be-unit.cov -coverpkg=github.com/grafana/grafana/..." GO_TEST_OUTPUT="/tmp/unit.log" make test-go-unit-cov + - name: Process and upload coverage + uses: ./.github/actions/test-coverage-processor + with: + test-type: 'be-unit' + # Needs to be named 'unit.cov' based on the Makefile command `make test-go-unit` + coverage-file: 'unit.cov' + codecov-token: ${{ secrets.CODECOV_TOKEN }} + codecov-flag: 'be-unit' + codecov-name: 'be-unit' + + - name: Install Grafana Bench + # We can't allow forks here, as we need secret access. + if: ${{ github.event_name != 'pull_request' }} + uses: ./.github/actions/setup-grafana-bench + + - name: Process output for Bench + if: ${{ github.event_name != 'pull_request' }} + run: | + grafana-bench report \ + --trigger pr-backend-unit-tests-oss \ + --report-input go \ + --report-output log \ + --grafana-version "$(git rev-parse HEAD)" \ + --suite-name grafana-oss-unit-tests \ + /tmp/unit.log + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: false diff --git a/.github/workflows/pr-backend-unit-tests.yml b/.github/workflows/pr-backend-unit-tests.yml index 99ec9b0ea49..f81b9c8f6ac 100644 --- a/.github/workflows/pr-backend-unit-tests.yml +++ b/.github/workflows/pr-backend-unit-tests.yml @@ -1,78 +1,104 @@ name: Backend Unit Tests on: - workflow_dispatch: - push: - branches: - - main - paths-ignore: - - 'docs/**' - - '**/*.md' pull_request: paths-ignore: - 'docs/**' - '**/*.md' +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + permissions: contents: read id-token: write -env: - EDITION: 'oss' - WIRE_TAGS: 'oss' - jobs: - backend-testing-coverage: - name: Backend Testing & Coverage - runs-on: ubuntu-latest + grafana: + # Run this workflow only for PRs from forks; if it gets merged into `main` or `release-*`, + # the `pr-backend-unit-tests-enterprise` workflow will run instead + if: github.event_name == 'pull_request' && github.event.pull_request.head.repo.fork == true + name: Grafana + runs-on: ubuntu-latest-8-cores + continue-on-error: true steps: - name: Checkout code uses: actions/checkout@v4 - - name: Setup Go uses: actions/setup-go@v5 with: go-version-file: go.mod - cache: true - - - name: Install dependencies - run: | - sudo apt-get update - sudo apt-get install -y build-essential shared-mime-info - go install github.com/mfridman/tparse@c1754a1f484ac5cd422697b0fec635177ddc8507 # v0.17.0 - + - name: Restore GOCACHE + uses: actions/cache/restore@v4 + with: + key: go-test-cache-${{ github.ref_name }} + restore-keys: | + go-test-cache-${{ github.base_ref }} + go-test-cache-main + path: /home/runner/.cache/go-build - name: Generate Go code run: make gen-go - - name: Run unit tests - run: COVER_OPTS="-coverprofile=be-unit.cov -coverpkg=github.com/grafana/grafana/..." GO_TEST_OUTPUT="/tmp/unit.log" make test-go-unit - - - name: Process and upload coverage - uses: ./.github/actions/test-coverage-processor + run: make test-go-unit + - name: "Generate token" + id: generate_token + uses: tibdex/github-app-token@b62528385c34dbc9f38e5f4225ac829252d1ea92 with: - test-type: 'be-unit' - # Needs to be named 'unit.cov' based on the Makefile command `make test-go-unit` - coverage-file: 'unit.cov' - codecov-token: ${{ secrets.CODECOV_TOKEN }} - codecov-flag: 'be-unit' - codecov-name: 'be-unit' + app_id: ${{ secrets.GRAFANA_DELIVERY_BOT_APP_ID }} + private_key: ${{ secrets.GRAFANA_DELIVERY_BOT_APP_PEM }} + - name: Clear GOCACHE + run: gh cache delete go-test-cache-${{ github.ref_name }} + continue-on-error: true + env: + GH_TOKEN: ${{ steps.generate_token.outputs.token }} + - name: Save GOCACHE + uses: actions/cache/save@v4 + with: + key: go-test-cache-${{ github.ref_name }} + path: /home/runner/.cache/go-build - - name: Install Grafana Bench - # We can't allow forks here, as we need secret access. - if: ${{ github.event_name != 'pull_request' }} - uses: ./.github/actions/setup-grafana-bench - - - name: Process output for Bench - if: ${{ github.event_name != 'pull_request' }} - run: | - grafana-bench report \ - --trigger pr-backend-unit-tests-oss \ - --report-input go \ - --report-output log \ - --grafana-version "$(git rev-parse HEAD)" \ - --suite-name grafana-oss-unit-tests \ - /tmp/unit.log - -concurrency: - group: ${{ github.workflow }}-${{ github.ref }} - cancel-in-progress: true + grafana-enterprise: + # Run this workflow for non-PR events (like pushes to `main` or `release-*`) OR for internal PRs (PRs not from forks) + if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.fork == false + name: Grafana Enterprise + runs-on: ubuntu-latest-8-cores + steps: + - name: Checkout code + uses: actions/checkout@v4 + - name: Setup Go + uses: actions/setup-go@v5 + with: + go-version-file: go.mod + - name: Restore GOCACHE + uses: actions/cache/restore@v4 + with: + key: go-test-cache-${{ github.ref_name }}-enterprise + restore-keys: | + go-test-cache-${{ github.base_ref }}-enterprise + go-test-cache-main-enterprise + path: /home/runner/.cache/go-build + - name: Setup Enterprise + uses: ./.github/actions/setup-enterprise + with: + github-app-name: 'grafana-ci-bot' + - name: Generate Go code + run: make gen-go + - name: Run unit tests + run: make test-go-unit + - name: "Generate token" + id: generate_token + uses: tibdex/github-app-token@b62528385c34dbc9f38e5f4225ac829252d1ea92 + with: + app_id: ${{ secrets.GRAFANA_DELIVERY_BOT_APP_ID }} + private_key: ${{ secrets.GRAFANA_DELIVERY_BOT_APP_PEM }} + - name: Clear GOCACHE + run: gh cache delete go-test-cache-${{ github.ref_name }}-enterprise + continue-on-error: true + env: + GH_TOKEN: ${{ steps.generate_token.outputs.token }} + - name: Save GOCACHE + uses: actions/cache/save@v4 + with: + key: go-test-cache-${{ github.ref_name }}-enterprise + path: /home/runner/.cache/go-build diff --git a/.github/workflows/pr-codeql-analysis-go.yml b/.github/workflows/pr-codeql-analysis-go.yml index ce9082f4400..46645b7fa3f 100644 --- a/.github/workflows/pr-codeql-analysis-go.yml +++ b/.github/workflows/pr-codeql-analysis-go.yml @@ -40,7 +40,7 @@ jobs: # Initializes the CodeQL tools for scanning. - name: Initialize CodeQL - uses: github/codeql-action/init@v2 + uses: github/codeql-action/init@v3 with: languages: "go" @@ -50,4 +50,4 @@ jobs: make build-go - name: Perform CodeQL Analysis - uses: github/codeql-action/analyze@v2 + uses: github/codeql-action/analyze@v3 diff --git a/.github/workflows/pr-codeql-analysis-javascript.yml b/.github/workflows/pr-codeql-analysis-javascript.yml index 6c5264c926a..d24b7db9671 100644 --- a/.github/workflows/pr-codeql-analysis-javascript.yml +++ b/.github/workflows/pr-codeql-analysis-javascript.yml @@ -28,9 +28,9 @@ jobs: # Initializes the CodeQL tools for scanning. - name: Initialize CodeQL - uses: github/codeql-action/init@v2 + uses: github/codeql-action/init@v3 with: languages: "javascript" - name: Perform CodeQL Analysis - uses: github/codeql-action/analyze@v2 + uses: github/codeql-action/analyze@v3 diff --git a/.github/workflows/pr-codeql-analysis-python.yml b/.github/workflows/pr-codeql-analysis-python.yml index aea55365afc..4e8b1b14747 100644 --- a/.github/workflows/pr-codeql-analysis-python.yml +++ b/.github/workflows/pr-codeql-analysis-python.yml @@ -26,9 +26,9 @@ jobs: # Initializes the CodeQL tools for scanning. - name: Initialize CodeQL - uses: github/codeql-action/init@v2 + uses: github/codeql-action/init@v3 with: languages: "python" - name: Perform CodeQL Analysis - uses: github/codeql-action/analyze@v2 + uses: github/codeql-action/analyze@v3 diff --git a/.github/workflows/pr-lint-build-docs.yml b/.github/workflows/pr-lint-build-docs.yml new file mode 100644 index 00000000000..8ed36d3da9a --- /dev/null +++ b/.github/workflows/pr-lint-build-docs.yml @@ -0,0 +1,52 @@ +name: Documentation + +on: + pull_request: + paths: + - '*.md' + - 'docs/**' + - 'packages/**/*.md' + - 'latest.json' + +jobs: + docs: + name: Build & Verify Docs + runs-on: ubuntu-latest + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Setup Node.js + uses: actions/setup-node@v4 + with: + node-version: '22.11.0' + cache: 'yarn' + + - name: Install dependencies + run: yarn install --immutable + + - name: Lint docs + run: yarn run prettier:checkDocs + env: + # Increase memory for prettier due to large number of files + NODE_OPTIONS: --max_old_space_size=8192 + + - name: Build docs website + run: | + # Create and start a container from the docs-base image in detached mode + docker run -d --name docs-builder grafana/docs-base:latest tail -f /dev/null + + # Create the directory structure inside the container + docker exec docs-builder mkdir -p /hugo/content/docs/grafana/latest + + # Create the _index.md file + docker exec docs-builder /bin/sh -c "echo -e '---\nredirectURL: /docs/grafana/latest/\ntype: redirect\nversioned: true\n---\n' > /hugo/content/docs/grafana/_index.md" + + # Copy the docs sources from the host to the container + docker cp docs/sources/. docs-builder:/hugo/content/docs/grafana/latest/ + + # Run the make prod command inside the container + docker exec -w /hugo docs-builder make prod || echo "Build completed with warnings" + + # Clean up the container + docker rm -f docs-builder diff --git a/.github/workflows/pr-test-integration.yml b/.github/workflows/pr-test-integration.yml new file mode 100644 index 00000000000..f0a5f0a7fa3 --- /dev/null +++ b/.github/workflows/pr-test-integration.yml @@ -0,0 +1,126 @@ +name: Integration Tests + +on: + push: + branches: + - main + - release-*.*.* + pull_request: + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +jobs: + sqlite: + name: Sqlite + runs-on: ubuntu-latest-8-cores + steps: + - name: Checkout code + uses: actions/checkout@v4 + - name: Setup Go + uses: actions/setup-go@v5 + with: + go-version-file: go.mod + cache: true + - name: Restore GOCACHE + uses: actions/cache/restore@v4 + with: + key: go-test-cache-${{ github.ref_name }}-sqlite + restore-keys: | + go-test-cache-${{ github.base_ref }}-sqlite + go-test-cache-main-sqlite + path: /home/runner/.cache/go-build + - run: | + make gen-go + go test -tags=sqlite -timeout=5m -run '^TestIntegration' $(find ./pkg -type f -name '*_test.go' -exec grep -l '^func TestIntegration' '{}' '+' | grep -o '\(.*\)/' | sort -u) + - name: Save GOCACHE + uses: actions/cache/save@v4 + with: + key: go-test-cache-${{ github.ref_name }}-sqlite + path: /home/runner/.cache/go-build + mysql: + name: MySQL + runs-on: ubuntu-latest-8-cores + env: + GRAFANA_TEST_DB: mysql + MYSQL_HOST: 127.0.0.1 + services: + mysql: + image: mysql:8.0.32 + env: + MYSQL_ROOT_PASSWORD: rootpass + MYSQL_DATABASE: grafana_tests + MYSQL_USER: grafana + MYSQL_PASSWORD: password + options: --health-cmd="mysqladmin ping --silent" --health-interval=10s --health-timeout=5s --health-retries=3 + ports: + - 3306:3306 + steps: + - name: Checkout code + uses: actions/checkout@v4 + - name: Setup Go + uses: actions/setup-go@v5 + with: + go-version-file: go.mod + cache: true + - name: Restore GOCACHE + uses: actions/cache/restore@v4 + with: + key: go-test-cache-${{ github.ref_name }}-mysql + restore-keys: | + go-test-cache-${{ github.base_ref }}-mysql + go-test-cache-main-mysql + path: /home/runner/.cache/go-build + - run: | + sudo apt-get update -yq && sudo apt-get install mariadb-client + cat devenv/docker/blocks/mysql_tests/setup.sql | mariadb -h 127.0.0.1 -P 3306 -u root -prootpass --disable-ssl-verify-server-cert + make gen-go + go test -tags=mysql -p=1 -timeout=5m -run '^TestIntegration' $(find ./pkg -type f -name '*_test.go' -exec grep -l '^func TestIntegration' '{}' '+' | grep -o '\(.*\)/' | sort -u) + - name: Save GOCACHE + uses: actions/cache/save@v4 + with: + key: go-test-cache-${{ github.ref_name }}-mysql + path: /home/runner/.cache/go-build + postgres: + name: Postgres + runs-on: ubuntu-latest-8-cores + services: + postgres: + image: postgres:12.3-alpine + env: + POSTGRES_USER: grafanatest + POSTGRES_PASSWORD: grafanatest + POSTGRES_DB: grafanatest + ports: + - 5432:5432 + steps: + - name: Checkout code + uses: actions/checkout@v4 + - name: Setup Go + uses: actions/setup-go@v5 + with: + go-version-file: go.mod + cache: true + - name: Restore GOCACHE + uses: actions/cache/restore@v4 + with: + key: go-test-cache-${{ github.ref_name }}-postgres + restore-keys: | + go-test-cache-${{ github.base_ref }}-postgres + go-test-cache-main-postgres + path: /home/runner/.cache/go-build + - env: + GRAFANA_TEST_DB: postgres + PGPASSWORD: grafanatest + POSTGRES_HOST: 127.0.0.1 + run: | + sudo apt-get update -yq && sudo apt-get install postgresql-client + psql -p 5432 -h 127.0.0.1 -U grafanatest -d grafanatest -f devenv/docker/blocks/postgres_tests/setup.sql + make gen-go + go test -p=1 -tags=postgres -timeout=5m -run '^TestIntegration' $(find ./pkg -type f -name '*_test.go' -exec grep -l '^func TestIntegration' '{}' '+' | grep -o '\(.*\)/' | sort -u) + - name: Save GOCACHE + uses: actions/cache/save@v4 + with: + key: go-test-cache-${{ github.ref_name }}-postgres + path: /home/runner/.cache/go-build diff --git a/.github/workflows/storybook-verification.yml b/.github/workflows/storybook-verification.yml new file mode 100644 index 00000000000..72eb6a4ad4c --- /dev/null +++ b/.github/workflows/storybook-verification.yml @@ -0,0 +1,40 @@ +name: Verify Storybook + +on: + pull_request: + paths: + - 'packages/grafana-ui/**' + - '.github/workflows/storybook-verification.yml' + - '!docs/**' + - '!*.md' + +jobs: + verify-storybook: + name: Verify Storybook + runs-on: ubuntu-latest + + steps: + - name: Checkout code + uses: actions/checkout@v4 + + - name: Setup Node.js + uses: actions/setup-node@v4 + with: + node-version-file: 'package.json' + cache: 'yarn' + + - name: Install dependencies + run: yarn install --immutable + + - name: Run Storybook and E2E tests + uses: cypress-io/github-action@v6 + with: + browser: chrome + start: yarn storybook --quiet + wait-on: 'http://localhost:9001' + wait-on-timeout: 60 + command: yarn e2e:storybook + install: false + env: + HOST: localhost + PORT: 9001 diff --git a/.gitignore b/.gitignore index 1a8be100668..eabffd1dbf4 100644 --- a/.gitignore +++ b/.gitignore @@ -68,6 +68,8 @@ public/css/*.min.css .vscode/ !.vscode/launch.json .vs/ +.cursor/ + .eslintcache .stylelintcache diff --git a/.vscode/launch.json b/.vscode/launch.json index 67c4f82699b..50393b02272 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -11,6 +11,11 @@ "cwd": "${workspaceFolder}", "args": ["server", "--homepath", "${workspaceFolder}", "--packaging", "dev", "cfg:app_mode=development"] }, + { + "name": "Attach to Go Process", + "type": "go", + "request": "attach" + }, { "name": "Attach to Test Process", "type": "go", diff --git a/Dockerfile b/Dockerfile index 1ba856b9220..f5e45b6259d 100644 --- a/Dockerfile +++ b/Dockerfile @@ -48,13 +48,13 @@ ARG WIRE_TAGS="oss" ARG BINGO="true" RUN if grep -i -q alpine /etc/issue; then \ - apk add --no-cache \ - # This is required to allow building on arm64 due to https://github.com/golang/go/issues/22040 - binutils-gold \ - bash \ - # Install build dependencies - gcc g++ make git; \ - fi + apk add --no-cache \ + # This is required to allow building on arm64 due to https://github.com/golang/go/issues/22040 + binutils-gold \ + bash \ + # Install build dependencies + gcc g++ make git; \ + fi WORKDIR /tmp/grafana @@ -63,6 +63,7 @@ COPY .bingo .bingo # Include vendored dependencies COPY pkg/util/xorm pkg/util/xorm +COPY pkg/apis/secret pkg/apis/secret COPY pkg/apiserver pkg/apiserver COPY pkg/apimachinery pkg/apimachinery COPY pkg/build pkg/build @@ -75,6 +76,7 @@ COPY pkg/aggregator pkg/aggregator COPY apps/playlist apps/playlist COPY apps/investigations apps/investigations COPY apps/advisor apps/advisor +COPY apps/dashboard apps/dashboard COPY apps apps COPY kindsv2 kindsv2 COPY apps/alerting/notifications apps/alerting/notifications @@ -83,9 +85,9 @@ COPY pkg/plugins/codegen pkg/plugins/codegen RUN go mod download RUN if [[ "$BINGO" = "true" ]]; then \ - go install github.com/bwplotka/bingo@latest && \ - bingo get -v; \ - fi + go install github.com/bwplotka/bingo@latest && \ + bingo get -v; \ + fi COPY embed.go Makefile build.go package.json ./ COPY cue.mod cue.mod @@ -130,75 +132,75 @@ ARG GF_UID="472" ARG GF_GID="0" ENV PATH="/usr/share/grafana/bin:$PATH" \ - GF_PATHS_CONFIG="/etc/grafana/grafana.ini" \ - GF_PATHS_DATA="/var/lib/grafana" \ - GF_PATHS_HOME="/usr/share/grafana" \ - GF_PATHS_LOGS="/var/log/grafana" \ - GF_PATHS_PLUGINS="/var/lib/grafana/plugins" \ - GF_PATHS_PROVISIONING="/etc/grafana/provisioning" + GF_PATHS_CONFIG="/etc/grafana/grafana.ini" \ + GF_PATHS_DATA="/var/lib/grafana" \ + GF_PATHS_HOME="/usr/share/grafana" \ + GF_PATHS_LOGS="/var/log/grafana" \ + GF_PATHS_PLUGINS="/var/lib/grafana/plugins" \ + GF_PATHS_PROVISIONING="/etc/grafana/provisioning" WORKDIR $GF_PATHS_HOME # Install dependencies RUN if grep -i -q alpine /etc/issue; then \ - apk add --no-cache ca-certificates bash curl tzdata musl-utils && \ - apk info -vv | sort; \ - elif grep -i -q ubuntu /etc/issue; then \ - DEBIAN_FRONTEND=noninteractive && \ - apt-get update && \ - apt-get install -y ca-certificates curl tzdata musl && \ - apt-get autoremove -y && \ - rm -rf /var/lib/apt/lists/*; \ - else \ - echo 'ERROR: Unsupported base image' && /bin/false; \ - fi + apk add --no-cache ca-certificates bash curl tzdata musl-utils && \ + apk info -vv | sort; \ + elif grep -i -q ubuntu /etc/issue; then \ + DEBIAN_FRONTEND=noninteractive && \ + apt-get update && \ + apt-get install -y ca-certificates curl tzdata musl && \ + apt-get autoremove -y && \ + rm -rf /var/lib/apt/lists/*; \ + else \ + echo 'ERROR: Unsupported base image' && /bin/false; \ + fi # glibc support for alpine x86_64 only # docker run --rm --env STDOUT=1 sgerrand/glibc-builder 2.40 /usr/glibc-compat > glibc-bin-2.40.tar.gz ARG GLIBC_VERSION=2.40 RUN if grep -i -q alpine /etc/issue && [ `arch` = "x86_64" ]; then \ - wget -qO- "https://dl.grafana.com/glibc/glibc-bin-$GLIBC_VERSION.tar.gz" | tar zxf - -C / \ - usr/glibc-compat/lib/ld-linux-x86-64.so.2 \ - usr/glibc-compat/lib/libc.so.6 \ - usr/glibc-compat/lib/libdl.so.2 \ - usr/glibc-compat/lib/libm.so.6 \ - usr/glibc-compat/lib/libpthread.so.0 \ - usr/glibc-compat/lib/librt.so.1 \ - usr/glibc-compat/lib/libresolv.so.2 && \ - mkdir /lib64 && \ - ln -s /usr/glibc-compat/lib/ld-linux-x86-64.so.2 /lib64; \ - fi + wget -qO- "https://dl.grafana.com/glibc/glibc-bin-$GLIBC_VERSION.tar.gz" | tar zxf - -C / \ + usr/glibc-compat/lib/ld-linux-x86-64.so.2 \ + usr/glibc-compat/lib/libc.so.6 \ + usr/glibc-compat/lib/libdl.so.2 \ + usr/glibc-compat/lib/libm.so.6 \ + usr/glibc-compat/lib/libpthread.so.0 \ + usr/glibc-compat/lib/librt.so.1 \ + usr/glibc-compat/lib/libresolv.so.2 && \ + mkdir /lib64 && \ + ln -s /usr/glibc-compat/lib/ld-linux-x86-64.so.2 /lib64; \ + fi COPY --from=go-src /tmp/grafana/conf ./conf RUN if [ ! $(getent group "$GF_GID") ]; then \ - if grep -i -q alpine /etc/issue; then \ - addgroup -S -g $GF_GID grafana; \ - else \ - addgroup --system --gid $GF_GID grafana; \ - fi; \ - fi && \ - GF_GID_NAME=$(getent group $GF_GID | cut -d':' -f1) && \ - mkdir -p "$GF_PATHS_HOME/.aws" && \ - if grep -i -q alpine /etc/issue; then \ - adduser -S -u $GF_UID -G "$GF_GID_NAME" grafana; \ - else \ - adduser --system --uid $GF_UID --ingroup "$GF_GID_NAME" grafana; \ - fi && \ - mkdir -p "$GF_PATHS_PROVISIONING/datasources" \ - "$GF_PATHS_PROVISIONING/dashboards" \ - "$GF_PATHS_PROVISIONING/notifiers" \ - "$GF_PATHS_PROVISIONING/plugins" \ - "$GF_PATHS_PROVISIONING/access-control" \ - "$GF_PATHS_PROVISIONING/alerting" \ - "$GF_PATHS_LOGS" \ - "$GF_PATHS_PLUGINS" \ - "$GF_PATHS_DATA" && \ - cp conf/sample.ini "$GF_PATHS_CONFIG" && \ - cp conf/ldap.toml /etc/grafana/ldap.toml && \ - chown -R "grafana:$GF_GID_NAME" "$GF_PATHS_DATA" "$GF_PATHS_HOME/.aws" "$GF_PATHS_LOGS" "$GF_PATHS_PLUGINS" "$GF_PATHS_PROVISIONING" && \ - chmod -R 777 "$GF_PATHS_DATA" "$GF_PATHS_HOME/.aws" "$GF_PATHS_LOGS" "$GF_PATHS_PLUGINS" "$GF_PATHS_PROVISIONING" + if grep -i -q alpine /etc/issue; then \ + addgroup -S -g $GF_GID grafana; \ + else \ + addgroup --system --gid $GF_GID grafana; \ + fi; \ + fi && \ + GF_GID_NAME=$(getent group $GF_GID | cut -d':' -f1) && \ + mkdir -p "$GF_PATHS_HOME/.aws" && \ + if grep -i -q alpine /etc/issue; then \ + adduser -S -u $GF_UID -G "$GF_GID_NAME" grafana; \ + else \ + adduser --system --uid $GF_UID --ingroup "$GF_GID_NAME" grafana; \ + fi && \ + mkdir -p "$GF_PATHS_PROVISIONING/datasources" \ + "$GF_PATHS_PROVISIONING/dashboards" \ + "$GF_PATHS_PROVISIONING/notifiers" \ + "$GF_PATHS_PROVISIONING/plugins" \ + "$GF_PATHS_PROVISIONING/access-control" \ + "$GF_PATHS_PROVISIONING/alerting" \ + "$GF_PATHS_LOGS" \ + "$GF_PATHS_PLUGINS" \ + "$GF_PATHS_DATA" && \ + cp conf/sample.ini "$GF_PATHS_CONFIG" && \ + cp conf/ldap.toml /etc/grafana/ldap.toml && \ + chown -R "grafana:$GF_GID_NAME" "$GF_PATHS_DATA" "$GF_PATHS_HOME/.aws" "$GF_PATHS_LOGS" "$GF_PATHS_PLUGINS" "$GF_PATHS_PROVISIONING" && \ + chmod -R 777 "$GF_PATHS_DATA" "$GF_PATHS_HOME/.aws" "$GF_PATHS_LOGS" "$GF_PATHS_PLUGINS" "$GF_PATHS_PROVISIONING" COPY --from=go-src /tmp/grafana/bin/grafana* /tmp/grafana/bin/*/grafana* ./bin/ COPY --from=js-src /tmp/grafana/public ./public diff --git a/Makefile b/Makefile index 699cfb0652e..96839b5c323 100644 --- a/Makefile +++ b/Makefile @@ -18,6 +18,9 @@ GO_BUILD_FLAGS += $(if $(GO_BUILD_DEV),-dev) GO_BUILD_FLAGS += $(if $(GO_BUILD_TAGS),-build-tags=$(GO_BUILD_TAGS)) GO_BUILD_FLAGS += $(GO_RACE_FLAG) GO_TEST_OUTPUT := $(shell [ -n "$(GO_TEST_OUTPUT)" ] && echo '-json | tee $(GO_TEST_OUTPUT) | tparse -all') +GO_UNIT_COVERAGE ?= true +GO_UNIT_COVER_PROFILE ?= unit.cov +GO_INTEGRATION_COVER_PROFILE ?= integration.cov GIT_BASE = remotes/origin/main # GNU xargs has flag -r, and BSD xargs (e.g. MacOS) has that behaviour by default @@ -246,8 +249,13 @@ test-go: test-go-unit test-go-integration .PHONY: test-go-unit test-go-unit: ## Run unit tests for backend with flags. - @echo "test backend unit tests" - $(GO) test $(GO_RACE_FLAG) -short -covermode=atomic -coverprofile=unit.cov -timeout=30m $(GO_TEST_FILES) $(GO_TEST_OUTPUT) + @echo "backend unit tests" + $(GO) test $(GO_RACE_FLAG) -v -short -timeout=30m $(GO_TEST_FILES) $(GO_TEST_OUTPUT) + +.PHONY: test-go-unit-cov +test-go-unit-cov: ## Run unit tests for backend with flags and coverage + @echo "backend unit tests with coverage" + $(GO) test $(GO_RACE_FLAG) -v -short $(if $(filter true,$(GO_UNIT_COVERAGE)),-covermode=atomic -coverprofile=$(GO_UNIT_COVER_PROFILE) $(if $(GO_UNIT_TEST_COVERPKG),-coverpkg=$(GO_UNIT_TEST_COVERPKG)),) -timeout=30m $(GO_TEST_FILES) $(GO_TEST_OUTPUT) .PHONY: test-go-unit-pretty test-go-unit-pretty: check-tparse @@ -260,7 +268,7 @@ test-go-unit-pretty: check-tparse .PHONY: test-go-integration test-go-integration: ## Run integration tests for backend with flags. @echo "test backend integration tests" - $(GO) test $(GO_RACE_FLAG) -count=1 -run "^TestIntegration" -covermode=atomic -coverprofile=integration.cov -timeout=5m $(GO_INTEGRATION_TESTS) $(GO_TEST_OUTPUT) + $(GO) test $(GO_RACE_FLAG) -count=1 -run "^TestIntegration" -covermode=atomic -coverprofile=$(GO_INTEGRATION_COVER_PROFILE) -timeout=5m $(GO_INTEGRATION_TESTS) $(GO_TEST_OUTPUT) .PHONY: test-go-integration-alertmanager test-go-integration-alertmanager: ## Run integration tests for the remote alertmanager (config taken from the mimir_backend block). @@ -425,6 +433,7 @@ protobuf: ## Compile protobuf definitions go install google.golang.org/grpc/cmd/protoc-gen-go-grpc@v1.4.0 buf generate pkg/plugins/backendplugin/pluginextensionv2 --template pkg/plugins/backendplugin/pluginextensionv2/buf.gen.yaml buf generate pkg/plugins/backendplugin/secretsmanagerplugin --template pkg/plugins/backendplugin/secretsmanagerplugin/buf.gen.yaml + buf generate pkg/apis/secret/v0alpha1/decrypt --template pkg/apis/secret/v0alpha1/decrypt/buf.gen.yaml buf generate pkg/storage/unified/resource --template pkg/storage/unified/resource/buf.gen.yaml buf generate pkg/services/authz/proto/v1 --template pkg/services/authz/proto/v1/buf.gen.yaml buf generate pkg/services/ngalert/store/proto/v1 --template pkg/services/ngalert/store/proto/v1/buf.gen.yaml diff --git a/apps/advisor/pkg/app/app.go b/apps/advisor/pkg/app/app.go index efa9188f8e5..5b34db5a090 100644 --- a/apps/advisor/pkg/app/app.go +++ b/apps/advisor/pkg/app/app.go @@ -13,6 +13,7 @@ import ( "github.com/grafana/grafana/apps/advisor/pkg/app/checks" "github.com/grafana/grafana/apps/advisor/pkg/app/checkscheduler" "github.com/grafana/grafana/apps/advisor/pkg/app/checktyperegisterer" + "github.com/grafana/grafana/pkg/apimachinery/identity" "github.com/grafana/grafana/pkg/infra/log" "k8s.io/apimachinery/pkg/runtime/schema" "k8s.io/klog/v2" @@ -25,11 +26,6 @@ func New(cfg app.Config) (app.App, error) { return nil, fmt.Errorf("invalid config type") } checkRegistry := specificConfig.CheckRegistry - stackID := specificConfig.StackID - namespace, err := checks.GetNamespace(stackID) - if err != nil { - return nil, err - } log := log.New("advisor.app") // Prepare storage client @@ -59,28 +55,29 @@ func New(cfg app.Config) (app.App, error) { Validator: &simple.Validator{ ValidateFunc: func(ctx context.Context, req *app.AdmissionRequest) error { if req.Object != nil { - _, err := getCheck(req.Object, checkMap) - return err + check, err := getCheck(req.Object, checkMap) + if err != nil { + return err + } + if req.Action == resource.AdmissionActionCreate { + go func() { + log.Debug("Processing check", "namespace", req.Object.GetNamespace()) + requester, err := identity.GetRequester(ctx) + if err != nil { + log.Error("Error getting requester", "error", err) + return + } + ctx = identity.WithRequester(context.Background(), requester) + err = processCheck(ctx, client, req.Object, check) + if err != nil { + log.Error("Error processing check", "error", err) + } + }() + } } return nil }, }, - Watcher: &simple.Watcher{ - AddFunc: func(ctx context.Context, obj resource.Object) error { - log.Debug("Adding check", "namespace", obj.GetNamespace()) - if obj.GetNamespace() != namespace { - log.Debug("Skipping check in namespace", "namespace", obj.GetNamespace()) - return nil - } else { - log.Debug("Processing check in namespace", "namespace", obj.GetNamespace()) - } - check, err := getCheck(obj, checkMap) - if err != nil { - return err - } - return processCheck(ctx, client, obj, check) - }, - }, }, { Kind: advisorv0alpha1.CheckTypeKind(), diff --git a/apps/advisor/pkg/app/checkregistry/checkregistry.go b/apps/advisor/pkg/app/checkregistry/checkregistry.go index 335b9cc7567..31be8ae936e 100644 --- a/apps/advisor/pkg/app/checkregistry/checkregistry.go +++ b/apps/advisor/pkg/app/checkregistry/checkregistry.go @@ -11,6 +11,7 @@ import ( "github.com/grafana/grafana/pkg/services/pluginsintegration/plugincontext" "github.com/grafana/grafana/pkg/services/pluginsintegration/plugininstaller" "github.com/grafana/grafana/pkg/services/pluginsintegration/pluginstore" + "github.com/grafana/grafana/pkg/services/pluginsintegration/provisionedplugins" ) type CheckService interface { @@ -25,11 +26,14 @@ type Service struct { pluginRepo repo.Service pluginPreinstall plugininstaller.Preinstall managedPlugins managedplugins.Manager + provisionedPlugins provisionedplugins.Manager } func ProvideService(datasourceSvc datasources.DataSourceService, pluginStore pluginstore.Store, pluginContextProvider *plugincontext.Provider, pluginClient plugins.Client, - pluginRepo repo.Service, pluginPreinstall plugininstaller.Preinstall, managedPlugins managedplugins.Manager) *Service { + pluginRepo repo.Service, pluginPreinstall plugininstaller.Preinstall, managedPlugins managedplugins.Manager, + provisionedPlugins provisionedplugins.Manager, +) *Service { return &Service{ datasourceSvc: datasourceSvc, pluginStore: pluginStore, @@ -38,6 +42,7 @@ func ProvideService(datasourceSvc datasources.DataSourceService, pluginStore plu pluginRepo: pluginRepo, pluginPreinstall: pluginPreinstall, managedPlugins: managedPlugins, + provisionedPlugins: provisionedPlugins, } } @@ -54,6 +59,7 @@ func (s *Service) Checks() []checks.Check { s.pluginRepo, s.pluginPreinstall, s.managedPlugins, + s.provisionedPlugins, ), } } diff --git a/apps/advisor/pkg/app/checks/plugincheck/check.go b/apps/advisor/pkg/app/checks/plugincheck/check.go index 45c54d4fdc0..3b08e0c5f6f 100644 --- a/apps/advisor/pkg/app/checks/plugincheck/check.go +++ b/apps/advisor/pkg/app/checks/plugincheck/check.go @@ -4,15 +4,18 @@ import ( "context" "fmt" sysruntime "runtime" + "slices" "github.com/Masterminds/semver/v3" advisor "github.com/grafana/grafana/apps/advisor/pkg/apis/advisor/v0alpha1" "github.com/grafana/grafana/apps/advisor/pkg/app/checks" "github.com/grafana/grafana/pkg/cmd/grafana-cli/services" + "github.com/grafana/grafana/pkg/infra/log" "github.com/grafana/grafana/pkg/plugins/repo" "github.com/grafana/grafana/pkg/services/pluginsintegration/managedplugins" "github.com/grafana/grafana/pkg/services/pluginsintegration/plugininstaller" "github.com/grafana/grafana/pkg/services/pluginsintegration/pluginstore" + "github.com/grafana/grafana/pkg/services/pluginsintegration/provisionedplugins" ) func New( @@ -20,20 +23,23 @@ func New( pluginRepo repo.Service, pluginPreinstall plugininstaller.Preinstall, managedPlugins managedplugins.Manager, + provisionedPlugins provisionedplugins.Manager, ) checks.Check { return &check{ - PluginStore: pluginStore, - PluginRepo: pluginRepo, - PluginPreinstall: pluginPreinstall, - ManagedPlugins: managedPlugins, + PluginStore: pluginStore, + PluginRepo: pluginRepo, + PluginPreinstall: pluginPreinstall, + ManagedPlugins: managedPlugins, + ProvisionedPlugins: provisionedPlugins, } } type check struct { - PluginStore pluginstore.Store - PluginRepo repo.Service - PluginPreinstall plugininstaller.Preinstall - ManagedPlugins managedplugins.Manager + PluginStore pluginstore.Store + PluginRepo repo.Service + PluginPreinstall plugininstaller.Preinstall + ManagedPlugins managedplugins.Manager + ProvisionedPlugins provisionedplugins.Manager } func (c *check) ID() string { @@ -55,9 +61,11 @@ func (c *check) Steps() []checks.Step { PluginRepo: c.PluginRepo, }, &updateStep{ - PluginRepo: c.PluginRepo, - PluginPreinstall: c.PluginPreinstall, - ManagedPlugins: c.ManagedPlugins, + PluginRepo: c.PluginRepo, + PluginPreinstall: c.PluginPreinstall, + ManagedPlugins: c.ManagedPlugins, + ProvisionedPlugins: c.ProvisionedPlugins, + log: log.New("advisor.check.plugin.update"), }, } } @@ -117,9 +125,12 @@ func (s *deprecationStep) Run(ctx context.Context, _ *advisor.CheckSpec, it any) } type updateStep struct { - PluginRepo repo.Service - PluginPreinstall plugininstaller.Preinstall - ManagedPlugins managedplugins.Manager + PluginRepo repo.Service + PluginPreinstall plugininstaller.Preinstall + ManagedPlugins managedplugins.Manager + ProvisionedPlugins provisionedplugins.Manager + provisionedPlugins []string + log log.Logger } func (s *updateStep) Title() string { @@ -146,11 +157,19 @@ func (s *updateStep) Run(ctx context.Context, _ *advisor.CheckSpec, i any) (*adv // Skip if it's a core plugin if p.IsCorePlugin() { + s.log.Debug("Skipping core plugin", "plugin", p.ID) return nil, nil } // Skip if it's managed or pinned if s.isManaged(ctx, p.ID) || s.PluginPreinstall.IsPinned(p.ID) { + s.log.Debug("Skipping managed or pinned plugin", "plugin", p.ID) + return nil, nil + } + + // Skip if it's provisioned + if s.isProvisioned(ctx, p.ID) { + s.log.Debug("Skipping provisioned plugin", "plugin", p.ID) return nil, nil } @@ -197,3 +216,14 @@ func (s *updateStep) isManaged(ctx context.Context, pluginID string) bool { } return false } + +func (s *updateStep) isProvisioned(ctx context.Context, pluginID string) bool { + if s.provisionedPlugins == nil { + var err error + s.provisionedPlugins, err = s.ProvisionedPlugins.ProvisionedPlugins(ctx) + if err != nil { + return false + } + } + return slices.Contains(s.provisionedPlugins, pluginID) +} diff --git a/apps/advisor/pkg/app/checks/plugincheck/check_test.go b/apps/advisor/pkg/app/checks/plugincheck/check_test.go index 13b2a17ea1b..c8cdc965a32 100644 --- a/apps/advisor/pkg/app/checks/plugincheck/check_test.go +++ b/apps/advisor/pkg/app/checks/plugincheck/check_test.go @@ -10,6 +10,7 @@ import ( "github.com/grafana/grafana/pkg/services/pluginsintegration/managedplugins" "github.com/grafana/grafana/pkg/services/pluginsintegration/plugininstaller" "github.com/grafana/grafana/pkg/services/pluginsintegration/pluginstore" + "github.com/grafana/grafana/pkg/services/pluginsintegration/provisionedplugins" "github.com/stretchr/testify/assert" ) @@ -21,6 +22,7 @@ func TestRun(t *testing.T) { pluginArchives map[string]*repo.PluginArchiveInfo pluginPreinstalled []string pluginManaged []string + pluginProvisioned []string expectedFailures []advisor.CheckReportFailure }{ { @@ -131,6 +133,20 @@ func TestRun(t *testing.T) { pluginManaged: []string{"plugin4"}, expectedFailures: []advisor.CheckReportFailure{}, }, + { + name: "Provisioned plugin", + plugins: []pluginstore.Plugin{ + {JSONData: plugins.JSONData{ID: "plugin5", Info: plugins.Info{Version: "1.0.0"}}}, + }, + pluginInfo: map[string]*repo.PluginInfo{ + "plugin5": {Status: "active"}, + }, + pluginArchives: map[string]*repo.PluginArchiveInfo{ + "plugin5": {Version: "1.1.0"}, + }, + pluginProvisioned: []string{"plugin5"}, + expectedFailures: []advisor.CheckReportFailure{}, + }, } for _, tt := range tests { @@ -142,7 +158,8 @@ func TestRun(t *testing.T) { } pluginPreinstall := &mockPluginPreinstall{pinned: tt.pluginPreinstalled} managedPlugins := &mockManagedPlugins{managed: tt.pluginManaged} - check := New(pluginStore, pluginRepo, pluginPreinstall, managedPlugins) + provisionedPlugins := &mockProvisionedPlugins{provisioned: tt.pluginProvisioned} + check := New(pluginStore, pluginRepo, pluginPreinstall, managedPlugins, provisionedPlugins) items, err := check.Items(context.Background()) assert.NoError(t, err) @@ -208,3 +225,12 @@ type mockManagedPlugins struct { func (m *mockManagedPlugins) ManagedPlugins(ctx context.Context) []string { return m.managed } + +type mockProvisionedPlugins struct { + provisionedplugins.Manager + provisioned []string +} + +func (m *mockProvisionedPlugins) ProvisionedPlugins(ctx context.Context) ([]string, error) { + return m.provisioned, nil +} diff --git a/apps/advisor/pkg/app/utils.go b/apps/advisor/pkg/app/utils.go index 8c1b6c00eb8..86ad12a714b 100644 --- a/apps/advisor/pkg/app/utils.go +++ b/apps/advisor/pkg/app/utils.go @@ -6,13 +6,9 @@ import ( "fmt" "sync" - claims "github.com/grafana/authlib/types" "github.com/grafana/grafana-app-sdk/resource" advisorv0alpha1 "github.com/grafana/grafana/apps/advisor/pkg/apis/advisor/v0alpha1" "github.com/grafana/grafana/apps/advisor/pkg/app/checks" - "github.com/grafana/grafana/pkg/apimachinery/identity" - "github.com/grafana/grafana/pkg/apimachinery/utils" - "github.com/grafana/grafana/pkg/services/user" ) func getCheck(obj resource.Object, checkMap map[string]checks.Check) (checks.Check, error) { @@ -39,6 +35,9 @@ func getStatusAnnotation(obj resource.Object) string { func setStatusAnnotation(ctx context.Context, client resource.Client, obj resource.Object, status string) error { annotations := obj.GetAnnotations() + if annotations == nil { + annotations = map[string]string{} + } annotations[checks.StatusAnnotation] = status return client.PatchInto(ctx, obj.GetStaticMetadata().Identifier(), resource.PatchRequest{ Operations: []resource.PatchOperation{{ @@ -59,20 +58,6 @@ func processCheck(ctx context.Context, client resource.Client, obj resource.Obje if !ok { return fmt.Errorf("invalid object type") } - // Populate ctx with the user that created the check - meta, err := utils.MetaAccessor(obj) - if err != nil { - return err - } - createdBy := meta.GetCreatedBy() - typ, uid, err := claims.ParseTypeID(createdBy) - if err != nil { - return err - } - ctx = identity.WithRequester(ctx, &user.SignedInUser{ - UserUID: uid, - FallbackType: typ, - }) // Get the items to check items, err := check.Items(ctx) if err != nil { diff --git a/apps/alerting/notifications/go.mod b/apps/alerting/notifications/go.mod index eaa0b14475d..aac1a5b28fb 100644 --- a/apps/alerting/notifications/go.mod +++ b/apps/alerting/notifications/go.mod @@ -62,13 +62,13 @@ require ( go.etcd.io/etcd/client/v3 v3.5.16 // indirect go.opentelemetry.io/auto/sdk v1.1.0 // indirect go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.59.0 // indirect - go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.59.0 // indirect - go.opentelemetry.io/otel v1.34.0 // indirect + go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.60.0 // indirect + go.opentelemetry.io/otel v1.35.0 // indirect go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.34.0 // indirect go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.34.0 // indirect - go.opentelemetry.io/otel/metric v1.34.0 // indirect - go.opentelemetry.io/otel/sdk v1.34.0 // indirect - go.opentelemetry.io/otel/trace v1.34.0 // indirect + go.opentelemetry.io/otel/metric v1.35.0 // indirect + go.opentelemetry.io/otel/sdk v1.35.0 // indirect + go.opentelemetry.io/otel/trace v1.35.0 // indirect go.opentelemetry.io/proto/otlp v1.5.0 // indirect go.uber.org/multierr v1.11.0 // indirect go.uber.org/zap v1.27.0 // indirect diff --git a/apps/alerting/notifications/go.sum b/apps/alerting/notifications/go.sum index 26ad8bf9fc2..c2e7b8b7d13 100644 --- a/apps/alerting/notifications/go.sum +++ b/apps/alerting/notifications/go.sum @@ -180,22 +180,22 @@ go.opentelemetry.io/auto/sdk v1.1.0 h1:cH53jehLUN6UFLY71z+NDOiNJqDdPRaXzTel0sJyS go.opentelemetry.io/auto/sdk v1.1.0/go.mod h1:3wSPjt5PWp2RhlCcmmOial7AvC4DQqZb7a7wCow3W8A= go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.59.0 h1:rgMkmiGfix9vFJDcDi1PK8WEQP4FLQwLDfhp5ZLpFeE= go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.59.0/go.mod h1:ijPqXp5P6IRRByFVVg9DY8P5HkxkHE5ARIa+86aXPf4= -go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.59.0 h1:CV7UdSGJt/Ao6Gp4CXckLxVRRsRgDHoI8XjbL3PDl8s= -go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.59.0/go.mod h1:FRmFuRJfag1IZ2dPkHnEoSFVgTVPUd2qf5Vi69hLb8I= -go.opentelemetry.io/otel v1.34.0 h1:zRLXxLCgL1WyKsPVrgbSdMN4c0FMkDAskSTQP+0hdUY= -go.opentelemetry.io/otel v1.34.0/go.mod h1:OWFPOQ+h4G8xpyjgqo4SxJYdDQ/qmRH+wivy7zzx9oI= +go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.60.0 h1:sbiXRNDSWJOTobXh5HyQKjq6wUC5tNybqjIqDpAY4CU= +go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.60.0/go.mod h1:69uWxva0WgAA/4bu2Yy70SLDBwZXuQ6PbBpbsa5iZrQ= +go.opentelemetry.io/otel v1.35.0 h1:xKWKPxrxB6OtMCbmMY021CqC45J+3Onta9MqjhnusiQ= +go.opentelemetry.io/otel v1.35.0/go.mod h1:UEqy8Zp11hpkUrL73gSlELM0DupHoiq72dR+Zqel/+Y= go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.34.0 h1:OeNbIYk/2C15ckl7glBlOBp5+WlYsOElzTNmiPW/x60= go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.34.0/go.mod h1:7Bept48yIeqxP2OZ9/AqIpYS94h2or0aB4FypJTc8ZM= go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.34.0 h1:tgJ0uaNS4c98WRNUEx5U3aDlrDOI5Rs+1Vifcw4DJ8U= go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.34.0/go.mod h1:U7HYyW0zt/a9x5J1Kjs+r1f/d4ZHnYFclhYY2+YbeoE= -go.opentelemetry.io/otel/metric v1.34.0 h1:+eTR3U0MyfWjRDhmFMxe2SsW64QrZ84AOhvqS7Y+PoQ= -go.opentelemetry.io/otel/metric v1.34.0/go.mod h1:CEDrp0fy2D0MvkXE+dPV7cMi8tWZwX3dmaIhwPOaqHE= -go.opentelemetry.io/otel/sdk v1.34.0 h1:95zS4k/2GOy069d321O8jWgYsW3MzVV+KuSPKp7Wr1A= -go.opentelemetry.io/otel/sdk v1.34.0/go.mod h1:0e/pNiaMAqaykJGKbi+tSjWfNNHMTxoC9qANsCzbyxU= -go.opentelemetry.io/otel/sdk/metric v1.32.0 h1:rZvFnvmvawYb0alrYkjraqJq0Z4ZUJAiyYCU9snn1CU= -go.opentelemetry.io/otel/sdk/metric v1.32.0/go.mod h1:PWeZlq0zt9YkYAp3gjKZ0eicRYvOh1Gd+X99x6GHpCQ= -go.opentelemetry.io/otel/trace v1.34.0 h1:+ouXS2V8Rd4hp4580a8q23bg0azF2nI8cqLYnC8mh/k= -go.opentelemetry.io/otel/trace v1.34.0/go.mod h1:Svm7lSjQD7kG7KJ/MUHPVXSDGz2OX4h0M2jHBhmSfRE= +go.opentelemetry.io/otel/metric v1.35.0 h1:0znxYu2SNyuMSQT4Y9WDWej0VpcsxkuklLa4/siN90M= +go.opentelemetry.io/otel/metric v1.35.0/go.mod h1:nKVFgxBZ2fReX6IlyW28MgZojkoAkJGaE8CpgeAU3oE= +go.opentelemetry.io/otel/sdk v1.35.0 h1:iPctf8iprVySXSKJffSS79eOjl9pvxV9ZqOWT0QejKY= +go.opentelemetry.io/otel/sdk v1.35.0/go.mod h1:+ga1bZliga3DxJ3CQGg3updiaAJoNECOgJREo9KHGQg= +go.opentelemetry.io/otel/sdk/metric v1.35.0 h1:1RriWBmCKgkeHEhM7a2uMjMUfP7MsOF5JpUCaEqEI9o= +go.opentelemetry.io/otel/sdk/metric v1.35.0/go.mod h1:is6XYCUMpcKi+ZsOvfluY5YstFnhW0BidkR+gL+qN+w= +go.opentelemetry.io/otel/trace v1.35.0 h1:dPpEfJu1sDIqruz7BHFG3c7528f6ddfSWfFDVt/xgMs= +go.opentelemetry.io/otel/trace v1.35.0/go.mod h1:WUk7DtFp1Aw2MkvqGdwiXYDZZNvA/1J8o6xRXLrIkyc= go.opentelemetry.io/proto/otlp v1.5.0 h1:xJvq7gMzB31/d406fB8U5CBdyQGw4P399D1aQWU/3i4= go.opentelemetry.io/proto/otlp v1.5.0/go.mod h1:keN8WnHxOy8PG0rQZjJJ5A2ebUoafqWp0eVQ4yIXvJ4= go.uber.org/goleak v1.3.0 h1:2K3zAYmnTNqV73imy9J1T3WC+gmCePx2hEGkimedGto= @@ -214,8 +214,8 @@ golang.org/x/exp v0.0.0-20240909161429-701f63a606c0/go.mod h1:2TbTHSBQa924w8M6Xs golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= -golang.org/x/mod v0.22.0 h1:D4nJWe9zXqHOmWqj4VMOJhvzj7bEZg4wEYa759z1pH4= -golang.org/x/mod v0.22.0/go.mod h1:6SkKJ3Xj0I0BrPOZoBy3bdMptDDU9oJrpohJ3eWZ1fY= +golang.org/x/mod v0.23.0 h1:Zb7khfcRGKk+kqfxFaP5tZqCnDZMjC5VtUBs87Hr6QM= +golang.org/x/mod v0.23.0/go.mod h1:6SkKJ3Xj0I0BrPOZoBy3bdMptDDU9oJrpohJ3eWZ1fY= golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20181201002055-351d144fa1fc/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= @@ -252,8 +252,8 @@ golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGm golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= -golang.org/x/tools v0.29.0 h1:Xx0h3TtM9rzQpQuR4dKLrdglAmCEN5Oi+P74JdhdzXE= -golang.org/x/tools v0.29.0/go.mod h1:KMQVMRsVxU6nHCFXrBPhDB8XncLNLM0lIy/F14RP588= +golang.org/x/tools v0.30.0 h1:BgcpHewrV5AUp2G9MebG4XPFI1E2W41zU1SaqVA9vJY= +golang.org/x/tools v0.30.0/go.mod h1:c347cR/OJfw5TI+GfX7RUPNMdDRRbjvYTS0jPyvsVtY= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= diff --git a/apps/dashboard/Makefile b/apps/dashboard/Makefile index d95e25e1abd..d9d8b7de608 100644 --- a/apps/dashboard/Makefile +++ b/apps/dashboard/Makefile @@ -2,7 +2,7 @@ generate: @grafana-app-sdk generate \ --source=./kinds/ \ - --gogenpath=../../pkg/apis \ + --gogenpath=./pkg/apis \ --tsgenpath=../../packages/grafana-schema/src/schema \ --grouping=group \ --defencoding=none \ diff --git a/apps/dashboard/go.mod b/apps/dashboard/go.mod new file mode 100644 index 00000000000..8c2285debc3 --- /dev/null +++ b/apps/dashboard/go.mod @@ -0,0 +1,125 @@ +module github.com/grafana/grafana/apps/dashboard + +go 1.23.7 + +require ( + github.com/grafana/grafana-app-sdk v0.31.0 + github.com/grafana/grafana-plugin-sdk-go v0.272.0 + github.com/grafana/grafana/pkg/apimachinery v0.0.0-20250312121619-f64be062c432 + github.com/stretchr/testify v1.10.0 + k8s.io/apimachinery v0.32.1 + k8s.io/kube-openapi v0.0.0-20241105132330-32ad38e42d3f +) + +require ( + github.com/BurntSushi/toml v1.4.0 // indirect + github.com/apache/arrow-go/v18 v18.0.1-0.20241212180703-82be143d7c30 // indirect + github.com/asaskevich/govalidator v0.0.0-20230301143203-a9d515a09cc2 // indirect + github.com/beorn7/perks v1.0.1 // indirect + github.com/cenkalti/backoff/v4 v4.3.0 // indirect + github.com/cespare/xxhash/v2 v2.3.0 // indirect + github.com/cheekybits/genny v1.0.0 // indirect + github.com/chromedp/cdproto v0.0.0-20240810084448-b931b754e476 // indirect + github.com/cpuguy83/go-md2man/v2 v2.0.6 // indirect + github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc // indirect + github.com/elazarl/goproxy v1.7.2 // indirect + github.com/emicklei/go-restful/v3 v3.11.0 // indirect + github.com/fatih/color v1.17.0 // indirect + github.com/fsnotify/fsnotify v1.8.0 // indirect + github.com/fxamacker/cbor/v2 v2.7.0 // indirect + github.com/getkin/kin-openapi v0.129.0 // indirect + github.com/go-logr/logr v1.4.2 // indirect + github.com/go-logr/stdr v1.2.2 // indirect + github.com/go-openapi/jsonpointer v0.21.0 // indirect + github.com/go-openapi/jsonreference v0.21.0 // indirect + github.com/go-openapi/swag v0.23.0 // indirect + github.com/goccy/go-json v0.10.4 // indirect + github.com/gogo/protobuf v1.3.2 // indirect + github.com/golang/protobuf v1.5.4 // indirect + github.com/google/flatbuffers v24.3.25+incompatible // indirect + github.com/google/gnostic-models v0.6.8 // indirect + github.com/google/go-cmp v0.7.0 // indirect + github.com/google/gofuzz v1.2.0 // indirect + github.com/google/uuid v1.6.0 // indirect + github.com/gorilla/mux v1.8.1 // indirect + github.com/grafana/grafana-app-sdk/logging v0.30.0 // indirect + github.com/grafana/otel-profiling-go v0.5.1 // indirect + github.com/grafana/pyroscope-go/godeltaprof v0.1.8 // indirect + github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus v1.0.1 // indirect + github.com/grpc-ecosystem/go-grpc-middleware/v2 v2.3.1 // indirect + github.com/grpc-ecosystem/grpc-gateway/v2 v2.26.1 // indirect + github.com/hashicorp/go-hclog v1.6.3 // indirect + github.com/hashicorp/go-plugin v1.6.3 // indirect + github.com/hashicorp/yamux v0.1.1 // indirect + github.com/josharian/intern v1.0.0 // indirect + github.com/json-iterator/go v1.1.12 // indirect + github.com/jszwedko/go-datemath v0.1.1-0.20230526204004-640a500621d6 // indirect + github.com/klauspost/compress v1.17.11 // indirect + github.com/klauspost/cpuid/v2 v2.2.9 // indirect + github.com/magefile/mage v1.15.0 // indirect + github.com/mailru/easyjson v0.7.7 // indirect + github.com/mattetti/filebuffer v1.0.1 // indirect + github.com/mattn/go-colorable v0.1.13 // indirect + github.com/mattn/go-isatty v0.0.20 // indirect + github.com/mattn/go-runewidth v0.0.16 // indirect + github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd // indirect + github.com/modern-go/reflect2 v1.0.2 // indirect + github.com/mohae/deepcopy v0.0.0-20170929034955-c48cc78d4826 // indirect + github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 // indirect + github.com/oasdiff/yaml v0.0.0-20241210131133-6b86fb107d80 // indirect + github.com/oasdiff/yaml3 v0.0.0-20241210130736-a94c01f36349 // indirect + github.com/oklog/run v1.1.0 // indirect + github.com/olekukonko/tablewriter v0.0.5 // indirect + github.com/perimeterx/marshmallow v1.1.5 // indirect + github.com/pierrec/lz4/v4 v4.1.21 // indirect + github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 // indirect + github.com/prometheus/client_golang v1.21.0 // indirect + github.com/prometheus/client_model v0.6.1 // indirect + github.com/prometheus/common v0.62.0 // indirect + github.com/prometheus/procfs v0.15.1 // indirect + github.com/rivo/uniseg v0.4.7 // indirect + github.com/russross/blackfriday/v2 v2.1.0 // indirect + github.com/smartystreets/goconvey v1.6.4 // indirect + github.com/unknwon/bra v0.0.0-20200517080246-1e3013ecaff8 // indirect + github.com/unknwon/com v1.0.1 // indirect + github.com/unknwon/log v0.0.0-20200308114134-929b1006e34a // indirect + github.com/urfave/cli v1.22.16 // indirect + github.com/x448/float16 v0.8.4 // indirect + github.com/zeebo/xxh3 v1.0.2 // indirect + go.opentelemetry.io/auto/sdk v1.1.0 // indirect + go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.59.0 // indirect + go.opentelemetry.io/contrib/instrumentation/net/http/httptrace/otelhttptrace v0.60.0 // indirect + go.opentelemetry.io/contrib/propagators/jaeger v1.34.0 // indirect + go.opentelemetry.io/contrib/samplers/jaegerremote v0.28.0 // indirect + go.opentelemetry.io/otel v1.35.0 // indirect + go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.34.0 // indirect + go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.34.0 // indirect + go.opentelemetry.io/otel/metric v1.35.0 // indirect + go.opentelemetry.io/otel/sdk v1.35.0 // indirect + go.opentelemetry.io/otel/trace v1.35.0 // indirect + go.opentelemetry.io/proto/otlp v1.5.0 // indirect + golang.org/x/exp v0.0.0-20240909161429-701f63a606c0 // indirect + golang.org/x/mod v0.23.0 // indirect + golang.org/x/net v0.36.0 // indirect + golang.org/x/oauth2 v0.27.0 // indirect + golang.org/x/sync v0.11.0 // indirect + golang.org/x/sys v0.30.0 // indirect + golang.org/x/term v0.29.0 // indirect + golang.org/x/text v0.22.0 // indirect + golang.org/x/time v0.9.0 // indirect + golang.org/x/tools v0.30.0 // indirect + golang.org/x/xerrors v0.0.0-20240903120638-7835f813f4da // indirect + google.golang.org/genproto/googleapis/api v0.0.0-20250204164813-702378808489 // indirect + google.golang.org/genproto/googleapis/rpc v0.0.0-20250207221924-e9438ea467c6 // indirect + google.golang.org/grpc v1.70.0 // indirect + google.golang.org/protobuf v1.36.5 // indirect + gopkg.in/fsnotify/fsnotify.v1 v1.4.7 // indirect + gopkg.in/inf.v0 v0.9.1 // indirect + gopkg.in/yaml.v3 v3.0.1 // indirect + k8s.io/client-go v0.32.1 // indirect + k8s.io/klog/v2 v2.130.1 // indirect + k8s.io/utils v0.0.0-20241104100929-3ea5e8cea738 // indirect + sigs.k8s.io/json v0.0.0-20241010143419-9aa6b5e7a4b3 // indirect + sigs.k8s.io/structured-merge-diff/v4 v4.5.0 // indirect + sigs.k8s.io/yaml v1.4.0 // indirect +) diff --git a/apps/dashboard/go.sum b/apps/dashboard/go.sum new file mode 100644 index 00000000000..33cfb1d9e90 --- /dev/null +++ b/apps/dashboard/go.sum @@ -0,0 +1,377 @@ +github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= +github.com/BurntSushi/toml v1.4.0 h1:kuoIxZQy2WRRk1pttg9asf+WVv6tWQuBNVmK8+nqPr0= +github.com/BurntSushi/toml v1.4.0/go.mod h1:ukJfTF/6rtPPRCnwkur4qwRxa8vTRFBF0uk2lLoLwho= +github.com/andybalholm/brotli v1.1.1 h1:PR2pgnyFznKEugtsUo0xLdDop5SKXd5Qf5ysW+7XdTA= +github.com/andybalholm/brotli v1.1.1/go.mod h1:05ib4cKhjx3OQYUY22hTVd34Bc8upXjOLL2rKwwZBoA= +github.com/apache/arrow-go/v18 v18.0.1-0.20241212180703-82be143d7c30 h1:hXVi7QKuCQ0E8Yujfu9b0f0RnzZ72efpWvPnZgnJPrE= +github.com/apache/arrow-go/v18 v18.0.1-0.20241212180703-82be143d7c30/go.mod h1:RNuWDIiGjq5nndL2PyQrndUy9nMLwheA3uWaAV7fe4U= +github.com/apache/thrift v0.21.0 h1:tdPmh/ptjE1IJnhbhrcl2++TauVjy242rkV/UzJChnE= +github.com/apache/thrift v0.21.0/go.mod h1:W1H8aR/QRtYNvrPeFXBtobyRkd0/YVhTc6i07XIAgDw= +github.com/asaskevich/govalidator v0.0.0-20230301143203-a9d515a09cc2 h1:DklsrG3dyBCFEj5IhUbnKptjxatkF07cF2ak3yi77so= +github.com/asaskevich/govalidator v0.0.0-20230301143203-a9d515a09cc2/go.mod h1:WaHUgvxTVq04UNunO+XhnAqY/wQc+bxr74GqbsZ/Jqw= +github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM= +github.com/beorn7/perks v1.0.1/go.mod h1:G2ZrVWU2WbWT9wwq4/hrbKbnv/1ERSJQ0ibhJ6rlkpw= +github.com/bufbuild/protocompile v0.4.0 h1:LbFKd2XowZvQ/kajzguUp2DC9UEIQhIq77fZZlaQsNA= +github.com/bufbuild/protocompile v0.4.0/go.mod h1:3v93+mbWn/v3xzN+31nwkJfrEpAUwp+BagBSZWx+TP8= +github.com/cenkalti/backoff/v4 v4.3.0 h1:MyRJ/UdXutAwSAT+s3wNd7MfTIcy71VQueUuFK343L8= +github.com/cenkalti/backoff/v4 v4.3.0/go.mod h1:Y3VNntkOUPxTVeUxJ/G5vcM//AlwfmyYozVcomhLiZE= +github.com/cespare/xxhash/v2 v2.3.0 h1:UL815xU9SqsFlibzuggzjXhog7bL6oX9BbNZnL2UFvs= +github.com/cespare/xxhash/v2 v2.3.0/go.mod h1:VGX0DQ3Q6kWi7AoAeZDth3/j3BFtOZR5XLFGgcrjCOs= +github.com/cheekybits/genny v1.0.0 h1:uGGa4nei+j20rOSeDeP5Of12XVm7TGUd4dJA9RDitfE= +github.com/cheekybits/genny v1.0.0/go.mod h1:+tQajlRqAUrPI7DOSpB0XAqZYtQakVtB7wXkRAgjxjQ= +github.com/chromedp/cdproto v0.0.0-20240810084448-b931b754e476 h1:VnjHsRXCRti7Av7E+j4DCha3kf68echfDzQ+wD11SBU= +github.com/chromedp/cdproto v0.0.0-20240810084448-b931b754e476/go.mod h1:GKljq0VrfU4D5yc+2qA6OVr8pmO/MBbPEWqWQ/oqGEs= +github.com/cpuguy83/go-md2man/v2 v2.0.0-20190314233015-f79a8a8ca69d/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= +github.com/cpuguy83/go-md2man/v2 v2.0.5/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= +github.com/cpuguy83/go-md2man/v2 v2.0.6 h1:XJtiaUW6dEEqVuZiMTn1ldk455QWwEIsMIJlo5vtkx0= +github.com/cpuguy83/go-md2man/v2 v2.0.6/go.mod h1:oOW0eioCTA6cOiMLiUPZOpcVxMig6NIQQ7OS05n1F4g= +github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= +github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= +github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc h1:U9qPSI2PIWSS1VwoXQT9A3Wy9MM3WgvqSxFWenqJduM= +github.com/davecgh/go-spew v1.1.2-0.20180830191138-d8f796af33cc/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= +github.com/elazarl/goproxy v1.7.2 h1:Y2o6urb7Eule09PjlhQRGNsqRfPmYI3KKQLFpCAV3+o= +github.com/elazarl/goproxy v1.7.2/go.mod h1:82vkLNir0ALaW14Rc399OTTjyNREgmdL2cVoIbS6XaE= +github.com/emicklei/go-restful/v3 v3.11.0 h1:rAQeMHw1c7zTmncogyy8VvRZwtkmkZ4FxERmMY4rD+g= +github.com/emicklei/go-restful/v3 v3.11.0/go.mod h1:6n3XBCmQQb25CM2LCACGz8ukIrRry+4bhvbpWn3mrbc= +github.com/fatih/color v1.13.0/go.mod h1:kLAiJbzzSOZDVNGyDpeOxJ47H46qBXwg5ILebYFFOfk= +github.com/fatih/color v1.17.0 h1:GlRw1BRJxkpqUCBKzKOw098ed57fEsKeNjpTe3cSjK4= +github.com/fatih/color v1.17.0/go.mod h1:YZ7TlrGPkiz6ku9fK3TLD/pl3CpsiFyu8N92HLgmosI= +github.com/felixge/httpsnoop v1.0.4 h1:NFTV2Zj1bL4mc9sqWACXbQFVBBg2W3GPvqp8/ESS2Wg= +github.com/felixge/httpsnoop v1.0.4/go.mod h1:m8KPJKqk1gH5J9DgRY2ASl2lWCfGKXixSwevea8zH2U= +github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= +github.com/fsnotify/fsnotify v1.8.0 h1:dAwr6QBTBZIkG8roQaJjGof0pp0EeF+tNV7YBP3F/8M= +github.com/fsnotify/fsnotify v1.8.0/go.mod h1:8jBTzvmWwFyi3Pb8djgCCO5IBqzKJ/Jwo8TRcHyHii0= +github.com/fxamacker/cbor/v2 v2.7.0 h1:iM5WgngdRBanHcxugY4JySA0nk1wZorNOpTgCMedv5E= +github.com/fxamacker/cbor/v2 v2.7.0/go.mod h1:pxXPTn3joSm21Gbwsv0w9OSA2y1HFR9qXEeXQVeNoDQ= +github.com/getkin/kin-openapi v0.129.0 h1:QGYTNcmyP5X0AtFQ2Dkou9DGBJsUETeLH9rFrJXZh30= +github.com/getkin/kin-openapi v0.129.0/go.mod h1:gmWI+b/J45xqpyK5wJmRRZse5wefA5H0RDMK46kLUtI= +github.com/go-logr/logr v1.2.2/go.mod h1:jdQByPbusPIv2/zmleS9BjJVeZ6kBagPoEUsqbVz/1A= +github.com/go-logr/logr v1.3.0/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY= +github.com/go-logr/logr v1.4.2 h1:6pFjapn8bFcIbiKo3XT4j/BhANplGihG6tvd+8rYgrY= +github.com/go-logr/logr v1.4.2/go.mod h1:9T104GzyrTigFIr8wt5mBrctHMim0Nb2HLGrmQ40KvY= +github.com/go-logr/stdr v1.2.2 h1:hSWxHoqTgW2S2qGc0LTAI563KZ5YKYRhT3MFKZMbjag= +github.com/go-logr/stdr v1.2.2/go.mod h1:mMo/vtBO5dYbehREoey6XUKy/eSumjCCveDpRre4VKE= +github.com/go-openapi/jsonpointer v0.21.0 h1:YgdVicSA9vH5RiHs9TZW5oyafXZFc6+2Vc1rr/O9oNQ= +github.com/go-openapi/jsonpointer v0.21.0/go.mod h1:IUyH9l/+uyhIYQ/PXVA41Rexl+kOkAPDdXEYns6fzUY= +github.com/go-openapi/jsonreference v0.21.0 h1:Rs+Y7hSXT83Jacb7kFyjn4ijOuVGSvOdF2+tg1TRrwQ= +github.com/go-openapi/jsonreference v0.21.0/go.mod h1:LmZmgsrTkVg9LG4EaHeY8cBDslNPMo06cago5JNLkm4= +github.com/go-openapi/swag v0.23.0 h1:vsEVJDUo2hPJ2tu0/Xc+4noaxyEffXNIs3cOULZ+GrE= +github.com/go-openapi/swag v0.23.0/go.mod h1:esZ8ITTYEsH1V2trKHjAN8Ai7xHb8RV+YSZ577vPjgQ= +github.com/go-test/deep v1.0.8 h1:TDsG77qcSprGbC6vTN8OuXp5g+J+b5Pcguhf7Zt61VM= +github.com/go-test/deep v1.0.8/go.mod h1:5C2ZWiW0ErCdrYzpqxLbTX7MG14M9iiw8DgHncVwcsE= +github.com/goccy/go-json v0.10.4 h1:JSwxQzIqKfmFX1swYPpUThQZp/Ka4wzJdK0LWVytLPM= +github.com/goccy/go-json v0.10.4/go.mod h1:oq7eo15ShAhp70Anwd5lgX2pLfOS3QCiwU/PULtXL6M= +github.com/gogo/protobuf v1.3.2 h1:Ov1cvc58UF3b5XjBnZv7+opcTcQFZebYjWzi34vdm4Q= +github.com/gogo/protobuf v1.3.2/go.mod h1:P1XiOD3dCwIKUDQYPy72D8LYyHL2YPYrpS2s69NZV8Q= +github.com/golang/protobuf v1.5.4 h1:i7eJL8qZTpSEXOPTxNKhASYpMn+8e5Q6AdndVa1dWek= +github.com/golang/protobuf v1.5.4/go.mod h1:lnTiLA8Wa4RWRcIUkrtSVa5nRhsEGBg48fD6rSs7xps= +github.com/golang/snappy v0.0.4 h1:yAGX7huGHXlcLOEtBnF4w7FQwA26wojNCwOYAEhLjQM= +github.com/golang/snappy v0.0.4/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= +github.com/google/flatbuffers v24.3.25+incompatible h1:CX395cjN9Kke9mmalRoL3d81AtFUxJM+yDthflgJGkI= +github.com/google/flatbuffers v24.3.25+incompatible/go.mod h1:1AeVuKshWv4vARoZatz6mlQ0JxURH0Kv5+zNeJKJCa8= +github.com/google/gnostic-models v0.6.8 h1:yo/ABAfM5IMRsS1VnXjTBvUb61tFIHozhlYvRgGre9I= +github.com/google/gnostic-models v0.6.8/go.mod h1:5n7qKqH0f5wFt+aWF8CW6pZLLNOfYuF5OpfBSENuI8U= +github.com/google/go-cmp v0.5.9/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= +github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= +github.com/google/go-cmp v0.7.0 h1:wk8382ETsv4JYUZwIsn6YpYiWiBsYLSJiTsyBybVuN8= +github.com/google/go-cmp v0.7.0/go.mod h1:pXiqmnSA92OHEEa9HXL2W4E7lf9JzCmGVUdgjX3N/iU= +github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= +github.com/google/gofuzz v1.2.0 h1:xRy4A+RhZaiKjJ1bPfwQ8sedCA+YS2YcCHW6ec7JMi0= +github.com/google/gofuzz v1.2.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg= +github.com/google/uuid v1.6.0 h1:NIvaJDMOsjHA8n1jAhLSgzrAzy1Hgr+hNrb57e+94F0= +github.com/google/uuid v1.6.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= +github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY= +github.com/gopherjs/gopherjs v0.0.0-20181103185306-d547d1d9531e h1:JKmoR8x90Iww1ks85zJ1lfDGgIiMDuIptTOhJq+zKyg= +github.com/gopherjs/gopherjs v0.0.0-20181103185306-d547d1d9531e/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY= +github.com/gorilla/mux v1.8.1 h1:TuBL49tXwgrFYWhqrNgrUNEY92u81SPhu7sTdzQEiWY= +github.com/gorilla/mux v1.8.1/go.mod h1:AKf9I4AEqPTmMytcMc0KkNouC66V3BtZ4qD5fmWSiMQ= +github.com/grafana/grafana-app-sdk v0.31.0 h1:/mFCcx+YqG8cWAi9hePDJQxIdtXDClDIDRgZwHkksFk= +github.com/grafana/grafana-app-sdk v0.31.0/go.mod h1:Xw00NL7qpRLo5r3Gn48Bl1Xn2n4eUDI5pYf/wMufKWs= +github.com/grafana/grafana-app-sdk/logging v0.30.0 h1:K/P/bm7Cp7Di4tqIJ3EQz2+842JozQGRaz62r95ApME= +github.com/grafana/grafana-app-sdk/logging v0.30.0/go.mod h1:xy6ZyVXl50Z3DBDLybvBPphbykPhuVNed/VNmen9DQM= +github.com/grafana/grafana-plugin-sdk-go v0.272.0 h1:TmPIG+6e3lYGzkyfUfCHuaMaaiwDbkCacTZ7V/JaSeg= +github.com/grafana/grafana-plugin-sdk-go v0.272.0/go.mod h1:i/9KH9y/6m5hkRnG3H6aR2nOMPbJUmvo4XNrHjI15cU= +github.com/grafana/grafana/pkg/apimachinery v0.0.0-20250312121619-f64be062c432 h1:/0MLOGx9Ow7ihR4smlUYHFvomXBpdpf/jLWHKNfEUiI= +github.com/grafana/grafana/pkg/apimachinery v0.0.0-20250312121619-f64be062c432/go.mod h1:A/SJ9CiAWNOdeD/IezNwRaDZusLKq0z6dTfhKDgZw5Y= +github.com/grafana/otel-profiling-go v0.5.1 h1:stVPKAFZSa7eGiqbYuG25VcqYksR6iWvF3YH66t4qL8= +github.com/grafana/otel-profiling-go v0.5.1/go.mod h1:ftN/t5A/4gQI19/8MoWurBEtC6gFw8Dns1sJZ9W4Tls= +github.com/grafana/pyroscope-go/godeltaprof v0.1.8 h1:iwOtYXeeVSAeYefJNaxDytgjKtUuKQbJqgAIjlnicKg= +github.com/grafana/pyroscope-go/godeltaprof v0.1.8/go.mod h1:2+l7K7twW49Ct4wFluZD3tZ6e0SjanjcUUBPVD/UuGU= +github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus v1.0.1 h1:qnpSQwGEnkcRpTqNOIR6bJbR0gAorgP9CSALpRcKoAA= +github.com/grpc-ecosystem/go-grpc-middleware/providers/prometheus v1.0.1/go.mod h1:lXGCsh6c22WGtjr+qGHj1otzZpV/1kwTMAqkwZsnWRU= +github.com/grpc-ecosystem/go-grpc-middleware/v2 v2.3.1 h1:KcFzXwzM/kGhIRHvc8jdixfIJjVzuUJdnv+5xsPutog= +github.com/grpc-ecosystem/go-grpc-middleware/v2 v2.3.1/go.mod h1:qOchhhIlmRcqk/O9uCo/puJlyo07YINaIqdZfZG3Jkc= +github.com/grpc-ecosystem/grpc-gateway/v2 v2.26.1 h1:e9Rjr40Z98/clHv5Yg79Is0NtosR5LXRvdr7o/6NwbA= +github.com/grpc-ecosystem/grpc-gateway/v2 v2.26.1/go.mod h1:tIxuGz/9mpox++sgp9fJjHO0+q1X9/UOWd798aAm22M= +github.com/hashicorp/go-hclog v1.6.3 h1:Qr2kF+eVWjTiYmU7Y31tYlP1h0q/X3Nl3tPGdaB11/k= +github.com/hashicorp/go-hclog v1.6.3/go.mod h1:W4Qnvbt70Wk/zYJryRzDRU/4r0kIg0PVHBcfoyhpF5M= +github.com/hashicorp/go-plugin v1.6.3 h1:xgHB+ZUSYeuJi96WtxEjzi23uh7YQpznjGh0U0UUrwg= +github.com/hashicorp/go-plugin v1.6.3/go.mod h1:MRobyh+Wc/nYy1V4KAXUiYfzxoYhs7V1mlH1Z7iY2h0= +github.com/hashicorp/yamux v0.1.1 h1:yrQxtgseBDrq9Y652vSRDvsKCJKOUD+GzTS4Y0Y8pvE= +github.com/hashicorp/yamux v0.1.1/go.mod h1:CtWFDAQgb7dxtzFs4tWbplKIe2jSi3+5vKbgIO0SLnQ= +github.com/jhump/protoreflect v1.15.1 h1:HUMERORf3I3ZdX05WaQ6MIpd/NJ434hTp5YiKgfCL6c= +github.com/jhump/protoreflect v1.15.1/go.mod h1:jD/2GMKKE6OqX8qTjhADU1e6DShO+gavG9e0Q693nKo= +github.com/josharian/intern v1.0.0 h1:vlS4z54oSdjm0bgjRigI+G1HpF+tI+9rE5LLzOg8HmY= +github.com/josharian/intern v1.0.0/go.mod h1:5DoeVV0s6jJacbCEi61lwdGj/aVlrQvzHFFd8Hwg//Y= +github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM= +github.com/json-iterator/go v1.1.12/go.mod h1:e30LSqwooZae/UwlEbR2852Gd8hjQvJoHmT4TnhNGBo= +github.com/jszwedko/go-datemath v0.1.1-0.20230526204004-640a500621d6 h1:SwcnSwBR7X/5EHJQlXBockkJVIMRVt5yKaesBPMtyZQ= +github.com/jszwedko/go-datemath v0.1.1-0.20230526204004-640a500621d6/go.mod h1:WrYiIuiXUMIvTDAQw97C+9l0CnBmCcvosPjN3XDqS/o= +github.com/jtolds/gls v4.2.1+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU= +github.com/jtolds/gls v4.20.0+incompatible h1:xdiiI2gbIgH/gLH7ADydsJ1uDOEzR8yvV7C0MuV77Wo= +github.com/jtolds/gls v4.20.0+incompatible/go.mod h1:QJZ7F/aHp+rZTRtaJ1ow/lLfFfVYBRgL+9YlvaHOwJU= +github.com/kisielk/errcheck v1.5.0/go.mod h1:pFxgyoBC7bSaBwPgfKdkLd5X25qrDl4LWUI2bnpBCr8= +github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= +github.com/klauspost/asmfmt v1.3.2 h1:4Ri7ox3EwapiOjCki+hw14RyKk201CN4rzyCJRFLpK4= +github.com/klauspost/asmfmt v1.3.2/go.mod h1:AG8TuvYojzulgDAMCnYn50l/5QV3Bs/tp6j0HLHbNSE= +github.com/klauspost/compress v1.17.11 h1:In6xLpyWOi1+C7tXUUWv2ot1QvBjxevKAaI6IXrJmUc= +github.com/klauspost/compress v1.17.11/go.mod h1:pMDklpSncoRMuLFrf1W9Ss9KT+0rH90U12bZKk7uwG0= +github.com/klauspost/cpuid/v2 v2.2.9 h1:66ze0taIn2H33fBvCkXuv9BmCwDfafmiIVpKV9kKGuY= +github.com/klauspost/cpuid/v2 v2.2.9/go.mod h1:rqkxqrZ1EhYM9G+hXH7YdowN5R5RGN6NK4QwQ3WMXF8= +github.com/kr/pretty v0.3.1 h1:flRD4NNwYAUpkphVc1HcthR4KEIFJ65n8Mw5qdRn3LE= +github.com/kr/pretty v0.3.1/go.mod h1:hoEshYVHaxMs3cyo3Yncou5ZscifuDolrwPKZanG3xk= +github.com/kr/text v0.2.0 h1:5Nx0Ya0ZqY2ygV366QzturHI13Jq95ApcVaJBhpS+AY= +github.com/kr/text v0.2.0/go.mod h1:eLer722TekiGuMkidMxC/pM04lWEeraHUUmBw8l2grE= +github.com/kylelemons/godebug v1.1.0 h1:RPNrshWIDI6G2gRW9EHilWtl7Z6Sb1BR0xunSBf0SNc= +github.com/kylelemons/godebug v1.1.0/go.mod h1:9/0rRGxNHcop5bhtWyNeEfOS8JIWk580+fNqagV/RAw= +github.com/magefile/mage v1.15.0 h1:BvGheCMAsG3bWUDbZ8AyXXpCNwU9u5CB6sM+HNb9HYg= +github.com/magefile/mage v1.15.0/go.mod h1:z5UZb/iS3GoOSn0JgWuiw7dxlurVYTu+/jHXqQg881A= +github.com/mailru/easyjson v0.7.7 h1:UGYAvKxe3sBsEDzO8ZeWOSlIQfWFlxbzLZe7hwFURr0= +github.com/mailru/easyjson v0.7.7/go.mod h1:xzfreul335JAWq5oZzymOObrkdz5UnU4kGfJJLY9Nlc= +github.com/mattetti/filebuffer v1.0.1 h1:gG7pyfnSIZCxdoKq+cPa8T0hhYtD9NxCdI4D7PTjRLM= +github.com/mattetti/filebuffer v1.0.1/go.mod h1:YdMURNDOttIiruleeVr6f56OrMc+MydEnTcXwtkxNVs= +github.com/mattn/go-colorable v0.1.9/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= +github.com/mattn/go-colorable v0.1.12/go.mod h1:u5H1YNBxpqRaxsYJYSkiCWKzEfiAb1Gb520KVy5xxl4= +github.com/mattn/go-colorable v0.1.13 h1:fFA4WZxdEF4tXPZVKMLwD8oUnCTTo08duU7wxecdEvA= +github.com/mattn/go-colorable v0.1.13/go.mod h1:7S9/ev0klgBDR4GtXTXX8a3vIGJpMovkB8vQcUbaXHg= +github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU= +github.com/mattn/go-isatty v0.0.14/go.mod h1:7GGIvUiUoEMVVmxf/4nioHXj79iQHKdU27kJ6hsGG94= +github.com/mattn/go-isatty v0.0.16/go.mod h1:kYGgaQfpe5nmfYZH+SKPsOc2e4SrIfOl2e/yFXSvRLM= +github.com/mattn/go-isatty v0.0.20 h1:xfD0iDuEKnDkl03q4limB+vH+GxLEtL/jb4xVJSWWEY= +github.com/mattn/go-isatty v0.0.20/go.mod h1:W+V8PltTTMOvKvAeJH7IuucS94S2C6jfK/D7dTCTo3Y= +github.com/mattn/go-runewidth v0.0.9/go.mod h1:H031xJmbD/WCDINGzjvQ9THkh0rPKHF+m2gUSrubnMI= +github.com/mattn/go-runewidth v0.0.16 h1:E5ScNMtiwvlvB5paMFdw9p4kSQzbXFikJ5SQO6TULQc= +github.com/mattn/go-runewidth v0.0.16/go.mod h1:Jdepj2loyihRzMpdS35Xk/zdY8IAYHsh153qUoGf23w= +github.com/minio/asm2plan9s v0.0.0-20200509001527-cdd76441f9d8 h1:AMFGa4R4MiIpspGNG7Z948v4n35fFGB3RR3G/ry4FWs= +github.com/minio/asm2plan9s v0.0.0-20200509001527-cdd76441f9d8/go.mod h1:mC1jAcsrzbxHt8iiaC+zU4b1ylILSosueou12R++wfY= +github.com/minio/c2goasm v0.0.0-20190812172519-36a3d3bbc4f3 h1:+n/aFZefKZp7spd8DFdX7uMikMLXX4oubIzJF4kv/wI= +github.com/minio/c2goasm v0.0.0-20190812172519-36a3d3bbc4f3/go.mod h1:RagcQ7I8IeTMnF8JTXieKnO4Z6JCsikNEzj0DwauVzE= +github.com/mitchellh/reflectwalk v1.0.2 h1:G2LzWKi524PWgd3mLHV8Y5k7s6XUvT0Gef6zxSIeXaQ= +github.com/mitchellh/reflectwalk v1.0.2/go.mod h1:mSTlrgnPZtwu0c4WaC2kGObEpuNDbx0jmZXqmk4esnw= +github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= +github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd h1:TRLaZ9cD/w8PVh93nsPXa1VrQ6jlwL5oN8l14QlcNfg= +github.com/modern-go/concurrent v0.0.0-20180306012644-bacd9c7ef1dd/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= +github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M= +github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk= +github.com/mohae/deepcopy v0.0.0-20170929034955-c48cc78d4826 h1:RWengNIwukTxcDr9M+97sNutRR1RKhG96O6jWumTTnw= +github.com/mohae/deepcopy v0.0.0-20170929034955-c48cc78d4826/go.mod h1:TaXosZuwdSHYgviHp1DAtfrULt5eUgsSMsZf+YrPgl8= +github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822 h1:C3w9PqII01/Oq1c1nUAm88MOHcQC9l5mIlSMApZMrHA= +github.com/munnerz/goautoneg v0.0.0-20191010083416-a7dc8b61c822/go.mod h1:+n7T8mK8HuQTcFwEeznm/DIxMOiR9yIdICNftLE1DvQ= +github.com/oasdiff/yaml v0.0.0-20241210131133-6b86fb107d80 h1:nZspmSkneBbtxU9TopEAE0CY+SBJLxO8LPUlw2vG4pU= +github.com/oasdiff/yaml v0.0.0-20241210131133-6b86fb107d80/go.mod h1:7tFDb+Y51LcDpn26GccuUgQXUk6t0CXZsivKjyimYX8= +github.com/oasdiff/yaml3 v0.0.0-20241210130736-a94c01f36349 h1:t05Ww3DxZutOqbMN+7OIuqDwXbhl32HiZGpLy26BAPc= +github.com/oasdiff/yaml3 v0.0.0-20241210130736-a94c01f36349/go.mod h1:y5+oSEHCPT/DGrS++Wc/479ERge0zTFxaF8PbGKcg2o= +github.com/oklog/run v1.1.0 h1:GEenZ1cK0+q0+wsJew9qUg/DyD8k3JzYsZAi5gYi2mA= +github.com/oklog/run v1.1.0/go.mod h1:sVPdnTZT1zYwAJeCMu2Th4T21pA3FPOQRfWjQlk7DVU= +github.com/olekukonko/tablewriter v0.0.5 h1:P2Ga83D34wi1o9J6Wh1mRuqd4mF/x/lgBS7N7AbDhec= +github.com/olekukonko/tablewriter v0.0.5/go.mod h1:hPp6KlRPjbx+hW8ykQs1w3UBbZlj6HuIJcUGPhkA7kY= +github.com/perimeterx/marshmallow v1.1.5 h1:a2LALqQ1BlHM8PZblsDdidgv1mWi1DgC2UmX50IvK2s= +github.com/perimeterx/marshmallow v1.1.5/go.mod h1:dsXbUu8CRzfYP5a87xpp0xq9S3u0Vchtcl8we9tYaXw= +github.com/pierrec/lz4/v4 v4.1.21 h1:yOVMLb6qSIDP67pl/5F7RepeKYu/VmTyEXvuMI5d9mQ= +github.com/pierrec/lz4/v4 v4.1.21/go.mod h1:gZWDp/Ze/IJXGXf23ltt2EXimqmTUXEy0GFuRQyBid4= +github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4= +github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= +github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= +github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2 h1:Jamvg5psRIccs7FGNTlIRMkT8wgtp5eCXdBlqhYGL6U= +github.com/pmezard/go-difflib v1.0.1-0.20181226105442-5d4384ee4fb2/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= +github.com/prometheus/client_golang v1.21.0 h1:DIsaGmiaBkSangBgMtWdNfxbMNdku5IK6iNhrEqWvdA= +github.com/prometheus/client_golang v1.21.0/go.mod h1:U9NM32ykUErtVBxdvD3zfi+EuFkkaBvMb09mIfe0Zgg= +github.com/prometheus/client_model v0.6.1 h1:ZKSh/rekM+n3CeS952MLRAdFwIKqeY8b62p8ais2e9E= +github.com/prometheus/client_model v0.6.1/go.mod h1:OrxVMOVHjw3lKMa8+x6HeMGkHMQyHDk9E3jmP2AmGiY= +github.com/prometheus/common v0.62.0 h1:xasJaQlnWAeyHdUBeGjXmutelfJHWMRr+Fg4QszZ2Io= +github.com/prometheus/common v0.62.0/go.mod h1:vyBcEuLSvWos9B1+CyL7JZ2up+uFzXhkqml0W5zIY1I= +github.com/prometheus/procfs v0.15.1 h1:YagwOFzUgYfKKHX6Dr+sHT7km/hxC76UB0learggepc= +github.com/prometheus/procfs v0.15.1/go.mod h1:fB45yRUv8NstnjriLhBQLuOUt+WW4BsoGhij/e3PBqk= +github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc= +github.com/rivo/uniseg v0.4.7 h1:WUdvkW8uEhrYfLC4ZzdpI2ztxP1I582+49Oc5Mq64VQ= +github.com/rivo/uniseg v0.4.7/go.mod h1:FN3SvrM+Zdj16jyLfmOkMNblXMcoc8DfTHruCPUcx88= +github.com/rogpeppe/go-internal v1.13.1 h1:KvO1DLK/DRN07sQ1LQKScxyZJuNnedQ5/wKSR38lUII= +github.com/rogpeppe/go-internal v1.13.1/go.mod h1:uMEvuHeurkdAXX61udpOXGD/AzZDWNMNyH2VO9fmH0o= +github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= +github.com/russross/blackfriday/v2 v2.1.0 h1:JIOH55/0cWyOuilr9/qlrm0BSXldqnqwMsf35Ld67mk= +github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= +github.com/shurcooL/sanitized_anchor_name v1.0.0/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc= +github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc= +github.com/smartystreets/assertions v0.0.0-20190116191733-b6c0e53d7304 h1:Jpy1PXuP99tXNrhbq2BaPz9B+jNAvH1JPQQpG/9GCXY= +github.com/smartystreets/assertions v0.0.0-20190116191733-b6c0e53d7304/go.mod h1:OnSkiWE9lh6wB0YB77sQom3nweQdgAjqCqsofrRNTgc= +github.com/smartystreets/goconvey v0.0.0-20181108003508-044398e4856c/go.mod h1:XDJAKZRPZ1CvBcN2aX5YOUTYGHki24fSF0Iv48Ibg0s= +github.com/smartystreets/goconvey v1.6.4 h1:fv0U8FUIMPNf1L9lnHLvLhgicrIVChEkdzIKYqbNC9s= +github.com/smartystreets/goconvey v1.6.4/go.mod h1:syvi0/a8iFYH4r/RixwvyeAJjdLS9QV7WQ/tjFTllLA= +github.com/spf13/pflag v1.0.6 h1:jFzHGLGAlb3ruxLB8MhbI6A8+AQX/2eW4qeyNZXNp2o= +github.com/spf13/pflag v1.0.6/go.mod h1:McXfInJRrz4CZXVZOBLb0bTZqETkiAhM9Iw0y3An2Bg= +github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= +github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw= +github.com/stretchr/objx v0.5.0/go.mod h1:Yh+to48EsGEfYuaHDzXPcE3xhTkx73EhmCGUpEOglKo= +github.com/stretchr/objx v0.5.2/go.mod h1:FRsXN1f5AsAjCGJKqEizvkpNtU+EGNCLh3NxZ/8L+MA= +github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= +github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= +github.com/stretchr/testify v1.7.2/go.mod h1:R6va5+xMeoiuVRoj+gSkQ7d3FALtqAAGI1FQKckRals= +github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU= +github.com/stretchr/testify v1.8.4/go.mod h1:sz/lmYIOXD/1dqDmKjjqLyZ2RngseejIcXlSw2iwfAo= +github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= +github.com/stretchr/testify v1.10.0 h1:Xv5erBjTwe/5IxqUQTdXv5kgmIvbHo3QQyRwhJsOfJA= +github.com/stretchr/testify v1.10.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= +github.com/ugorji/go/codec v1.2.11 h1:BMaWp1Bb6fHwEtbplGBGJ498wD+LKlNSl25MjdZY4dU= +github.com/ugorji/go/codec v1.2.11/go.mod h1:UNopzCgEMSXjBc6AOMqYvWC1ktqTAfzJZUZgYf6w6lg= +github.com/unknwon/bra v0.0.0-20200517080246-1e3013ecaff8 h1:aVGB3YnaS/JNfOW3tiHIlmNmTDg618va+eT0mVomgyI= +github.com/unknwon/bra v0.0.0-20200517080246-1e3013ecaff8/go.mod h1:fVle4kNr08ydeohzYafr20oZzbAkhQT39gKK/pFQ5M4= +github.com/unknwon/com v1.0.1 h1:3d1LTxD+Lnf3soQiD4Cp/0BRB+Rsa/+RTvz8GMMzIXs= +github.com/unknwon/com v1.0.1/go.mod h1:tOOxU81rwgoCLoOVVPHb6T/wt8HZygqH5id+GNnlCXM= +github.com/unknwon/log v0.0.0-20150304194804-e617c87089d3/go.mod h1:1xEUf2abjfP92w2GZTV+GgaRxXErwRXcClbUwrNJffU= +github.com/unknwon/log v0.0.0-20200308114134-929b1006e34a h1:vcrhXnj9g9PIE+cmZgaPSwOyJ8MAQTRmsgGrB0x5rF4= +github.com/unknwon/log v0.0.0-20200308114134-929b1006e34a/go.mod h1:1xEUf2abjfP92w2GZTV+GgaRxXErwRXcClbUwrNJffU= +github.com/urfave/cli v1.22.1/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0= +github.com/urfave/cli v1.22.16 h1:MH0k6uJxdwdeWQTwhSO42Pwr4YLrNLwBtg1MRgTqPdQ= +github.com/urfave/cli v1.22.16/go.mod h1:EeJR6BKodywf4zciqrdw6hpCPk68JO9z5LazXZMn5Po= +github.com/x448/float16 v0.8.4 h1:qLwI1I70+NjRFUR3zs1JPUCgaCXSh3SW62uAKT1mSBM= +github.com/x448/float16 v0.8.4/go.mod h1:14CWIYCyZA/cWjXOioeEpHeN/83MdbZDRQHoFcYsOfg= +github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= +github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= +github.com/zeebo/assert v1.3.0 h1:g7C04CbJuIDKNPFHmsk4hwZDO5O+kntRxzaUoNXj+IQ= +github.com/zeebo/assert v1.3.0/go.mod h1:Pq9JiuJQpG8JLJdtkwrJESF0Foym2/D9XMU5ciN/wJ0= +github.com/zeebo/xxh3 v1.0.2 h1:xZmwmqxHZA8AI603jOQ0tMqmBr9lPeFwGg6d+xy9DC0= +github.com/zeebo/xxh3 v1.0.2/go.mod h1:5NWz9Sef7zIDm2JHfFlcQvNekmcEl9ekUZQQKCYaDcA= +go.opentelemetry.io/auto/sdk v1.1.0 h1:cH53jehLUN6UFLY71z+NDOiNJqDdPRaXzTel0sJySYA= +go.opentelemetry.io/auto/sdk v1.1.0/go.mod h1:3wSPjt5PWp2RhlCcmmOial7AvC4DQqZb7a7wCow3W8A= +go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.59.0 h1:rgMkmiGfix9vFJDcDi1PK8WEQP4FLQwLDfhp5ZLpFeE= +go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.59.0/go.mod h1:ijPqXp5P6IRRByFVVg9DY8P5HkxkHE5ARIa+86aXPf4= +go.opentelemetry.io/contrib/instrumentation/net/http/httptrace/otelhttptrace v0.60.0 h1:0tY123n7CdWMem7MOVdKOt0YfshufLCwfE5Bob+hQuM= +go.opentelemetry.io/contrib/instrumentation/net/http/httptrace/otelhttptrace v0.60.0/go.mod h1:CosX/aS4eHnG9D7nESYpV753l4j9q5j3SL/PUYd2lR8= +go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.60.0 h1:sbiXRNDSWJOTobXh5HyQKjq6wUC5tNybqjIqDpAY4CU= +go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.60.0/go.mod h1:69uWxva0WgAA/4bu2Yy70SLDBwZXuQ6PbBpbsa5iZrQ= +go.opentelemetry.io/contrib/propagators/jaeger v1.34.0 h1:D3htJISCUU/wOVlKwisVKancWm+2U4h9xDEaiMkiyRE= +go.opentelemetry.io/contrib/propagators/jaeger v1.34.0/go.mod h1:DAX1bsj+uDm2ZuOQH/RgZRx7RQZWyzV5W2WR/0UX8JA= +go.opentelemetry.io/contrib/samplers/jaegerremote v0.28.0 h1:Xx1N6cDr8iWy1Cz6OcY7oS0ACdt/6HDYTdu4KskuC7s= +go.opentelemetry.io/contrib/samplers/jaegerremote v0.28.0/go.mod h1:iWS+NvC948FyfnJbVfPN9h/8+vr8CR2FPn6XsLRkvH8= +go.opentelemetry.io/otel v1.21.0/go.mod h1:QZzNPQPm1zLX4gZK4cMi+71eaorMSGT3A4znnUvNNEo= +go.opentelemetry.io/otel v1.35.0 h1:xKWKPxrxB6OtMCbmMY021CqC45J+3Onta9MqjhnusiQ= +go.opentelemetry.io/otel v1.35.0/go.mod h1:UEqy8Zp11hpkUrL73gSlELM0DupHoiq72dR+Zqel/+Y= +go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.34.0 h1:OeNbIYk/2C15ckl7glBlOBp5+WlYsOElzTNmiPW/x60= +go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.34.0/go.mod h1:7Bept48yIeqxP2OZ9/AqIpYS94h2or0aB4FypJTc8ZM= +go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.34.0 h1:tgJ0uaNS4c98WRNUEx5U3aDlrDOI5Rs+1Vifcw4DJ8U= +go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.34.0/go.mod h1:U7HYyW0zt/a9x5J1Kjs+r1f/d4ZHnYFclhYY2+YbeoE= +go.opentelemetry.io/otel/metric v1.21.0/go.mod h1:o1p3CA8nNHW8j5yuQLdc1eeqEaPfzug24uvsyIEJRWM= +go.opentelemetry.io/otel/metric v1.35.0 h1:0znxYu2SNyuMSQT4Y9WDWej0VpcsxkuklLa4/siN90M= +go.opentelemetry.io/otel/metric v1.35.0/go.mod h1:nKVFgxBZ2fReX6IlyW28MgZojkoAkJGaE8CpgeAU3oE= +go.opentelemetry.io/otel/sdk v1.21.0/go.mod h1:Nna6Yv7PWTdgJHVRD9hIYywQBRx7pbox6nwBnZIxl/E= +go.opentelemetry.io/otel/sdk v1.35.0 h1:iPctf8iprVySXSKJffSS79eOjl9pvxV9ZqOWT0QejKY= +go.opentelemetry.io/otel/sdk v1.35.0/go.mod h1:+ga1bZliga3DxJ3CQGg3updiaAJoNECOgJREo9KHGQg= +go.opentelemetry.io/otel/sdk/metric v1.35.0 h1:1RriWBmCKgkeHEhM7a2uMjMUfP7MsOF5JpUCaEqEI9o= +go.opentelemetry.io/otel/sdk/metric v1.35.0/go.mod h1:is6XYCUMpcKi+ZsOvfluY5YstFnhW0BidkR+gL+qN+w= +go.opentelemetry.io/otel/trace v1.21.0/go.mod h1:LGbsEB0f9LGjN+OZaQQ26sohbOmiMR+BaslueVtS/qQ= +go.opentelemetry.io/otel/trace v1.35.0 h1:dPpEfJu1sDIqruz7BHFG3c7528f6ddfSWfFDVt/xgMs= +go.opentelemetry.io/otel/trace v1.35.0/go.mod h1:WUk7DtFp1Aw2MkvqGdwiXYDZZNvA/1J8o6xRXLrIkyc= +go.opentelemetry.io/proto/otlp v1.5.0 h1:xJvq7gMzB31/d406fB8U5CBdyQGw4P399D1aQWU/3i4= +go.opentelemetry.io/proto/otlp v1.5.0/go.mod h1:keN8WnHxOy8PG0rQZjJJ5A2ebUoafqWp0eVQ4yIXvJ4= +go.uber.org/goleak v1.3.0 h1:2K3zAYmnTNqV73imy9J1T3WC+gmCePx2hEGkimedGto= +go.uber.org/goleak v1.3.0/go.mod h1:CoHD4mav9JJNrW/WLlf7HGZPjdw8EucARQHekz1X6bE= +golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= +golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= +golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= +golang.org/x/exp v0.0.0-20240909161429-701f63a606c0 h1:e66Fs6Z+fZTbFBAxKfP3PALWBtpfqks2bwGcexMxgtk= +golang.org/x/exp v0.0.0-20240909161429-701f63a606c0/go.mod h1:2TbTHSBQa924w8M6Xs1QcRcFwyucIwBGpK1p2f1YFFY= +golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= +golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= +golang.org/x/mod v0.23.0 h1:Zb7khfcRGKk+kqfxFaP5tZqCnDZMjC5VtUBs87Hr6QM= +golang.org/x/mod v0.23.0/go.mod h1:6SkKJ3Xj0I0BrPOZoBy3bdMptDDU9oJrpohJ3eWZ1fY= +golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= +golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= +golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= +golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= +golang.org/x/net v0.0.0-20201021035429-f5854403a974/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= +golang.org/x/net v0.36.0 h1:vWF2fRbw4qslQsQzgFqZff+BItCvGFQqKzKIzx1rmoA= +golang.org/x/net v0.36.0/go.mod h1:bFmbeoIPfrw4sMHNhb4J9f6+tPziuGjq7Jk/38fxi1I= +golang.org/x/oauth2 v0.27.0 h1:da9Vo7/tDv5RH/7nZDz1eMGS/q1Vv1N/7FCrBhI9I3M= +golang.org/x/oauth2 v0.27.0/go.mod h1:onh5ek6nERTohokkhCD/y2cV4Do3fxFHFuAejCkRWT8= +golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.11.0 h1:GGz8+XQP4FvTTrjZPzNKTMFtSXH80RAzG+5ghFPgK9w= +golang.org/x/sync v0.11.0/go.mod h1:Czt+wKu1gCyEFDUtn0jG5QVvpJ6rzVqr5aXyt9drQfk= +golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= +golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20191020152052-9984515f0562/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20200116001909-b77594299b42/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20200223170610-d5e6a3e2c0ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20200930185726-fdedc70b468f/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= +golang.org/x/sys v0.0.0-20210630005230-0f9fa26af87c/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20210927094055-39ccf1dd6fa6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220503163025-988cb79eb6c6/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.6.0/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.14.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/sys v0.30.0 h1:QjkSwP/36a20jFYWkSue1YwXzLmsV5Gfq7Eiy72C1uc= +golang.org/x/sys v0.30.0/go.mod h1:/VUhepiaJMQUp4+oa/7Zr1D23ma6VTLIYjOOTFZPUcA= +golang.org/x/term v0.29.0 h1:L6pJp37ocefwRRtYPKSWOWzOtWSxVajvz2ldH/xi3iU= +golang.org/x/term v0.29.0/go.mod h1:6bl4lRlvVuDgSf3179VpIxBF0o10JUpXWOnI7nErv7s= +golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= +golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= +golang.org/x/text v0.22.0 h1:bofq7m3/HAFvbF51jz3Q9wLg3jkvSPuiZu/pD1XwgtM= +golang.org/x/text v0.22.0/go.mod h1:YRoo4H8PVmsu+E3Ou7cqLVH8oXWIHVoX0jqUWALQhfY= +golang.org/x/time v0.9.0 h1:EsRrnYcQiGH+5FfbgvV4AP7qEZstoyrHB0DzarOQ4ZY= +golang.org/x/time v0.9.0/go.mod h1:3BpzKBy/shNhVucY/MWOyx10tF3SFh9QdLuxbVysPQM= +golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= +golang.org/x/tools v0.0.0-20190328211700-ab21143f2384/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= +golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= +golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= +golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= +golang.org/x/tools v0.30.0 h1:BgcpHewrV5AUp2G9MebG4XPFI1E2W41zU1SaqVA9vJY= +golang.org/x/tools v0.30.0/go.mod h1:c347cR/OJfw5TI+GfX7RUPNMdDRRbjvYTS0jPyvsVtY= +golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= +golang.org/x/xerrors v0.0.0-20240903120638-7835f813f4da h1:noIWHXmPHxILtqtCOPIhSt0ABwskkZKjD3bXGnZGpNY= +golang.org/x/xerrors v0.0.0-20240903120638-7835f813f4da/go.mod h1:NDW/Ps6MPRej6fsCIbMTohpP40sJ/P/vI1MoTEGwX90= +gonum.org/v1/gonum v0.15.1 h1:FNy7N6OUZVUaWG9pTiD+jlhdQ3lMP+/LcTpJ6+a8sQ0= +gonum.org/v1/gonum v0.15.1/go.mod h1:eZTZuRFrzu5pcyjN5wJhcIhnUdNijYxX1T2IcrOGY0o= +google.golang.org/genproto/googleapis/api v0.0.0-20250204164813-702378808489 h1:fCuMM4fowGzigT89NCIsW57Pk9k2D12MMi2ODn+Nk+o= +google.golang.org/genproto/googleapis/api v0.0.0-20250204164813-702378808489/go.mod h1:iYONQfRdizDB8JJBybql13nArx91jcUk7zCXEsOofM4= +google.golang.org/genproto/googleapis/rpc v0.0.0-20250207221924-e9438ea467c6 h1:2duwAxN2+k0xLNpjnHTXoMUgnv6VPSp5fiqTuwSxjmI= +google.golang.org/genproto/googleapis/rpc v0.0.0-20250207221924-e9438ea467c6/go.mod h1:8BS3B93F/U1juMFq9+EDk+qOT5CO1R9IzXxG3PTqiRk= +google.golang.org/grpc v1.70.0 h1:pWFv03aZoHzlRKHWicjsZytKAiYCtNS0dHbXnIdq7jQ= +google.golang.org/grpc v1.70.0/go.mod h1:ofIJqVKDXx/JiXrwr2IG4/zwdH9txy3IlF40RmcJSQw= +google.golang.org/protobuf v1.36.5 h1:tPhr+woSbjfYvY6/GPufUoYizxw1cF/yFoxJ2fmpwlM= +google.golang.org/protobuf v1.36.5/go.mod h1:9fA7Ob0pmnwhb644+1+CVWFRbNajQ6iRojtC/QF5bRE= +gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= +gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c h1:Hei/4ADfdWqJk1ZMxUNpqntNwaWcugrBjAiHlqqRiVk= +gopkg.in/check.v1 v1.0.0-20201130134442-10cb98267c6c/go.mod h1:JHkPIbrfpd72SG/EVd6muEfDQjcINNoR0C8j2r3qZ4Q= +gopkg.in/evanphx/json-patch.v4 v4.12.0 h1:n6jtcsulIzXPJaxegRbvFNNrZDjbij7ny3gmSPG+6V4= +gopkg.in/evanphx/json-patch.v4 v4.12.0/go.mod h1:p8EYWUEYMpynmqDbY58zCKCFZw8pRWMG4EsWvDvM72M= +gopkg.in/fsnotify/fsnotify.v1 v1.4.7 h1:XNNYLJHt73EyYiCZi6+xjupS9CpvmiDgjPTAjrBlQbo= +gopkg.in/fsnotify/fsnotify.v1 v1.4.7/go.mod h1:Fyux9zXlo4rWoMSIzpn9fDAYjalPqJ/K1qJ27s+7ltE= +gopkg.in/inf.v0 v0.9.1 h1:73M5CoZyi3ZLMOyDlQh031Cx6N9NDJ2Vvfl76EDAgDc= +gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw= +gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= +gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= +gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= +gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= +gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= +k8s.io/api v0.32.1 h1:f562zw9cy+GvXzXf0CKlVQ7yHJVYzLfL6JAS4kOAaOc= +k8s.io/api v0.32.1/go.mod h1:/Yi/BqkuueW1BgpoePYBRdDYfjPF5sgTr5+YqDZra5k= +k8s.io/apimachinery v0.32.1 h1:683ENpaCBjma4CYqsmZyhEzrGz6cjn1MY/X2jB2hkZs= +k8s.io/apimachinery v0.32.1/go.mod h1:GpHVgxoKlTxClKcteaeuF1Ul/lDVb74KpZcxcmLDElE= +k8s.io/client-go v0.32.1 h1:otM0AxdhdBIaQh7l1Q0jQpmo7WOFIk5FFa4bg6YMdUU= +k8s.io/client-go v0.32.1/go.mod h1:aTTKZY7MdxUaJ/KiUs8D+GssR9zJZi77ZqtzcGXIiDg= +k8s.io/klog/v2 v2.130.1 h1:n9Xl7H1Xvksem4KFG4PYbdQCQxqc/tTUyrgXaOhHSzk= +k8s.io/klog/v2 v2.130.1/go.mod h1:3Jpz1GvMt720eyJH1ckRHK1EDfpxISzJ7I9OYgaDtPE= +k8s.io/kube-openapi v0.0.0-20241105132330-32ad38e42d3f h1:GA7//TjRY9yWGy1poLzYYJJ4JRdzg3+O6e8I+e+8T5Y= +k8s.io/kube-openapi v0.0.0-20241105132330-32ad38e42d3f/go.mod h1:R/HEjbvWI0qdfb8viZUeVZm0X6IZnxAydC7YU42CMw4= +k8s.io/utils v0.0.0-20241104100929-3ea5e8cea738 h1:M3sRQVHv7vB20Xc2ybTt7ODCeFj6JSWYFzOFnYeS6Ro= +k8s.io/utils v0.0.0-20241104100929-3ea5e8cea738/go.mod h1:OLgZIPagt7ERELqWJFomSt595RzquPNLL48iOWgYOg0= +sigs.k8s.io/json v0.0.0-20241010143419-9aa6b5e7a4b3 h1:/Rv+M11QRah1itp8VhT6HoVx1Ray9eB4DBr+K+/sCJ8= +sigs.k8s.io/json v0.0.0-20241010143419-9aa6b5e7a4b3/go.mod h1:18nIHnGi6636UCz6m8i4DhaJ65T6EruyzmoQqI2BVDo= +sigs.k8s.io/structured-merge-diff/v4 v4.5.0 h1:nbCitCK2hfnhyiKo6uf2HxUPTCodY6Qaf85SbDIaMBk= +sigs.k8s.io/structured-merge-diff/v4 v4.5.0/go.mod h1:N8f93tFZh9U6vpxwRArLiikrE5/2tiu1w1AGfACIGE4= +sigs.k8s.io/yaml v1.4.0 h1:Mk1wCc2gy/F0THH0TAp1QYyJNzRm2KCLy3o5ASXVI5E= +sigs.k8s.io/yaml v1.4.0/go.mod h1:Ejl7/uTz7PSA4eKMyQCUTnhZYNmLIl+5c2lQPGR2BPY= diff --git a/apps/dashboard/kinds/v2alpha1/dashboard_spec.cue b/apps/dashboard/kinds/v2alpha1/dashboard_spec.cue index a1216596268..b3324616401 100644 --- a/apps/dashboard/kinds/v2alpha1/dashboard_spec.cue +++ b/apps/dashboard/kinds/v2alpha1/dashboard_spec.cue @@ -564,6 +564,7 @@ RowsLayoutRowKind: { RowsLayoutRowSpec: { title?: string collapsed: bool + conditionalRendering?: ConditionalRenderingGroupKind repeat?: RowRepeatOptions layout: GridLayoutKind | ResponsiveGridLayoutKind | TabsLayoutKind } @@ -587,6 +588,7 @@ ResponsiveGridLayoutItemKind: { ResponsiveGridLayoutItemSpec: { element: ElementReference repeat?: ResponsiveGridRepeatOptions + conditionalRendering?: ConditionalRenderingGroupKind } TabsLayoutKind: { @@ -921,3 +923,42 @@ AdhocVariableKind: { kind: "AdhocVariable" spec: AdhocVariableSpec } + +ConditionalRenderingGroupKind: { + kind: "ConditionalRenderingGroup" + spec: ConditionalRenderingGroupSpec +} + +ConditionalRenderingGroupSpec: { + condition: "and" | "or" + items: [...ConditionalRenderingVariableKind | ConditionalRenderingDataKind | ConditionalRenderingTimeIntervalKind] +} + +ConditionalRenderingVariableKind: { + kind: "ConditionalRenderingVariable" + spec: ConditionalRenderingVariableSpec +} + +ConditionalRenderingVariableSpec: { + variable: string + operator: "equals" | "notEquals" + value: string +} + +ConditionalRenderingDataKind: { + kind: "ConditionalRenderingData" + spec: ConditionalRenderingDataSpec +} + +ConditionalRenderingDataSpec: { + value: bool +} + +ConditionalRenderingTimeIntervalKind: { + kind: "ConditionalRenderingTimeInterval" + spec: ConditionalRenderingTimeIntervalSpec +} + +ConditionalRenderingTimeIntervalSpec: { + value: string +} \ No newline at end of file diff --git a/pkg/apis/dashboard/types.go b/apps/dashboard/pkg/apis/dashboard/types.go similarity index 100% rename from pkg/apis/dashboard/types.go rename to apps/dashboard/pkg/apis/dashboard/types.go diff --git a/pkg/apis/dashboard/utils.go b/apps/dashboard/pkg/apis/dashboard/utils.go similarity index 100% rename from pkg/apis/dashboard/utils.go rename to apps/dashboard/pkg/apis/dashboard/utils.go diff --git a/pkg/apis/dashboard/v0alpha1/constants.go b/apps/dashboard/pkg/apis/dashboard/v0alpha1/constants.go similarity index 100% rename from pkg/apis/dashboard/v0alpha1/constants.go rename to apps/dashboard/pkg/apis/dashboard/v0alpha1/constants.go diff --git a/pkg/apis/dashboard/v0alpha1/dashboard_codec_gen.go b/apps/dashboard/pkg/apis/dashboard/v0alpha1/dashboard_codec_gen.go similarity index 100% rename from pkg/apis/dashboard/v0alpha1/dashboard_codec_gen.go rename to apps/dashboard/pkg/apis/dashboard/v0alpha1/dashboard_codec_gen.go diff --git a/pkg/apis/dashboard/v0alpha1/dashboard_metadata_gen.go b/apps/dashboard/pkg/apis/dashboard/v0alpha1/dashboard_metadata_gen.go similarity index 100% rename from pkg/apis/dashboard/v0alpha1/dashboard_metadata_gen.go rename to apps/dashboard/pkg/apis/dashboard/v0alpha1/dashboard_metadata_gen.go diff --git a/pkg/apis/dashboard/v0alpha1/dashboard_object_gen.go b/apps/dashboard/pkg/apis/dashboard/v0alpha1/dashboard_object_gen.go similarity index 100% rename from pkg/apis/dashboard/v0alpha1/dashboard_object_gen.go rename to apps/dashboard/pkg/apis/dashboard/v0alpha1/dashboard_object_gen.go diff --git a/pkg/apis/dashboard/v0alpha1/dashboard_schema_gen.go b/apps/dashboard/pkg/apis/dashboard/v0alpha1/dashboard_schema_gen.go similarity index 100% rename from pkg/apis/dashboard/v0alpha1/dashboard_schema_gen.go rename to apps/dashboard/pkg/apis/dashboard/v0alpha1/dashboard_schema_gen.go diff --git a/pkg/apis/dashboard/v0alpha1/dashboard_spec.go b/apps/dashboard/pkg/apis/dashboard/v0alpha1/dashboard_spec.go similarity index 100% rename from pkg/apis/dashboard/v0alpha1/dashboard_spec.go rename to apps/dashboard/pkg/apis/dashboard/v0alpha1/dashboard_spec.go diff --git a/pkg/apis/dashboard/v0alpha1/dashboard_spec_gen.go b/apps/dashboard/pkg/apis/dashboard/v0alpha1/dashboard_spec_gen.go similarity index 100% rename from pkg/apis/dashboard/v0alpha1/dashboard_spec_gen.go rename to apps/dashboard/pkg/apis/dashboard/v0alpha1/dashboard_spec_gen.go diff --git a/pkg/apis/dashboard/v0alpha1/dashboard_status_gen.go b/apps/dashboard/pkg/apis/dashboard/v0alpha1/dashboard_status_gen.go similarity index 100% rename from pkg/apis/dashboard/v0alpha1/dashboard_status_gen.go rename to apps/dashboard/pkg/apis/dashboard/v0alpha1/dashboard_status_gen.go diff --git a/pkg/apis/dashboard/v0alpha1/deepcopy.go b/apps/dashboard/pkg/apis/dashboard/v0alpha1/deepcopy.go similarity index 100% rename from pkg/apis/dashboard/v0alpha1/deepcopy.go rename to apps/dashboard/pkg/apis/dashboard/v0alpha1/deepcopy.go diff --git a/pkg/apis/dashboard/v0alpha1/doc.go b/apps/dashboard/pkg/apis/dashboard/v0alpha1/doc.go similarity index 63% rename from pkg/apis/dashboard/v0alpha1/doc.go rename to apps/dashboard/pkg/apis/dashboard/v0alpha1/doc.go index 748fa7fffd2..a71646dde24 100644 --- a/pkg/apis/dashboard/v0alpha1/doc.go +++ b/apps/dashboard/pkg/apis/dashboard/v0alpha1/doc.go @@ -1,10 +1,10 @@ // +k8s:openapi-gen=true // +k8s:defaulter-gen=TypeMeta -// +k8s:conversion-gen=github.com/grafana/grafana/pkg/apis/dashboard +// +k8s:conversion-gen=github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard // +groupName=dashboard.grafana.app // NOTE (@radiohead): we do not use package-wide deepcopy generation // because grafana-app-sdk already provides deepcopy functions. // Kinds which are not generated by the SDK are explicitly opted in to deepcopy generation. -package v0alpha1 // import "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1" +package v0alpha1 // import "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1" diff --git a/pkg/apis/dashboard/v0alpha1/register.go b/apps/dashboard/pkg/apis/dashboard/v0alpha1/register.go similarity index 100% rename from pkg/apis/dashboard/v0alpha1/register.go rename to apps/dashboard/pkg/apis/dashboard/v0alpha1/register.go diff --git a/pkg/apis/dashboard/v0alpha1/search.go b/apps/dashboard/pkg/apis/dashboard/v0alpha1/search.go similarity index 100% rename from pkg/apis/dashboard/v0alpha1/search.go rename to apps/dashboard/pkg/apis/dashboard/v0alpha1/search.go diff --git a/pkg/apis/dashboard/v0alpha1/types.go b/apps/dashboard/pkg/apis/dashboard/v0alpha1/types.go similarity index 100% rename from pkg/apis/dashboard/v0alpha1/types.go rename to apps/dashboard/pkg/apis/dashboard/v0alpha1/types.go diff --git a/pkg/apis/dashboard/v0alpha1/zz_generated.conversion.go b/apps/dashboard/pkg/apis/dashboard/v0alpha1/zz_generated.conversion.go similarity index 99% rename from pkg/apis/dashboard/v0alpha1/zz_generated.conversion.go rename to apps/dashboard/pkg/apis/dashboard/v0alpha1/zz_generated.conversion.go index ade3e08a22a..b76e6b614ab 100644 --- a/pkg/apis/dashboard/v0alpha1/zz_generated.conversion.go +++ b/apps/dashboard/pkg/apis/dashboard/v0alpha1/zz_generated.conversion.go @@ -11,7 +11,7 @@ import ( url "net/url" unsafe "unsafe" - dashboard "github.com/grafana/grafana/pkg/apis/dashboard" + dashboard "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard" conversion "k8s.io/apimachinery/pkg/conversion" runtime "k8s.io/apimachinery/pkg/runtime" ) diff --git a/pkg/apis/dashboard/v0alpha1/zz_generated.deepcopy.go b/apps/dashboard/pkg/apis/dashboard/v0alpha1/zz_generated.deepcopy.go similarity index 100% rename from pkg/apis/dashboard/v0alpha1/zz_generated.deepcopy.go rename to apps/dashboard/pkg/apis/dashboard/v0alpha1/zz_generated.deepcopy.go diff --git a/pkg/apis/dashboard/v0alpha1/zz_generated.defaults.go b/apps/dashboard/pkg/apis/dashboard/v0alpha1/zz_generated.defaults.go similarity index 100% rename from pkg/apis/dashboard/v0alpha1/zz_generated.defaults.go rename to apps/dashboard/pkg/apis/dashboard/v0alpha1/zz_generated.defaults.go diff --git a/pkg/apis/dashboard/v0alpha1/zz_generated.openapi.go b/apps/dashboard/pkg/apis/dashboard/v0alpha1/zz_generated.openapi.go similarity index 82% rename from pkg/apis/dashboard/v0alpha1/zz_generated.openapi.go rename to apps/dashboard/pkg/apis/dashboard/v0alpha1/zz_generated.openapi.go index 6249102860d..a9d0f5b73c7 100644 --- a/pkg/apis/dashboard/v0alpha1/zz_generated.openapi.go +++ b/apps/dashboard/pkg/apis/dashboard/v0alpha1/zz_generated.openapi.go @@ -15,31 +15,31 @@ import ( func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenAPIDefinition { return map[string]common.OpenAPIDefinition{ - "github.com/grafana/grafana/pkg/apimachinery/apis/common/v0alpha1.Unstructured": commonv0alpha1.Unstructured{}.OpenAPIDefinition(), - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.AnnotationActions": schema_pkg_apis_dashboard_v0alpha1_AnnotationActions(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.AnnotationPermission": schema_pkg_apis_dashboard_v0alpha1_AnnotationPermission(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.Dashboard": schema_pkg_apis_dashboard_v0alpha1_Dashboard(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.DashboardAccess": schema_pkg_apis_dashboard_v0alpha1_DashboardAccess(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.DashboardConversionStatus": schema_pkg_apis_dashboard_v0alpha1_DashboardConversionStatus(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.DashboardHit": schema_pkg_apis_dashboard_v0alpha1_DashboardHit(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.DashboardJSONCodec": schema_pkg_apis_dashboard_v0alpha1_DashboardJSONCodec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.DashboardList": schema_pkg_apis_dashboard_v0alpha1_DashboardList(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.DashboardMetadata": schema_pkg_apis_dashboard_v0alpha1_DashboardMetadata(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.DashboardStatus": schema_pkg_apis_dashboard_v0alpha1_DashboardStatus(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.DashboardVersionInfo": schema_pkg_apis_dashboard_v0alpha1_DashboardVersionInfo(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.DashboardVersionList": schema_pkg_apis_dashboard_v0alpha1_DashboardVersionList(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.DashboardWithAccessInfo": schema_pkg_apis_dashboard_v0alpha1_DashboardWithAccessInfo(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.FacetResult": schema_pkg_apis_dashboard_v0alpha1_FacetResult(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.LibraryPanel": schema_pkg_apis_dashboard_v0alpha1_LibraryPanel(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.LibraryPanelList": schema_pkg_apis_dashboard_v0alpha1_LibraryPanelList(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.LibraryPanelSpec": schema_pkg_apis_dashboard_v0alpha1_LibraryPanelSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.LibraryPanelStatus": schema_pkg_apis_dashboard_v0alpha1_LibraryPanelStatus(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.SearchResults": schema_pkg_apis_dashboard_v0alpha1_SearchResults(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.SortBy": schema_pkg_apis_dashboard_v0alpha1_SortBy(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.SortableField": schema_pkg_apis_dashboard_v0alpha1_SortableField(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.SortableFields": schema_pkg_apis_dashboard_v0alpha1_SortableFields(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.TermFacet": schema_pkg_apis_dashboard_v0alpha1_TermFacet(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.VersionsQueryOptions": schema_pkg_apis_dashboard_v0alpha1_VersionsQueryOptions(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.AnnotationActions": schema_pkg_apis_dashboard_v0alpha1_AnnotationActions(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.AnnotationPermission": schema_pkg_apis_dashboard_v0alpha1_AnnotationPermission(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.Dashboard": schema_pkg_apis_dashboard_v0alpha1_Dashboard(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.DashboardAccess": schema_pkg_apis_dashboard_v0alpha1_DashboardAccess(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.DashboardConversionStatus": schema_pkg_apis_dashboard_v0alpha1_DashboardConversionStatus(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.DashboardHit": schema_pkg_apis_dashboard_v0alpha1_DashboardHit(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.DashboardJSONCodec": schema_pkg_apis_dashboard_v0alpha1_DashboardJSONCodec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.DashboardList": schema_pkg_apis_dashboard_v0alpha1_DashboardList(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.DashboardMetadata": schema_pkg_apis_dashboard_v0alpha1_DashboardMetadata(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.DashboardStatus": schema_pkg_apis_dashboard_v0alpha1_DashboardStatus(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.DashboardVersionInfo": schema_pkg_apis_dashboard_v0alpha1_DashboardVersionInfo(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.DashboardVersionList": schema_pkg_apis_dashboard_v0alpha1_DashboardVersionList(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.DashboardWithAccessInfo": schema_pkg_apis_dashboard_v0alpha1_DashboardWithAccessInfo(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.FacetResult": schema_pkg_apis_dashboard_v0alpha1_FacetResult(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.LibraryPanel": schema_pkg_apis_dashboard_v0alpha1_LibraryPanel(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.LibraryPanelList": schema_pkg_apis_dashboard_v0alpha1_LibraryPanelList(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.LibraryPanelSpec": schema_pkg_apis_dashboard_v0alpha1_LibraryPanelSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.LibraryPanelStatus": schema_pkg_apis_dashboard_v0alpha1_LibraryPanelStatus(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.SearchResults": schema_pkg_apis_dashboard_v0alpha1_SearchResults(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.SortBy": schema_pkg_apis_dashboard_v0alpha1_SortBy(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.SortableField": schema_pkg_apis_dashboard_v0alpha1_SortableField(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.SortableFields": schema_pkg_apis_dashboard_v0alpha1_SortableFields(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.TermFacet": schema_pkg_apis_dashboard_v0alpha1_TermFacet(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.VersionsQueryOptions": schema_pkg_apis_dashboard_v0alpha1_VersionsQueryOptions(ref), + "github.com/grafana/grafana/pkg/apimachinery/apis/common/v0alpha1.Unstructured": commonv0alpha1.Unstructured{}.OpenAPIDefinition(), } } @@ -86,13 +86,13 @@ func schema_pkg_apis_dashboard_v0alpha1_AnnotationPermission(ref common.Referenc "dashboard": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.AnnotationActions"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.AnnotationActions"), }, }, "organization": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.AnnotationActions"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.AnnotationActions"), }, }, }, @@ -100,7 +100,7 @@ func schema_pkg_apis_dashboard_v0alpha1_AnnotationPermission(ref common.Referenc }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.AnnotationActions"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.AnnotationActions"}, } } @@ -139,7 +139,7 @@ func schema_pkg_apis_dashboard_v0alpha1_Dashboard(ref common.ReferenceCallback) "status": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.DashboardStatus"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.DashboardStatus"), }, }, }, @@ -147,7 +147,7 @@ func schema_pkg_apis_dashboard_v0alpha1_Dashboard(ref common.ReferenceCallback) }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apimachinery/apis/common/v0alpha1.Unstructured", "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.DashboardStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.DashboardStatus", "github.com/grafana/grafana/pkg/apimachinery/apis/common/v0alpha1.Unstructured", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, } } @@ -208,7 +208,7 @@ func schema_pkg_apis_dashboard_v0alpha1_DashboardAccess(ref common.ReferenceCall }, "annotationsPermissions": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.AnnotationPermission"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.AnnotationPermission"), }, }, }, @@ -216,7 +216,7 @@ func schema_pkg_apis_dashboard_v0alpha1_DashboardAccess(ref common.ReferenceCall }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.AnnotationPermission"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.AnnotationPermission"}, } } @@ -382,7 +382,7 @@ func schema_pkg_apis_dashboard_v0alpha1_DashboardList(ref common.ReferenceCallba Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.Dashboard"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.Dashboard"), }, }, }, @@ -393,7 +393,7 @@ func schema_pkg_apis_dashboard_v0alpha1_DashboardList(ref common.ReferenceCallba }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.Dashboard", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.Dashboard", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, } } @@ -502,14 +502,14 @@ func schema_pkg_apis_dashboard_v0alpha1_DashboardStatus(ref common.ReferenceCall "conversion": { SchemaProps: spec.SchemaProps{ Description: "Optional conversion status.", - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.DashboardConversionStatus"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.DashboardConversionStatus"), }, }, }, }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.DashboardConversionStatus"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.DashboardConversionStatus"}, } } @@ -596,7 +596,7 @@ func schema_pkg_apis_dashboard_v0alpha1_DashboardVersionList(ref common.Referenc Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.DashboardVersionInfo"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.DashboardVersionInfo"), }, }, }, @@ -606,7 +606,7 @@ func schema_pkg_apis_dashboard_v0alpha1_DashboardVersionList(ref common.Referenc }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.DashboardVersionInfo", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.DashboardVersionInfo", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, } } @@ -646,13 +646,13 @@ func schema_pkg_apis_dashboard_v0alpha1_DashboardWithAccessInfo(ref common.Refer "status": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.DashboardStatus"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.DashboardStatus"), }, }, "access": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.DashboardAccess"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.DashboardAccess"), }, }, }, @@ -660,7 +660,7 @@ func schema_pkg_apis_dashboard_v0alpha1_DashboardWithAccessInfo(ref common.Refer }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apimachinery/apis/common/v0alpha1.Unstructured", "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.DashboardAccess", "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.DashboardStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.DashboardAccess", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.DashboardStatus", "github.com/grafana/grafana/pkg/apimachinery/apis/common/v0alpha1.Unstructured", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, } } @@ -698,7 +698,7 @@ func schema_pkg_apis_dashboard_v0alpha1_FacetResult(ref common.ReferenceCallback Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.TermFacet"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.TermFacet"), }, }, }, @@ -708,7 +708,7 @@ func schema_pkg_apis_dashboard_v0alpha1_FacetResult(ref common.ReferenceCallback }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.TermFacet"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.TermFacet"}, } } @@ -743,13 +743,13 @@ func schema_pkg_apis_dashboard_v0alpha1_LibraryPanel(ref common.ReferenceCallbac SchemaProps: spec.SchemaProps{ Description: "Panel properties", Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.LibraryPanelSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.LibraryPanelSpec"), }, }, "status": { SchemaProps: spec.SchemaProps{ Description: "Status will show errors", - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.LibraryPanelStatus"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.LibraryPanelStatus"), }, }, }, @@ -757,7 +757,7 @@ func schema_pkg_apis_dashboard_v0alpha1_LibraryPanel(ref common.ReferenceCallbac }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.LibraryPanelSpec", "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.LibraryPanelStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.LibraryPanelSpec", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.LibraryPanelStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, } } @@ -794,7 +794,7 @@ func schema_pkg_apis_dashboard_v0alpha1_LibraryPanelList(ref common.ReferenceCal Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.LibraryPanel"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.LibraryPanel"), }, }, }, @@ -804,7 +804,7 @@ func schema_pkg_apis_dashboard_v0alpha1_LibraryPanelList(ref common.ReferenceCal }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.LibraryPanel", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.LibraryPanel", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, } } @@ -966,7 +966,7 @@ func schema_pkg_apis_dashboard_v0alpha1_SearchResults(ref common.ReferenceCallba Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.DashboardHit"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.DashboardHit"), }, }, }, @@ -989,7 +989,7 @@ func schema_pkg_apis_dashboard_v0alpha1_SearchResults(ref common.ReferenceCallba "sortBy": { SchemaProps: spec.SchemaProps{ Description: "How are the results sorted", - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.SortBy"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.SortBy"), }, }, "facets": { @@ -1001,7 +1001,7 @@ func schema_pkg_apis_dashboard_v0alpha1_SearchResults(ref common.ReferenceCallba Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.FacetResult"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.FacetResult"), }, }, }, @@ -1012,7 +1012,7 @@ func schema_pkg_apis_dashboard_v0alpha1_SearchResults(ref common.ReferenceCallba }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.DashboardHit", "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.FacetResult", "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.SortBy"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.DashboardHit", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.FacetResult", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.SortBy"}, } } @@ -1100,7 +1100,7 @@ func schema_pkg_apis_dashboard_v0alpha1_SortableFields(ref common.ReferenceCallb Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.SortableField"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.SortableField"), }, }, }, @@ -1111,7 +1111,7 @@ func schema_pkg_apis_dashboard_v0alpha1_SortableFields(ref common.ReferenceCallb }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v0alpha1.SortableField"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1.SortableField"}, } } diff --git a/apps/dashboard/pkg/apis/dashboard/v0alpha1/zz_generated.openapi_violation_exceptions.list b/apps/dashboard/pkg/apis/dashboard/v0alpha1/zz_generated.openapi_violation_exceptions.list new file mode 100644 index 00000000000..68505c7d05d --- /dev/null +++ b/apps/dashboard/pkg/apis/dashboard/v0alpha1/zz_generated.openapi_violation_exceptions.list @@ -0,0 +1,9 @@ +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1,DashboardHit,Tags +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1,DashboardMetadata,Finalizers +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1,FacetResult,Terms +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1,LibraryPanelStatus,Warnings +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1,SearchResults,Hits +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1,SortableFields,Fields +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1,SortBy,Descending +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1,SortableField,Field +API rule violation: names_match,github.com/grafana/grafana/pkg/apimachinery/apis/common/v0alpha1,Unstructured,Object diff --git a/pkg/apis/dashboard/v1alpha1/constants.go b/apps/dashboard/pkg/apis/dashboard/v1alpha1/constants.go similarity index 100% rename from pkg/apis/dashboard/v1alpha1/constants.go rename to apps/dashboard/pkg/apis/dashboard/v1alpha1/constants.go diff --git a/pkg/apis/dashboard/v1alpha1/dashboard_codec_gen.go b/apps/dashboard/pkg/apis/dashboard/v1alpha1/dashboard_codec_gen.go similarity index 100% rename from pkg/apis/dashboard/v1alpha1/dashboard_codec_gen.go rename to apps/dashboard/pkg/apis/dashboard/v1alpha1/dashboard_codec_gen.go diff --git a/pkg/apis/dashboard/v1alpha1/dashboard_metadata_gen.go b/apps/dashboard/pkg/apis/dashboard/v1alpha1/dashboard_metadata_gen.go similarity index 100% rename from pkg/apis/dashboard/v1alpha1/dashboard_metadata_gen.go rename to apps/dashboard/pkg/apis/dashboard/v1alpha1/dashboard_metadata_gen.go diff --git a/pkg/apis/dashboard/v1alpha1/dashboard_object_gen.go b/apps/dashboard/pkg/apis/dashboard/v1alpha1/dashboard_object_gen.go similarity index 100% rename from pkg/apis/dashboard/v1alpha1/dashboard_object_gen.go rename to apps/dashboard/pkg/apis/dashboard/v1alpha1/dashboard_object_gen.go diff --git a/pkg/apis/dashboard/v1alpha1/dashboard_schema_gen.go b/apps/dashboard/pkg/apis/dashboard/v1alpha1/dashboard_schema_gen.go similarity index 100% rename from pkg/apis/dashboard/v1alpha1/dashboard_schema_gen.go rename to apps/dashboard/pkg/apis/dashboard/v1alpha1/dashboard_schema_gen.go diff --git a/pkg/apis/dashboard/v1alpha1/dashboard_spec.go b/apps/dashboard/pkg/apis/dashboard/v1alpha1/dashboard_spec.go similarity index 100% rename from pkg/apis/dashboard/v1alpha1/dashboard_spec.go rename to apps/dashboard/pkg/apis/dashboard/v1alpha1/dashboard_spec.go diff --git a/pkg/apis/dashboard/v1alpha1/dashboard_spec_gen.go b/apps/dashboard/pkg/apis/dashboard/v1alpha1/dashboard_spec_gen.go similarity index 100% rename from pkg/apis/dashboard/v1alpha1/dashboard_spec_gen.go rename to apps/dashboard/pkg/apis/dashboard/v1alpha1/dashboard_spec_gen.go diff --git a/pkg/apis/dashboard/v1alpha1/dashboard_status_gen.go b/apps/dashboard/pkg/apis/dashboard/v1alpha1/dashboard_status_gen.go similarity index 100% rename from pkg/apis/dashboard/v1alpha1/dashboard_status_gen.go rename to apps/dashboard/pkg/apis/dashboard/v1alpha1/dashboard_status_gen.go diff --git a/pkg/apis/dashboard/v1alpha1/deepcopy.go b/apps/dashboard/pkg/apis/dashboard/v1alpha1/deepcopy.go similarity index 100% rename from pkg/apis/dashboard/v1alpha1/deepcopy.go rename to apps/dashboard/pkg/apis/dashboard/v1alpha1/deepcopy.go diff --git a/pkg/apis/dashboard/v1alpha1/doc.go b/apps/dashboard/pkg/apis/dashboard/v1alpha1/doc.go similarity index 63% rename from pkg/apis/dashboard/v1alpha1/doc.go rename to apps/dashboard/pkg/apis/dashboard/v1alpha1/doc.go index f10d157ec41..66bf673964c 100644 --- a/pkg/apis/dashboard/v1alpha1/doc.go +++ b/apps/dashboard/pkg/apis/dashboard/v1alpha1/doc.go @@ -1,10 +1,10 @@ // +k8s:openapi-gen=true // +k8s:defaulter-gen=TypeMeta -// +k8s:conversion-gen=github.com/grafana/grafana/pkg/apis/dashboard +// +k8s:conversion-gen=github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard // +groupName=dashboard.grafana.app // NOTE (@radiohead): we do not use package-wide deepcopy generation // because grafana-app-sdk already provides deepcopy functions. // Kinds which are not generated by the SDK are explicitly opted in to deepcopy generation. -package v1alpha1 // import "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1" +package v1alpha1 // import "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1" diff --git a/pkg/apis/dashboard/v1alpha1/register.go b/apps/dashboard/pkg/apis/dashboard/v1alpha1/register.go similarity index 100% rename from pkg/apis/dashboard/v1alpha1/register.go rename to apps/dashboard/pkg/apis/dashboard/v1alpha1/register.go diff --git a/pkg/apis/dashboard/v1alpha1/types.go b/apps/dashboard/pkg/apis/dashboard/v1alpha1/types.go similarity index 100% rename from pkg/apis/dashboard/v1alpha1/types.go rename to apps/dashboard/pkg/apis/dashboard/v1alpha1/types.go diff --git a/pkg/apis/dashboard/v1alpha1/zz_generated.conversion.go b/apps/dashboard/pkg/apis/dashboard/v1alpha1/zz_generated.conversion.go similarity index 99% rename from pkg/apis/dashboard/v1alpha1/zz_generated.conversion.go rename to apps/dashboard/pkg/apis/dashboard/v1alpha1/zz_generated.conversion.go index d5a3f99ce07..85780124520 100644 --- a/pkg/apis/dashboard/v1alpha1/zz_generated.conversion.go +++ b/apps/dashboard/pkg/apis/dashboard/v1alpha1/zz_generated.conversion.go @@ -11,7 +11,7 @@ import ( url "net/url" unsafe "unsafe" - dashboard "github.com/grafana/grafana/pkg/apis/dashboard" + dashboard "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard" conversion "k8s.io/apimachinery/pkg/conversion" runtime "k8s.io/apimachinery/pkg/runtime" ) diff --git a/pkg/apis/dashboard/v1alpha1/zz_generated.deepcopy.go b/apps/dashboard/pkg/apis/dashboard/v1alpha1/zz_generated.deepcopy.go similarity index 100% rename from pkg/apis/dashboard/v1alpha1/zz_generated.deepcopy.go rename to apps/dashboard/pkg/apis/dashboard/v1alpha1/zz_generated.deepcopy.go diff --git a/pkg/apis/dashboard/v1alpha1/zz_generated.defaults.go b/apps/dashboard/pkg/apis/dashboard/v1alpha1/zz_generated.defaults.go similarity index 100% rename from pkg/apis/dashboard/v1alpha1/zz_generated.defaults.go rename to apps/dashboard/pkg/apis/dashboard/v1alpha1/zz_generated.defaults.go diff --git a/pkg/apis/dashboard/v1alpha1/zz_generated.openapi.go b/apps/dashboard/pkg/apis/dashboard/v1alpha1/zz_generated.openapi.go similarity index 82% rename from pkg/apis/dashboard/v1alpha1/zz_generated.openapi.go rename to apps/dashboard/pkg/apis/dashboard/v1alpha1/zz_generated.openapi.go index f9de16ee169..9e3bb475d68 100644 --- a/pkg/apis/dashboard/v1alpha1/zz_generated.openapi.go +++ b/apps/dashboard/pkg/apis/dashboard/v1alpha1/zz_generated.openapi.go @@ -15,24 +15,24 @@ import ( func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenAPIDefinition { return map[string]common.OpenAPIDefinition{ - "github.com/grafana/grafana/pkg/apimachinery/apis/common/v0alpha1.Unstructured": v0alpha1.Unstructured{}.OpenAPIDefinition(), - "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.AnnotationActions": schema_pkg_apis_dashboard_v1alpha1_AnnotationActions(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.AnnotationPermission": schema_pkg_apis_dashboard_v1alpha1_AnnotationPermission(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.Dashboard": schema_pkg_apis_dashboard_v1alpha1_Dashboard(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.DashboardAccess": schema_pkg_apis_dashboard_v1alpha1_DashboardAccess(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.DashboardConversionStatus": schema_pkg_apis_dashboard_v1alpha1_DashboardConversionStatus(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.DashboardJSONCodec": schema_pkg_apis_dashboard_v1alpha1_DashboardJSONCodec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.DashboardList": schema_pkg_apis_dashboard_v1alpha1_DashboardList(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.DashboardMetadata": schema_pkg_apis_dashboard_v1alpha1_DashboardMetadata(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.DashboardStatus": schema_pkg_apis_dashboard_v1alpha1_DashboardStatus(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.DashboardVersionInfo": schema_pkg_apis_dashboard_v1alpha1_DashboardVersionInfo(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.DashboardVersionList": schema_pkg_apis_dashboard_v1alpha1_DashboardVersionList(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.DashboardWithAccessInfo": schema_pkg_apis_dashboard_v1alpha1_DashboardWithAccessInfo(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.LibraryPanel": schema_pkg_apis_dashboard_v1alpha1_LibraryPanel(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.LibraryPanelList": schema_pkg_apis_dashboard_v1alpha1_LibraryPanelList(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.LibraryPanelSpec": schema_pkg_apis_dashboard_v1alpha1_LibraryPanelSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.LibraryPanelStatus": schema_pkg_apis_dashboard_v1alpha1_LibraryPanelStatus(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.VersionsQueryOptions": schema_pkg_apis_dashboard_v1alpha1_VersionsQueryOptions(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.AnnotationActions": schema_pkg_apis_dashboard_v1alpha1_AnnotationActions(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.AnnotationPermission": schema_pkg_apis_dashboard_v1alpha1_AnnotationPermission(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.Dashboard": schema_pkg_apis_dashboard_v1alpha1_Dashboard(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.DashboardAccess": schema_pkg_apis_dashboard_v1alpha1_DashboardAccess(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.DashboardConversionStatus": schema_pkg_apis_dashboard_v1alpha1_DashboardConversionStatus(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.DashboardJSONCodec": schema_pkg_apis_dashboard_v1alpha1_DashboardJSONCodec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.DashboardList": schema_pkg_apis_dashboard_v1alpha1_DashboardList(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.DashboardMetadata": schema_pkg_apis_dashboard_v1alpha1_DashboardMetadata(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.DashboardStatus": schema_pkg_apis_dashboard_v1alpha1_DashboardStatus(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.DashboardVersionInfo": schema_pkg_apis_dashboard_v1alpha1_DashboardVersionInfo(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.DashboardVersionList": schema_pkg_apis_dashboard_v1alpha1_DashboardVersionList(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.DashboardWithAccessInfo": schema_pkg_apis_dashboard_v1alpha1_DashboardWithAccessInfo(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.LibraryPanel": schema_pkg_apis_dashboard_v1alpha1_LibraryPanel(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.LibraryPanelList": schema_pkg_apis_dashboard_v1alpha1_LibraryPanelList(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.LibraryPanelSpec": schema_pkg_apis_dashboard_v1alpha1_LibraryPanelSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.LibraryPanelStatus": schema_pkg_apis_dashboard_v1alpha1_LibraryPanelStatus(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.VersionsQueryOptions": schema_pkg_apis_dashboard_v1alpha1_VersionsQueryOptions(ref), + "github.com/grafana/grafana/pkg/apimachinery/apis/common/v0alpha1.Unstructured": v0alpha1.Unstructured{}.OpenAPIDefinition(), } } @@ -79,13 +79,13 @@ func schema_pkg_apis_dashboard_v1alpha1_AnnotationPermission(ref common.Referenc "dashboard": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.AnnotationActions"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.AnnotationActions"), }, }, "organization": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.AnnotationActions"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.AnnotationActions"), }, }, }, @@ -93,7 +93,7 @@ func schema_pkg_apis_dashboard_v1alpha1_AnnotationPermission(ref common.Referenc }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.AnnotationActions"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.AnnotationActions"}, } } @@ -132,7 +132,7 @@ func schema_pkg_apis_dashboard_v1alpha1_Dashboard(ref common.ReferenceCallback) "status": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.DashboardStatus"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.DashboardStatus"), }, }, }, @@ -140,7 +140,7 @@ func schema_pkg_apis_dashboard_v1alpha1_Dashboard(ref common.ReferenceCallback) }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apimachinery/apis/common/v0alpha1.Unstructured", "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.DashboardStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.DashboardStatus", "github.com/grafana/grafana/pkg/apimachinery/apis/common/v0alpha1.Unstructured", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, } } @@ -202,7 +202,7 @@ func schema_pkg_apis_dashboard_v1alpha1_DashboardAccess(ref common.ReferenceCall }, "annotationsPermissions": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.AnnotationPermission"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.AnnotationPermission"), }, }, }, @@ -210,7 +210,7 @@ func schema_pkg_apis_dashboard_v1alpha1_DashboardAccess(ref common.ReferenceCall }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.AnnotationPermission"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.AnnotationPermission"}, } } @@ -296,7 +296,7 @@ func schema_pkg_apis_dashboard_v1alpha1_DashboardList(ref common.ReferenceCallba Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.Dashboard"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.Dashboard"), }, }, }, @@ -307,7 +307,7 @@ func schema_pkg_apis_dashboard_v1alpha1_DashboardList(ref common.ReferenceCallba }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.Dashboard", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.Dashboard", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, } } @@ -416,14 +416,14 @@ func schema_pkg_apis_dashboard_v1alpha1_DashboardStatus(ref common.ReferenceCall "conversion": { SchemaProps: spec.SchemaProps{ Description: "Optional conversion status.", - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.DashboardConversionStatus"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.DashboardConversionStatus"), }, }, }, }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.DashboardConversionStatus"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.DashboardConversionStatus"}, } } @@ -510,7 +510,7 @@ func schema_pkg_apis_dashboard_v1alpha1_DashboardVersionList(ref common.Referenc Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.DashboardVersionInfo"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.DashboardVersionInfo"), }, }, }, @@ -520,7 +520,7 @@ func schema_pkg_apis_dashboard_v1alpha1_DashboardVersionList(ref common.Referenc }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.DashboardVersionInfo", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.DashboardVersionInfo", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, } } @@ -560,13 +560,13 @@ func schema_pkg_apis_dashboard_v1alpha1_DashboardWithAccessInfo(ref common.Refer "status": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.DashboardStatus"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.DashboardStatus"), }, }, "access": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.DashboardAccess"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.DashboardAccess"), }, }, }, @@ -574,7 +574,7 @@ func schema_pkg_apis_dashboard_v1alpha1_DashboardWithAccessInfo(ref common.Refer }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apimachinery/apis/common/v0alpha1.Unstructured", "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.DashboardAccess", "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.DashboardStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.DashboardAccess", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.DashboardStatus", "github.com/grafana/grafana/pkg/apimachinery/apis/common/v0alpha1.Unstructured", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, } } @@ -609,13 +609,13 @@ func schema_pkg_apis_dashboard_v1alpha1_LibraryPanel(ref common.ReferenceCallbac SchemaProps: spec.SchemaProps{ Description: "Panel properties", Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.LibraryPanelSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.LibraryPanelSpec"), }, }, "status": { SchemaProps: spec.SchemaProps{ Description: "Status will show errors", - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.LibraryPanelStatus"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.LibraryPanelStatus"), }, }, }, @@ -623,7 +623,7 @@ func schema_pkg_apis_dashboard_v1alpha1_LibraryPanel(ref common.ReferenceCallbac }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.LibraryPanelSpec", "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.LibraryPanelStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.LibraryPanelSpec", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.LibraryPanelStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, } } @@ -660,7 +660,7 @@ func schema_pkg_apis_dashboard_v1alpha1_LibraryPanelList(ref common.ReferenceCal Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.LibraryPanel"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.LibraryPanel"), }, }, }, @@ -670,7 +670,7 @@ func schema_pkg_apis_dashboard_v1alpha1_LibraryPanelList(ref common.ReferenceCal }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1.LibraryPanel", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1.LibraryPanel", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, } } diff --git a/pkg/apis/dashboard/v1alpha1/zz_generated.openapi_violation_exceptions.list b/apps/dashboard/pkg/apis/dashboard/v1alpha1/zz_generated.openapi_violation_exceptions.list similarity index 62% rename from pkg/apis/dashboard/v1alpha1/zz_generated.openapi_violation_exceptions.list rename to apps/dashboard/pkg/apis/dashboard/v1alpha1/zz_generated.openapi_violation_exceptions.list index a34c29a7192..9a9b51f93c7 100644 --- a/pkg/apis/dashboard/v1alpha1/zz_generated.openapi_violation_exceptions.list +++ b/apps/dashboard/pkg/apis/dashboard/v1alpha1/zz_generated.openapi_violation_exceptions.list @@ -1,3 +1,3 @@ -API rule violation: list_type_missing,github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1,DashboardMetadata,Finalizers -API rule violation: list_type_missing,github.com/grafana/grafana/pkg/apis/dashboard/v1alpha1,LibraryPanelStatus,Warnings +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1,DashboardMetadata,Finalizers +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1,LibraryPanelStatus,Warnings API rule violation: names_match,github.com/grafana/grafana/pkg/apimachinery/apis/common/v0alpha1,Unstructured,Object diff --git a/pkg/apis/dashboard/v2alpha1/constants.go b/apps/dashboard/pkg/apis/dashboard/v2alpha1/constants.go similarity index 100% rename from pkg/apis/dashboard/v2alpha1/constants.go rename to apps/dashboard/pkg/apis/dashboard/v2alpha1/constants.go diff --git a/pkg/apis/dashboard/v2alpha1/dashboard_codec_gen.go b/apps/dashboard/pkg/apis/dashboard/v2alpha1/dashboard_codec_gen.go similarity index 100% rename from pkg/apis/dashboard/v2alpha1/dashboard_codec_gen.go rename to apps/dashboard/pkg/apis/dashboard/v2alpha1/dashboard_codec_gen.go diff --git a/pkg/apis/dashboard/v2alpha1/dashboard_metadata_gen.go b/apps/dashboard/pkg/apis/dashboard/v2alpha1/dashboard_metadata_gen.go similarity index 100% rename from pkg/apis/dashboard/v2alpha1/dashboard_metadata_gen.go rename to apps/dashboard/pkg/apis/dashboard/v2alpha1/dashboard_metadata_gen.go diff --git a/pkg/apis/dashboard/v2alpha1/dashboard_object_gen.go b/apps/dashboard/pkg/apis/dashboard/v2alpha1/dashboard_object_gen.go similarity index 100% rename from pkg/apis/dashboard/v2alpha1/dashboard_object_gen.go rename to apps/dashboard/pkg/apis/dashboard/v2alpha1/dashboard_object_gen.go diff --git a/pkg/apis/dashboard/v2alpha1/dashboard_schema_gen.go b/apps/dashboard/pkg/apis/dashboard/v2alpha1/dashboard_schema_gen.go similarity index 100% rename from pkg/apis/dashboard/v2alpha1/dashboard_schema_gen.go rename to apps/dashboard/pkg/apis/dashboard/v2alpha1/dashboard_schema_gen.go diff --git a/pkg/apis/dashboard/v2alpha1/dashboard_spec_gen.go b/apps/dashboard/pkg/apis/dashboard/v2alpha1/dashboard_spec_gen.go similarity index 90% rename from pkg/apis/dashboard/v2alpha1/dashboard_spec_gen.go rename to apps/dashboard/pkg/apis/dashboard/v2alpha1/dashboard_spec_gen.go index ade7b3398b0..9f13ee1f69b 100644 --- a/pkg/apis/dashboard/v2alpha1/dashboard_spec_gen.go +++ b/apps/dashboard/pkg/apis/dashboard/v2alpha1/dashboard_spec_gen.go @@ -833,10 +833,11 @@ func NewDashboardRowsLayoutRowKind() *DashboardRowsLayoutRowKind { // +k8s:openapi-gen=true type DashboardRowsLayoutRowSpec struct { - Title *string `json:"title,omitempty"` - Collapsed bool `json:"collapsed"` - Repeat *DashboardRowRepeatOptions `json:"repeat,omitempty"` - Layout DashboardGridLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind `json:"layout"` + Title *string `json:"title,omitempty"` + Collapsed bool `json:"collapsed"` + ConditionalRendering *DashboardConditionalRenderingGroupKind `json:"conditionalRendering,omitempty"` + Repeat *DashboardRowRepeatOptions `json:"repeat,omitempty"` + Layout DashboardGridLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind `json:"layout"` } // NewDashboardRowsLayoutRowSpec creates a new DashboardRowsLayoutRowSpec object. @@ -846,6 +847,105 @@ func NewDashboardRowsLayoutRowSpec() *DashboardRowsLayoutRowSpec { } } +// +k8s:openapi-gen=true +type DashboardConditionalRenderingGroupKind struct { + Kind string `json:"kind"` + Spec DashboardConditionalRenderingGroupSpec `json:"spec"` +} + +// NewDashboardConditionalRenderingGroupKind creates a new DashboardConditionalRenderingGroupKind object. +func NewDashboardConditionalRenderingGroupKind() *DashboardConditionalRenderingGroupKind { + return &DashboardConditionalRenderingGroupKind{ + Kind: "ConditionalRenderingGroup", + Spec: *NewDashboardConditionalRenderingGroupSpec(), + } +} + +// +k8s:openapi-gen=true +type DashboardConditionalRenderingGroupSpec struct { + Condition DashboardConditionalRenderingGroupSpecCondition `json:"condition"` + Items []DashboardConditionalRenderingVariableKindOrConditionalRenderingDataKindOrConditionalRenderingTimeIntervalKind `json:"items"` +} + +// NewDashboardConditionalRenderingGroupSpec creates a new DashboardConditionalRenderingGroupSpec object. +func NewDashboardConditionalRenderingGroupSpec() *DashboardConditionalRenderingGroupSpec { + return &DashboardConditionalRenderingGroupSpec{} +} + +// +k8s:openapi-gen=true +type DashboardConditionalRenderingVariableKind struct { + Kind string `json:"kind"` + Spec DashboardConditionalRenderingVariableSpec `json:"spec"` +} + +// NewDashboardConditionalRenderingVariableKind creates a new DashboardConditionalRenderingVariableKind object. +func NewDashboardConditionalRenderingVariableKind() *DashboardConditionalRenderingVariableKind { + return &DashboardConditionalRenderingVariableKind{ + Kind: "ConditionalRenderingVariable", + Spec: *NewDashboardConditionalRenderingVariableSpec(), + } +} + +// +k8s:openapi-gen=true +type DashboardConditionalRenderingVariableSpec struct { + Variable string `json:"variable"` + Operator DashboardConditionalRenderingVariableSpecOperator `json:"operator"` + Value string `json:"value"` +} + +// NewDashboardConditionalRenderingVariableSpec creates a new DashboardConditionalRenderingVariableSpec object. +func NewDashboardConditionalRenderingVariableSpec() *DashboardConditionalRenderingVariableSpec { + return &DashboardConditionalRenderingVariableSpec{} +} + +// +k8s:openapi-gen=true +type DashboardConditionalRenderingDataKind struct { + Kind string `json:"kind"` + Spec DashboardConditionalRenderingDataSpec `json:"spec"` +} + +// NewDashboardConditionalRenderingDataKind creates a new DashboardConditionalRenderingDataKind object. +func NewDashboardConditionalRenderingDataKind() *DashboardConditionalRenderingDataKind { + return &DashboardConditionalRenderingDataKind{ + Kind: "ConditionalRenderingData", + Spec: *NewDashboardConditionalRenderingDataSpec(), + } +} + +// +k8s:openapi-gen=true +type DashboardConditionalRenderingDataSpec struct { + Value bool `json:"value"` +} + +// NewDashboardConditionalRenderingDataSpec creates a new DashboardConditionalRenderingDataSpec object. +func NewDashboardConditionalRenderingDataSpec() *DashboardConditionalRenderingDataSpec { + return &DashboardConditionalRenderingDataSpec{} +} + +// +k8s:openapi-gen=true +type DashboardConditionalRenderingTimeIntervalKind struct { + Kind string `json:"kind"` + Spec DashboardConditionalRenderingTimeIntervalSpec `json:"spec"` +} + +// NewDashboardConditionalRenderingTimeIntervalKind creates a new DashboardConditionalRenderingTimeIntervalKind object. +func NewDashboardConditionalRenderingTimeIntervalKind() *DashboardConditionalRenderingTimeIntervalKind { + return &DashboardConditionalRenderingTimeIntervalKind{ + Kind: "ConditionalRenderingTimeInterval", + Spec: *NewDashboardConditionalRenderingTimeIntervalSpec(), + } +} + +// +k8s:openapi-gen=true +type DashboardConditionalRenderingTimeIntervalSpec struct { + Value string `json:"value"` +} + +// NewDashboardConditionalRenderingTimeIntervalSpec creates a new DashboardConditionalRenderingTimeIntervalSpec object. +func NewDashboardConditionalRenderingTimeIntervalSpec() *DashboardConditionalRenderingTimeIntervalSpec { + return &DashboardConditionalRenderingTimeIntervalSpec{} +} + // +k8s:openapi-gen=true type DashboardResponsiveGridLayoutKind struct { Kind string `json:"kind"` @@ -888,8 +988,9 @@ func NewDashboardResponsiveGridLayoutItemKind() *DashboardResponsiveGridLayoutIt // +k8s:openapi-gen=true type DashboardResponsiveGridLayoutItemSpec struct { - Element DashboardElementReference `json:"element"` - Repeat *DashboardResponsiveGridRepeatOptions `json:"repeat,omitempty"` + Element DashboardElementReference `json:"element"` + Repeat *DashboardResponsiveGridRepeatOptions `json:"repeat,omitempty"` + ConditionalRendering *DashboardConditionalRenderingGroupKind `json:"conditionalRendering,omitempty"` } // NewDashboardResponsiveGridLayoutItemSpec creates a new DashboardResponsiveGridLayoutItemSpec object. @@ -1675,6 +1776,22 @@ const ( DashboardRepeatOptionsDirectionV DashboardRepeatOptionsDirection = "v" ) +// +k8s:openapi-gen=true +type DashboardConditionalRenderingGroupSpecCondition string + +const ( + DashboardConditionalRenderingGroupSpecConditionAnd DashboardConditionalRenderingGroupSpecCondition = "and" + DashboardConditionalRenderingGroupSpecConditionOr DashboardConditionalRenderingGroupSpecCondition = "or" +) + +// +k8s:openapi-gen=true +type DashboardConditionalRenderingVariableSpecOperator string + +const ( + DashboardConditionalRenderingVariableSpecOperatorEquals DashboardConditionalRenderingVariableSpecOperator = "equals" + DashboardConditionalRenderingVariableSpecOperatorNotEquals DashboardConditionalRenderingVariableSpecOperator = "notEquals" +) + // +k8s:openapi-gen=true type DashboardTimeSettingsSpecWeekStart string @@ -1968,6 +2085,80 @@ func (resource *DashboardGridLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKin return fmt.Errorf("could not unmarshal resource with `kind = %v`", discriminator) } +// +k8s:openapi-gen=true +type DashboardConditionalRenderingVariableKindOrConditionalRenderingDataKindOrConditionalRenderingTimeIntervalKind struct { + ConditionalRenderingVariableKind *DashboardConditionalRenderingVariableKind `json:"ConditionalRenderingVariableKind,omitempty"` + ConditionalRenderingDataKind *DashboardConditionalRenderingDataKind `json:"ConditionalRenderingDataKind,omitempty"` + ConditionalRenderingTimeIntervalKind *DashboardConditionalRenderingTimeIntervalKind `json:"ConditionalRenderingTimeIntervalKind,omitempty"` +} + +// NewDashboardConditionalRenderingVariableKindOrConditionalRenderingDataKindOrConditionalRenderingTimeIntervalKind creates a new DashboardConditionalRenderingVariableKindOrConditionalRenderingDataKindOrConditionalRenderingTimeIntervalKind object. +func NewDashboardConditionalRenderingVariableKindOrConditionalRenderingDataKindOrConditionalRenderingTimeIntervalKind() *DashboardConditionalRenderingVariableKindOrConditionalRenderingDataKindOrConditionalRenderingTimeIntervalKind { + return &DashboardConditionalRenderingVariableKindOrConditionalRenderingDataKindOrConditionalRenderingTimeIntervalKind{} +} + +// MarshalJSON implements a custom JSON marshalling logic to encode `DashboardConditionalRenderingVariableKindOrConditionalRenderingDataKindOrConditionalRenderingTimeIntervalKind` as JSON. +func (resource DashboardConditionalRenderingVariableKindOrConditionalRenderingDataKindOrConditionalRenderingTimeIntervalKind) MarshalJSON() ([]byte, error) { + if resource.ConditionalRenderingVariableKind != nil { + return json.Marshal(resource.ConditionalRenderingVariableKind) + } + if resource.ConditionalRenderingDataKind != nil { + return json.Marshal(resource.ConditionalRenderingDataKind) + } + if resource.ConditionalRenderingTimeIntervalKind != nil { + return json.Marshal(resource.ConditionalRenderingTimeIntervalKind) + } + + return nil, fmt.Errorf("no value for disjunction of refs") +} + +// UnmarshalJSON implements a custom JSON unmarshalling logic to decode `DashboardConditionalRenderingVariableKindOrConditionalRenderingDataKindOrConditionalRenderingTimeIntervalKind` from JSON. +func (resource *DashboardConditionalRenderingVariableKindOrConditionalRenderingDataKindOrConditionalRenderingTimeIntervalKind) UnmarshalJSON(raw []byte) error { + if raw == nil { + return nil + } + + // FIXME: this is wasteful, we need to find a more efficient way to unmarshal this. + parsedAsMap := make(map[string]interface{}) + if err := json.Unmarshal(raw, &parsedAsMap); err != nil { + return err + } + + discriminator, found := parsedAsMap["kind"] + if !found { + return errors.New("discriminator field 'kind' not found in payload") + } + + switch discriminator { + case "ConditionalRenderingData": + var dashboardConditionalRenderingDataKind DashboardConditionalRenderingDataKind + if err := json.Unmarshal(raw, &dashboardConditionalRenderingDataKind); err != nil { + return err + } + + resource.ConditionalRenderingDataKind = &dashboardConditionalRenderingDataKind + return nil + case "ConditionalRenderingTimeInterval": + var dashboardConditionalRenderingTimeIntervalKind DashboardConditionalRenderingTimeIntervalKind + if err := json.Unmarshal(raw, &dashboardConditionalRenderingTimeIntervalKind); err != nil { + return err + } + + resource.ConditionalRenderingTimeIntervalKind = &dashboardConditionalRenderingTimeIntervalKind + return nil + case "ConditionalRenderingVariable": + var dashboardConditionalRenderingVariableKind DashboardConditionalRenderingVariableKind + if err := json.Unmarshal(raw, &dashboardConditionalRenderingVariableKind); err != nil { + return err + } + + resource.ConditionalRenderingVariableKind = &dashboardConditionalRenderingVariableKind + return nil + } + + return fmt.Errorf("could not unmarshal resource with `kind = %v`", discriminator) +} + // +k8s:openapi-gen=true type DashboardGridLayoutKindOrRowsLayoutKindOrResponsiveGridLayoutKind struct { GridLayoutKind *DashboardGridLayoutKind `json:"GridLayoutKind,omitempty"` diff --git a/pkg/apis/dashboard/v2alpha1/dashboard_status_gen.go b/apps/dashboard/pkg/apis/dashboard/v2alpha1/dashboard_status_gen.go similarity index 100% rename from pkg/apis/dashboard/v2alpha1/dashboard_status_gen.go rename to apps/dashboard/pkg/apis/dashboard/v2alpha1/dashboard_status_gen.go diff --git a/pkg/apis/dashboard/v2alpha1/deepcopy.go b/apps/dashboard/pkg/apis/dashboard/v2alpha1/deepcopy.go similarity index 100% rename from pkg/apis/dashboard/v2alpha1/deepcopy.go rename to apps/dashboard/pkg/apis/dashboard/v2alpha1/deepcopy.go diff --git a/pkg/apis/dashboard/v2alpha1/doc.go b/apps/dashboard/pkg/apis/dashboard/v2alpha1/doc.go similarity index 63% rename from pkg/apis/dashboard/v2alpha1/doc.go rename to apps/dashboard/pkg/apis/dashboard/v2alpha1/doc.go index 8866425fdce..c4f1d65781e 100644 --- a/pkg/apis/dashboard/v2alpha1/doc.go +++ b/apps/dashboard/pkg/apis/dashboard/v2alpha1/doc.go @@ -1,10 +1,10 @@ // +k8s:openapi-gen=true // +k8s:defaulter-gen=TypeMeta -// +k8s:conversion-gen=github.com/grafana/grafana/pkg/apis/dashboard +// +k8s:conversion-gen=github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard // +groupName=dashboard.grafana.app // NOTE (@radiohead): we do not use package-wide deepcopy generation // because grafana-app-sdk already provides deepcopy functions. // Kinds which are not generated by the SDK are explicitly opted in to deepcopy generation. -package v2alpha1 // import "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1" +package v2alpha1 // import "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1" diff --git a/pkg/apis/dashboard/v2alpha1/register.go b/apps/dashboard/pkg/apis/dashboard/v2alpha1/register.go similarity index 100% rename from pkg/apis/dashboard/v2alpha1/register.go rename to apps/dashboard/pkg/apis/dashboard/v2alpha1/register.go diff --git a/pkg/apis/dashboard/v2alpha1/types.go b/apps/dashboard/pkg/apis/dashboard/v2alpha1/types.go similarity index 100% rename from pkg/apis/dashboard/v2alpha1/types.go rename to apps/dashboard/pkg/apis/dashboard/v2alpha1/types.go diff --git a/pkg/apis/dashboard/v2alpha1/zz_generated.conversion.go b/apps/dashboard/pkg/apis/dashboard/v2alpha1/zz_generated.conversion.go similarity index 99% rename from pkg/apis/dashboard/v2alpha1/zz_generated.conversion.go rename to apps/dashboard/pkg/apis/dashboard/v2alpha1/zz_generated.conversion.go index 10204d0a3b3..fe4c7479194 100644 --- a/pkg/apis/dashboard/v2alpha1/zz_generated.conversion.go +++ b/apps/dashboard/pkg/apis/dashboard/v2alpha1/zz_generated.conversion.go @@ -11,7 +11,7 @@ import ( url "net/url" unsafe "unsafe" - dashboard "github.com/grafana/grafana/pkg/apis/dashboard" + dashboard "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard" conversion "k8s.io/apimachinery/pkg/conversion" runtime "k8s.io/apimachinery/pkg/runtime" ) diff --git a/pkg/apis/dashboard/v2alpha1/zz_generated.deepcopy.go b/apps/dashboard/pkg/apis/dashboard/v2alpha1/zz_generated.deepcopy.go similarity index 100% rename from pkg/apis/dashboard/v2alpha1/zz_generated.deepcopy.go rename to apps/dashboard/pkg/apis/dashboard/v2alpha1/zz_generated.deepcopy.go diff --git a/pkg/apis/dashboard/v2alpha1/zz_generated.defaults.go b/apps/dashboard/pkg/apis/dashboard/v2alpha1/zz_generated.defaults.go similarity index 100% rename from pkg/apis/dashboard/v2alpha1/zz_generated.defaults.go rename to apps/dashboard/pkg/apis/dashboard/v2alpha1/zz_generated.defaults.go diff --git a/pkg/apis/dashboard/v2alpha1/zz_generated.openapi.go b/apps/dashboard/pkg/apis/dashboard/v2alpha1/zz_generated.openapi.go similarity index 62% rename from pkg/apis/dashboard/v2alpha1/zz_generated.openapi.go rename to apps/dashboard/pkg/apis/dashboard/v2alpha1/zz_generated.openapi.go index 1025adcda86..ccb68473004 100644 --- a/pkg/apis/dashboard/v2alpha1/zz_generated.openapi.go +++ b/apps/dashboard/pkg/apis/dashboard/v2alpha1/zz_generated.openapi.go @@ -14,113 +14,122 @@ import ( func GetOpenAPIDefinitions(ref common.ReferenceCallback) map[string]common.OpenAPIDefinition { return map[string]common.OpenAPIDefinition{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.AnnotationActions": schema_pkg_apis_dashboard_v2alpha1_AnnotationActions(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.AnnotationPermission": schema_pkg_apis_dashboard_v2alpha1_AnnotationPermission(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.Dashboard": schema_pkg_apis_dashboard_v2alpha1_Dashboard(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardAccess": schema_pkg_apis_dashboard_v2alpha1_DashboardAccess(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardAdHocFilterWithLabels": schema_pkg_apis_dashboard_v2alpha1_DashboardAdHocFilterWithLabels(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardAdhocVariableKind": schema_pkg_apis_dashboard_v2alpha1_DashboardAdhocVariableKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardAdhocVariableSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardAdhocVariableSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardAnnotationPanelFilter": schema_pkg_apis_dashboard_v2alpha1_DashboardAnnotationPanelFilter(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardAnnotationQueryKind": schema_pkg_apis_dashboard_v2alpha1_DashboardAnnotationQueryKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardAnnotationQuerySpec": schema_pkg_apis_dashboard_v2alpha1_DashboardAnnotationQuerySpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardConstantVariableKind": schema_pkg_apis_dashboard_v2alpha1_DashboardConstantVariableKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardConstantVariableSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardConstantVariableSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardConversionStatus": schema_pkg_apis_dashboard_v2alpha1_DashboardConversionStatus(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardCustomVariableKind": schema_pkg_apis_dashboard_v2alpha1_DashboardCustomVariableKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardCustomVariableSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardCustomVariableSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDashboardLink": schema_pkg_apis_dashboard_v2alpha1_DashboardDashboardLink(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDataLink": schema_pkg_apis_dashboard_v2alpha1_DashboardDataLink(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDataQueryKind": schema_pkg_apis_dashboard_v2alpha1_DashboardDataQueryKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDataSourceRef": schema_pkg_apis_dashboard_v2alpha1_DashboardDataSourceRef(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDataTransformerConfig": schema_pkg_apis_dashboard_v2alpha1_DashboardDataTransformerConfig(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDatasourceVariableKind": schema_pkg_apis_dashboard_v2alpha1_DashboardDatasourceVariableKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDatasourceVariableSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardDatasourceVariableSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDynamicConfigValue": schema_pkg_apis_dashboard_v2alpha1_DashboardDynamicConfigValue(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardElementReference": schema_pkg_apis_dashboard_v2alpha1_DashboardElementReference(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardFieldColor": schema_pkg_apis_dashboard_v2alpha1_DashboardFieldColor(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardFieldConfig": schema_pkg_apis_dashboard_v2alpha1_DashboardFieldConfig(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardFieldConfigSource": schema_pkg_apis_dashboard_v2alpha1_DashboardFieldConfigSource(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutItemKind": schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutItemKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutItemKindOrGridLayoutRowKind": schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutItemKindOrGridLayoutRowKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutItemSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutItemSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKind": schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind": schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKindOrRowsLayoutKindOrResponsiveGridLayoutKind": schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutKindOrRowsLayoutKindOrResponsiveGridLayoutKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKindOrRowsLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind": schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutKindOrRowsLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutRowKind": schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutRowKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutRowSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutRowSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGroupByVariableKind": schema_pkg_apis_dashboard_v2alpha1_DashboardGroupByVariableKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGroupByVariableSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardGroupByVariableSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardIntervalVariableKind": schema_pkg_apis_dashboard_v2alpha1_DashboardIntervalVariableKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardIntervalVariableSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardIntervalVariableSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardJSONCodec": schema_pkg_apis_dashboard_v2alpha1_DashboardJSONCodec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardLibraryPanelKind": schema_pkg_apis_dashboard_v2alpha1_DashboardLibraryPanelKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardLibraryPanelKindSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardLibraryPanelKindSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardLibraryPanelRef": schema_pkg_apis_dashboard_v2alpha1_DashboardLibraryPanelRef(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardList": schema_pkg_apis_dashboard_v2alpha1_DashboardList(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardMatcherConfig": schema_pkg_apis_dashboard_v2alpha1_DashboardMatcherConfig(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardMetadata": schema_pkg_apis_dashboard_v2alpha1_DashboardMetadata(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardMetricFindValue": schema_pkg_apis_dashboard_v2alpha1_DashboardMetricFindValue(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardPanelKind": schema_pkg_apis_dashboard_v2alpha1_DashboardPanelKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardPanelKindOrLibraryPanelKind": schema_pkg_apis_dashboard_v2alpha1_DashboardPanelKindOrLibraryPanelKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardPanelQueryKind": schema_pkg_apis_dashboard_v2alpha1_DashboardPanelQueryKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardPanelQuerySpec": schema_pkg_apis_dashboard_v2alpha1_DashboardPanelQuerySpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardPanelSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardPanelSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardQueryGroupKind": schema_pkg_apis_dashboard_v2alpha1_DashboardQueryGroupKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardQueryGroupSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardQueryGroupSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardQueryOptionsSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardQueryOptionsSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardQueryVariableKind": schema_pkg_apis_dashboard_v2alpha1_DashboardQueryVariableKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardQueryVariableKindOrTextVariableKindOrConstantVariableKindOrDatasourceVariableKindOrIntervalVariableKindOrCustomVariableKindOrGroupByVariableKindOrAdhocVariableKind": schema_pkg_apis_dashboard_v2alpha1_DashboardQueryVariableKindOrTextVariableKindOrConstantVariableKindOrDatasourceVariableKindOrIntervalVariableKindOrCustomVariableKindOrGroupByVariableKindOrAdhocVariableKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardQueryVariableSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardQueryVariableSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRangeMap": schema_pkg_apis_dashboard_v2alpha1_DashboardRangeMap(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRegexMap": schema_pkg_apis_dashboard_v2alpha1_DashboardRegexMap(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRepeatOptions": schema_pkg_apis_dashboard_v2alpha1_DashboardRepeatOptions(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutItemKind": schema_pkg_apis_dashboard_v2alpha1_DashboardResponsiveGridLayoutItemKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutItemSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardResponsiveGridLayoutItemSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutKind": schema_pkg_apis_dashboard_v2alpha1_DashboardResponsiveGridLayoutKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardResponsiveGridLayoutSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridRepeatOptions": schema_pkg_apis_dashboard_v2alpha1_DashboardResponsiveGridRepeatOptions(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRowRepeatOptions": schema_pkg_apis_dashboard_v2alpha1_DashboardRowRepeatOptions(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutKind": schema_pkg_apis_dashboard_v2alpha1_DashboardRowsLayoutKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutRowKind": schema_pkg_apis_dashboard_v2alpha1_DashboardRowsLayoutRowKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutRowSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardRowsLayoutRowSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardRowsLayoutSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardSpecialValueMap": schema_pkg_apis_dashboard_v2alpha1_DashboardSpecialValueMap(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardStatus": schema_pkg_apis_dashboard_v2alpha1_DashboardStatus(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardStringOrArrayOfString": schema_pkg_apis_dashboard_v2alpha1_DashboardStringOrArrayOfString(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardStringOrFloat64": schema_pkg_apis_dashboard_v2alpha1_DashboardStringOrFloat64(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutKind": schema_pkg_apis_dashboard_v2alpha1_DashboardTabsLayoutKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardTabsLayoutSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutTabKind": schema_pkg_apis_dashboard_v2alpha1_DashboardTabsLayoutTabKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutTabSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardTabsLayoutTabSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTextVariableKind": schema_pkg_apis_dashboard_v2alpha1_DashboardTextVariableKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTextVariableSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardTextVariableSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardThreshold": schema_pkg_apis_dashboard_v2alpha1_DashboardThreshold(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardThresholdsConfig": schema_pkg_apis_dashboard_v2alpha1_DashboardThresholdsConfig(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTimeRangeOption": schema_pkg_apis_dashboard_v2alpha1_DashboardTimeRangeOption(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTimeSettingsSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardTimeSettingsSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTransformationKind": schema_pkg_apis_dashboard_v2alpha1_DashboardTransformationKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardV2alpha1FieldConfigSourceOverrides": schema_pkg_apis_dashboard_v2alpha1_DashboardV2alpha1FieldConfigSourceOverrides(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardV2alpha1RangeMapOptions": schema_pkg_apis_dashboard_v2alpha1_DashboardV2alpha1RangeMapOptions(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardV2alpha1RegexMapOptions": schema_pkg_apis_dashboard_v2alpha1_DashboardV2alpha1RegexMapOptions(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardV2alpha1SpecialValueMapOptions": schema_pkg_apis_dashboard_v2alpha1_DashboardV2alpha1SpecialValueMapOptions(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardValueMap": schema_pkg_apis_dashboard_v2alpha1_DashboardValueMap(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardValueMapOrRangeMapOrRegexMapOrSpecialValueMap": schema_pkg_apis_dashboard_v2alpha1_DashboardValueMapOrRangeMapOrRegexMapOrSpecialValueMap(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardValueMappingResult": schema_pkg_apis_dashboard_v2alpha1_DashboardValueMappingResult(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVariableOption": schema_pkg_apis_dashboard_v2alpha1_DashboardVariableOption(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVersionInfo": schema_pkg_apis_dashboard_v2alpha1_DashboardVersionInfo(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVersionList": schema_pkg_apis_dashboard_v2alpha1_DashboardVersionList(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVizConfigKind": schema_pkg_apis_dashboard_v2alpha1_DashboardVizConfigKind(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVizConfigSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardVizConfigSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardWithAccessInfo": schema_pkg_apis_dashboard_v2alpha1_DashboardWithAccessInfo(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.LibraryPanel": schema_pkg_apis_dashboard_v2alpha1_LibraryPanel(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.LibraryPanelList": schema_pkg_apis_dashboard_v2alpha1_LibraryPanelList(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.LibraryPanelSpec": schema_pkg_apis_dashboard_v2alpha1_LibraryPanelSpec(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.LibraryPanelStatus": schema_pkg_apis_dashboard_v2alpha1_LibraryPanelStatus(ref), - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.VersionsQueryOptions": schema_pkg_apis_dashboard_v2alpha1_VersionsQueryOptions(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.AnnotationActions": schema_pkg_apis_dashboard_v2alpha1_AnnotationActions(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.AnnotationPermission": schema_pkg_apis_dashboard_v2alpha1_AnnotationPermission(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.Dashboard": schema_pkg_apis_dashboard_v2alpha1_Dashboard(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardAccess": schema_pkg_apis_dashboard_v2alpha1_DashboardAccess(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardAdHocFilterWithLabels": schema_pkg_apis_dashboard_v2alpha1_DashboardAdHocFilterWithLabels(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardAdhocVariableKind": schema_pkg_apis_dashboard_v2alpha1_DashboardAdhocVariableKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardAdhocVariableSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardAdhocVariableSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardAnnotationPanelFilter": schema_pkg_apis_dashboard_v2alpha1_DashboardAnnotationPanelFilter(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardAnnotationQueryKind": schema_pkg_apis_dashboard_v2alpha1_DashboardAnnotationQueryKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardAnnotationQuerySpec": schema_pkg_apis_dashboard_v2alpha1_DashboardAnnotationQuerySpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingDataKind": schema_pkg_apis_dashboard_v2alpha1_DashboardConditionalRenderingDataKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingDataSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardConditionalRenderingDataSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingGroupKind": schema_pkg_apis_dashboard_v2alpha1_DashboardConditionalRenderingGroupKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingGroupSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardConditionalRenderingGroupSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingTimeIntervalKind": schema_pkg_apis_dashboard_v2alpha1_DashboardConditionalRenderingTimeIntervalKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingTimeIntervalSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardConditionalRenderingTimeIntervalSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingVariableKind": schema_pkg_apis_dashboard_v2alpha1_DashboardConditionalRenderingVariableKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingVariableKindOrConditionalRenderingDataKindOrConditionalRenderingTimeIntervalKind": schema_pkg_apis_dashboard_v2alpha1_DashboardConditionalRenderingVariableKindOrConditionalRenderingDataKindOrConditionalRenderingTimeIntervalKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingVariableSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardConditionalRenderingVariableSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConstantVariableKind": schema_pkg_apis_dashboard_v2alpha1_DashboardConstantVariableKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConstantVariableSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardConstantVariableSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConversionStatus": schema_pkg_apis_dashboard_v2alpha1_DashboardConversionStatus(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardCustomVariableKind": schema_pkg_apis_dashboard_v2alpha1_DashboardCustomVariableKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardCustomVariableSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardCustomVariableSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDashboardLink": schema_pkg_apis_dashboard_v2alpha1_DashboardDashboardLink(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDataLink": schema_pkg_apis_dashboard_v2alpha1_DashboardDataLink(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDataQueryKind": schema_pkg_apis_dashboard_v2alpha1_DashboardDataQueryKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDataSourceRef": schema_pkg_apis_dashboard_v2alpha1_DashboardDataSourceRef(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDataTransformerConfig": schema_pkg_apis_dashboard_v2alpha1_DashboardDataTransformerConfig(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDatasourceVariableKind": schema_pkg_apis_dashboard_v2alpha1_DashboardDatasourceVariableKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDatasourceVariableSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardDatasourceVariableSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDynamicConfigValue": schema_pkg_apis_dashboard_v2alpha1_DashboardDynamicConfigValue(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardElementReference": schema_pkg_apis_dashboard_v2alpha1_DashboardElementReference(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardFieldColor": schema_pkg_apis_dashboard_v2alpha1_DashboardFieldColor(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardFieldConfig": schema_pkg_apis_dashboard_v2alpha1_DashboardFieldConfig(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardFieldConfigSource": schema_pkg_apis_dashboard_v2alpha1_DashboardFieldConfigSource(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutItemKind": schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutItemKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutItemKindOrGridLayoutRowKind": schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutItemKindOrGridLayoutRowKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutItemSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutItemSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKind": schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind": schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKindOrRowsLayoutKindOrResponsiveGridLayoutKind": schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutKindOrRowsLayoutKindOrResponsiveGridLayoutKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKindOrRowsLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind": schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutKindOrRowsLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutRowKind": schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutRowKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutRowSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutRowSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGroupByVariableKind": schema_pkg_apis_dashboard_v2alpha1_DashboardGroupByVariableKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGroupByVariableSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardGroupByVariableSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardIntervalVariableKind": schema_pkg_apis_dashboard_v2alpha1_DashboardIntervalVariableKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardIntervalVariableSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardIntervalVariableSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardJSONCodec": schema_pkg_apis_dashboard_v2alpha1_DashboardJSONCodec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardLibraryPanelKind": schema_pkg_apis_dashboard_v2alpha1_DashboardLibraryPanelKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardLibraryPanelKindSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardLibraryPanelKindSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardLibraryPanelRef": schema_pkg_apis_dashboard_v2alpha1_DashboardLibraryPanelRef(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardList": schema_pkg_apis_dashboard_v2alpha1_DashboardList(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardMatcherConfig": schema_pkg_apis_dashboard_v2alpha1_DashboardMatcherConfig(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardMetadata": schema_pkg_apis_dashboard_v2alpha1_DashboardMetadata(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardMetricFindValue": schema_pkg_apis_dashboard_v2alpha1_DashboardMetricFindValue(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardPanelKind": schema_pkg_apis_dashboard_v2alpha1_DashboardPanelKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardPanelKindOrLibraryPanelKind": schema_pkg_apis_dashboard_v2alpha1_DashboardPanelKindOrLibraryPanelKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardPanelQueryKind": schema_pkg_apis_dashboard_v2alpha1_DashboardPanelQueryKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardPanelQuerySpec": schema_pkg_apis_dashboard_v2alpha1_DashboardPanelQuerySpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardPanelSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardPanelSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardQueryGroupKind": schema_pkg_apis_dashboard_v2alpha1_DashboardQueryGroupKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardQueryGroupSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardQueryGroupSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardQueryOptionsSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardQueryOptionsSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardQueryVariableKind": schema_pkg_apis_dashboard_v2alpha1_DashboardQueryVariableKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardQueryVariableKindOrTextVariableKindOrConstantVariableKindOrDatasourceVariableKindOrIntervalVariableKindOrCustomVariableKindOrGroupByVariableKindOrAdhocVariableKind": schema_pkg_apis_dashboard_v2alpha1_DashboardQueryVariableKindOrTextVariableKindOrConstantVariableKindOrDatasourceVariableKindOrIntervalVariableKindOrCustomVariableKindOrGroupByVariableKindOrAdhocVariableKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardQueryVariableSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardQueryVariableSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRangeMap": schema_pkg_apis_dashboard_v2alpha1_DashboardRangeMap(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRegexMap": schema_pkg_apis_dashboard_v2alpha1_DashboardRegexMap(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRepeatOptions": schema_pkg_apis_dashboard_v2alpha1_DashboardRepeatOptions(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutItemKind": schema_pkg_apis_dashboard_v2alpha1_DashboardResponsiveGridLayoutItemKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutItemSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardResponsiveGridLayoutItemSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutKind": schema_pkg_apis_dashboard_v2alpha1_DashboardResponsiveGridLayoutKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardResponsiveGridLayoutSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridRepeatOptions": schema_pkg_apis_dashboard_v2alpha1_DashboardResponsiveGridRepeatOptions(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRowRepeatOptions": schema_pkg_apis_dashboard_v2alpha1_DashboardRowRepeatOptions(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutKind": schema_pkg_apis_dashboard_v2alpha1_DashboardRowsLayoutKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutRowKind": schema_pkg_apis_dashboard_v2alpha1_DashboardRowsLayoutRowKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutRowSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardRowsLayoutRowSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardRowsLayoutSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardSpecialValueMap": schema_pkg_apis_dashboard_v2alpha1_DashboardSpecialValueMap(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardStatus": schema_pkg_apis_dashboard_v2alpha1_DashboardStatus(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardStringOrArrayOfString": schema_pkg_apis_dashboard_v2alpha1_DashboardStringOrArrayOfString(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardStringOrFloat64": schema_pkg_apis_dashboard_v2alpha1_DashboardStringOrFloat64(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutKind": schema_pkg_apis_dashboard_v2alpha1_DashboardTabsLayoutKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardTabsLayoutSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutTabKind": schema_pkg_apis_dashboard_v2alpha1_DashboardTabsLayoutTabKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutTabSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardTabsLayoutTabSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTextVariableKind": schema_pkg_apis_dashboard_v2alpha1_DashboardTextVariableKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTextVariableSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardTextVariableSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardThreshold": schema_pkg_apis_dashboard_v2alpha1_DashboardThreshold(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardThresholdsConfig": schema_pkg_apis_dashboard_v2alpha1_DashboardThresholdsConfig(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTimeRangeOption": schema_pkg_apis_dashboard_v2alpha1_DashboardTimeRangeOption(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTimeSettingsSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardTimeSettingsSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTransformationKind": schema_pkg_apis_dashboard_v2alpha1_DashboardTransformationKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardV2alpha1FieldConfigSourceOverrides": schema_pkg_apis_dashboard_v2alpha1_DashboardV2alpha1FieldConfigSourceOverrides(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardV2alpha1RangeMapOptions": schema_pkg_apis_dashboard_v2alpha1_DashboardV2alpha1RangeMapOptions(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardV2alpha1RegexMapOptions": schema_pkg_apis_dashboard_v2alpha1_DashboardV2alpha1RegexMapOptions(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardV2alpha1SpecialValueMapOptions": schema_pkg_apis_dashboard_v2alpha1_DashboardV2alpha1SpecialValueMapOptions(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardValueMap": schema_pkg_apis_dashboard_v2alpha1_DashboardValueMap(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardValueMapOrRangeMapOrRegexMapOrSpecialValueMap": schema_pkg_apis_dashboard_v2alpha1_DashboardValueMapOrRangeMapOrRegexMapOrSpecialValueMap(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardValueMappingResult": schema_pkg_apis_dashboard_v2alpha1_DashboardValueMappingResult(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVariableOption": schema_pkg_apis_dashboard_v2alpha1_DashboardVariableOption(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVersionInfo": schema_pkg_apis_dashboard_v2alpha1_DashboardVersionInfo(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVersionList": schema_pkg_apis_dashboard_v2alpha1_DashboardVersionList(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVizConfigKind": schema_pkg_apis_dashboard_v2alpha1_DashboardVizConfigKind(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVizConfigSpec": schema_pkg_apis_dashboard_v2alpha1_DashboardVizConfigSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardWithAccessInfo": schema_pkg_apis_dashboard_v2alpha1_DashboardWithAccessInfo(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.LibraryPanel": schema_pkg_apis_dashboard_v2alpha1_LibraryPanel(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.LibraryPanelList": schema_pkg_apis_dashboard_v2alpha1_LibraryPanelList(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.LibraryPanelSpec": schema_pkg_apis_dashboard_v2alpha1_LibraryPanelSpec(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.LibraryPanelStatus": schema_pkg_apis_dashboard_v2alpha1_LibraryPanelStatus(ref), + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.VersionsQueryOptions": schema_pkg_apis_dashboard_v2alpha1_VersionsQueryOptions(ref), } } @@ -167,13 +176,13 @@ func schema_pkg_apis_dashboard_v2alpha1_AnnotationPermission(ref common.Referenc "dashboard": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.AnnotationActions"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.AnnotationActions"), }, }, "organization": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.AnnotationActions"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.AnnotationActions"), }, }, }, @@ -181,7 +190,7 @@ func schema_pkg_apis_dashboard_v2alpha1_AnnotationPermission(ref common.Referenc }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.AnnotationActions"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.AnnotationActions"}, } } @@ -215,13 +224,13 @@ func schema_pkg_apis_dashboard_v2alpha1_Dashboard(ref common.ReferenceCallback) SchemaProps: spec.SchemaProps{ Description: "Spec is the spec of the Dashboard", Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardSpec"), }, }, "status": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardStatus"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardStatus"), }, }, }, @@ -229,7 +238,7 @@ func schema_pkg_apis_dashboard_v2alpha1_Dashboard(ref common.ReferenceCallback) }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardSpec", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardSpec", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, } } @@ -291,7 +300,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardAccess(ref common.ReferenceCall }, "annotationsPermissions": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.AnnotationPermission"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.AnnotationPermission"), }, }, }, @@ -299,7 +308,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardAccess(ref common.ReferenceCall }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.AnnotationPermission"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.AnnotationPermission"}, } } @@ -402,7 +411,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardAdhocVariableKind(ref common.Re "spec": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardAdhocVariableSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardAdhocVariableSpec"), }, }, }, @@ -410,7 +419,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardAdhocVariableKind(ref common.Re }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardAdhocVariableSpec"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardAdhocVariableSpec"}, } } @@ -430,7 +439,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardAdhocVariableSpec(ref common.Re }, "datasource": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDataSourceRef"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDataSourceRef"), }, }, "baseFilters": { @@ -440,7 +449,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardAdhocVariableSpec(ref common.Re Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardAdHocFilterWithLabels"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardAdHocFilterWithLabels"), }, }, }, @@ -453,7 +462,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardAdhocVariableSpec(ref common.Re Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardAdHocFilterWithLabels"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardAdHocFilterWithLabels"), }, }, }, @@ -466,7 +475,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardAdhocVariableSpec(ref common.Re Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardMetricFindValue"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardMetricFindValue"), }, }, }, @@ -503,7 +512,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardAdhocVariableSpec(ref common.Re }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardAdHocFilterWithLabels", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDataSourceRef", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardMetricFindValue"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardAdHocFilterWithLabels", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDataSourceRef", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardMetricFindValue"}, } } @@ -558,7 +567,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardAnnotationQueryKind(ref common. "spec": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardAnnotationQuerySpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardAnnotationQuerySpec"), }, }, }, @@ -566,7 +575,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardAnnotationQueryKind(ref common. }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardAnnotationQuerySpec"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardAnnotationQuerySpec"}, } } @@ -578,12 +587,12 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardAnnotationQuerySpec(ref common. Properties: map[string]spec.Schema{ "datasource": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDataSourceRef"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDataSourceRef"), }, }, "query": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDataQueryKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDataQueryKind"), }, }, "enable": { @@ -622,7 +631,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardAnnotationQuerySpec(ref common. }, "filter": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardAnnotationPanelFilter"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardAnnotationPanelFilter"), }, }, }, @@ -630,7 +639,256 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardAnnotationQuerySpec(ref common. }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardAnnotationPanelFilter", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDataQueryKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDataSourceRef"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardAnnotationPanelFilter", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDataQueryKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDataSourceRef"}, + } +} + +func schema_pkg_apis_dashboard_v2alpha1_DashboardConditionalRenderingDataKind(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingDataSpec"), + }, + }, + }, + Required: []string{"kind", "spec"}, + }, + }, + Dependencies: []string{ + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingDataSpec"}, + } +} + +func schema_pkg_apis_dashboard_v2alpha1_DashboardConditionalRenderingDataSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "value": { + SchemaProps: spec.SchemaProps{ + Default: false, + Type: []string{"boolean"}, + Format: "", + }, + }, + }, + Required: []string{"value"}, + }, + }, + } +} + +func schema_pkg_apis_dashboard_v2alpha1_DashboardConditionalRenderingGroupKind(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingGroupSpec"), + }, + }, + }, + Required: []string{"kind", "spec"}, + }, + }, + Dependencies: []string{ + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingGroupSpec"}, + } +} + +func schema_pkg_apis_dashboard_v2alpha1_DashboardConditionalRenderingGroupSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "condition": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "items": { + SchemaProps: spec.SchemaProps{ + Type: []string{"array"}, + Items: &spec.SchemaOrArray{ + Schema: &spec.Schema{ + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingVariableKindOrConditionalRenderingDataKindOrConditionalRenderingTimeIntervalKind"), + }, + }, + }, + }, + }, + }, + Required: []string{"condition", "items"}, + }, + }, + Dependencies: []string{ + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingVariableKindOrConditionalRenderingDataKindOrConditionalRenderingTimeIntervalKind"}, + } +} + +func schema_pkg_apis_dashboard_v2alpha1_DashboardConditionalRenderingTimeIntervalKind(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingTimeIntervalSpec"), + }, + }, + }, + Required: []string{"kind", "spec"}, + }, + }, + Dependencies: []string{ + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingTimeIntervalSpec"}, + } +} + +func schema_pkg_apis_dashboard_v2alpha1_DashboardConditionalRenderingTimeIntervalSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "value": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"value"}, + }, + }, + } +} + +func schema_pkg_apis_dashboard_v2alpha1_DashboardConditionalRenderingVariableKind(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "kind": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "spec": { + SchemaProps: spec.SchemaProps{ + Default: map[string]interface{}{}, + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingVariableSpec"), + }, + }, + }, + Required: []string{"kind", "spec"}, + }, + }, + Dependencies: []string{ + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingVariableSpec"}, + } +} + +func schema_pkg_apis_dashboard_v2alpha1_DashboardConditionalRenderingVariableKindOrConditionalRenderingDataKindOrConditionalRenderingTimeIntervalKind(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "ConditionalRenderingVariableKind": { + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingVariableKind"), + }, + }, + "ConditionalRenderingDataKind": { + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingDataKind"), + }, + }, + "ConditionalRenderingTimeIntervalKind": { + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingTimeIntervalKind"), + }, + }, + }, + }, + }, + Dependencies: []string{ + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingDataKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingTimeIntervalKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingVariableKind"}, + } +} + +func schema_pkg_apis_dashboard_v2alpha1_DashboardConditionalRenderingVariableSpec(ref common.ReferenceCallback) common.OpenAPIDefinition { + return common.OpenAPIDefinition{ + Schema: spec.Schema{ + SchemaProps: spec.SchemaProps{ + Type: []string{"object"}, + Properties: map[string]spec.Schema{ + "variable": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "operator": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + "value": { + SchemaProps: spec.SchemaProps{ + Default: "", + Type: []string{"string"}, + Format: "", + }, + }, + }, + Required: []string{"variable", "operator", "value"}, + }, + }, } } @@ -651,7 +909,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardConstantVariableKind(ref common "spec": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardConstantVariableSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConstantVariableSpec"), }, }, }, @@ -659,7 +917,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardConstantVariableKind(ref common }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardConstantVariableSpec"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConstantVariableSpec"}, } } @@ -687,7 +945,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardConstantVariableSpec(ref common "current": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"), }, }, "label": { @@ -721,7 +979,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardConstantVariableSpec(ref common }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"}, } } @@ -780,7 +1038,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardCustomVariableKind(ref common.R "spec": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardCustomVariableSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardCustomVariableSpec"), }, }, }, @@ -788,7 +1046,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardCustomVariableKind(ref common.R }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardCustomVariableSpec"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardCustomVariableSpec"}, } } @@ -816,7 +1074,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardCustomVariableSpec(ref common.R "current": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"), }, }, "options": { @@ -826,7 +1084,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardCustomVariableSpec(ref common.R Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"), }, }, }, @@ -883,7 +1141,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardCustomVariableSpec(ref common.R }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"}, } } @@ -1106,7 +1364,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardDataTransformerConfig(ref commo "filter": { SchemaProps: spec.SchemaProps{ Description: "Optional frame matcher. When missing it will be applied to all results", - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardMatcherConfig"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardMatcherConfig"), }, }, "topic": { @@ -1128,7 +1386,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardDataTransformerConfig(ref commo }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardMatcherConfig"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardMatcherConfig"}, } } @@ -1149,7 +1407,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardDatasourceVariableKind(ref comm "spec": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDatasourceVariableSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDatasourceVariableSpec"), }, }, }, @@ -1157,7 +1415,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardDatasourceVariableKind(ref comm }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDatasourceVariableSpec"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDatasourceVariableSpec"}, } } @@ -1199,7 +1457,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardDatasourceVariableSpec(ref comm "current": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"), }, }, "options": { @@ -1209,7 +1467,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardDatasourceVariableSpec(ref comm Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"), }, }, }, @@ -1266,7 +1524,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardDatasourceVariableSpec(ref comm }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"}, } } @@ -1443,7 +1701,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardFieldConfig(ref common.Referenc Items: &spec.SchemaOrArray{ Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardValueMapOrRangeMapOrRegexMapOrSpecialValueMap"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardValueMapOrRangeMapOrRegexMapOrSpecialValueMap"), }, }, }, @@ -1452,13 +1710,13 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardFieldConfig(ref common.Referenc "thresholds": { SchemaProps: spec.SchemaProps{ Description: "Map numeric values to states", - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardThresholdsConfig"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardThresholdsConfig"), }, }, "color": { SchemaProps: spec.SchemaProps{ Description: "Panel color configuration", - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardFieldColor"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardFieldColor"), }, }, "links": { @@ -1501,7 +1759,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardFieldConfig(ref common.Referenc }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardFieldColor", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardThresholdsConfig", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardValueMapOrRangeMapOrRegexMapOrSpecialValueMap"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardFieldColor", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardThresholdsConfig", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardValueMapOrRangeMapOrRegexMapOrSpecialValueMap"}, } } @@ -1516,7 +1774,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardFieldConfigSource(ref common.Re SchemaProps: spec.SchemaProps{ Description: "Defaults are the options applied to all fields.", Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardFieldConfig"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardFieldConfig"), }, }, "overrides": { @@ -1527,7 +1785,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardFieldConfigSource(ref common.Re Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardV2alpha1FieldConfigSourceOverrides"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardV2alpha1FieldConfigSourceOverrides"), }, }, }, @@ -1538,7 +1796,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardFieldConfigSource(ref common.Re }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardFieldConfig", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardV2alpha1FieldConfigSourceOverrides"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardFieldConfig", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardV2alpha1FieldConfigSourceOverrides"}, } } @@ -1558,7 +1816,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutItemKind(ref common.R "spec": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutItemSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutItemSpec"), }, }, }, @@ -1566,7 +1824,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutItemKind(ref common.R }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutItemSpec"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutItemSpec"}, } } @@ -1578,19 +1836,19 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutItemKindOrGridLayoutR Properties: map[string]spec.Schema{ "GridLayoutItemKind": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutItemKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutItemKind"), }, }, "GridLayoutRowKind": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutRowKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutRowKind"), }, }, }, }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutItemKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutRowKind"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutItemKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutRowKind"}, } } @@ -1632,12 +1890,12 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutItemSpec(ref common.R SchemaProps: spec.SchemaProps{ Description: "reference to a PanelKind from dashboard.spec.elements Expressed as JSON Schema reference", Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardElementReference"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardElementReference"), }, }, "repeat": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRepeatOptions"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRepeatOptions"), }, }, }, @@ -1645,7 +1903,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutItemSpec(ref common.R }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardElementReference", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRepeatOptions"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardElementReference", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRepeatOptions"}, } } @@ -1665,7 +1923,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutKind(ref common.Refer "spec": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutSpec"), }, }, }, @@ -1673,7 +1931,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutKind(ref common.Refer }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutSpec"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutSpec"}, } } @@ -1685,24 +1943,24 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutKindOrResponsiveGridL Properties: map[string]spec.Schema{ "GridLayoutKind": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKind"), }, }, "ResponsiveGridLayoutKind": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutKind"), }, }, "TabsLayoutKind": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutKind"), }, }, }, }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutKind"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutKind"}, } } @@ -1714,24 +1972,24 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutKindOrRowsLayoutKindO Properties: map[string]spec.Schema{ "GridLayoutKind": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKind"), }, }, "RowsLayoutKind": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutKind"), }, }, "ResponsiveGridLayoutKind": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutKind"), }, }, }, }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutKind"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutKind"}, } } @@ -1743,29 +2001,29 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutKindOrRowsLayoutKindO Properties: map[string]spec.Schema{ "GridLayoutKind": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKind"), }, }, "RowsLayoutKind": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutKind"), }, }, "ResponsiveGridLayoutKind": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutKind"), }, }, "TabsLayoutKind": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutKind"), }, }, }, }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutKind"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutKind"}, } } @@ -1785,7 +2043,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutRowKind(ref common.Re "spec": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutRowSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutRowSpec"), }, }, }, @@ -1793,7 +2051,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutRowKind(ref common.Re }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutRowSpec"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutRowSpec"}, } } @@ -1832,7 +2090,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutRowSpec(ref common.Re Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutItemKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutItemKind"), }, }, }, @@ -1840,7 +2098,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutRowSpec(ref common.Re }, "repeat": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRowRepeatOptions"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRowRepeatOptions"), }, }, }, @@ -1848,7 +2106,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutRowSpec(ref common.Re }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutItemKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRowRepeatOptions"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutItemKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRowRepeatOptions"}, } } @@ -1864,7 +2122,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutSpec(ref common.Refer Items: &spec.SchemaOrArray{ Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutItemKindOrGridLayoutRowKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutItemKindOrGridLayoutRowKind"), }, }, }, @@ -1875,7 +2133,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardGridLayoutSpec(ref common.Refer }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutItemKindOrGridLayoutRowKind"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutItemKindOrGridLayoutRowKind"}, } } @@ -1896,7 +2154,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardGroupByVariableKind(ref common. "spec": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGroupByVariableSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGroupByVariableSpec"), }, }, }, @@ -1904,7 +2162,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardGroupByVariableKind(ref common. }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGroupByVariableSpec"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGroupByVariableSpec"}, } } @@ -1924,13 +2182,13 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardGroupByVariableSpec(ref common. }, "datasource": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDataSourceRef"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDataSourceRef"), }, }, "current": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"), }, }, "options": { @@ -1940,7 +2198,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardGroupByVariableSpec(ref common. Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"), }, }, }, @@ -1984,7 +2242,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardGroupByVariableSpec(ref common. }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDataSourceRef", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDataSourceRef", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"}, } } @@ -2005,7 +2263,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardIntervalVariableKind(ref common "spec": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardIntervalVariableSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardIntervalVariableSpec"), }, }, }, @@ -2013,7 +2271,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardIntervalVariableKind(ref common }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardIntervalVariableSpec"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardIntervalVariableSpec"}, } } @@ -2041,7 +2299,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardIntervalVariableSpec(ref common "current": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"), }, }, "options": { @@ -2051,7 +2309,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardIntervalVariableSpec(ref common Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"), }, }, }, @@ -2116,7 +2374,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardIntervalVariableSpec(ref common }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"}, } } @@ -2147,7 +2405,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardLibraryPanelKind(ref common.Ref "spec": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardLibraryPanelKindSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardLibraryPanelKindSpec"), }, }, }, @@ -2155,7 +2413,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardLibraryPanelKind(ref common.Ref }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardLibraryPanelKindSpec"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardLibraryPanelKindSpec"}, } } @@ -2184,7 +2442,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardLibraryPanelKindSpec(ref common "libraryPanel": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardLibraryPanelRef"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardLibraryPanelRef"), }, }, }, @@ -2192,7 +2450,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardLibraryPanelKindSpec(ref common }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardLibraryPanelRef"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardLibraryPanelRef"}, } } @@ -2259,7 +2517,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardList(ref common.ReferenceCallba Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.Dashboard"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.Dashboard"), }, }, }, @@ -2270,7 +2528,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardList(ref common.ReferenceCallba }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.Dashboard", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.Dashboard", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, } } @@ -2415,7 +2673,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardMetricFindValue(ref common.Refe }, "value": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardStringOrFloat64"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardStringOrFloat64"), }, }, "group": { @@ -2435,7 +2693,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardMetricFindValue(ref common.Refe }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardStringOrFloat64"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardStringOrFloat64"}, } } @@ -2455,7 +2713,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardPanelKind(ref common.ReferenceC "spec": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardPanelSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardPanelSpec"), }, }, }, @@ -2463,7 +2721,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardPanelKind(ref common.ReferenceC }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardPanelSpec"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardPanelSpec"}, } } @@ -2475,19 +2733,19 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardPanelKindOrLibraryPanelKind(ref Properties: map[string]spec.Schema{ "PanelKind": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardPanelKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardPanelKind"), }, }, "LibraryPanelKind": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardLibraryPanelKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardLibraryPanelKind"), }, }, }, }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardLibraryPanelKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardPanelKind"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardLibraryPanelKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardPanelKind"}, } } @@ -2507,7 +2765,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardPanelQueryKind(ref common.Refer "spec": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardPanelQuerySpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardPanelQuerySpec"), }, }, }, @@ -2515,7 +2773,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardPanelQueryKind(ref common.Refer }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardPanelQuerySpec"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardPanelQuerySpec"}, } } @@ -2528,12 +2786,12 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardPanelQuerySpec(ref common.Refer "query": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDataQueryKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDataQueryKind"), }, }, "datasource": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDataSourceRef"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDataSourceRef"), }, }, "refId": { @@ -2555,7 +2813,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardPanelQuerySpec(ref common.Refer }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDataQueryKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDataSourceRef"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDataQueryKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDataSourceRef"}, } } @@ -2593,7 +2851,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardPanelSpec(ref common.ReferenceC Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDataLink"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDataLink"), }, }, }, @@ -2602,13 +2860,13 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardPanelSpec(ref common.ReferenceC "data": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardQueryGroupKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardQueryGroupKind"), }, }, "vizConfig": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVizConfigKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVizConfigKind"), }, }, "transparent": { @@ -2622,7 +2880,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardPanelSpec(ref common.ReferenceC }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDataLink", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardQueryGroupKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVizConfigKind"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDataLink", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardQueryGroupKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVizConfigKind"}, } } @@ -2642,7 +2900,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardQueryGroupKind(ref common.Refer "spec": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardQueryGroupSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardQueryGroupSpec"), }, }, }, @@ -2650,7 +2908,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardQueryGroupKind(ref common.Refer }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardQueryGroupSpec"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardQueryGroupSpec"}, } } @@ -2667,7 +2925,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardQueryGroupSpec(ref common.Refer Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardPanelQueryKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardPanelQueryKind"), }, }, }, @@ -2680,7 +2938,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardQueryGroupSpec(ref common.Refer Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTransformationKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTransformationKind"), }, }, }, @@ -2689,7 +2947,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardQueryGroupSpec(ref common.Refer "queryOptions": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardQueryOptionsSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardQueryOptionsSpec"), }, }, }, @@ -2697,7 +2955,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardQueryGroupSpec(ref common.Refer }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardPanelQueryKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardQueryOptionsSpec", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTransformationKind"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardPanelQueryKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardQueryOptionsSpec", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTransformationKind"}, } } @@ -2772,7 +3030,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardQueryVariableKind(ref common.Re "spec": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardQueryVariableSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardQueryVariableSpec"), }, }, }, @@ -2780,7 +3038,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardQueryVariableKind(ref common.Re }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardQueryVariableSpec"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardQueryVariableSpec"}, } } @@ -2792,49 +3050,49 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardQueryVariableKindOrTextVariable Properties: map[string]spec.Schema{ "QueryVariableKind": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardQueryVariableKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardQueryVariableKind"), }, }, "TextVariableKind": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTextVariableKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTextVariableKind"), }, }, "ConstantVariableKind": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardConstantVariableKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConstantVariableKind"), }, }, "DatasourceVariableKind": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDatasourceVariableKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDatasourceVariableKind"), }, }, "IntervalVariableKind": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardIntervalVariableKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardIntervalVariableKind"), }, }, "CustomVariableKind": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardCustomVariableKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardCustomVariableKind"), }, }, "GroupByVariableKind": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGroupByVariableKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGroupByVariableKind"), }, }, "AdhocVariableKind": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardAdhocVariableKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardAdhocVariableKind"), }, }, }, }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardAdhocVariableKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardConstantVariableKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardCustomVariableKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDatasourceVariableKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGroupByVariableKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardIntervalVariableKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardQueryVariableKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTextVariableKind"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardAdhocVariableKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConstantVariableKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardCustomVariableKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDatasourceVariableKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGroupByVariableKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardIntervalVariableKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardQueryVariableKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTextVariableKind"}, } } @@ -2855,7 +3113,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardQueryVariableSpec(ref common.Re "current": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"), }, }, "label": { @@ -2893,13 +3151,13 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardQueryVariableSpec(ref common.Re }, "datasource": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDataSourceRef"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDataSourceRef"), }, }, "query": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDataQueryKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDataQueryKind"), }, }, "regex": { @@ -2929,7 +3187,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardQueryVariableSpec(ref common.Re Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"), }, }, }, @@ -2966,7 +3224,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardQueryVariableSpec(ref common.Re }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDataQueryKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDataSourceRef", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDataQueryKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDataSourceRef", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"}, } } @@ -2989,7 +3247,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardRangeMap(ref common.ReferenceCa SchemaProps: spec.SchemaProps{ Description: "Range to match against and the result to apply when the value is within the range", Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardV2alpha1RangeMapOptions"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardV2alpha1RangeMapOptions"), }, }, }, @@ -2997,7 +3255,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardRangeMap(ref common.ReferenceCa }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardV2alpha1RangeMapOptions"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardV2alpha1RangeMapOptions"}, } } @@ -3020,7 +3278,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardRegexMap(ref common.ReferenceCa SchemaProps: spec.SchemaProps{ Description: "Regular expression to match against and the result to apply when the value matches the regex", Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardV2alpha1RegexMapOptions"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardV2alpha1RegexMapOptions"), }, }, }, @@ -3028,7 +3286,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardRegexMap(ref common.ReferenceCa }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardV2alpha1RegexMapOptions"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardV2alpha1RegexMapOptions"}, } } @@ -3087,7 +3345,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardResponsiveGridLayoutItemKind(re "spec": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutItemSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutItemSpec"), }, }, }, @@ -3095,7 +3353,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardResponsiveGridLayoutItemKind(re }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutItemSpec"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutItemSpec"}, } } @@ -3108,12 +3366,17 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardResponsiveGridLayoutItemSpec(re "element": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardElementReference"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardElementReference"), }, }, "repeat": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridRepeatOptions"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridRepeatOptions"), + }, + }, + "conditionalRendering": { + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingGroupKind"), }, }, }, @@ -3121,7 +3384,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardResponsiveGridLayoutItemSpec(re }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardElementReference", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridRepeatOptions"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingGroupKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardElementReference", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridRepeatOptions"}, } } @@ -3141,7 +3404,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardResponsiveGridLayoutKind(ref co "spec": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutSpec"), }, }, }, @@ -3149,7 +3412,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardResponsiveGridLayoutKind(ref co }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutSpec"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutSpec"}, } } @@ -3180,7 +3443,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardResponsiveGridLayoutSpec(ref co Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutItemKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutItemKind"), }, }, }, @@ -3191,7 +3454,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardResponsiveGridLayoutSpec(ref co }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutItemKind"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardResponsiveGridLayoutItemKind"}, } } @@ -3265,7 +3528,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardRowsLayoutKind(ref common.Refer "spec": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutSpec"), }, }, }, @@ -3273,7 +3536,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardRowsLayoutKind(ref common.Refer }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutSpec"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutSpec"}, } } @@ -3293,7 +3556,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardRowsLayoutRowKind(ref common.Re "spec": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutRowSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutRowSpec"), }, }, }, @@ -3301,7 +3564,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardRowsLayoutRowKind(ref common.Re }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutRowSpec"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutRowSpec"}, } } @@ -3324,14 +3587,19 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardRowsLayoutRowSpec(ref common.Re Format: "", }, }, + "conditionalRendering": { + SchemaProps: spec.SchemaProps{ + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingGroupKind"), + }, + }, "repeat": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRowRepeatOptions"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRowRepeatOptions"), }, }, "layout": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind"), }, }, }, @@ -3339,7 +3607,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardRowsLayoutRowSpec(ref common.Re }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRowRepeatOptions"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConditionalRenderingGroupKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRowRepeatOptions"}, } } @@ -3356,7 +3624,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardRowsLayoutSpec(ref common.Refer Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutRowKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutRowKind"), }, }, }, @@ -3367,7 +3635,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardRowsLayoutSpec(ref common.Refer }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutRowKind"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRowsLayoutRowKind"}, } } @@ -3385,7 +3653,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardSpec(ref common.ReferenceCallba Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardAnnotationQueryKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardAnnotationQueryKind"), }, }, }, @@ -3420,7 +3688,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardSpec(ref common.ReferenceCallba Allows: true, Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardPanelKindOrLibraryPanelKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardPanelKindOrLibraryPanelKind"), }, }, }, @@ -3428,7 +3696,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardSpec(ref common.ReferenceCallba }, "layout": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKindOrRowsLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKindOrRowsLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind"), }, }, "links": { @@ -3439,7 +3707,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardSpec(ref common.ReferenceCallba Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDashboardLink"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDashboardLink"), }, }, }, @@ -3485,7 +3753,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardSpec(ref common.ReferenceCallba "timeSettings": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTimeSettingsSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTimeSettingsSpec"), }, }, "title": { @@ -3503,7 +3771,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardSpec(ref common.ReferenceCallba Items: &spec.SchemaOrArray{ Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardQueryVariableKindOrTextVariableKindOrConstantVariableKindOrDatasourceVariableKindOrIntervalVariableKindOrCustomVariableKindOrGroupByVariableKindOrAdhocVariableKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardQueryVariableKindOrTextVariableKindOrConstantVariableKindOrDatasourceVariableKindOrIntervalVariableKindOrCustomVariableKindOrGroupByVariableKindOrAdhocVariableKind"), }, }, }, @@ -3514,7 +3782,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardSpec(ref common.ReferenceCallba }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardAnnotationQueryKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDashboardLink", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKindOrRowsLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardPanelKindOrLibraryPanelKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardQueryVariableKindOrTextVariableKindOrConstantVariableKindOrDatasourceVariableKindOrIntervalVariableKindOrCustomVariableKindOrGroupByVariableKindOrAdhocVariableKind", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTimeSettingsSpec"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardAnnotationQueryKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDashboardLink", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKindOrRowsLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardPanelKindOrLibraryPanelKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardQueryVariableKindOrTextVariableKindOrConstantVariableKindOrDatasourceVariableKindOrIntervalVariableKindOrCustomVariableKindOrGroupByVariableKindOrAdhocVariableKind", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTimeSettingsSpec"}, } } @@ -3536,7 +3804,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardSpecialValueMap(ref common.Refe "options": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardV2alpha1SpecialValueMapOptions"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardV2alpha1SpecialValueMapOptions"), }, }, }, @@ -3544,7 +3812,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardSpecialValueMap(ref common.Refe }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardV2alpha1SpecialValueMapOptions"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardV2alpha1SpecialValueMapOptions"}, } } @@ -3557,14 +3825,14 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardStatus(ref common.ReferenceCall "conversion": { SchemaProps: spec.SchemaProps{ Description: "Optional conversion status.", - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardConversionStatus"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConversionStatus"), }, }, }, }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardConversionStatus"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardConversionStatus"}, } } @@ -3640,7 +3908,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardTabsLayoutKind(ref common.Refer "spec": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutSpec"), }, }, }, @@ -3648,7 +3916,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardTabsLayoutKind(ref common.Refer }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutSpec"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutSpec"}, } } @@ -3665,7 +3933,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardTabsLayoutSpec(ref common.Refer Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutTabKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutTabKind"), }, }, }, @@ -3676,7 +3944,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardTabsLayoutSpec(ref common.Refer }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutTabKind"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutTabKind"}, } } @@ -3696,7 +3964,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardTabsLayoutTabKind(ref common.Re "spec": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutTabSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutTabSpec"), }, }, }, @@ -3704,7 +3972,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardTabsLayoutTabKind(ref common.Re }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutTabSpec"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTabsLayoutTabSpec"}, } } @@ -3722,7 +3990,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardTabsLayoutTabSpec(ref common.Re }, "layout": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKindOrRowsLayoutKindOrResponsiveGridLayoutKind"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKindOrRowsLayoutKindOrResponsiveGridLayoutKind"), }, }, }, @@ -3730,7 +3998,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardTabsLayoutTabSpec(ref common.Re }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKindOrRowsLayoutKindOrResponsiveGridLayoutKind"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardGridLayoutKindOrRowsLayoutKindOrResponsiveGridLayoutKind"}, } } @@ -3751,7 +4019,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardTextVariableKind(ref common.Ref "spec": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTextVariableSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTextVariableSpec"), }, }, }, @@ -3759,7 +4027,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardTextVariableKind(ref common.Ref }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTextVariableSpec"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTextVariableSpec"}, } } @@ -3780,7 +4048,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardTextVariableSpec(ref common.Ref "current": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"), }, }, "query": { @@ -3821,7 +4089,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardTextVariableSpec(ref common.Ref }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVariableOption"}, } } @@ -3872,7 +4140,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardThresholdsConfig(ref common.Ref Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardThreshold"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardThreshold"), }, }, }, @@ -3883,7 +4151,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardThresholdsConfig(ref common.Ref }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardThreshold"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardThreshold"}, } } @@ -3982,7 +4250,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardTimeSettingsSpec(ref common.Ref Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTimeRangeOption"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTimeRangeOption"), }, }, }, @@ -4023,7 +4291,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardTimeSettingsSpec(ref common.Ref }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardTimeRangeOption"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardTimeRangeOption"}, } } @@ -4044,7 +4312,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardTransformationKind(ref common.R "spec": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDataTransformerConfig"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDataTransformerConfig"), }, }, }, @@ -4052,7 +4320,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardTransformationKind(ref common.R }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDataTransformerConfig"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDataTransformerConfig"}, } } @@ -4065,7 +4333,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardV2alpha1FieldConfigSourceOverri "matcher": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardMatcherConfig"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardMatcherConfig"), }, }, "properties": { @@ -4075,7 +4343,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardV2alpha1FieldConfigSourceOverri Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDynamicConfigValue"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDynamicConfigValue"), }, }, }, @@ -4086,7 +4354,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardV2alpha1FieldConfigSourceOverri }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardDynamicConfigValue", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardMatcherConfig"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardDynamicConfigValue", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardMatcherConfig"}, } } @@ -4114,7 +4382,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardV2alpha1RangeMapOptions(ref com SchemaProps: spec.SchemaProps{ Description: "Config to apply when the value is within the range", Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardValueMappingResult"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardValueMappingResult"), }, }, }, @@ -4122,7 +4390,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardV2alpha1RangeMapOptions(ref com }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardValueMappingResult"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardValueMappingResult"}, } } @@ -4144,7 +4412,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardV2alpha1RegexMapOptions(ref com SchemaProps: spec.SchemaProps{ Description: "Config to apply when the value matches the regex", Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardValueMappingResult"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardValueMappingResult"), }, }, }, @@ -4152,7 +4420,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardV2alpha1RegexMapOptions(ref com }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardValueMappingResult"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardValueMappingResult"}, } } @@ -4174,7 +4442,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardV2alpha1SpecialValueMapOptions( SchemaProps: spec.SchemaProps{ Description: "Config to apply when the value matches the special value", Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardValueMappingResult"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardValueMappingResult"), }, }, }, @@ -4182,7 +4450,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardV2alpha1SpecialValueMapOptions( }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardValueMappingResult"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardValueMappingResult"}, } } @@ -4210,7 +4478,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardValueMap(ref common.ReferenceCa Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardValueMappingResult"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardValueMappingResult"), }, }, }, @@ -4221,7 +4489,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardValueMap(ref common.ReferenceCa }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardValueMappingResult"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardValueMappingResult"}, } } @@ -4233,29 +4501,29 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardValueMapOrRangeMapOrRegexMapOrS Properties: map[string]spec.Schema{ "ValueMap": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardValueMap"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardValueMap"), }, }, "RangeMap": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRangeMap"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRangeMap"), }, }, "RegexMap": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRegexMap"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRegexMap"), }, }, "SpecialValueMap": { SchemaProps: spec.SchemaProps{ - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardSpecialValueMap"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardSpecialValueMap"), }, }, }, }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRangeMap", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardRegexMap", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardSpecialValueMap", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardValueMap"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRangeMap", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardRegexMap", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardSpecialValueMap", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardValueMap"}, } } @@ -4317,13 +4585,13 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardVariableOption(ref common.Refer "text": { SchemaProps: spec.SchemaProps{ Description: "Text to be displayed for the option", - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardStringOrArrayOfString"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardStringOrArrayOfString"), }, }, "value": { SchemaProps: spec.SchemaProps{ Description: "Value of the option", - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardStringOrArrayOfString"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardStringOrArrayOfString"), }, }, }, @@ -4331,7 +4599,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardVariableOption(ref common.Refer }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardStringOrArrayOfString"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardStringOrArrayOfString"}, } } @@ -4418,7 +4686,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardVersionList(ref common.Referenc Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVersionInfo"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVersionInfo"), }, }, }, @@ -4428,7 +4696,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardVersionList(ref common.Referenc }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVersionInfo", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVersionInfo", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, } } @@ -4449,7 +4717,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardVizConfigKind(ref common.Refere "spec": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVizConfigSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVizConfigSpec"), }, }, }, @@ -4457,7 +4725,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardVizConfigKind(ref common.Refere }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardVizConfigSpec"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardVizConfigSpec"}, } } @@ -4492,7 +4760,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardVizConfigSpec(ref common.Refere "fieldConfig": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardFieldConfigSource"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardFieldConfigSource"), }, }, }, @@ -4500,7 +4768,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardVizConfigSpec(ref common.Refere }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardFieldConfigSource"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardFieldConfigSource"}, } } @@ -4535,19 +4803,19 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardWithAccessInfo(ref common.Refer SchemaProps: spec.SchemaProps{ Description: "Spec is the spec of the Dashboard", Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardSpec"), }, }, "status": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardStatus"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardStatus"), }, }, "access": { SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardAccess"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardAccess"), }, }, }, @@ -4555,7 +4823,7 @@ func schema_pkg_apis_dashboard_v2alpha1_DashboardWithAccessInfo(ref common.Refer }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardAccess", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardSpec", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.DashboardStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardAccess", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardSpec", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.DashboardStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, } } @@ -4590,13 +4858,13 @@ func schema_pkg_apis_dashboard_v2alpha1_LibraryPanel(ref common.ReferenceCallbac SchemaProps: spec.SchemaProps{ Description: "Panel properties", Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.LibraryPanelSpec"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.LibraryPanelSpec"), }, }, "status": { SchemaProps: spec.SchemaProps{ Description: "Status will show errors", - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.LibraryPanelStatus"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.LibraryPanelStatus"), }, }, }, @@ -4604,7 +4872,7 @@ func schema_pkg_apis_dashboard_v2alpha1_LibraryPanel(ref common.ReferenceCallbac }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.LibraryPanelSpec", "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.LibraryPanelStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.LibraryPanelSpec", "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.LibraryPanelStatus", "k8s.io/apimachinery/pkg/apis/meta/v1.ObjectMeta"}, } } @@ -4641,7 +4909,7 @@ func schema_pkg_apis_dashboard_v2alpha1_LibraryPanelList(ref common.ReferenceCal Schema: &spec.Schema{ SchemaProps: spec.SchemaProps{ Default: map[string]interface{}{}, - Ref: ref("github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.LibraryPanel"), + Ref: ref("github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.LibraryPanel"), }, }, }, @@ -4651,7 +4919,7 @@ func schema_pkg_apis_dashboard_v2alpha1_LibraryPanelList(ref common.ReferenceCal }, }, Dependencies: []string{ - "github.com/grafana/grafana/pkg/apis/dashboard/v2alpha1.LibraryPanel", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1.LibraryPanel", "k8s.io/apimachinery/pkg/apis/meta/v1.ListMeta"}, } } diff --git a/apps/dashboard/pkg/apis/dashboard/v2alpha1/zz_generated.openapi_violation_exceptions.list b/apps/dashboard/pkg/apis/dashboard/v2alpha1/zz_generated.openapi_violation_exceptions.list new file mode 100644 index 00000000000..31084da6e9f --- /dev/null +++ b/apps/dashboard/pkg/apis/dashboard/v2alpha1/zz_generated.openapi_violation_exceptions.list @@ -0,0 +1,69 @@ +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardAdHocFilterWithLabels,ValueLabels +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardAdHocFilterWithLabels,Values +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardAdhocVariableSpec,BaseFilters +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardAdhocVariableSpec,DefaultKeys +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardAdhocVariableSpec,Filters +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardConditionalRenderingGroupSpec,Items +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardCustomVariableSpec,Options +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardDashboardLink,Tags +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardDatasourceVariableSpec,Options +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardFieldConfig,Links +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardFieldConfig,Mappings +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardFieldConfigSource,Overrides +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardGridLayoutRowSpec,Elements +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardGridLayoutSpec,Items +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardGroupByVariableSpec,Options +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardIntervalVariableSpec,Options +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardMetadata,Finalizers +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardPanelSpec,Links +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardQueryGroupSpec,Queries +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardQueryGroupSpec,Transformations +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardQueryVariableSpec,Options +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardResponsiveGridLayoutSpec,Items +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardRowsLayoutSpec,Rows +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardSpec,Annotations +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardSpec,Links +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardSpec,Tags +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardSpec,Variables +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardStringOrArrayOfString,ArrayOfString +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardTabsLayoutSpec,Tabs +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardThresholdsConfig,Steps +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardTimeSettingsSpec,AutoRefreshIntervals +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardTimeSettingsSpec,QuickRanges +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardV2alpha1FieldConfigSourceOverrides,Properties +API rule violation: list_type_missing,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,LibraryPanelStatus,Warnings +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardConditionalRenderingVariableKindOrConditionalRenderingDataKindOrConditionalRenderingTimeIntervalKind,ConditionalRenderingDataKind +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardConditionalRenderingVariableKindOrConditionalRenderingDataKindOrConditionalRenderingTimeIntervalKind,ConditionalRenderingTimeIntervalKind +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardConditionalRenderingVariableKindOrConditionalRenderingDataKindOrConditionalRenderingTimeIntervalKind,ConditionalRenderingVariableKind +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardGridLayoutItemKindOrGridLayoutRowKind,GridLayoutItemKind +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardGridLayoutItemKindOrGridLayoutRowKind,GridLayoutRowKind +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardGridLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind,GridLayoutKind +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardGridLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind,ResponsiveGridLayoutKind +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardGridLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind,TabsLayoutKind +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardGridLayoutKindOrRowsLayoutKindOrResponsiveGridLayoutKind,GridLayoutKind +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardGridLayoutKindOrRowsLayoutKindOrResponsiveGridLayoutKind,ResponsiveGridLayoutKind +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardGridLayoutKindOrRowsLayoutKindOrResponsiveGridLayoutKind,RowsLayoutKind +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardGridLayoutKindOrRowsLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind,GridLayoutKind +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardGridLayoutKindOrRowsLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind,ResponsiveGridLayoutKind +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardGridLayoutKindOrRowsLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind,RowsLayoutKind +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardGridLayoutKindOrRowsLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind,TabsLayoutKind +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardIntervalVariableSpec,AutoCount +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardIntervalVariableSpec,AutoMin +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardPanelKindOrLibraryPanelKind,LibraryPanelKind +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardPanelKindOrLibraryPanelKind,PanelKind +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardQueryVariableKindOrTextVariableKindOrConstantVariableKindOrDatasourceVariableKindOrIntervalVariableKindOrCustomVariableKindOrGroupByVariableKindOrAdhocVariableKind,AdhocVariableKind +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardQueryVariableKindOrTextVariableKindOrConstantVariableKindOrDatasourceVariableKindOrIntervalVariableKindOrCustomVariableKindOrGroupByVariableKindOrAdhocVariableKind,ConstantVariableKind +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardQueryVariableKindOrTextVariableKindOrConstantVariableKindOrDatasourceVariableKindOrIntervalVariableKindOrCustomVariableKindOrGroupByVariableKindOrAdhocVariableKind,CustomVariableKind +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardQueryVariableKindOrTextVariableKindOrConstantVariableKindOrDatasourceVariableKindOrIntervalVariableKindOrCustomVariableKindOrGroupByVariableKindOrAdhocVariableKind,DatasourceVariableKind +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardQueryVariableKindOrTextVariableKindOrConstantVariableKindOrDatasourceVariableKindOrIntervalVariableKindOrCustomVariableKindOrGroupByVariableKindOrAdhocVariableKind,GroupByVariableKind +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardQueryVariableKindOrTextVariableKindOrConstantVariableKindOrDatasourceVariableKindOrIntervalVariableKindOrCustomVariableKindOrGroupByVariableKindOrAdhocVariableKind,IntervalVariableKind +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardQueryVariableKindOrTextVariableKindOrConstantVariableKindOrDatasourceVariableKindOrIntervalVariableKindOrCustomVariableKindOrGroupByVariableKindOrAdhocVariableKind,QueryVariableKind +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardQueryVariableKindOrTextVariableKindOrConstantVariableKindOrDatasourceVariableKindOrIntervalVariableKindOrCustomVariableKindOrGroupByVariableKindOrAdhocVariableKind,TextVariableKind +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardStringOrArrayOfString,ArrayOfString +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardStringOrArrayOfString,String +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardStringOrFloat64,Float64 +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardStringOrFloat64,String +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardValueMapOrRangeMapOrRegexMapOrSpecialValueMap,RangeMap +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardValueMapOrRangeMapOrRegexMapOrSpecialValueMap,RegexMap +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardValueMapOrRangeMapOrRegexMapOrSpecialValueMap,SpecialValueMap +API rule violation: names_match,github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1,DashboardValueMapOrRangeMapOrRegexMapOrSpecialValueMap,ValueMap diff --git a/pkg/apis/dashboard_manifest.go b/apps/dashboard/pkg/apis/dashboard_manifest.go similarity index 100% rename from pkg/apis/dashboard_manifest.go rename to apps/dashboard/pkg/apis/dashboard_manifest.go diff --git a/apps/dashboard/pkg/migration/conversion/conversion.go b/apps/dashboard/pkg/migration/conversion/conversion.go new file mode 100644 index 00000000000..7058230eba2 --- /dev/null +++ b/apps/dashboard/pkg/migration/conversion/conversion.go @@ -0,0 +1,173 @@ +package conversion + +import ( + "k8s.io/apimachinery/pkg/conversion" + "k8s.io/apimachinery/pkg/runtime" + + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1" + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1" + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1" + "github.com/grafana/grafana/apps/dashboard/pkg/migration" + "github.com/grafana/grafana/apps/dashboard/pkg/migration/schemaversion" +) + +func RegisterConversions(s *runtime.Scheme) error { + if err := s.AddConversionFunc((*v0alpha1.Dashboard)(nil), (*v1alpha1.Dashboard)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_V0_to_V1(a.(*v0alpha1.Dashboard), b.(*v1alpha1.Dashboard), scope) + }); err != nil { + return err + } + if err := s.AddConversionFunc((*v0alpha1.Dashboard)(nil), (*v2alpha1.Dashboard)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_V0_to_V2(a.(*v0alpha1.Dashboard), b.(*v2alpha1.Dashboard), scope) + }); err != nil { + return err + } + if err := s.AddConversionFunc((*v1alpha1.Dashboard)(nil), (*v0alpha1.Dashboard)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_V1_to_V0(a.(*v1alpha1.Dashboard), b.(*v0alpha1.Dashboard), scope) + }); err != nil { + return err + } + if err := s.AddConversionFunc((*v1alpha1.Dashboard)(nil), (*v2alpha1.Dashboard)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_V1_to_V2(a.(*v1alpha1.Dashboard), b.(*v2alpha1.Dashboard), scope) + }); err != nil { + return err + } + if err := s.AddConversionFunc((*v2alpha1.Dashboard)(nil), (*v0alpha1.Dashboard)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_V2_to_V0(a.(*v2alpha1.Dashboard), b.(*v0alpha1.Dashboard), scope) + }); err != nil { + return err + } + if err := s.AddConversionFunc((*v2alpha1.Dashboard)(nil), (*v1alpha1.Dashboard)(nil), func(a, b interface{}, scope conversion.Scope) error { + return Convert_V2_to_V1(a.(*v2alpha1.Dashboard), b.(*v1alpha1.Dashboard), scope) + }); err != nil { + return err + } + return nil +} + +func Convert_V0_to_V1(in *v0alpha1.Dashboard, out *v1alpha1.Dashboard, scope conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + + out.Spec.Object = in.Spec.Object + + out.Status = v1alpha1.DashboardStatus{ + Conversion: &v1alpha1.DashboardConversionStatus{ + StoredVersion: v0alpha1.VERSION, + }, + } + + if err := migration.Migrate(out.Spec.Object, schemaversion.LATEST_VERSION); err != nil { + out.Status.Conversion.Failed = true + out.Status.Conversion.Error = err.Error() + } + + return nil +} + +func Convert_V0_to_V2(in *v0alpha1.Dashboard, out *v2alpha1.Dashboard, scope conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + + // TODO (@radiohead): implement V0 to V2 conversion + // This is the bare minimum conversion that is needed to make the dashboard servable. + + if v, ok := in.Spec.Object["title"]; ok { + if title, ok := v.(string); ok { + out.Spec.Title = title + } + } + + // We need to make sure the layout is set to some value, otherwise the JSON marshaling will fail. + out.Spec.Layout = v2alpha1.DashboardGridLayoutKindOrRowsLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind{ + GridLayoutKind: &v2alpha1.DashboardGridLayoutKind{ + Kind: "GridLayout", + Spec: v2alpha1.DashboardGridLayoutSpec{}, + }, + } + + out.Status = v2alpha1.DashboardStatus{ + Conversion: &v2alpha1.DashboardConversionStatus{ + StoredVersion: v0alpha1.VERSION, + Failed: true, + Error: "backend conversion not yet implemented", + }, + } + + return nil +} + +func Convert_V1_to_V0(in *v1alpha1.Dashboard, out *v0alpha1.Dashboard, scope conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + + out.Spec.Object = in.Spec.Object + + out.Status = v0alpha1.DashboardStatus{ + Conversion: &v0alpha1.DashboardConversionStatus{ + StoredVersion: v1alpha1.VERSION, + }, + } + + return nil +} + +func Convert_V1_to_V2(in *v1alpha1.Dashboard, out *v2alpha1.Dashboard, scope conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + + // TODO (@radiohead): implement V1 to V2 conversion + // This is the bare minimum conversion that is needed to make the dashboard servable. + + if v, ok := in.Spec.Object["title"]; ok { + if title, ok := v.(string); ok { + out.Spec.Title = title + } + } + + // We need to make sure the layout is set to some value, otherwise the JSON marshaling will fail. + out.Spec.Layout = v2alpha1.DashboardGridLayoutKindOrRowsLayoutKindOrResponsiveGridLayoutKindOrTabsLayoutKind{ + GridLayoutKind: &v2alpha1.DashboardGridLayoutKind{ + Kind: "GridLayout", + Spec: v2alpha1.DashboardGridLayoutSpec{}, + }, + } + + out.Status = v2alpha1.DashboardStatus{ + Conversion: &v2alpha1.DashboardConversionStatus{ + StoredVersion: v1alpha1.VERSION, + Failed: true, + Error: "backend conversion not yet implemented", + }, + } + + return nil +} + +func Convert_V2_to_V0(in *v2alpha1.Dashboard, out *v0alpha1.Dashboard, scope conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + + // TODO: implement V2 to V0 conversion + + out.Status = v0alpha1.DashboardStatus{ + Conversion: &v0alpha1.DashboardConversionStatus{ + StoredVersion: v2alpha1.VERSION, + Failed: true, + Error: "backend conversion not yet implemented", + }, + } + + return nil +} + +func Convert_V2_to_V1(in *v2alpha1.Dashboard, out *v1alpha1.Dashboard, scope conversion.Scope) error { + out.ObjectMeta = in.ObjectMeta + + // TODO: implement V2 to V1 conversion + + out.Status = v1alpha1.DashboardStatus{ + Conversion: &v1alpha1.DashboardConversionStatus{ + StoredVersion: v2alpha1.VERSION, + Failed: true, + Error: "backend conversion not yet implemented", + }, + } + + return nil +} diff --git a/apps/dashboard/pkg/migration/conversion/conversion_test.go b/apps/dashboard/pkg/migration/conversion/conversion_test.go new file mode 100644 index 00000000000..23cbd9fc2ba --- /dev/null +++ b/apps/dashboard/pkg/migration/conversion/conversion_test.go @@ -0,0 +1,47 @@ +package conversion + +import ( + "fmt" + "strings" + "testing" + + "github.com/stretchr/testify/require" + v1 "k8s.io/apimachinery/pkg/apis/meta/v1" + "k8s.io/apimachinery/pkg/runtime" + + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v0alpha1" + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v1alpha1" + "github.com/grafana/grafana/apps/dashboard/pkg/apis/dashboard/v2alpha1" + common "github.com/grafana/grafana/pkg/apimachinery/apis/common/v0alpha1" + "github.com/grafana/grafana/pkg/apimachinery/utils" +) + +func TestConversionMatrixExist(t *testing.T) { + versions := []v1.Object{ + &v0alpha1.Dashboard{Spec: common.Unstructured{Object: map[string]any{"title": "dashboardV0"}}}, + &v1alpha1.Dashboard{Spec: common.Unstructured{Object: map[string]any{"title": "dashboardV1"}}}, + &v2alpha1.Dashboard{Spec: v2alpha1.DashboardSpec{Title: "dashboardV2"}}, + } + + scheme := runtime.NewScheme() + err := RegisterConversions(scheme) + require.NoError(t, err) + + for idx, in := range versions { + kind := fmt.Sprintf("%T", in)[1:] + t.Run(kind, func(t *testing.T) { + for i, out := range versions { + if i == idx { + continue // skip the same version + } + err = scheme.Convert(in, out, nil) + require.NoError(t, err) + } + + // Make sure we get the right title for each value + meta, err := utils.MetaAccessor(in) + require.NoError(t, err) + require.True(t, strings.HasPrefix(meta.FindTitle(""), "dashboard")) + }) + } +} diff --git a/pkg/apis/dashboard/migration/migrate.go b/apps/dashboard/pkg/migration/migrate.go similarity index 69% rename from pkg/apis/dashboard/migration/migrate.go rename to apps/dashboard/pkg/migration/migrate.go index 2a419596767..0f8992e6d2d 100644 --- a/pkg/apis/dashboard/migration/migrate.go +++ b/apps/dashboard/pkg/migration/migrate.go @@ -1,6 +1,6 @@ package migration -import "github.com/grafana/grafana/pkg/apis/dashboard/migration/schemaversion" +import "github.com/grafana/grafana/apps/dashboard/pkg/migration/schemaversion" func Migrate(dash map[string]interface{}, targetVersion int) error { if dash == nil { @@ -9,6 +9,12 @@ func Migrate(dash map[string]interface{}, targetVersion int) error { inputVersion := schemaversion.GetSchemaVersion(dash) dash["schemaVersion"] = inputVersion + // If the schema version is older than the minimum version, with migration support, + // we don't migrate the dashboard. + if inputVersion < schemaversion.MIN_VERSION { + return schemaversion.NewMigrationError("schema version is too old", inputVersion, schemaversion.MIN_VERSION) + } + for nextVersion := inputVersion + 1; nextVersion <= targetVersion; nextVersion++ { if migration, ok := schemaversion.Migrations[nextVersion]; ok { if err := migration(dash); err != nil { diff --git a/pkg/apis/dashboard/migration/migrate_test.go b/apps/dashboard/pkg/migration/migrate_test.go similarity index 86% rename from pkg/apis/dashboard/migration/migrate_test.go rename to apps/dashboard/pkg/migration/migrate_test.go index e037c37f00f..ef2a3468ce0 100644 --- a/pkg/apis/dashboard/migration/migrate_test.go +++ b/apps/dashboard/pkg/migration/migrate_test.go @@ -11,8 +11,8 @@ import ( "github.com/stretchr/testify/require" - "github.com/grafana/grafana/pkg/apis/dashboard/migration" - "github.com/grafana/grafana/pkg/apis/dashboard/migration/schemaversion" + "github.com/grafana/grafana/apps/dashboard/pkg/migration" + "github.com/grafana/grafana/apps/dashboard/pkg/migration/schemaversion" ) const INPUT_DIR = "testdata/input" @@ -22,6 +22,15 @@ func TestMigrate(t *testing.T) { files, err := os.ReadDir(INPUT_DIR) require.NoError(t, err) + t.Run("minimum version check", func(t *testing.T) { + err := migration.Migrate(map[string]interface{}{ + "schemaVersion": schemaversion.MIN_VERSION - 1, + }, schemaversion.MIN_VERSION) + + var minVersionErr = schemaversion.NewMigrationError("schema version is too old", schemaversion.MIN_VERSION-1, schemaversion.MIN_VERSION) + require.ErrorAs(t, err, &minVersionErr) + }) + for _, f := range files { if f.IsDir() { continue diff --git a/pkg/apis/dashboard/migration/schemaversion/errors.go b/apps/dashboard/pkg/migration/schemaversion/errors.go similarity index 55% rename from pkg/apis/dashboard/migration/schemaversion/errors.go rename to apps/dashboard/pkg/migration/schemaversion/errors.go index f5bbbe7d1fa..ee98593219d 100644 --- a/pkg/apis/dashboard/migration/schemaversion/errors.go +++ b/apps/dashboard/pkg/migration/schemaversion/errors.go @@ -23,3 +23,17 @@ type MigrationError struct { func (e *MigrationError) Error() string { return fmt.Errorf("schema migration from version %d to %d failed: %v", e.currentVersion, e.targetVersion, e.msg).Error() } + +// MinimumVersionError is an error that is returned when the schema version is below the minimum version. +func NewMinimumVersionError(inputVersion int) *MinimumVersionError { + return &MinimumVersionError{inputVersion: inputVersion} +} + +// MinimumVersionError is an error type for minimum version errors. +type MinimumVersionError struct { + inputVersion int +} + +func (e *MinimumVersionError) Error() string { + return fmt.Errorf("input schema version is below minimum version. input: %d minimum: %d", e.inputVersion, MIN_VERSION).Error() +} diff --git a/pkg/apis/dashboard/migration/schemaversion/migrations.go b/apps/dashboard/pkg/migration/schemaversion/migrations.go similarity index 90% rename from pkg/apis/dashboard/migration/schemaversion/migrations.go rename to apps/dashboard/pkg/migration/schemaversion/migrations.go index 3d83da73a3f..81bdd545dc6 100644 --- a/pkg/apis/dashboard/migration/schemaversion/migrations.go +++ b/apps/dashboard/pkg/migration/schemaversion/migrations.go @@ -4,7 +4,10 @@ import "strconv" type SchemaVersionMigrationFunc func(map[string]interface{}) error -const LATEST_VERSION = 41 +const ( + MIN_VERSION = 36 + LATEST_VERSION = 41 +) var Migrations = map[int]SchemaVersionMigrationFunc{ 37: V37, diff --git a/pkg/apis/dashboard/migration/schemaversion/migrations_test.go b/apps/dashboard/pkg/migration/schemaversion/migrations_test.go similarity index 95% rename from pkg/apis/dashboard/migration/schemaversion/migrations_test.go rename to apps/dashboard/pkg/migration/schemaversion/migrations_test.go index b20f7e4f561..02918b7b8fa 100644 --- a/pkg/apis/dashboard/migration/schemaversion/migrations_test.go +++ b/apps/dashboard/pkg/migration/schemaversion/migrations_test.go @@ -3,7 +3,7 @@ package schemaversion_test import ( "testing" - "github.com/grafana/grafana/pkg/apis/dashboard/migration/schemaversion" + "github.com/grafana/grafana/apps/dashboard/pkg/migration/schemaversion" "github.com/stretchr/testify/require" ) diff --git a/pkg/apis/dashboard/migration/schemaversion/v37.go b/apps/dashboard/pkg/migration/schemaversion/v37.go similarity index 100% rename from pkg/apis/dashboard/migration/schemaversion/v37.go rename to apps/dashboard/pkg/migration/schemaversion/v37.go diff --git a/pkg/apis/dashboard/migration/schemaversion/v37_test.go b/apps/dashboard/pkg/migration/schemaversion/v37_test.go similarity index 98% rename from pkg/apis/dashboard/migration/schemaversion/v37_test.go rename to apps/dashboard/pkg/migration/schemaversion/v37_test.go index e0b2f4c27cb..71bafee584c 100644 --- a/pkg/apis/dashboard/migration/schemaversion/v37_test.go +++ b/apps/dashboard/pkg/migration/schemaversion/v37_test.go @@ -3,7 +3,7 @@ package schemaversion_test import ( "testing" - "github.com/grafana/grafana/pkg/apis/dashboard/migration/schemaversion" + "github.com/grafana/grafana/apps/dashboard/pkg/migration/schemaversion" ) func TestV37(t *testing.T) { diff --git a/pkg/apis/dashboard/migration/schemaversion/v38.go b/apps/dashboard/pkg/migration/schemaversion/v38.go similarity index 100% rename from pkg/apis/dashboard/migration/schemaversion/v38.go rename to apps/dashboard/pkg/migration/schemaversion/v38.go diff --git a/pkg/apis/dashboard/migration/schemaversion/v38_test.go b/apps/dashboard/pkg/migration/schemaversion/v38_test.go similarity index 98% rename from pkg/apis/dashboard/migration/schemaversion/v38_test.go rename to apps/dashboard/pkg/migration/schemaversion/v38_test.go index f4bbb8c9cb6..9725fd3af66 100644 --- a/pkg/apis/dashboard/migration/schemaversion/v38_test.go +++ b/apps/dashboard/pkg/migration/schemaversion/v38_test.go @@ -3,7 +3,7 @@ package schemaversion_test import ( "testing" - "github.com/grafana/grafana/pkg/apis/dashboard/migration/schemaversion" + "github.com/grafana/grafana/apps/dashboard/pkg/migration/schemaversion" ) func TestV38(t *testing.T) { diff --git a/pkg/apis/dashboard/migration/schemaversion/v39.go b/apps/dashboard/pkg/migration/schemaversion/v39.go similarity index 100% rename from pkg/apis/dashboard/migration/schemaversion/v39.go rename to apps/dashboard/pkg/migration/schemaversion/v39.go diff --git a/pkg/apis/dashboard/migration/schemaversion/v39_test.go b/apps/dashboard/pkg/migration/schemaversion/v39_test.go similarity index 97% rename from pkg/apis/dashboard/migration/schemaversion/v39_test.go rename to apps/dashboard/pkg/migration/schemaversion/v39_test.go index d204d31f0cf..2eab71718cc 100644 --- a/pkg/apis/dashboard/migration/schemaversion/v39_test.go +++ b/apps/dashboard/pkg/migration/schemaversion/v39_test.go @@ -3,7 +3,7 @@ package schemaversion_test import ( "testing" - "github.com/grafana/grafana/pkg/apis/dashboard/migration/schemaversion" + "github.com/grafana/grafana/apps/dashboard/pkg/migration/schemaversion" ) func TestV39(t *testing.T) { diff --git a/pkg/apis/dashboard/migration/schemaversion/v40.go b/apps/dashboard/pkg/migration/schemaversion/v40.go similarity index 100% rename from pkg/apis/dashboard/migration/schemaversion/v40.go rename to apps/dashboard/pkg/migration/schemaversion/v40.go diff --git a/pkg/apis/dashboard/migration/schemaversion/v40_test.go b/apps/dashboard/pkg/migration/schemaversion/v40_test.go similarity index 94% rename from pkg/apis/dashboard/migration/schemaversion/v40_test.go rename to apps/dashboard/pkg/migration/schemaversion/v40_test.go index 179a2fbf655..041ac473f5d 100644 --- a/pkg/apis/dashboard/migration/schemaversion/v40_test.go +++ b/apps/dashboard/pkg/migration/schemaversion/v40_test.go @@ -3,7 +3,7 @@ package schemaversion_test import ( "testing" - "github.com/grafana/grafana/pkg/apis/dashboard/migration/schemaversion" + "github.com/grafana/grafana/apps/dashboard/pkg/migration/schemaversion" ) func TestV40(t *testing.T) { diff --git a/pkg/apis/dashboard/migration/schemaversion/v41.go b/apps/dashboard/pkg/migration/schemaversion/v41.go similarity index 100% rename from pkg/apis/dashboard/migration/schemaversion/v41.go rename to apps/dashboard/pkg/migration/schemaversion/v41.go diff --git a/pkg/apis/dashboard/migration/schemaversion/v41_test.go b/apps/dashboard/pkg/migration/schemaversion/v41_test.go similarity index 92% rename from pkg/apis/dashboard/migration/schemaversion/v41_test.go rename to apps/dashboard/pkg/migration/schemaversion/v41_test.go index d0f11d227f3..642d6ed41a3 100644 --- a/pkg/apis/dashboard/migration/schemaversion/v41_test.go +++ b/apps/dashboard/pkg/migration/schemaversion/v41_test.go @@ -3,7 +3,7 @@ package schemaversion_test import ( "testing" - "github.com/grafana/grafana/pkg/apis/dashboard/migration/schemaversion" + "github.com/grafana/grafana/apps/dashboard/pkg/migration/schemaversion" ) func TestV41(t *testing.T) { diff --git a/pkg/apis/dashboard/migration/testdata/input/36.legend_normalization.json b/apps/dashboard/pkg/migration/testdata/input/36.legend_normalization.json similarity index 100% rename from pkg/apis/dashboard/migration/testdata/input/36.legend_normalization.json rename to apps/dashboard/pkg/migration/testdata/input/36.legend_normalization.json diff --git a/pkg/apis/dashboard/migration/testdata/input/37.timeseries_table_display_mode.json b/apps/dashboard/pkg/migration/testdata/input/37.timeseries_table_display_mode.json similarity index 100% rename from pkg/apis/dashboard/migration/testdata/input/37.timeseries_table_display_mode.json rename to apps/dashboard/pkg/migration/testdata/input/37.timeseries_table_display_mode.json diff --git a/pkg/apis/dashboard/migration/testdata/input/38.transform_timeseries_table.json b/apps/dashboard/pkg/migration/testdata/input/38.transform_timeseries_table.json similarity index 100% rename from pkg/apis/dashboard/migration/testdata/input/38.transform_timeseries_table.json rename to apps/dashboard/pkg/migration/testdata/input/38.transform_timeseries_table.json diff --git a/pkg/apis/dashboard/migration/testdata/input/39.refresh_true.json b/apps/dashboard/pkg/migration/testdata/input/39.refresh_true.json similarity index 100% rename from pkg/apis/dashboard/migration/testdata/input/39.refresh_true.json rename to apps/dashboard/pkg/migration/testdata/input/39.refresh_true.json diff --git a/pkg/apis/dashboard/migration/testdata/input/40.time_picker_time_options.json b/apps/dashboard/pkg/migration/testdata/input/40.time_picker_time_options.json similarity index 100% rename from pkg/apis/dashboard/migration/testdata/input/40.time_picker_time_options.json rename to apps/dashboard/pkg/migration/testdata/input/40.time_picker_time_options.json diff --git a/pkg/apis/dashboard/migration/testdata/output/36.legend_normalization.37.json b/apps/dashboard/pkg/migration/testdata/output/36.legend_normalization.37.json similarity index 100% rename from pkg/apis/dashboard/migration/testdata/output/36.legend_normalization.37.json rename to apps/dashboard/pkg/migration/testdata/output/36.legend_normalization.37.json diff --git a/pkg/apis/dashboard/migration/testdata/output/36.legend_normalization.38.json b/apps/dashboard/pkg/migration/testdata/output/36.legend_normalization.38.json similarity index 100% rename from pkg/apis/dashboard/migration/testdata/output/36.legend_normalization.38.json rename to apps/dashboard/pkg/migration/testdata/output/36.legend_normalization.38.json diff --git a/pkg/apis/dashboard/migration/testdata/output/36.legend_normalization.39.json b/apps/dashboard/pkg/migration/testdata/output/36.legend_normalization.39.json similarity index 100% rename from pkg/apis/dashboard/migration/testdata/output/36.legend_normalization.39.json rename to apps/dashboard/pkg/migration/testdata/output/36.legend_normalization.39.json diff --git a/pkg/apis/dashboard/migration/testdata/output/36.legend_normalization.40.json b/apps/dashboard/pkg/migration/testdata/output/36.legend_normalization.40.json similarity index 100% rename from pkg/apis/dashboard/migration/testdata/output/36.legend_normalization.40.json rename to apps/dashboard/pkg/migration/testdata/output/36.legend_normalization.40.json diff --git a/pkg/apis/dashboard/migration/testdata/output/36.legend_normalization.41.json b/apps/dashboard/pkg/migration/testdata/output/36.legend_normalization.41.json similarity index 100% rename from pkg/apis/dashboard/migration/testdata/output/36.legend_normalization.41.json rename to apps/dashboard/pkg/migration/testdata/output/36.legend_normalization.41.json diff --git a/pkg/apis/dashboard/migration/testdata/output/37.timeseries_table_display_mode.38.json b/apps/dashboard/pkg/migration/testdata/output/37.timeseries_table_display_mode.38.json similarity index 100% rename from pkg/apis/dashboard/migration/testdata/output/37.timeseries_table_display_mode.38.json rename to apps/dashboard/pkg/migration/testdata/output/37.timeseries_table_display_mode.38.json diff --git a/pkg/apis/dashboard/migration/testdata/output/37.timeseries_table_display_mode.39.json b/apps/dashboard/pkg/migration/testdata/output/37.timeseries_table_display_mode.39.json similarity index 100% rename from pkg/apis/dashboard/migration/testdata/output/37.timeseries_table_display_mode.39.json rename to apps/dashboard/pkg/migration/testdata/output/37.timeseries_table_display_mode.39.json diff --git a/pkg/apis/dashboard/migration/testdata/output/37.timeseries_table_display_mode.40.json b/apps/dashboard/pkg/migration/testdata/output/37.timeseries_table_display_mode.40.json similarity index 100% rename from pkg/apis/dashboard/migration/testdata/output/37.timeseries_table_display_mode.40.json rename to apps/dashboard/pkg/migration/testdata/output/37.timeseries_table_display_mode.40.json diff --git a/pkg/apis/dashboard/migration/testdata/output/37.timeseries_table_display_mode.41.json b/apps/dashboard/pkg/migration/testdata/output/37.timeseries_table_display_mode.41.json similarity index 100% rename from pkg/apis/dashboard/migration/testdata/output/37.timeseries_table_display_mode.41.json rename to apps/dashboard/pkg/migration/testdata/output/37.timeseries_table_display_mode.41.json diff --git a/pkg/apis/dashboard/migration/testdata/output/38.transform_timeseries_table.39.json b/apps/dashboard/pkg/migration/testdata/output/38.transform_timeseries_table.39.json similarity index 100% rename from pkg/apis/dashboard/migration/testdata/output/38.transform_timeseries_table.39.json rename to apps/dashboard/pkg/migration/testdata/output/38.transform_timeseries_table.39.json diff --git a/pkg/apis/dashboard/migration/testdata/output/38.transform_timeseries_table.40.json b/apps/dashboard/pkg/migration/testdata/output/38.transform_timeseries_table.40.json similarity index 100% rename from pkg/apis/dashboard/migration/testdata/output/38.transform_timeseries_table.40.json rename to apps/dashboard/pkg/migration/testdata/output/38.transform_timeseries_table.40.json diff --git a/pkg/apis/dashboard/migration/testdata/output/38.transform_timeseries_table.41.json b/apps/dashboard/pkg/migration/testdata/output/38.transform_timeseries_table.41.json similarity index 100% rename from pkg/apis/dashboard/migration/testdata/output/38.transform_timeseries_table.41.json rename to apps/dashboard/pkg/migration/testdata/output/38.transform_timeseries_table.41.json diff --git a/pkg/apis/dashboard/migration/testdata/output/39.refresh_true.40.json b/apps/dashboard/pkg/migration/testdata/output/39.refresh_true.40.json similarity index 100% rename from pkg/apis/dashboard/migration/testdata/output/39.refresh_true.40.json rename to apps/dashboard/pkg/migration/testdata/output/39.refresh_true.40.json diff --git a/pkg/apis/dashboard/migration/testdata/output/39.refresh_true.41.json b/apps/dashboard/pkg/migration/testdata/output/39.refresh_true.41.json similarity index 100% rename from pkg/apis/dashboard/migration/testdata/output/39.refresh_true.41.json rename to apps/dashboard/pkg/migration/testdata/output/39.refresh_true.41.json diff --git a/pkg/apis/dashboard/migration/testdata/output/40.time_picker_time_options.41.json b/apps/dashboard/pkg/migration/testdata/output/40.time_picker_time_options.41.json similarity index 100% rename from pkg/apis/dashboard/migration/testdata/output/40.time_picker_time_options.41.json rename to apps/dashboard/pkg/migration/testdata/output/40.time_picker_time_options.41.json diff --git a/apps/investigations/go.mod b/apps/investigations/go.mod index 645f323e800..aada9c2c3b4 100644 --- a/apps/investigations/go.mod +++ b/apps/investigations/go.mod @@ -56,13 +56,14 @@ require ( github.com/spf13/pflag v1.0.6 // indirect github.com/x448/float16 v0.8.4 // indirect go.opentelemetry.io/auto/sdk v1.1.0 // indirect - go.opentelemetry.io/otel v1.34.0 // indirect + go.opentelemetry.io/otel v1.35.0 // indirect go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.34.0 // indirect go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.34.0 // indirect go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp v1.34.0 // indirect - go.opentelemetry.io/otel/metric v1.34.0 // indirect - go.opentelemetry.io/otel/sdk v1.34.0 // indirect - go.opentelemetry.io/otel/trace v1.34.0 // indirect + go.opentelemetry.io/otel/metric v1.35.0 // indirect + go.opentelemetry.io/otel/sdk v1.35.0 // indirect + go.opentelemetry.io/otel/sdk/metric v1.35.0 // indirect + go.opentelemetry.io/otel/trace v1.35.0 // indirect go.opentelemetry.io/proto/otlp v1.5.0 // indirect golang.org/x/net v0.36.0 // indirect golang.org/x/oauth2 v0.27.0 // indirect @@ -71,6 +72,7 @@ require ( golang.org/x/term v0.29.0 // indirect golang.org/x/text v0.22.0 // indirect golang.org/x/time v0.9.0 // indirect + golang.org/x/tools v0.30.0 // indirect gomodules.xyz/jsonpatch/v2 v2.4.0 // indirect google.golang.org/genproto/googleapis/api v0.0.0-20250204164813-702378808489 // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20250207221924-e9438ea467c6 // indirect diff --git a/apps/investigations/go.sum b/apps/investigations/go.sum index 88d0fa45e79..129a8163693 100644 --- a/apps/investigations/go.sum +++ b/apps/investigations/go.sum @@ -126,22 +126,22 @@ github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9de github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= go.opentelemetry.io/auto/sdk v1.1.0 h1:cH53jehLUN6UFLY71z+NDOiNJqDdPRaXzTel0sJySYA= go.opentelemetry.io/auto/sdk v1.1.0/go.mod h1:3wSPjt5PWp2RhlCcmmOial7AvC4DQqZb7a7wCow3W8A= -go.opentelemetry.io/otel v1.34.0 h1:zRLXxLCgL1WyKsPVrgbSdMN4c0FMkDAskSTQP+0hdUY= -go.opentelemetry.io/otel v1.34.0/go.mod h1:OWFPOQ+h4G8xpyjgqo4SxJYdDQ/qmRH+wivy7zzx9oI= +go.opentelemetry.io/otel v1.35.0 h1:xKWKPxrxB6OtMCbmMY021CqC45J+3Onta9MqjhnusiQ= +go.opentelemetry.io/otel v1.35.0/go.mod h1:UEqy8Zp11hpkUrL73gSlELM0DupHoiq72dR+Zqel/+Y= go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.34.0 h1:OeNbIYk/2C15ckl7glBlOBp5+WlYsOElzTNmiPW/x60= go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.34.0/go.mod h1:7Bept48yIeqxP2OZ9/AqIpYS94h2or0aB4FypJTc8ZM= go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.34.0 h1:tgJ0uaNS4c98WRNUEx5U3aDlrDOI5Rs+1Vifcw4DJ8U= go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.34.0/go.mod h1:U7HYyW0zt/a9x5J1Kjs+r1f/d4ZHnYFclhYY2+YbeoE= go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp v1.34.0 h1:BEj3SPM81McUZHYjRS5pEgNgnmzGJ5tRpU5krWnV8Bs= go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp v1.34.0/go.mod h1:9cKLGBDzI/F3NoHLQGm4ZrYdIHsvGt6ej6hUowxY0J4= -go.opentelemetry.io/otel/metric v1.34.0 h1:+eTR3U0MyfWjRDhmFMxe2SsW64QrZ84AOhvqS7Y+PoQ= -go.opentelemetry.io/otel/metric v1.34.0/go.mod h1:CEDrp0fy2D0MvkXE+dPV7cMi8tWZwX3dmaIhwPOaqHE= -go.opentelemetry.io/otel/sdk v1.34.0 h1:95zS4k/2GOy069d321O8jWgYsW3MzVV+KuSPKp7Wr1A= -go.opentelemetry.io/otel/sdk v1.34.0/go.mod h1:0e/pNiaMAqaykJGKbi+tSjWfNNHMTxoC9qANsCzbyxU= -go.opentelemetry.io/otel/sdk/metric v1.32.0 h1:rZvFnvmvawYb0alrYkjraqJq0Z4ZUJAiyYCU9snn1CU= -go.opentelemetry.io/otel/sdk/metric v1.32.0/go.mod h1:PWeZlq0zt9YkYAp3gjKZ0eicRYvOh1Gd+X99x6GHpCQ= -go.opentelemetry.io/otel/trace v1.34.0 h1:+ouXS2V8Rd4hp4580a8q23bg0azF2nI8cqLYnC8mh/k= -go.opentelemetry.io/otel/trace v1.34.0/go.mod h1:Svm7lSjQD7kG7KJ/MUHPVXSDGz2OX4h0M2jHBhmSfRE= +go.opentelemetry.io/otel/metric v1.35.0 h1:0znxYu2SNyuMSQT4Y9WDWej0VpcsxkuklLa4/siN90M= +go.opentelemetry.io/otel/metric v1.35.0/go.mod h1:nKVFgxBZ2fReX6IlyW28MgZojkoAkJGaE8CpgeAU3oE= +go.opentelemetry.io/otel/sdk v1.35.0 h1:iPctf8iprVySXSKJffSS79eOjl9pvxV9ZqOWT0QejKY= +go.opentelemetry.io/otel/sdk v1.35.0/go.mod h1:+ga1bZliga3DxJ3CQGg3updiaAJoNECOgJREo9KHGQg= +go.opentelemetry.io/otel/sdk/metric v1.35.0 h1:1RriWBmCKgkeHEhM7a2uMjMUfP7MsOF5JpUCaEqEI9o= +go.opentelemetry.io/otel/sdk/metric v1.35.0/go.mod h1:is6XYCUMpcKi+ZsOvfluY5YstFnhW0BidkR+gL+qN+w= +go.opentelemetry.io/otel/trace v1.35.0 h1:dPpEfJu1sDIqruz7BHFG3c7528f6ddfSWfFDVt/xgMs= +go.opentelemetry.io/otel/trace v1.35.0/go.mod h1:WUk7DtFp1Aw2MkvqGdwiXYDZZNvA/1J8o6xRXLrIkyc= go.opentelemetry.io/proto/otlp v1.5.0 h1:xJvq7gMzB31/d406fB8U5CBdyQGw4P399D1aQWU/3i4= go.opentelemetry.io/proto/otlp v1.5.0/go.mod h1:keN8WnHxOy8PG0rQZjJJ5A2ebUoafqWp0eVQ4yIXvJ4= go.uber.org/goleak v1.3.0 h1:2K3zAYmnTNqV73imy9J1T3WC+gmCePx2hEGkimedGto= @@ -181,8 +181,8 @@ golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGm golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= -golang.org/x/tools v0.29.0 h1:Xx0h3TtM9rzQpQuR4dKLrdglAmCEN5Oi+P74JdhdzXE= -golang.org/x/tools v0.29.0/go.mod h1:KMQVMRsVxU6nHCFXrBPhDB8XncLNLM0lIy/F14RP588= +golang.org/x/tools v0.30.0 h1:BgcpHewrV5AUp2G9MebG4XPFI1E2W41zU1SaqVA9vJY= +golang.org/x/tools v0.30.0/go.mod h1:c347cR/OJfw5TI+GfX7RUPNMdDRRbjvYTS0jPyvsVtY= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= diff --git a/apps/playlist/go.mod b/apps/playlist/go.mod index 6214b9ae328..b8162370ed4 100644 --- a/apps/playlist/go.mod +++ b/apps/playlist/go.mod @@ -57,13 +57,14 @@ require ( github.com/spf13/pflag v1.0.6 // indirect github.com/x448/float16 v0.8.4 // indirect go.opentelemetry.io/auto/sdk v1.1.0 // indirect - go.opentelemetry.io/otel v1.34.0 // indirect + go.opentelemetry.io/otel v1.35.0 // indirect go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.34.0 // indirect go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.34.0 // indirect go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp v1.34.0 // indirect - go.opentelemetry.io/otel/metric v1.34.0 // indirect - go.opentelemetry.io/otel/sdk v1.34.0 // indirect - go.opentelemetry.io/otel/trace v1.34.0 // indirect + go.opentelemetry.io/otel/metric v1.35.0 // indirect + go.opentelemetry.io/otel/sdk v1.35.0 // indirect + go.opentelemetry.io/otel/sdk/metric v1.35.0 // indirect + go.opentelemetry.io/otel/trace v1.35.0 // indirect go.opentelemetry.io/proto/otlp v1.5.0 // indirect golang.org/x/net v0.36.0 // indirect golang.org/x/oauth2 v0.27.0 // indirect @@ -72,6 +73,7 @@ require ( golang.org/x/term v0.29.0 // indirect golang.org/x/text v0.22.0 // indirect golang.org/x/time v0.9.0 // indirect + golang.org/x/tools v0.30.0 // indirect gomodules.xyz/jsonpatch/v2 v2.4.0 // indirect google.golang.org/genproto/googleapis/api v0.0.0-20250204164813-702378808489 // indirect google.golang.org/genproto/googleapis/rpc v0.0.0-20250207221924-e9438ea467c6 // indirect diff --git a/apps/playlist/go.sum b/apps/playlist/go.sum index 88d0fa45e79..129a8163693 100644 --- a/apps/playlist/go.sum +++ b/apps/playlist/go.sum @@ -126,22 +126,22 @@ github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9de github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= go.opentelemetry.io/auto/sdk v1.1.0 h1:cH53jehLUN6UFLY71z+NDOiNJqDdPRaXzTel0sJySYA= go.opentelemetry.io/auto/sdk v1.1.0/go.mod h1:3wSPjt5PWp2RhlCcmmOial7AvC4DQqZb7a7wCow3W8A= -go.opentelemetry.io/otel v1.34.0 h1:zRLXxLCgL1WyKsPVrgbSdMN4c0FMkDAskSTQP+0hdUY= -go.opentelemetry.io/otel v1.34.0/go.mod h1:OWFPOQ+h4G8xpyjgqo4SxJYdDQ/qmRH+wivy7zzx9oI= +go.opentelemetry.io/otel v1.35.0 h1:xKWKPxrxB6OtMCbmMY021CqC45J+3Onta9MqjhnusiQ= +go.opentelemetry.io/otel v1.35.0/go.mod h1:UEqy8Zp11hpkUrL73gSlELM0DupHoiq72dR+Zqel/+Y= go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.34.0 h1:OeNbIYk/2C15ckl7glBlOBp5+WlYsOElzTNmiPW/x60= go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.34.0/go.mod h1:7Bept48yIeqxP2OZ9/AqIpYS94h2or0aB4FypJTc8ZM= go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.34.0 h1:tgJ0uaNS4c98WRNUEx5U3aDlrDOI5Rs+1Vifcw4DJ8U= go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.34.0/go.mod h1:U7HYyW0zt/a9x5J1Kjs+r1f/d4ZHnYFclhYY2+YbeoE= go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp v1.34.0 h1:BEj3SPM81McUZHYjRS5pEgNgnmzGJ5tRpU5krWnV8Bs= go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp v1.34.0/go.mod h1:9cKLGBDzI/F3NoHLQGm4ZrYdIHsvGt6ej6hUowxY0J4= -go.opentelemetry.io/otel/metric v1.34.0 h1:+eTR3U0MyfWjRDhmFMxe2SsW64QrZ84AOhvqS7Y+PoQ= -go.opentelemetry.io/otel/metric v1.34.0/go.mod h1:CEDrp0fy2D0MvkXE+dPV7cMi8tWZwX3dmaIhwPOaqHE= -go.opentelemetry.io/otel/sdk v1.34.0 h1:95zS4k/2GOy069d321O8jWgYsW3MzVV+KuSPKp7Wr1A= -go.opentelemetry.io/otel/sdk v1.34.0/go.mod h1:0e/pNiaMAqaykJGKbi+tSjWfNNHMTxoC9qANsCzbyxU= -go.opentelemetry.io/otel/sdk/metric v1.32.0 h1:rZvFnvmvawYb0alrYkjraqJq0Z4ZUJAiyYCU9snn1CU= -go.opentelemetry.io/otel/sdk/metric v1.32.0/go.mod h1:PWeZlq0zt9YkYAp3gjKZ0eicRYvOh1Gd+X99x6GHpCQ= -go.opentelemetry.io/otel/trace v1.34.0 h1:+ouXS2V8Rd4hp4580a8q23bg0azF2nI8cqLYnC8mh/k= -go.opentelemetry.io/otel/trace v1.34.0/go.mod h1:Svm7lSjQD7kG7KJ/MUHPVXSDGz2OX4h0M2jHBhmSfRE= +go.opentelemetry.io/otel/metric v1.35.0 h1:0znxYu2SNyuMSQT4Y9WDWej0VpcsxkuklLa4/siN90M= +go.opentelemetry.io/otel/metric v1.35.0/go.mod h1:nKVFgxBZ2fReX6IlyW28MgZojkoAkJGaE8CpgeAU3oE= +go.opentelemetry.io/otel/sdk v1.35.0 h1:iPctf8iprVySXSKJffSS79eOjl9pvxV9ZqOWT0QejKY= +go.opentelemetry.io/otel/sdk v1.35.0/go.mod h1:+ga1bZliga3DxJ3CQGg3updiaAJoNECOgJREo9KHGQg= +go.opentelemetry.io/otel/sdk/metric v1.35.0 h1:1RriWBmCKgkeHEhM7a2uMjMUfP7MsOF5JpUCaEqEI9o= +go.opentelemetry.io/otel/sdk/metric v1.35.0/go.mod h1:is6XYCUMpcKi+ZsOvfluY5YstFnhW0BidkR+gL+qN+w= +go.opentelemetry.io/otel/trace v1.35.0 h1:dPpEfJu1sDIqruz7BHFG3c7528f6ddfSWfFDVt/xgMs= +go.opentelemetry.io/otel/trace v1.35.0/go.mod h1:WUk7DtFp1Aw2MkvqGdwiXYDZZNvA/1J8o6xRXLrIkyc= go.opentelemetry.io/proto/otlp v1.5.0 h1:xJvq7gMzB31/d406fB8U5CBdyQGw4P399D1aQWU/3i4= go.opentelemetry.io/proto/otlp v1.5.0/go.mod h1:keN8WnHxOy8PG0rQZjJJ5A2ebUoafqWp0eVQ4yIXvJ4= go.uber.org/goleak v1.3.0 h1:2K3zAYmnTNqV73imy9J1T3WC+gmCePx2hEGkimedGto= @@ -181,8 +181,8 @@ golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGm golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= -golang.org/x/tools v0.29.0 h1:Xx0h3TtM9rzQpQuR4dKLrdglAmCEN5Oi+P74JdhdzXE= -golang.org/x/tools v0.29.0/go.mod h1:KMQVMRsVxU6nHCFXrBPhDB8XncLNLM0lIy/F14RP588= +golang.org/x/tools v0.30.0 h1:BgcpHewrV5AUp2G9MebG4XPFI1E2W41zU1SaqVA9vJY= +golang.org/x/tools v0.30.0/go.mod h1:c347cR/OJfw5TI+GfX7RUPNMdDRRbjvYTS0jPyvsVtY= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= diff --git a/conf/defaults.ini b/conf/defaults.ini index a216bb0792a..ba04540e320 100644 --- a/conf/defaults.ini +++ b/conf/defaults.ini @@ -198,7 +198,7 @@ type = database # cache connectionstring options # database: will use Grafana primary database. -# redis: config like redis server e.g. `addr=127.0.0.1:6379,pool_size=100,db=0,ssl=false`. Only addr is required. ssl may be 'true', 'false', or 'insecure'. +# redis: config like redis server e.g. `addr=127.0.0.1:6379,pool_size=100,db=0,username=grafana,password=grafanaRocks,ssl=false`. Only addr is required. ssl may be 'true', 'false', or 'insecure'. # memcache: 127.0.0.1:11211 connstr = @@ -1406,6 +1406,14 @@ resolved_alert_retention = 15m # 0 value means no limit rule_version_record_limit = 0 +# The retention period for deleted alerting rules. +# Determines how long deleted rules are retained before being permanently removed. +# The retention duration must be specified using a time format with unit suffixes +# such as ms, s, m, h, d (e.g., 30d for 30 days). +# Default: 30d +# 0 value means that rules are deleted permanently immediately. +deleted_rule_retention = 30d + [unified_alerting.screenshots] # Enable screenshots in notifications. You must have either installed the Grafana image rendering # plugin, or set up Grafana to use a remote rendering service. @@ -1527,9 +1535,6 @@ timeout = 10s # Only has effect if the grafanaManagedRecordRulesDatasources feature toggle is enabled. default_datasource_uid = -# Suffix to apply to the data source URL for remote write requests. -remote_write_path_suffix = /push - # Optional custom headers to include in recording rule write requests. [recording_rules.custom_headers] # exampleHeader = exampleValue diff --git a/conf/sample.ini b/conf/sample.ini index 21ef0ad88c6..15f94510ba6 100644 --- a/conf/sample.ini +++ b/conf/sample.ini @@ -197,7 +197,7 @@ # cache connectionstring options # database: will use Grafana primary database. -# redis: config like redis server e.g. `addr=127.0.0.1:6379,pool_size=100,db=0,ssl=false`. Only addr is required. ssl may be 'true', 'false', or 'insecure'. +# redis: config like redis server e.g. `addr=127.0.0.1:6379,pool_size=100,db=0,username=grafana,password=grafanaRocks,ssl=false`. Only addr is required. ssl may be 'true', 'false', or 'insecure'. # memcache: 127.0.0.1:11211 ;connstr = @@ -1389,6 +1389,14 @@ # 0 value means no limit ;rule_version_record_limit= 0 +# The retention period for deleted alerting rules. +# Determines how long deleted rules are retained before being permanently removed. +# The retention duration must be specified using a time format with unit suffixes +# such as ms, s, m, h, d (e.g., 30d for 30 days). +# Default: 30d +# 0 value means that rules are deleted permanently immediately. +;deleted_rule_retention = 30d + [unified_alerting.screenshots] # Enable screenshots in notifications. You must have either installed the Grafana image rendering # plugin, or set up Grafana to use a remote rendering service. @@ -1509,9 +1517,6 @@ timeout = 30s # Only has effect if the grafanaManagedRecordRulesDatasources feature toggle is enabled. default_datasource_uid = -# Suffix to apply to the data source URL for remote write requests. -remote_write_path_suffix = /push - # Optional custom headers to include in recording rule write requests. [recording_rules.custom_headers] # exampleHeader = exampleValue diff --git a/docs/sources/administration/provisioning/index.md b/docs/sources/administration/provisioning/index.md index bbbbec185cd..6145d69a761 100644 --- a/docs/sources/administration/provisioning/index.md +++ b/docs/sources/administration/provisioning/index.md @@ -24,26 +24,25 @@ Refer to [Configuration](../../setup-grafana/configure-grafana/) for more inform ### Configuration file locations -- Default configuration from `$WORKING_DIR/conf/defaults.ini` -- Custom configuration from `$WORKING_DIR/conf/custom.ini` -- The custom configuration file path can be overridden using the `--config` parameter +Grafana reads its default configuration from `/conf/defaults.ini`. +By default, Grafana reads custom configuration from `/conf/custom.ini`. +You can override the custom configuration path with the `--config` option. {{< admonition type="note" >}} -If you have installed Grafana using the `deb` or `rpm` -packages, then your configuration file is located at -`/etc/grafana/grafana.ini`. This path is specified in the Grafana -`init.d` script using the `--config` file parameter. +The Deb and RPM packages install the configuration file at `/etc/grafana/grafana.ini`. +The Grafana init.d script sets the `--config` option to that path. {{< /admonition >}} -### Environment variables +### Use environment variables -You can use environment variable interpolation in all three provisioning configuration types. -The allowed syntax is either `$ENV_VAR_NAME` or `${ENV_VAR_NAME}`, and it can be used only for values, not for keys or larger parts -of the configurations. If the environment variable value has a `$` (e.g. `Pa$sw0rd`), use the `$ENV_VAR_NAME` syntax to avoid double expansion. -It's not available in the dashboard's definition files, just the dashboard provisioning -configuration. +You can use environment variable lookups in all provisioning configuration. +The syntax for an environment variable is `$ENV_VAR_NAME` or `${ENV_VAR_NAME}`. +If the environment variable value has a `$` in it (for example, `Pa$sw0rd`), use the `$ENV_VAR_NAME` syntax to avoid double expansion. +You can only use environment variables for configuration values and not for keys or bigger parts of the configuration file structure. -Example: +You can use environment variables in dashboard provisioning configuration but not the dashboard definition files themselves. + +The following example looks up the data source URL port, user, and password using environment variables: ```yaml datasources: @@ -54,40 +53,38 @@ datasources: password: $PASSWORD ``` -You can use `$$` if you have a literal `$` in your value and want to avoid interpolation. +To escape a literal `$` in your provisioning file values, use `$$`. ## Configuration management tools -Currently, we don't provide any scripts or manifests for configuring Grafana. -Rather than spending time learning and creating scripts or manifests for each tool, we think our time is better spent making Grafana easier to provision. -Therefore, we heavily rely on the expertise of the community. +The Grafana community maintains libraries for many popular configuration management tools. -| Tool | Project | -| --------- | ------------------------------------------------------------------------------------------------------------------------------- | -| Puppet | [https://forge.puppet.com/puppet/grafana](https://forge.puppet.com/puppet/grafana) | -| Ansible | [https://github.com/grafana/grafana-ansible-collection](https://github.com/grafana/grafana-ansible-collection) | -| Chef | [https://github.com/sous-chefs/chef-grafana](https://github.com/sous-chefs/chef-grafana) | -| Saltstack | [https://github.com/salt-formulas/salt-formula-grafana](https://github.com/salt-formulas/salt-formula-grafana) | -| Jsonnet | [https://github.com/grafana/grafonnet-lib/](https://github.com/grafana/grafonnet-lib/) | -| NixOS | [services.grafana.provision module](https://github.com/NixOS/nixpkgs/blob/master/nixos/modules/services/monitoring/grafana.nix) | +| Tool | Project | +| --------- | --------------------------------------------------------------------------------------------------------------------------------- | +| Puppet | | +| Ansible | | +| Chef | | +| Saltstack | | +| Jsonnet | ) | +| NixOS | [`services.grafana.provision` module](https://github.com/NixOS/nixpkgs/blob/master/nixos/modules/services/monitoring/grafana.nix) | ## Data sources You can manage data sources in Grafana by adding YAML configuration files in the [`provisioning/datasources`](../../setup-grafana/configure-grafana/#provisioning) directory. -Each configuration file can contain a list of `datasources` to add or update during startup. +Each configuration file contains a list of data sources, under the `datasources` key, to add or update during startup. If the data source already exists, Grafana reconfigures it to match the provisioned configuration file. -The configuration file can also list data sources to automatically delete, called `deleteDatasources`. +You can also list data sources to automatically delete, using the key `deleteDatasources`. Grafana deletes the data sources listed in `deleteDatasources` _before_ adding or updating those in the `datasources` list. You can configure Grafana to automatically delete provisioned data sources when they're removed from the provisioning file. To do so, add `prune: true` to the root of your data source provisioning file. With this configuration, Grafana also removes the provisioned data sources if you remove the provisioning file entirely. -### Running multiple Grafana instances +### Run multiple Grafana instances If you run multiple instances of Grafana, add a version number to each data source in the configuration and increase it when you update the configuration. -Grafana updates only data sources with the same or lower version number than specified in the configuration. +Grafana only updates data sources with the same or lower version number than the one set in the configuration file. This prevents old configurations from overwriting newer ones if you have different versions of the `datasource.yaml` file that don't define version numbers, and then restart instances at the same time. ### Example data source configuration file @@ -176,99 +173,100 @@ For provisioning examples of specific data sources, refer to that [data source's #### JSON data -Not all data sources have the same configuration settings. Only the most common fields are included in examples. -To provision the rest of a data source's settings, include them as a JSON blob in the `jsonData` field. +Not all data sources have the same configuration settings, only the most common ones are fields in the data source provisioning file. +To provision the rest of a data source's settings, include them as JSON in the `jsonData` field. Common settings in the [built-in core data sources](../../datasources/#built-in-core-data-sources) include: +| Name | Type | Data source | Description | +| ------------------------------- | ------- | ---------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | +| `tlsAuth` | boolean | _HTTP\*_, MySQL | Enable TLS authentication using client cert configured in secure JSON data | +| `tlsAuthWithCACert` | boolean | _HTTP\*_, MySQL, PostgreSQL | Enable TLS authentication using CA cert | +| `tlsSkipVerify` | boolean | _HTTP\*_, MySQL, PostgreSQL, MSSQL | Controls whether a client verifies the server's certificate chain and host name. | +| `serverName` | string | _HTTP\*_, MSSQL | Optional. Controls the server name used for certificate common name/subject alternative name verification. Defaults to using the data source URL. | +| `timeout` | string | _HTTP\*_ | Request timeout in seconds. Overrides `dataproxy.timeout` option | +| `graphiteVersion` | string | Graphite | Graphite version | +| `timeInterval` | string | Prometheus, Elasticsearch, InfluxDB, MySQL, PostgreSQL and MSSQL | Lowest interval/step value that should be used for this data source. | +| `httpMode` | string | InfluxDB | HTTP Method. 'GET', 'POST', defaults to GET | +| `maxSeries` | number | InfluxDB | Max number of series/tables that Grafana processes | +| `httpMethod` | string | Prometheus | HTTP Method. 'GET', 'POST', defaults to POST | +| `customQueryParameters` | string | Prometheus | Query parameters to add, as a URL-encoded string. | +| `manageAlerts` | boolean | Prometheus and Loki | Manage alerts via Alerting UI | +| `alertmanagerUid` | string | Prometheus and Loki | UID of Alertmanager that manages Alert for this data source. | +| `timeField` | string | Elasticsearch | Which field that should be used as timestamp | +| `interval` | string | Elasticsearch | Index date time format. nil(No Pattern), 'Hourly', 'Daily', 'Weekly', 'Monthly' or 'Yearly' | +| `logMessageField` | string | Elasticsearch | Which field should be used as the log message | +| `logLevelField` | string | Elasticsearch | Which field should be used to indicate the priority of the log message | +| `maxConcurrentShardRequests` | number | Elasticsearch | Maximum number of concurrent shard requests that each sub-search request executes per node | +| `sigV4Auth` | boolean | Elasticsearch and Prometheus | Enable usage of SigV4 | +| `sigV4AuthType` | string | Elasticsearch and Prometheus | SigV4 auth provider. default/credentials/keys | +| `sigV4ExternalId` | string | Elasticsearch and Prometheus | Optional SigV4 External ID | +| `sigV4AssumeRoleArn` | string | Elasticsearch and Prometheus | Optional SigV4 ARN role to assume | +| `sigV4Region` | string | Elasticsearch and Prometheus | SigV4 AWS region | +| `sigV4Profile` | string | Elasticsearch and Prometheus | Optional SigV4 credentials profile | +| `authType` | string | Amazon CloudWatch | Auth provider. default/credentials/keys | +| `externalId` | string | Amazon CloudWatch | Optional External ID | +| `assumeRoleArn` | string | Amazon CloudWatch | Optional ARN role to assume | +| `defaultRegion` | string | Amazon CloudWatch | Optional default AWS region | +| `customMetricsNamespaces` | string | Amazon CloudWatch | Namespaces of Custom Metrics | +| `profile` | string | Amazon CloudWatch | Optional credentials profile | +| `tsdbVersion` | string | OpenTSDB | Version | +| `tsdbResolution` | string | OpenTSDB | Resolution | +| `sslmode` | string | PostgreSQL | SSL mode. 'disable', 'require', 'verify-ca' or 'verify-full' | +| `tlsConfigurationMethod` | string | PostgreSQL | SSL certificate configuration, either by 'file-path' or 'file-content' | +| `sslRootCertFile` | string | PostgreSQL, MSSQL | SSL server root certificate file, must be readable by the Grafana user | +| `sslCertFile` | string | PostgreSQL | SSL client certificate file, must be readable by the Grafana user | +| `sslKeyFile` | string | PostgreSQL | SSL client key file, must be readable by _only_ the Grafana user | +| `encrypt` | string | MSSQL | Determines SSL encryption handling. Options include: `disable` - data sent between client and server is not encrypted; `false` - data sent between client and server is not encrypted beyond the login packet; `true` - data sent between client and server is encrypted. Default is `false`. | +| `postgresVersion` | number | PostgreSQL | Postgres version as a number (903/904/905/906/1000) meaning v9.3, v9.4, ..., v10 | +| `timescaledb` | boolean | PostgreSQL | Enable usage of TimescaleDB extension | +| `maxOpenConns` | number | MySQL, PostgreSQL and MSSQL | Maximum number of open connections to the database (Grafana v5.4+) | +| `maxIdleConns` | number | MySQL, PostgreSQL and MSSQL | Maximum number of connections in the idle connection pool (Grafana v5.4+) | +| `connMaxLifetime` | number | MySQL, PostgreSQL and MSSQL | Maximum amount of time in seconds a connection may be reused (Grafana v5.4+) | +| `keepCookies` | array | _HTTP\*_ | Cookies that needs to be passed along while communicating with data sources | +| `prometheusVersion` | string | Prometheus | The version of the Prometheus data source, such as `2.37.0`, `2.24.0` | +| `prometheusType` | string | Prometheus | Prometheus database type. Options are `Prometheus`, `Cortex`, `Mimir` or`Thanos`. | +| `cacheLevel` | string | Prometheus | Determines the duration of the browser cache. Valid values include: `Low`, `Medium`, `High`, and `None`. | +| `incrementalQuerying` | string | Prometheus | Experimental: Turn on incremental querying to enhance dashboard reload performance with slow data sources | +| `incrementalQueryOverlapWindow` | string | Prometheus | Experimental: Configure incremental query overlap window. Requires a valid duration string, for example, `180s` or `15m` Default value is `10m` (10 minutes). | +| `disableRecordingRules` | boolean | Prometheus | Experimental: Turn off Prometheus recording rules | +| `implementation` | string | Alertmanager | The implementation of the Alertmanager data source, such as `prometheus`, `cortex` or `mimir` | +| `handleGrafanaManagedAlerts` | boolean | Alertmanager | When enabled, Grafana-managed alerts are sent to this Alertmanager | + {{< admonition type="note" >}} Data sources tagged with _HTTP\*_ communicate using the HTTP protocol, which includes all core data source plugins except MySQL, PostgreSQL, and MSSQL. {{< /admonition >}} -| Name | Type | Data source | Description | -| ----------------------------- | ------- | ---------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| tlsAuth | boolean | _HTTP\*_, MySQL | Enable TLS authentication using client cert configured in secure json data | -| tlsAuthWithCACert | boolean | _HTTP\*_, MySQL, PostgreSQL | Enable TLS authentication using CA cert | -| tlsSkipVerify | boolean | _HTTP\*_, MySQL, PostgreSQL, MSSQL | Controls whether a client verifies the server's certificate chain and host name. | -| serverName | string | _HTTP\*_, MSSQL | Optional. Controls the server name used for certificate common name/subject alternative name verification. Defaults to using the data source URL. | -| timeout | string | _HTTP\*_ | Request timeout in seconds. Overrides dataproxy.timeout option | -| graphiteVersion | string | Graphite | Graphite version | -| timeInterval | string | Prometheus, Elasticsearch, InfluxDB, MySQL, PostgreSQL and MSSQL | Lowest interval/step value that should be used for this data source. | -| httpMode | string | Influxdb | HTTP Method. 'GET', 'POST', defaults to GET | -| maxSeries | number | Influxdb | Max number of series/tables that Grafana processes | -| httpMethod | string | Prometheus | HTTP Method. 'GET', 'POST', defaults to POST | -| customQueryParameters | string | Prometheus | Query parameters to add, as a URL-encoded string. | -| manageAlerts | boolean | Prometheus and Loki | Manage alerts via Alerting UI | -| alertmanagerUid | string | Prometheus and Loki | UID of Alert Manager that manages Alert for this data source. | -| timeField | string | Elasticsearch | Which field that should be used as timestamp | -| interval | string | Elasticsearch | Index date time format. nil(No Pattern), 'Hourly', 'Daily', 'Weekly', 'Monthly' or 'Yearly' | -| logMessageField | string | Elasticsearch | Which field should be used as the log message | -| logLevelField | string | Elasticsearch | Which field should be used to indicate the priority of the log message | -| maxConcurrentShardRequests | number | Elasticsearch | Maximum number of concurrent shard requests that each sub-search request executes per node | -| sigV4Auth | boolean | Elasticsearch and Prometheus | Enable usage of SigV4 | -| sigV4AuthType | string | Elasticsearch and Prometheus | SigV4 auth provider. default/credentials/keys | -| sigV4ExternalId | string | Elasticsearch and Prometheus | Optional SigV4 External ID | -| sigV4AssumeRoleArn | string | Elasticsearch and Prometheus | Optional SigV4 ARN role to assume | -| sigV4Region | string | Elasticsearch and Prometheus | SigV4 AWS region | -| sigV4Profile | string | Elasticsearch and Prometheus | Optional SigV4 credentials profile | -| authType | string | Cloudwatch | Auth provider. default/credentials/keys | -| externalId | string | Cloudwatch | Optional External ID | -| assumeRoleArn | string | Cloudwatch | Optional ARN role to assume | -| defaultRegion | string | Cloudwatch | Optional default AWS region | -| customMetricsNamespaces | string | Cloudwatch | Namespaces of Custom Metrics | -| profile | string | Cloudwatch | Optional credentials profile | -| tsdbVersion | string | OpenTSDB | Version | -| tsdbResolution | string | OpenTSDB | Resolution | -| sslmode | string | PostgreSQL | SSLmode. 'disable', 'require', 'verify-ca' or 'verify-full' | -| tlsConfigurationMethod | string | PostgreSQL | SSL Certificate configuration, either by 'file-path' or 'file-content' | -| sslRootCertFile | string | PostgreSQL, MSSQL | SSL server root certificate file, must be readable by the Grafana user | -| sslCertFile | string | PostgreSQL | SSL client certificate file, must be readable by the Grafana user | -| sslKeyFile | string | PostgreSQL | SSL client key file, must be readable by _only_ the Grafana user | -| encrypt | string | MSSQL | Determines SSL encryption handling. Options include: `disable` - data sent between client and server is not encrypted; `false` - data sent between client and server is not encrypted beyond the login packet; `true` - data sent between client and server is encrypted. Default is `false`. | -| postgresVersion | number | PostgreSQL | Postgres version as a number (903/904/905/906/1000) meaning v9.3, v9.4, ..., v10 | -| timescaledb | boolean | PostgreSQL | Enable usage of TimescaleDB extension | -| maxOpenConns | number | MySQL, PostgreSQL and MSSQL | Maximum number of open connections to the database | -| maxIdleConns | number | MySQL, PostgreSQL and MSSQL | Maximum number of connections in the idle connection pool | -| connMaxLifetime | number | MySQL, PostgreSQL and MSSQL | Maximum amount of time in seconds a connection may be reused | -| keepCookies | array | _HTTP\*_ | Cookies that needs to be passed along while communicating with data sources | -| prometheusVersion | string | Prometheus | The version of the Prometheus data source, such as `2.37.0`, `2.24.0` | -| prometheusType | string | Prometheus | Prometheus database type. Options are `Prometheus`, `Cortex`, `Mimir` or`Thanos`. | -| cacheLevel | string | Prometheus | Determines the duration of the browser cache. Valid values include: `Low`, `Medium`, `High`, and `None`. This field is configurable when you enable the `prometheusResourceBrowserCache` feature flag. | -| incrementalQuerying | string | Prometheus | Experimental: Turn on incremental querying to enhance dashboard reload performance with slow data sources | -| incrementalQueryOverlapWindow | string | Prometheus | Experimental: Configure incremental query overlap window. Requires a valid duration string, i.e. `180s` or `15m` Default value is `10m` (10 minutes). | -| disableRecordingRules | boolean | Prometheus | Experimental: Turn off Prometheus recording rules | -| implementation | string | AlertManager | The implementation of the AlertManager data source, such as `prometheus`, `cortex` or `mimir` | -| handleGrafanaManagedAlerts | boolean | AlertManager | When enabled, Grafana-managed alerts are sent to this Alertmanager | - For examples of specific data sources' JSON data, refer to that [data source's documentation](../../datasources/). -#### Secure JSON Data +#### Secure JSON data -Secure JSON data is a map of settings that are encrypted with a [secret key](../../setup-grafana/configure-grafana/#secret_key) from the Grafana configuration. -The encryption hides content from the users of the application. -This should be used for storing the TLS Cert and password that Grafana appends to the request on the server side. +Secure JSON data is a map of settings encrypted with a [secret key](../../setup-grafana/configure-grafana/#secret_key). +The encryption hides the JSON data from the users of Grafana. +You should use secure JSON data to store TLS certificates and passwords for data source HTTP requests. All of these settings are optional. -{{< admonition type="note" >}} -The _HTTP\*_ tag denotes data sources that communicate using the HTTP protocol, including all core data source plugins except MySQL, PostgreSQL, and MS SQL. -{{< /admonition >}} +| Name | Type | Data source | Description | +| ------------------- | ------ | ---------------------------------- | -------------------------------------------------------- | +| `tlsCACert` | string | _HTTP\*_, MySQL, PostgreSQL | CA cert for out going requests | +| `tlsClientCert` | string | _HTTP\*_, MySQL, PostgreSQL | TLS Client cert for outgoing requests | +| `tlsClientKey` | string | _HTTP\*_, MySQL, PostgreSQL | TLS Client key for outgoing requests | +| `password` | string | _HTTP\*_, MySQL, PostgreSQL, MSSQL | password | +| `basicAuthPassword` | string | _HTTP\*_ | password for basic authentication | +| `accessKey` | string | Amazon CloudWatch | Access key for connecting to Amazon CloudWatch | +| `secretKey` | string | Amazon CloudWatch | Secret key for connecting to Amazon CloudWatch | +| `sigV4AccessKey` | string | Elasticsearch and Prometheus | SigV4 access key. Required when using keys auth provider | +| `sigV4SecretKey` | string | Elasticsearch and Prometheus | SigV4 secret key. Required when using keys auth provider | -| Name | Type | Data source | Description | -| ----------------- | ------ | ---------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------- | -| tlsCACert | string | _HTTP\*_, MySQL, PostgreSQL | CA cert for out going requests. You can point directly to your stored cert by using an environment variable following the `$__file{path/to/ca}` format. | -| tlsClientCert | string | _HTTP\*_, MySQL, PostgreSQL | TLS Client cert for outgoing requests. You can point directly to your stored cert by using an environment variable following the `$__file{path/to/cert}` format. | -| tlsClientKey | string | _HTTP\*_, MySQL, PostgreSQL | TLS Client key for outgoing requests. You can point directly to your stored key by using an environment variable following the `$__file{path/to/key}` format. | -| password | string | _HTTP\*_, MySQL, PostgreSQL, MSSQL | password | -| basicAuthPassword | string | _HTTP\*_ | password for basic authentication | -| accessKey | string | Cloudwatch | Access key for connecting to Cloudwatch | -| secretKey | string | Cloudwatch | Secret key for connecting to Cloudwatch | -| sigV4AccessKey | string | Elasticsearch and Prometheus | SigV4 access key. Required when using keys auth provider | -| sigV4SecretKey | string | Elasticsearch and Prometheus | SigV4 secret key. Required when using keys auth provider | +{{< admonition type="note" >}} +The _HTTP\*_ tag denotes data sources that communicate using the HTTP protocol, including all core data source plugins except MySQL, PostgreSQL, and MSSQL. +{{< /admonition >}} #### Custom HTTP headers for data sources -Data sources managed with provisioning can be configured to add HTTP headers to all requests. +You can add HTTP headers to all requests sent to data sources managed by Grafana provisioning Configure the header name in the `jsonData` field and the header value in `secureJsonData`. +The following example sets the `HeaderName` header to have the value `HeaderValue` and the `Authorization` header to have the value `Bearer XXXXXXXXX`: ```yaml apiVersion: 1 @@ -286,12 +284,12 @@ datasources: ## Plugins You can manage plugin applications in Grafana by adding one or more YAML configuration files in the [`provisioning/plugins`](../../setup-grafana/configure-grafana/#provisioning) directory. -Each configuration file can contain a list of `apps` that update during start up. -Grafana updates each app to match the configuration file. +Each configuration file contains a list of `apps` that Grafana configures during start up. +Grafana configures each app to use the configuration in the file. {{< admonition type="note" >}} This feature enables you to provision plugin configurations, not the plugins themselves. -The plugins must already be installed on the Grafana instance. +You must have already installed the plugin to use plugin configuration provisioning. {{< /admonition >}} ### Example plugin configuration file @@ -321,9 +319,9 @@ apps: ## Dashboards You can manage dashboards in Grafana by adding one or more YAML configuration files in the [`provisioning/dashboards`](../../setup-grafana/configure-grafana/#dashboards) directory. -Each configuration file can contain a list of `dashboards providers` that load dashboards into Grafana from the local filesystem. +Each configuration file contains a list of `providers` that Grafana uses to load dashboards from the local filesystem. -The dashboard provider configuration file looks somewhat like this: +### Example dashboard configuration file ```yaml apiVersion: 1 @@ -352,53 +350,55 @@ providers: foldersFromFilesStructure: true ``` -When Grafana starts, it updates and inserts all dashboards available in the configured path. -Then later on, Grafana polls that path every **updateIntervalSeconds**, looks for updated JSON files, and updates and inserts those into the database. - -> **Note:** Dashboards are provisioned to the root level if the `folder` option is missing or empty. - -#### Making changes to a provisioned dashboard - -While you can change a provisioned dashboard in the Grafana UI, those changes can't be saved back to the provisioning source. -If `allowUiUpdates` is set to `true` and you make changes to a provisioned dashboard, you can `Save` the dashboard, then changes persist to the Grafana database. +When Grafana starts, it updates or creates all dashboards found in the configured path. +It later polls that path every `updateIntervalSeconds` for updates to the dashboard files and updates its database. {{< admonition type="note" >}} -If a provisioned dashboard is saved from the UI and then later updated from the source, the dashboard stored in the database will always be overwritten. The `version` property in the JSON file won't affect this, even if it's lower than the version of the existing dashboard. - -If a provisioned dashboard is saved from the UI and the source is removed, the dashboard stored in the database is deleted unless the configuration option `disableDeletion` is set to `true`. +Grafana installs dashboards at the root level if you don't set the `folder` field. {{< /admonition >}} -If `allowUiUpdates` is configured to `false`, you are not able to make changes to a provisioned dashboard. When you click `Save`, Grafana brings up a _Cannot save provisioned dashboard_ dialog. The screenshot below illustrates this behavior. +#### Make changes to a provisioned dashboard -Grafana offers options to export the JSON definition of a dashboard. Either `Copy JSON to Clipboard` or `Save JSON to file` can help you synchronize your dashboard changes back to the provisioning source. +You can make changes to a provisioned dashboard in the Grafana UI but its not possible to automatically save the changes back to the provisioning source. +If `allowUiUpdates` is set to `true` and you make changes to a provisioned dashboard, when you save the dashboard, Grafana persists the changes to its database. -{{< admonition type="note" >}} -The JSON definition in the input field when using `Copy JSON to Clipboard` or `Save JSON to file` has the `id` field automatically removed to aid the provisioning workflow. +{{< admonition type="caution" >}} +If you save a provisioned dashboard in the UI and then later update the provisioning source, Grafana always overwrites the database dashboard with the one from the provisioning file. +Grafana ignores the `version` property in the JSON file, even if it's lower than the dashboard in the database. {{< /admonition >}} +{{< admonition type="caution" >}} +If you save a provisioned dashboard in the UI and remove the provisioning source, Grafana deletes the dashboard in the database unless you have set the option `disableDeletion` to `true`. +{{< /admonition >}} + +If you set `allowUiUpdates` to `false`, you can't save changes to a provisioned dashboard. +When you try to save changes to a provisioned dashboard, Grafana brings up a _Cannot save provisioned dashboard_ dialog box. + +Grafana offers options to export the JSON definition of a dashboard. +Use either **Copy JSON to Clipboard** or **Save JSON to file** to sync your dashboard changes back to the provisioning source. +Grafana removes the `id` field from the dashboard JSON to help the provisioning workflow. + +The following screenshot illustrates this behavior. + {{< figure src="/static/img/docs/v51/provisioning_cannot_save_dashboard.png" max-width="500px" class="docs-image--no-shadow" >}} ### Reusable dashboard URLs -If the dashboard in the JSON file contains an [UID](../../dashboards/build-dashboards/view-dashboard-json-model/), Grafana forces insert/update on that UID. -This allows you to migrate dashboards between Grafana instances and provisioning Grafana from configuration without breaking the URLs given because the new dashboard URL uses the UID as identifier. -When Grafana starts, it updates and inserts all dashboards available in the configured folders. -If you modify the file, then the dashboard is also updated. -By default, Grafana deletes dashboards in the database if the file is removed. -You can disable this behavior using the `disableDeletion` setting. +If the dashboard in the JSON file contains an [UID](../../dashboards/build-dashboards/view-dashboard-json-model/), Grafana updates that the dashboard with that UID in the database. +This lets you migrate dashboards between Grafana instances and keep consistent dashboard URLs. +When Grafana starts, it creates or updates all dashboards available in the configured folders. -{{< admonition type="note" >}} -Provisioning allows you to overwrite existing dashboards -which leads to problems if you reuse settings that are supposed to be unique. -Be careful not to reuse the same `title` multiple times within a folder -or `uid` within the same installation as this causes weird behaviors. +{{< admonition type="caution" >}} +You can overwrite existing dashboards with provisioning. + +Be careful not to reuse the same `title` multiple times within a folder or `uid` within the same Grafana instance to avoid inconsistent behavior. {{< /admonition >}} ### Provision folders structure from filesystem to Grafana -If you already store your dashboards using folders in a git repo or on a filesystem, and also you want to have the same folder names in the Grafana menu, you can use `foldersFromFilesStructure` option. +If you already store your dashboards using folders in a Git repository or on a filesystem, and want to have the same folder names in the Grafana menu, use `foldersFromFilesStructure` option. -For example, to replicate these dashboards structure from the filesystem to Grafana, +For example, to replicate the following dashboards structure from the filesystem to Grafana: ``` /etc/dashboards @@ -410,7 +410,7 @@ For example, to replicate these dashboards structure from the filesystem to Graf └── /resources_dashboard.json ``` -You need to specify just this short provision configuration file. +use the following provisioning configuration file: ```yaml apiVersion: 1 @@ -424,14 +424,14 @@ providers: foldersFromFilesStructure: true ``` -In this example, `server` and `application` become new folders in the Grafana menu. +Grafana creates the `server` and `application` folders in the UI. -{{< admonition type="note" >}} -The `folder` and `folderUid` options should be empty or missing to make `foldersFromFilesStructure` work. +To use `foldersFromFilesStructure`, you must unset the `folder` and `folderUid` options. To provision dashboards to the root level, store them in the root of your `path`. -You can't create nested folders structures, where you have folders within folders. +{{< admonition type="note" >}} +This feature doesn't let you create nested folder structures, where you have folders within folders. {{< /admonition >}} ## Alerting @@ -440,212 +440,223 @@ For information on provisioning Grafana Alerting, refer to [Provision Grafana Al ### Supported settings -The following sections detail the supported settings and secure settings for each alert notification type. Secure settings are stored encrypted in the database and you add them to `secure_settings` in the YAML file instead of `settings`. +The following sections detail the supported settings and secure settings for each alert notification type. +In the provisioning YAML use `settings` for settings and `secure_settings` for secure settings. +Grafana encrypts secure settings in the database. #### Alert notification `pushover` -| Name | Secure setting | -| ---------- | -------------- | -| apiToken | yes | -| userKey | yes | -| device | | -| priority | | -| okPriority | | -| retry | | -| expire | | -| sound | | -| okSound | | +| Name | Secure setting | +| ------------ | -------------- | +| `apiToken` | yes | +| `userKey` | yes | +| `device` | | +| `priority` | | +| `okPriority` | | +| `retry` | | +| `expire` | | +| `sound` | | +| `okSound` | | #### Alert notification `discord` -| Name | Secure setting | -| -------------------- | -------------- | -| url | yes | -| avatar_url | | -| content | | -| use_discord_username | | +| Name | Secure setting | +| ---------------------- | -------------- | +| `url` | yes | +| `avatar_url` | | +| `content` | | +| `use_discord_username` | | #### Alert notification `slack` -| Name | Secure setting | -| -------------- | -------------- | -| url | yes | -| recipient | | -| username | | -| icon_emoji | | -| icon_url | | -| uploadImage | | -| mentionUsers | | -| mentionGroups | | -| mentionChannel | | -| token | yes | -| color | | +| Name | Secure setting | +| ---------------- | -------------- | +| `url` | yes | +| `recipient` | | +| `username` | | +| `icon_emoji` | | +| `icon_url` | | +| `uploadImage` | | +| `mentionUsers` | | +| `mentionGroups` | | +| `mentionChannel` | | +| `token` | yes | +| `color` | | #### Alert notification `victorops` -| Name | -| ----------- | -| url | -| autoResolve | +| Name | +| ------------- | +| `url` | +| `autoResolve` | #### Alert notification `kafka` -| Name | -| -------------- | -| kafkaRestProxy | -| kafkaTopic | +| Name | +| ---------------- | +| `kafkaRestProxy` | +| `kafkaTopic` | #### Alert notification `LINE` -| Name | Secure setting | -| ----- | -------------- | -| token | yes | +| Name | Secure setting | +| ------- | -------------- | +| `token` | yes | #### Alert notification `MQTT` -| Name | Secure setting | -| ------------- | -------------- | -| brokerUrl | | -| clientId | | -| topic | | -| messageFormat | | -| username | | -| password | yes | -| retain | | -| qos | | -| tlsConfig | | +| Name | Secure setting | +| --------------- | -------------- | +| `brokerUrl` | | +| `clientId` | | +| `topic` | | +| `messageFormat` | | +| `username` | | +| `password` | yes | +| `retain` | | +| `qos` | | +| `tlsConfig` | | -##### TLS config +##### TLS configuration -| Name | Secure setting | -| ------------------ | -------------- | -| insecureSkipVerify | | -| clientCertificate | yes | -| clientKey | yes | -| caCertificate | yes | +| Name | Secure setting | +| -------------------- | -------------- | +| `insecureSkipVerify` | | +| `clientCertificate` | yes | +| `clientKey` | yes | +| `caCertificate` | yes | #### Alert notification `pagerduty` -| Name | Secure setting | -| -------------- | -------------- | -| integrationKey | yes | -| autoResolve | | +| Name | Secure setting | +| ---------------- | -------------- | +| `integrationKey` | yes | +| `autoResolve` | | #### Alert notification `sensu` -| Name | Secure setting | -| -------- | -------------- | -| url | | -| source | | -| handler | | -| username | | -| password | yes | +| Name | Secure setting | +| ---------- | -------------- | +| `url` | | +| `source` | | +| `handler` | | +| `username` | | +| `password` | yes | #### Alert notification `sensugo` -| Name | Secure setting | -| --------- | -------------- | -| url | | -| apikey | yes | -| entity | | -| check | | -| handler | | -| namespace | | +| Name | Secure setting | +| ----------- | -------------- | +| `url` | | +| `apikey` | yes | +| `entity` | | +| `check` | | +| `handler` | | +| `namespace` | | #### Alert notification `prometheus-alertmanager` -| Name | Secure setting | -| ----------------- | -------------- | -| url | | -| basicAuthUser | | -| basicAuthPassword | yes | +| Name | Secure setting | +| ------------------- | -------------- | +| `url` | | +| `basicAuthUser` | | +| `basicAuthPassword` | yes | #### Alert notification `teams` -| Name | -| ---- | -| url | +| Name | Secure setting | +| ----- | -------------- | +| `url` | | #### Alert notification `dingding` -| Name | -| ---- | -| url | +| Name | Secure setting | +| ----- | -------------- | +| `url` | | #### Alert notification `email` -| Name | -| ----------- | -| singleEmail | -| addresses | +| Name | Secure setting | +| ------------- | -------------- | +| `singleEmail` | | +| `addresses` | | #### Alert notification `hipchat` -| Name | -| ------ | -| url | -| apikey | -| roomid | +| Name | Secure setting | +| -------- | -------------- | +| `url` | | +| `apikey` | | +| `roomid` | | #### Alert notification `opsgenie` -| Name | Secure setting | -| ---------------- | -------------- | -| apiKey | yes | -| apiUrl | | -| autoClose | | -| overridePriority | | -| sendTagsAs | | +| Name | Secure setting | +| ------------------ | -------------- | +| `apiKey` | yes | +| `apiUrl` | | +| `autoClose` | | +| `overridePriority` | | +| `sendTagsAs` | | #### Alert notification `telegram` -| Name | Secure setting | -| ----------- | -------------- | -| bottoken | yes | -| chatid | | -| uploadImage | | +| Name | Secure setting | +| ------------- | -------------- | +| `bottoken` | yes | +| `chatid` | | +| `uploadImage` | | #### Alert notification `threema` -| Name | Secure setting | -| ------------ | -------------- | -| gateway_id | | -| recipient_id | | -| api_secret | yes | +| Name | Secure setting | +| -------------- | -------------- | +| `gateway_id` | | +| `recipient_id` | | +| `api_secret` | yes | #### Alert notification `webhook` -| Name | Secure setting | -| ----------- | -------------- | -| url | | -| http_method | | -| username | | -| password | yes | -| tls_config | | +| Name | Secure setting | +| ------------- | -------------- | +| `url` | | +| `http_method` | | +| `username` | | +| `password` | yes | +| `tls_config` | | +| `hmac_config` | | -##### TLS config +##### TLS configuration -| Name | Secure setting | -| ------------------ | -------------- | -| insecureSkipVerify | | -| clientCertificate | yes | -| clientKey | yes | -| caCertificate | yes | +| Name | Secure setting | +| -------------------- | -------------- | +| `insecureSkipVerify` | | +| `clientCertificate` | yes | +| `clientKey` | yes | +| `caCertificate` | yes | + +##### HMAC signature configuration + +| Name | Secure setting | +| ----------------- | -------------- | +| `secret` | yes | +| `header` | | +| `timestampHeader` | | #### Alert notification `googlechat` -| Name | -| ---- | -| url | +| Name | Secure setting | +| ----- | -------------- | +| `url` | | #### Alert notification `Cisco Webex Teams` -| Name | Secure setting | -| --------- | -------------- | -| message | | -| room_id | | -| api_url | | -| bot_token | yes | +| Name | Secure setting | +| ----------- | -------------- | +| `message` | | +| `room_id` | | +| `api_url` | | +| `bot_token` | yes | ## Grafana Enterprise diff --git a/docs/sources/administration/roles-and-permissions/access-control/rbac-terraform-provisioning/index.md b/docs/sources/administration/roles-and-permissions/access-control/rbac-terraform-provisioning/index.md index ce6acbaf2b5..e262d6bc8d6 100644 --- a/docs/sources/administration/roles-and-permissions/access-control/rbac-terraform-provisioning/index.md +++ b/docs/sources/administration/roles-and-permissions/access-control/rbac-terraform-provisioning/index.md @@ -93,6 +93,75 @@ provider "grafana" { } ``` +## Provision basic roles + +The following example shows how to assign basic roles to users, teams, and service accounts. Basic roles are predefined in Grafana and provide a set of permissions for common use cases. + +| Basic role | UID | +| --------------- | --------------------- | +| `None` | `basic_none` | +| `Viewer` | `basic_viewer` | +| `Editor` | `basic_editor` | +| `Admin` | `basic_admin` | +| `Grafana Admin` | `basic_grafana_admin` | + +You can use any of the basic role UIDs from the table above in your role assignments. For example, to assign the "None" role, use `basic_none` as the `role_uid`. + +```terraform +resource "grafana_team" "viewer_team" { + name = "terraform_viewer_team" +} + +resource "grafana_user" "editor_user" { + email = "terraform_editor@example.com" + login = "terraform_editor_user" + password = +} + +resource "grafana_service_account" "admin_sa" { + name = "terraform_admin_sa" +} + +# Assign Viewer role to a team +resource "grafana_role_assignment" "viewer_role_assignment" { + role_uid = "basic_viewer" + teams = [grafana_team.viewer_team.id] +} + +# Assign Editor role to a user +resource "grafana_role_assignment" "editor_role_assignment" { + role_uid = "basic_editor" + users = [grafana_user.editor_user.id] +} + +# Assign Admin role to a service account +resource "grafana_role_assignment" "admin_role_assignment" { + role_uid = "basic_admin" + service_accounts = [grafana_service_account.admin_sa.id] +} +``` + +### Provision basic role to multiple users + +```terraform +resource "grafana_user" "editor_user_2" { + email = "terraform_editor_2@example.com" + login = "terraform_editor_2_user" + password = +} +resource "grafana_user" "editor_user_3" { + email = "terraform_editor_3@example.com" + login = "terraform_editor_3_user" + password = +} + +# Assign Editor role to multiply users +resource "grafana_role_assignment" "editor_role_assignment" { + role_uid = "basic_editor" + users = [grafana_user.editor_user_2.id, grafana_user.editor_user_3.id] +} +``` + ## Provision custom roles The following example shows how to provision a custom role with some permissions. diff --git a/docs/sources/alerting/alerting-rules/link-alert-rules-to-panels.md b/docs/sources/alerting/alerting-rules/link-alert-rules-to-panels.md index 746cb778052..78cce1a5efa 100644 --- a/docs/sources/alerting/alerting-rules/link-alert-rules-to-panels.md +++ b/docs/sources/alerting/alerting-rules/link-alert-rules-to-panels.md @@ -33,6 +33,11 @@ refs: destination: /docs/grafana//alerting/monitor-status/view-alert-state/#view-alert-state-on-panels - pattern: /docs/grafana-cloud/ destination: /docs/grafana-cloud/alerting-and-irm/alerting/monitor-status/view-alert-state/#view-alert-state-on-panels + images-in-notifications: + - pattern: /docs/grafana/ + destination: /docs/grafana//alerting/configure-notifications/template-notifications/images-in-notifications/ + - pattern: /docs/grafana-cloud/ + destination: /docs/grafana-cloud/alerting-and-irm/alerting/configure-notifications/template-notifications/images-in-notifications/ --- # Create and link alert rules to panels @@ -41,13 +46,10 @@ Grafana allows you to link an alert rule to a dashboard panel. This can help you - Inform alert responders about where to investigate and which data to examine. - Visualize the alert state directly from dashboards. +- Include a screenshot of the panel in notification messages. An alert rule is linked to a panel by setting the [`dashboardUId` and `panelId` annotations](ref:annotations). Both annotations must be set together. -{{% admonition type="tutorial" %}} -For a hands-on example of integrating alert rules with dashboards, check out [Part 5 of our Get Started with Grafana Alerting tutorial](http://www.grafana.com/tutorials/alerting-get-started-pt5/). -{{% /admonition %}} - ## Link alert rules to panels When configuring the alert rule, you can set the dashboard and panel annotations as shown in this [video](https://youtu.be/ClLp-iSoaSY?si=qKWnvSVaQuvYcuw9&t=170). @@ -59,6 +61,8 @@ When configuring the alert rule, you can set the dashboard and panel annotations You can then [view the alert state on the panel](ref:view-alert-state-on-panels). +By default, notification messages include a link to the dashboard panel. Additionally, you can [enable displaying panel screenshots in notifications](ref:images-in-notifications). + {{< figure src="/media/docs/alerting/panel-displays-alert-state.png" max-width="1200px" caption="A panel displaying the alert status and state changes." >}} ## Create alert rules from panels @@ -75,6 +79,8 @@ To streamline alert creation, you can create an alert rule directly from a panel You can then [view the alert state on the panel](ref:view-alert-state-on-panels). +By default, notification messages include a link to the dashboard panel. Additionally, you can [enable displaying panel screenshots in notifications](ref:images-in-notifications). + {{% admonition type="note" %}} Changes to panel and alert rule queries aren't synchronized. If you change a query, you have to update it in both the panel and the alert rule. {{% /admonition %}} @@ -86,3 +92,7 @@ This option is available only in [time series panels](ref:time-series-visualizat 1. Hover over the top-right corner of the panel and click the panel menu icon. 1. Click **Edit**. 1. Click the **Alert** tab to view existing alert rules or create a new one. + +{{< admonition type="tip" >}} +For a practical example that links a panel to an alert rule, refer to [Part 5 of our Get Started with Grafana Alerting tutorial](http://www.grafana.com/tutorials/alerting-get-started-pt5/). +{{% /admonition %}} diff --git a/docs/sources/alerting/alerting-rules/templates/_index.md b/docs/sources/alerting/alerting-rules/templates/_index.md index f6da85e1977..cb12bf47513 100644 --- a/docs/sources/alerting/alerting-rules/templates/_index.md +++ b/docs/sources/alerting/alerting-rules/templates/_index.md @@ -176,7 +176,7 @@ Template labels when the labels returned by your queries are insufficient. For i Here’s an example of templating a `severity` label based on the query value. -``` +```go {{ if (gt $values.A.Value 90.0) -}} critical {{ else if (gt $values.A.Value 80.0) -}} diff --git a/docs/sources/alerting/configure-notifications/manage-contact-points/integrations/webhook-notifier.md b/docs/sources/alerting/configure-notifications/manage-contact-points/integrations/webhook-notifier.md index e7741ac3b56..bf4e0cc90fe 100644 --- a/docs/sources/alerting/configure-notifications/manage-contact-points/integrations/webhook-notifier.md +++ b/docs/sources/alerting/configure-notifications/manage-contact-points/integrations/webhook-notifier.md @@ -72,6 +72,7 @@ For more details on contact points, including how to test them and enable notifi | Authentication Header Credentials | Credentials for the `Authorization` Request header. | | Max Alerts | Maximum number of alerts to include in a notification. Any alerts exceeding this limit are ignored. `0` means no limit. | | TLS | TLS configuration options, including CA certificate, client certificate, and client key. | +| HMAC Signature | HMAC signature configuration options. | {{< admonition type="note" >}} @@ -79,6 +80,37 @@ You can configure either HTTP Basic Authentication or the Authorization request {{< /admonition >}} +#### HMAC signature + +You can secure your webhook notifications using HMAC signatures to verify the authenticity and integrity of the requests. When enabled, Grafana signs the webhook payload with a shared secret using HMAC-SHA256. + +| Option | Description | +| ---------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | +| Secret | The shared secret key used to generate the HMAC signature. | +| Header | The HTTP header where the signature will be set. Default is `X-Grafana-Alerting-Signature`. | +| Timestamp Header | Optional header to include a timestamp in the signature calculation. When specified, Grafana will set a Unix timestamp in this header and include it in the HMAC calculation. This provides protection against replay attacks. | + +When HMAC signing is configured, Grafana generates a signature using HMAC-SHA256 with your secret key. If a timestamp header is specified, a Unix timestamp is included in the signature calculation. The signature is calculated as: + +``` +HMAC(timestamp + ":" + body) +``` + +The timestamp is sent in the specified header. If no timestamp header is specified, the signature is calculated just from the request body. The signature is sent as a hex-encoded string in the specified signature header. + +##### Validate a request + +To validate incoming webhook requests from Grafana, follow these steps: + +1. Extract the signature from the header (default is `X-Grafana-Alerting-Signature`). +2. If you configured a timestamp header, extract the timestamp value and verify it's recent to prevent replay attacks. +3. Calculate the expected signature: + - Create an HMAC-SHA256 hash using your shared secret + - If using timestamps, include the timestamp followed by a colon (`:`) before the request body + - Hash the raw request body + - Convert the result to a hexadecimal string +4. Compare the calculated signature with the one in the request header. + #### Optional settings using templates Use the following settings to include custom data within the [JSON payload](#body). Both options support using [notification templates](ref:notification-templates). diff --git a/docs/sources/alerting/fundamentals/alert-rule-evaluation/state-and-health.md b/docs/sources/alerting/fundamentals/alert-rule-evaluation/state-and-health.md index 4c871e2d6e7..5438c8c377b 100644 --- a/docs/sources/alerting/fundamentals/alert-rule-evaluation/state-and-health.md +++ b/docs/sources/alerting/fundamentals/alert-rule-evaluation/state-and-health.md @@ -52,14 +52,16 @@ An alert instance can be in either of the following states: | **No Data\*** | The state of an alert whose query returns no data or all values are null.
An alert in this state generates a new [DatasourceNoData alert](#no-data-and-error-alerts). You can [modify the default behavior of the no data state](#modify-the-no-data-or-error-state). | | **Error\*** | The state of an alert when an error or timeout occurred evaluating the alert rule.
An alert in this state generates a new [DatasourceError alert](#no-data-and-error-alerts). You can [modify the default behavior of the error state](#modify-the-no-data-or-error-state). | +If an alert rule changes (except for updates to annotations, the evaluation interval, or other internal fields), its alert instances reset to the `Normal` state. The alert instance state then updates accordingly during the next evaluation. + +{{< figure src="/media/docs/alerting/alert-instance-states-v3.png" caption="Alert instance state diagram" alt="A diagram of the distinct alert instance states and transitions." max-width="750px" >}} + {{< admonition type="note" >}} `No Data` and `Error` states are supported only for Grafana-managed alert rules. {{< /admonition >}} -{{< figure src="/media/docs/alerting/alert-instance-states-v3.png" caption="Alert instance state diagram" alt="A diagram of the distinct alert instance states and transitions." max-width="750px" >}} - ### Notification routing Alert instances will be routed for [notifications](ref:notifications) when they are in the `Alerting` state or have been `Resolved`, transitioning from `Alerting` to `Normal` state. diff --git a/docs/sources/alerting/fundamentals/alert-rules/annotation-label.md b/docs/sources/alerting/fundamentals/alert-rules/annotation-label.md index 41d3c4c0220..ade6b016049 100644 --- a/docs/sources/alerting/fundamentals/alert-rules/annotation-label.md +++ b/docs/sources/alerting/fundamentals/alert-rules/annotation-label.md @@ -136,6 +136,8 @@ If multiple label keys are sanitized to the same value, the duplicates have a sh Annotations add additional information to alert instances, helping responders identify and address potential issues. +Create clear and self-explanatory annotations so that first responders can investigate without needing deeper knowledge of the alert setup. + Annotations are displayed in Grafana and are included by default in notifications. Grafana provides several optional annotations that you can edit: - `summary`: A short summary of what the alert has detected and why. diff --git a/docs/sources/alerting/fundamentals/notifications/group-alert-notifications.md b/docs/sources/alerting/fundamentals/notifications/group-alert-notifications.md index 8e2eab652e8..64b1e83ef54 100644 --- a/docs/sources/alerting/fundamentals/notifications/group-alert-notifications.md +++ b/docs/sources/alerting/fundamentals/notifications/group-alert-notifications.md @@ -55,7 +55,7 @@ Alert instances are grouped together if they have the same exact label values fo For example, given the `Group by` option set to the `team` label: - `alertname:foo, team=frontend`, and `alertname:bar, team=frontend` are in one group. -- `alertname:foo, team=backend`, and `alertname:qux, team=backend` are in another group. +- `alertname:foo, team=frontend`, and `alertname:qux, team=backend` are in another group. ### Group by alert rule or labels @@ -99,7 +99,9 @@ flowchart LR Group wait is the duration Grafana waits before sending the first notification for a new group of alerts. -The longer the group wait, the more time other alerts have to be included in the initial notification of the new group. The shorter the group wait, the earlier the first notification is sent, but at the risk of not including some alerts. +This option helps reduce the number of notifications sent for related alerts occurring within a short time frame. The longer the group wait, the more time other alerts have to be included in the initial notification of the new group. The shorter the group wait, the earlier the first notification is sent, but at the risk of not including some alerts. + +If an alert is resolved before the duration elapses, no notification is sent for that alert. This reduces noise from flapping alerts. **Example** @@ -125,7 +127,10 @@ Consider a notification policy that: If an alert was too late to be included in the first notification due to group wait, it is included in subsequent notifications after group interval. -Group interval is the duration to wait before sending notifications about group changes. For instance, a group change may be adding a new firing alert to the group, or resolving an existing alert. +Group interval is the duration to wait before sending notifications about group changes. A group change occurs when: + +- A new firing alert is added to the group. +- An existing alert is resolved. **Example** @@ -170,6 +175,8 @@ Repeat interval is evaluated every time the group interval resets. If the alert Repeat interval must not only be greater than or equal to group interval, but also must be a multiple of Group interval. If Repeat interval is not a multiple of group interval it is coerced into one. For example, if your Group interval is 5 minutes, and your Repeat interval is 9 minutes, the Repeat interval is rounded up to the nearest multiple of 5 which is 10 minutes. +The maximum duration of the repeat interval is 5 days, constrained by the default value of the `notification_log_retention` setting in Grafana. + **Example** Here are the related excerpts from the previous example: diff --git a/docs/sources/alerting/fundamentals/templates.md b/docs/sources/alerting/fundamentals/templates.md index 3b2fa4de8c5..4e4243aee9c 100644 --- a/docs/sources/alerting/fundamentals/templates.md +++ b/docs/sources/alerting/fundamentals/templates.md @@ -63,6 +63,7 @@ In Grafana, you have various options to template your alert notification message - Labels are used to differentiate an alert instance from all other alert instances. - Template labels to add an additional label based on a query value, or when the labels from the query are incomplete or not descriptive enough. + - Avoid displaying query values in labels as this can create numerous alert instances—use annotations instead. 1. [Notification templates](#template-notifications) - Notification templates are used by contact points for consistent messaging in notification titles and descriptions. @@ -124,18 +125,16 @@ You can also template labels based on query results. This is helpful if the labe - Add a new label to change how alerts are identified and grouped into different alert groups. - Add a new label used by notification policies or silences to manage how the alert is handled. -Here’s an example of templating a `severity` label based on the query value: +Here’s an example of templating a new `env` label based on the value of a query label: ```go -{{ if (gt $values.A.Value 90.0) -}} -critical -{{ else if (gt $values.A.Value 80.0) -}} -high -{{ else if (gt $values.A.Value 60.0) -}} -medium -{{ else -}} -low -{{- end }} +{{- if eq $labels.instance "prod-server-1" -}} +production +{{- else if eq $labels.instance "staging-server-1" -}} +staging +{{- else -}} +development +{{- end -}} ``` For more details on how to template labels, refer to [Template annotations and labels](ref:templating-labels-annotations). diff --git a/docs/sources/alerting/monitor-status/view-alert-rules.md b/docs/sources/alerting/monitor-status/view-alert-rules.md index 293faf3a0cf..2d7a404b90b 100644 --- a/docs/sources/alerting/monitor-status/view-alert-rules.md +++ b/docs/sources/alerting/monitor-status/view-alert-rules.md @@ -59,13 +59,14 @@ Select a group to expand it and view the list of alert rules within that group. For details on how rule states and alert instance states are displayed, refer to [View alert state](ref:view-alert-state). -## View and compare alert rules versions. +## View, compare and restore alert rules versions. -To view previous alert rules for an alert, complete the following steps. +To view or restore previous versions for an alert rule, complete the following steps. 1. Navigate to **Alerts & IRM -> Alerting -> Alert rules**. 1. Select an alert rule and click **View**. 1. Click the **Versions** tab. The page displays a list of the previous rule versions. -On the Alert rule's Versions page you can view and compare the previous rule versions. +On the Alert rule's Versions page you can view, compare and restore the previous rule versions. +{{< figure src="/media/docs/alerting/screenshot-grafana-alerting-version-history-v3.png" max-width="750px" alt="View alert rule history to compare and restore previous alert rules." >}} diff --git a/docs/sources/alerting/set-up/provision-alerting-resources/export-alerting-resources/index.md b/docs/sources/alerting/set-up/provision-alerting-resources/export-alerting-resources/index.md index 3a6f3576452..a7fac56ebe9 100644 --- a/docs/sources/alerting/set-up/provision-alerting-resources/export-alerting-resources/index.md +++ b/docs/sources/alerting/set-up/provision-alerting-resources/export-alerting-resources/index.md @@ -197,11 +197,7 @@ However, you can export it by manually copying the content and name of the notif All notification policies are provisioned through a single resource: the root of the notification policy tree. -{{% admonition type="warning" %}} - -Since the policy tree is a single resource, provisioning it overwrites a policy tree created through any other means. - -{{< /admonition >}} +{{< docs/shared lookup="alerts/warning-provisioning-tree.md" source="grafana" version="" >}} To export the notification policy tree from the Grafana UI, complete the following steps. diff --git a/docs/sources/alerting/set-up/provision-alerting-resources/file-provisioning/index.md b/docs/sources/alerting/set-up/provision-alerting-resources/file-provisioning/index.md index 850600cc074..898fdf894bf 100644 --- a/docs/sources/alerting/set-up/provision-alerting-resources/file-provisioning/index.md +++ b/docs/sources/alerting/set-up/provision-alerting-resources/file-provisioning/index.md @@ -628,6 +628,13 @@ settings: clientKey: key in PEM format # caCertificate: CA certificate in PEM format + hmacConfig: + # + secret: secret-key + # + header: X-Grafana-Alerting-Signature + # + timestampHeader: X-Grafana-Alerting-Signature-Timestamp ``` {{< /collapse >}} @@ -702,11 +709,7 @@ Create or reset the notification policy tree using provisioning files in your Gr In Grafana, the entire notification policy tree is considered a single, large resource. Add new specific policies as sub-policies under the root policy. Since specific policies may depend on each other, you cannot provision subsets of the policy tree; the entire tree must be defined in a single place. -{{% admonition type="warning" %}} - -Since the policy tree is a single resource, provisioning it will overwrite a policy tree created through any other means. - -{{< /admonition >}} +{{< docs/shared lookup="alerts/warning-provisioning-tree.md" source="grafana" version="" >}} 1. Find the notification policy tree in Grafana. 1. [Export](ref:export_policies) and download a provisioning file for your notification policy tree. diff --git a/docs/sources/alerting/set-up/provision-alerting-resources/terraform-provisioning/index.md b/docs/sources/alerting/set-up/provision-alerting-resources/terraform-provisioning/index.md index 0821f5ec0b4..2a5f5d97211 100644 --- a/docs/sources/alerting/set-up/provision-alerting-resources/terraform-provisioning/index.md +++ b/docs/sources/alerting/set-up/provision-alerting-resources/terraform-provisioning/index.md @@ -341,11 +341,7 @@ In this section, we'll create Terraform configurations for each alerting resourc [Notification policies](ref:notification-policy) defines how to route alert instances to your contact points. -{{% admonition type="warning" %}} - -Since the policy tree is a single resource, provisioning the `grafana_notification_policy` resource will overwrite a policy tree created through any other means. - -{{< /admonition >}} +{{< docs/shared lookup="alerts/warning-provisioning-tree.md" source="grafana" version="" >}} 1. Find the default notification policy tree. Alternatively, consider writing the resource in code as demonstrated in the example below. diff --git a/docs/sources/datasources/aws-cloudwatch/aws-authentication/index.md b/docs/sources/datasources/aws-cloudwatch/aws-authentication/index.md index 9ae64f44856..6cebd2089fd 100644 --- a/docs/sources/datasources/aws-cloudwatch/aws-authentication/index.md +++ b/docs/sources/datasources/aws-cloudwatch/aws-authentication/index.md @@ -164,7 +164,7 @@ Grafana Assume Role is currently in [private preview](https://grafana.com/docs/r It's currently only available for Amazon CloudWatch. -To get early access this feature, reach out to Customer Support and ask for the `awsDatasourcesTempCredentials` feature toggle to be enabled and the `cloudwatchRemoteDatasource` and `athenaRemoteDatasource` feature toggles to be disabled on your account. +To gain early access to this feature, contact Customer Support and ask for the `awsDatasourcesTempCredentials` feature toggle to be enabled on your account. {{% /admonition %}} The Grafana Assume Role authentication provider lets you authenticate with AWS without having to create and maintain long term AWS users or rotate their access and secret keys. Instead, you can create an IAM role that has permissions to access CloudWatch and a trust relationship with Grafana's AWS account. Grafana's AWS account then makes an STS request to AWS to create temporary credentials to access your AWS data. It makes this STS request by passing along an `externalID` that's unique per Cloud account, to ensure that Grafana Cloud users can only access their own AWS data. For more information, refer to the [AWS documentation on external ID](https://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_create_for-user_externalid.html). diff --git a/docs/sources/setup-grafana/configure-grafana/_index.md b/docs/sources/setup-grafana/configure-grafana/_index.md index 5c7b92515ec..c77d5cab8d7 100644 --- a/docs/sources/setup-grafana/configure-grafana/_index.md +++ b/docs/sources/setup-grafana/configure-grafana/_index.md @@ -491,11 +491,13 @@ Leave empty when using `database` and Grafana uses the primary database. ##### `redis` -Example connection string: `addr=127.0.0.1:6379,pool_size=100,db=0,ssl=false` +Example connection string: `addr=127.0.0.1:6379,pool_size=100,db=0,username=grafana,password=grafanaRocks,ssl=false` - `addr` is the host `:` port of the Redis server. - `pool_size` (optional) is the number of underlying connections that can be made to Redis. - `db` (optional) is the number identifier of the Redis database you want to use. +- `username` (optional) is the connection identifier to authenticate the current connection. +- `password` (optional) is the connection secret to authenticate the current connection. - `ssl` (optional) is if SSL should be used to connect to Redis server. The value may be `true`, `false`, or `insecure`. Setting the value to `insecure` skips verification of the certificate chain and hostname when making the connection. ##### `memcache` @@ -2753,6 +2755,10 @@ Set the default start of the week, valid values are: `saturday`, `sunday`, `mond Set this to `false` to disable expressions and hide them in the Grafana UI. Default is `true`. +#### `sql_expression_cell_limit` + +Set the maximum number of cells that can be passed to a SQL expression. Default is `100000`. + ### `[geomap]` This section controls the defaults settings for **Geomap Plugin**. diff --git a/docs/sources/setup-grafana/configure-grafana/feature-toggles/index.md b/docs/sources/setup-grafana/configure-grafana/feature-toggles/index.md index c401c8dd581..23849201ec7 100644 --- a/docs/sources/setup-grafana/configure-grafana/feature-toggles/index.md +++ b/docs/sources/setup-grafana/configure-grafana/feature-toggles/index.md @@ -21,67 +21,66 @@ For more information about feature release stages, refer to [Release life cycle Most [generally available](https://grafana.com/docs/release-life-cycle/#general-availability) features are enabled by default. You can disable these feature by setting the feature flag to "false" in the configuration. -| Feature toggle name | Description | Enabled by default | -| -------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------ | -| `disableEnvelopeEncryption` | Disable envelope encryption (emergency only) | | -| `publicDashboardsScene` | Enables public dashboard rendering using scenes | Yes | -| `featureHighlights` | Highlight Grafana Enterprise features | | -| `correlations` | Correlations page | Yes | -| `cloudWatchCrossAccountQuerying` | Enables cross-account querying in CloudWatch datasources | Yes | -| `nestedFolders` | Enable folder nesting | Yes | -| `logsContextDatasourceUi` | Allow datasource to provide custom UI for context view | Yes | -| `lokiQuerySplitting` | Split large interval queries into subqueries with smaller time intervals | Yes | -| `influxdbBackendMigration` | Query InfluxDB InfluxQL without the proxy | Yes | -| `dataplaneFrontendFallback` | Support dataplane contract field name change for transformations and field name matchers where the name is different | Yes | -| `unifiedRequestLog` | Writes error logs to the request logger | Yes | -| `recordedQueriesMulti` | Enables writing multiple items from a single query within Recorded Queries | Yes | -| `logsExploreTableVisualisation` | A table visualisation for logs in Explore | Yes | -| `transformationsRedesign` | Enables the transformations redesign | Yes | -| `traceQLStreaming` | Enables response streaming of TraceQL queries of the Tempo data source | | -| `awsAsyncQueryCaching` | Enable caching for async queries for Redshift and Athena. Requires that the datasource has caching and async query support enabled | Yes | -| `alertingNoDataErrorExecution` | Changes how Alerting state manager handles execution of NoData/Error | Yes | -| `angularDeprecationUI` | Display Angular warnings in dashboards and panels | Yes | -| `dashgpt` | Enable AI powered features in dashboards | Yes | -| `alertingInsights` | Show the new alerting insights landing page | Yes | -| `panelMonitoring` | Enables panel monitoring through logs and measurements | Yes | -| `formatString` | Enable format string transformer | Yes | -| `kubernetesPlaylists` | Use the kubernetes API in the frontend for playlists, and route /api/playlist requests to k8s | Yes | -| `recoveryThreshold` | Enables feature recovery threshold (aka hysteresis) for threshold server-side expression | Yes | -| `lokiStructuredMetadata` | Enables the loki data source to request structured metadata from the Loki server | Yes | -| `addFieldFromCalculationStatFunctions` | Add cumulative and window functions to the add field from calculation transformation | Yes | -| `annotationPermissionUpdate` | Change the way annotation permissions work by scoping them to folders and dashboards. | Yes | -| `dashboardSceneForViewers` | Enables dashboard rendering using Scenes for viewer roles | Yes | -| `dashboardSceneSolo` | Enables rendering dashboards using scenes for solo panels | Yes | -| `dashboardScene` | Enables dashboard rendering using scenes for all roles | Yes | -| `ssoSettingsApi` | Enables the SSO settings API and the OAuth configuration UIs in Grafana | Yes | -| `logsInfiniteScrolling` | Enables infinite scrolling for the Logs panel in Explore and Dashboards | Yes | -| `exploreMetrics` | Enables the new Grafana Metrics Drilldown core app | Yes | -| `alertingSimplifiedRouting` | Enables users to easily configure alert notifications by specifying a contact point directly when editing or creating an alert rule | Yes | -| `logRowsPopoverMenu` | Enable filtering menu displayed when text of a log line is selected | Yes | -| `lokiQueryHints` | Enables query hints for Loki | Yes | -| `alertingQueryOptimization` | Optimizes eligible queries in order to reduce load on datasources | | -| `groupToNestedTableTransformation` | Enables the group to nested table transformation | Yes | -| `newPDFRendering` | New implementation for the dashboard-to-PDF rendering | Yes | -| `tlsMemcached` | Use TLS-enabled memcached in the enterprise caching feature | Yes | -| `ssoSettingsSAML` | Use the new SSO Settings API to configure the SAML connector | Yes | -| `cloudWatchNewLabelParsing` | Updates CloudWatch label parsing to be more accurate | Yes | -| `accessActionSets` | Introduces action sets for resource permissions. Also ensures that all folder editors and admins can create subfolders without needing any additional permissions. | Yes | -| `newDashboardSharingComponent` | Enables the new sharing drawer design | Yes | -| `pluginProxyPreserveTrailingSlash` | Preserve plugin proxy trailing slash. | | -| `pinNavItems` | Enables pinning of nav items | Yes | -| `alertingApiServer` | Register Alerting APIs with the K8s API server | Yes | -| `cloudWatchRoundUpEndTime` | Round up end time for metric queries to the next minute to avoid missing data | Yes | -| `newFiltersUI` | Enables new combobox style UI for the Ad hoc filters variable in scenes architecture | Yes | -| `alertingQueryAndExpressionsStepMode` | Enables step mode for alerting queries and expressions | Yes | -| `useSessionStorageForRedirection` | Use session storage for handling the redirection after login | Yes | -| `userStorageAPI` | Enables the user storage API | Yes | -| `azureMonitorDisableLogLimit` | Disables the log limit restriction for Azure Monitor when true. The limit is enabled by default. | | -| `preinstallAutoUpdate` | Enables automatic updates for pre-installed plugins | Yes | -| `reportingUseRawTimeRange` | Uses the original report or dashboard time range instead of making an absolute transformation | Yes | -| `alertingUIOptimizeReducer` | Enables removing the reducer from the alerting UI when creating a new alert rule and using instant query | Yes | -| `azureMonitorEnableUserAuth` | Enables user auth for Azure Monitor datasource only | Yes | -| `alertingNotificationsStepMode` | Enables simplified step mode in the notifications section | Yes | -| `lokiLabelNamesQueryApi` | Defaults to using the Loki `/labels` API instead of `/series` | Yes | +| Feature toggle name | Description | Enabled by default | +| -------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------- | ------------------ | +| `disableEnvelopeEncryption` | Disable envelope encryption (emergency only) | | +| `publicDashboardsScene` | Enables public dashboard rendering using scenes | Yes | +| `featureHighlights` | Highlight Grafana Enterprise features | | +| `correlations` | Correlations page | Yes | +| `cloudWatchCrossAccountQuerying` | Enables cross-account querying in CloudWatch datasources | Yes | +| `nestedFolders` | Enable folder nesting | Yes | +| `logsContextDatasourceUi` | Allow datasource to provide custom UI for context view | Yes | +| `lokiQuerySplitting` | Split large interval queries into subqueries with smaller time intervals | Yes | +| `influxdbBackendMigration` | Query InfluxDB InfluxQL without the proxy | Yes | +| `dataplaneFrontendFallback` | Support dataplane contract field name change for transformations and field name matchers where the name is different | Yes | +| `unifiedRequestLog` | Writes error logs to the request logger | Yes | +| `recordedQueriesMulti` | Enables writing multiple items from a single query within Recorded Queries | Yes | +| `logsExploreTableVisualisation` | A table visualisation for logs in Explore | Yes | +| `transformationsRedesign` | Enables the transformations redesign | Yes | +| `traceQLStreaming` | Enables response streaming of TraceQL queries of the Tempo data source | | +| `awsAsyncQueryCaching` | Enable caching for async queries for Redshift and Athena. Requires that the datasource has caching and async query support enabled | Yes | +| `alertingNoDataErrorExecution` | Changes how Alerting state manager handles execution of NoData/Error | Yes | +| `angularDeprecationUI` | Display Angular warnings in dashboards and panels | Yes | +| `dashgpt` | Enable AI powered features in dashboards | Yes | +| `alertingInsights` | Show the new alerting insights landing page | Yes | +| `panelMonitoring` | Enables panel monitoring through logs and measurements | Yes | +| `formatString` | Enable format string transformer | Yes | +| `kubernetesPlaylists` | Use the kubernetes API in the frontend for playlists, and route /api/playlist requests to k8s | Yes | +| `recoveryThreshold` | Enables feature recovery threshold (aka hysteresis) for threshold server-side expression | Yes | +| `lokiStructuredMetadata` | Enables the loki data source to request structured metadata from the Loki server | Yes | +| `addFieldFromCalculationStatFunctions` | Add cumulative and window functions to the add field from calculation transformation | Yes | +| `annotationPermissionUpdate` | Change the way annotation permissions work by scoping them to folders and dashboards. | Yes | +| `dashboardSceneForViewers` | Enables dashboard rendering using Scenes for viewer roles | Yes | +| `dashboardSceneSolo` | Enables rendering dashboards using scenes for solo panels | Yes | +| `dashboardScene` | Enables dashboard rendering using scenes for all roles | Yes | +| `ssoSettingsApi` | Enables the SSO settings API and the OAuth configuration UIs in Grafana | Yes | +| `logsInfiniteScrolling` | Enables infinite scrolling for the Logs panel in Explore and Dashboards | Yes | +| `exploreMetrics` | Enables the new Grafana Metrics Drilldown core app | Yes | +| `alertingSimplifiedRouting` | Enables users to easily configure alert notifications by specifying a contact point directly when editing or creating an alert rule | Yes | +| `logRowsPopoverMenu` | Enable filtering menu displayed when text of a log line is selected | Yes | +| `lokiQueryHints` | Enables query hints for Loki | Yes | +| `alertingQueryOptimization` | Optimizes eligible queries in order to reduce load on datasources | | +| `groupToNestedTableTransformation` | Enables the group to nested table transformation | Yes | +| `newPDFRendering` | New implementation for the dashboard-to-PDF rendering | Yes | +| `tlsMemcached` | Use TLS-enabled memcached in the enterprise caching feature | Yes | +| `ssoSettingsSAML` | Use the new SSO Settings API to configure the SAML connector | Yes | +| `cloudWatchNewLabelParsing` | Updates CloudWatch label parsing to be more accurate | Yes | +| `newDashboardSharingComponent` | Enables the new sharing drawer design | Yes | +| `pluginProxyPreserveTrailingSlash` | Preserve plugin proxy trailing slash. | | +| `pinNavItems` | Enables pinning of nav items | Yes | +| `alertingApiServer` | Register Alerting APIs with the K8s API server | Yes | +| `cloudWatchRoundUpEndTime` | Round up end time for metric queries to the next minute to avoid missing data | Yes | +| `newFiltersUI` | Enables new combobox style UI for the Ad hoc filters variable in scenes architecture | Yes | +| `alertingQueryAndExpressionsStepMode` | Enables step mode for alerting queries and expressions | Yes | +| `useSessionStorageForRedirection` | Use session storage for handling the redirection after login | Yes | +| `userStorageAPI` | Enables the user storage API | Yes | +| `azureMonitorDisableLogLimit` | Disables the log limit restriction for Azure Monitor when true. The limit is enabled by default. | | +| `preinstallAutoUpdate` | Enables automatic updates for pre-installed plugins | Yes | +| `reportingUseRawTimeRange` | Uses the original report or dashboard time range instead of making an absolute transformation | Yes | +| `alertingUIOptimizeReducer` | Enables removing the reducer from the alerting UI when creating a new alert rule and using instant query | Yes | +| `azureMonitorEnableUserAuth` | Enables user auth for Azure Monitor datasource only | Yes | +| `alertingNotificationsStepMode` | Enables simplified step mode in the notifications section | Yes | +| `lokiLabelNamesQueryApi` | Defaults to using the Loki `/labels` API instead of `/series` | Yes | ## Public preview feature toggles @@ -116,6 +115,7 @@ Most [generally available](https://grafana.com/docs/release-life-cycle/#general- | `improvedExternalSessionHandling` | Enables improved support for OAuth external sessions. After enabling this feature, users might need to re-authenticate themselves. | | `elasticsearchCrossClusterSearch` | Enables cross cluster search in the Elasticsearch datasource | | `improvedExternalSessionHandlingSAML` | Enables improved support for SAML external sessions. Ensure the NameID format is correctly configured in Grafana for SAML Single Logout to function properly. | +| `exploreMetricsUseExternalAppPlugin` | Use the externalized Grafana Metrics Drilldown (formerly known as Explore Metrics) app plugin | | `alertRuleRestore` | Enables the alert rule restore feature | ## Experimental feature toggles @@ -214,7 +214,6 @@ Experimental features might be changed or removed without prior notice. | `enableSCIM` | Enables SCIM support for user and group management | | `crashDetection` | Enables browser crash detection reporting to Faro. | | `jaegerBackendMigration` | Enables querying the Jaeger data source without the proxy | -| `useV2DashboardsAPI` | Use the v2 kubernetes API in the frontend for dashboards | | `unifiedHistory` | Displays the navigation history so the user can navigate back to previous pages | | `investigationsBackend` | Enable the investigations backend API | | `k8SFolderCounts` | Enable folder's api server counts | diff --git a/docs/sources/shared/alerts/alerting_provisioning.md b/docs/sources/shared/alerts/alerting_provisioning.md index 134bd086f97..40d3c72622d 100644 --- a/docs/sources/shared/alerts/alerting_provisioning.md +++ b/docs/sources/shared/alerts/alerting_provisioning.md @@ -1386,6 +1386,8 @@ Status: Conflict ### Sets the notification policy tree. (_RoutePutPolicyTree_) +{{< docs/shared lookup="alerts/warning-provisioning-tree.md" source="grafana" version="" >}} + ``` PUT /api/v1/provisioning/policies ``` diff --git a/docs/sources/shared/alerts/warning-provisioning-tree.md b/docs/sources/shared/alerts/warning-provisioning-tree.md new file mode 100644 index 00000000000..36ecf9b0fa6 --- /dev/null +++ b/docs/sources/shared/alerts/warning-provisioning-tree.md @@ -0,0 +1,9 @@ +--- +title: 'Warning Provisioning Tree' +--- + +{{% admonition type="warning" %}} + +Since the policy tree is a single resource, provisioning it will overwrite all policies in the notification policy tree. However, it does not affect internal policies created when alert rules directly select a contact point. + +{{< /admonition >}} diff --git a/e2e/cypress/support/e2e.js b/e2e/cypress/support/e2e.js index ddd50a58844..284ac975ef0 100644 --- a/e2e/cypress/support/e2e.js +++ b/e2e/cypress/support/e2e.js @@ -51,8 +51,8 @@ beforeEach(() => { cy.setLocalStorage('grafana.featureToggles', 'dashboardScene=false'); } - if (Cypress.env('useV2DashboardsAPI')) { - cy.logToConsole('enabling v2 dashboards API in localstorage'); - cy.setLocalStorage('grafana.featureToggles', 'useV2DashboardsAPI=true'); + if (Cypress.env('kubernetesDashboards')) { + cy.logToConsole('enabling kubernetes dashboards API in localstorage'); + cy.setLocalStorage('grafana.featureToggles', 'kubernetesDashboards=true'); } }); diff --git a/e2e/old-arch/utils/flows/addDataSource.ts b/e2e/old-arch/utils/flows/addDataSource.ts index 777ed6caf31..002dddbd070 100644 --- a/e2e/old-arch/utils/flows/addDataSource.ts +++ b/e2e/old-arch/utils/flows/addDataSource.ts @@ -58,7 +58,7 @@ export const addDataSource = (config?: Partial) => { if (basicAuth) { cy.contains('label', 'Basic auth').scrollIntoView().click(); - cy.contains('.gf-form-group', 'Basic Auth Details') + cy.contains('section', 'Basic Auth Details') .should('be.visible') .scrollIntoView() .within(() => { diff --git a/e2e/run-suite b/e2e/run-suite index bc0eebd1567..ef649a6c6c4 100755 --- a/e2e/run-suite +++ b/e2e/run-suite @@ -28,7 +28,7 @@ declare -A env=( testFilesForSingleSuite="*.spec.ts" rootForEnterpriseSuite="./e2e/extensions-suite" rootForOldArch="./e2e/old-arch" -rootForDashboardsSchemaV2="./e2e/dashboards-suite" +rootForKubernetesDashboards="./e2e/dashboards-suite" declare -A cypressConfig=( [screenshotsFolder]=./e2e/"${args[0]}"/screenshots @@ -113,8 +113,8 @@ case "$1" in env[DISABLE_SCENES]=true ;; "dashboards-schema-v2") - env[useV2DashboardsAPI]=true - cypressConfig[specPattern]=$rootForDashboardsSchemaV2/$testFilesForSingleSuite + env[kubernetesDashboards]=true + cypressConfig[specPattern]=$rootForKubernetesDashboards/$testFilesForSingleSuite cypressConfig[video]=false case "$2" in "debug") diff --git a/e2e/utils/flows/addDataSource.ts b/e2e/utils/flows/addDataSource.ts index 777ed6caf31..002dddbd070 100644 --- a/e2e/utils/flows/addDataSource.ts +++ b/e2e/utils/flows/addDataSource.ts @@ -58,7 +58,7 @@ export const addDataSource = (config?: Partial) => { if (basicAuth) { cy.contains('label', 'Basic auth').scrollIntoView().click(); - cy.contains('.gf-form-group', 'Basic Auth Details') + cy.contains('section', 'Basic Auth Details') .should('be.visible') .scrollIntoView() .within(() => { diff --git a/eslint.config.js b/eslint.config.js index 8c4910b7310..3b29e36521b 100644 --- a/eslint.config.js +++ b/eslint.config.js @@ -262,6 +262,7 @@ module.exports = [ 'prefer-const': 'error', 'react/no-unused-prop-types': 'error', 'react/self-closing-comp': 'error', + 'react/jsx-no-useless-fragment': ['error', { allowExpressions: true }], 'unicorn/no-unused-properties': 'error', }, }, diff --git a/go.mod b/go.mod index e3249c27b66..3a489495e2d 100644 --- a/go.mod +++ b/go.mod @@ -89,7 +89,7 @@ require ( github.com/grafana/grafana-cloud-migration-snapshot v1.6.0 // @grafana/grafana-operator-experience-squad github.com/grafana/grafana-google-sdk-go v0.2.1 // @grafana/partner-datasources github.com/grafana/grafana-openapi-client-go v0.0.0-20231213163343-bd475d63fb79 // @grafana/grafana-backend-group - github.com/grafana/grafana-plugin-sdk-go v0.267.0 // @grafana/plugins-platform-backend + github.com/grafana/grafana-plugin-sdk-go v0.272.0 // @grafana/plugins-platform-backend github.com/grafana/loki/v3 v3.2.1 // @grafana/observability-logs github.com/grafana/otel-profiling-go v0.5.1 // @grafana/grafana-backend-group github.com/grafana/pyroscope-go/godeltaprof v0.1.8 // @grafana/observability-traces-and-profiling @@ -156,28 +156,28 @@ require ( github.com/yudai/gojsondiff v1.0.0 // @grafana/grafana-backend-group go.opentelemetry.io/collector/pdata v1.22.0 // @grafana/grafana-backend-group go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.59.0 // @grafana/plugins-platform-backend - go.opentelemetry.io/contrib/instrumentation/net/http/httptrace/otelhttptrace v0.59.0 // @grafana/grafana-operator-experience-squad + go.opentelemetry.io/contrib/instrumentation/net/http/httptrace/otelhttptrace v0.60.0 // @grafana/grafana-operator-experience-squad go.opentelemetry.io/contrib/propagators/jaeger v1.34.0 // @grafana/grafana-backend-group go.opentelemetry.io/contrib/samplers/jaegerremote v0.28.0 // @grafana/grafana-backend-group - go.opentelemetry.io/otel v1.34.0 // @grafana/grafana-backend-group + go.opentelemetry.io/otel v1.35.0 // @grafana/grafana-backend-group go.opentelemetry.io/otel/exporters/jaeger v1.17.0 // @grafana/grafana-backend-group go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.34.0 // @grafana/grafana-backend-group go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracegrpc v1.34.0 // @grafana/grafana-backend-group - go.opentelemetry.io/otel/sdk v1.34.0 // @grafana/grafana-backend-group - go.opentelemetry.io/otel/trace v1.34.0 // @grafana/grafana-backend-group + go.opentelemetry.io/otel/sdk v1.35.0 // @grafana/grafana-backend-group + go.opentelemetry.io/otel/trace v1.35.0 // @grafana/grafana-backend-group go.uber.org/atomic v1.11.0 // @grafana/alerting-backend go.uber.org/goleak v1.3.0 // @grafana/grafana-search-and-storage go.uber.org/zap v1.27.0 // @grafana/identity-access-team gocloud.dev v0.40.0 // @grafana/grafana-app-platform-squad golang.org/x/crypto v0.35.0 // @grafana/grafana-backend-group golang.org/x/exp v0.0.0-20240909161429-701f63a606c0 // @grafana/alerting-backend - golang.org/x/mod v0.22.0 // indirect; @grafana/grafana-backend-group + golang.org/x/mod v0.23.0 // indirect; @grafana/grafana-backend-group golang.org/x/net v0.36.0 // @grafana/oss-big-tent @grafana/partner-datasources golang.org/x/oauth2 v0.27.0 // @grafana/identity-access-team golang.org/x/sync v0.11.0 // @grafana/alerting-backend golang.org/x/text v0.22.0 // @grafana/grafana-backend-group golang.org/x/time v0.9.0 // @grafana/grafana-backend-group - golang.org/x/tools v0.29.0 // indirect; @grafana/grafana-as-code + golang.org/x/tools v0.30.0 // indirect; @grafana/grafana-as-code gonum.org/v1/gonum v0.15.1 // @grafana/oss-big-tent google.golang.org/api v0.220.0 // @grafana/grafana-backend-group google.golang.org/grpc v1.70.0 // @grafana/plugins-platform-backend @@ -331,7 +331,7 @@ require ( github.com/dolthub/maphash v0.1.0 // indirect github.com/dustin/go-humanize v1.0.1 // indirect github.com/edsrzf/mmap-go v1.2.0 // indirect - github.com/elazarl/goproxy v1.7.1 // indirect + github.com/elazarl/goproxy v1.7.2 // indirect github.com/emicklei/go-restful/v3 v3.11.0 // indirect github.com/emicklei/proto v1.13.2 // indirect github.com/emirpasic/gods v1.18.1 // indirect @@ -519,10 +519,10 @@ require ( go.opencensus.io v0.24.0 // @grafana/grafana-backend-group go.opentelemetry.io/auto/sdk v1.1.0 // indirect go.opentelemetry.io/contrib/detectors/gcp v1.33.0 // indirect - go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.59.0 // @grafana/sharing-squad + go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.60.0 // @grafana/sharing-squad go.opentelemetry.io/otel/exporters/otlp/otlptrace/otlptracehttp v1.34.0 // indirect - go.opentelemetry.io/otel/metric v1.34.0 // indirect - go.opentelemetry.io/otel/sdk/metric v1.32.0 // indirect + go.opentelemetry.io/otel/metric v1.35.0 // indirect + go.opentelemetry.io/otel/sdk/metric v1.35.0 // indirect go.opentelemetry.io/proto/otlp v1.5.0 // indirect go.uber.org/mock v0.5.0 // indirect go.uber.org/multierr v1.11.0 // indirect diff --git a/go.sum b/go.sum index 680b16f06d5..e5ac733e108 100644 --- a/go.sum +++ b/go.sum @@ -1103,8 +1103,8 @@ github.com/edsrzf/mmap-go v1.2.0/go.mod h1:19H/e8pUPLicwkyNgOykDXkJ9F0MHE+Z52B8E github.com/efficientgo/core v1.0.0-rc.3 h1:X6CdgycYWDcbYiJr1H1+lQGzx13o7bq3EUkbB9DsSPc= github.com/efficientgo/core v1.0.0-rc.3/go.mod h1:FfGdkzWarkuzOlY04VY+bGfb1lWrjaL6x/GLcQ4vJps= github.com/elazarl/goproxy v0.0.0-20170405201442-c4fc26588b6e/go.mod h1:/Zj4wYkgs4iZTTu3o/KG3Itv/qCCa8VVMlb3i9OVuzc= -github.com/elazarl/goproxy v1.7.1 h1:1P7LPSxbqtNxusFnXclj6O56pjfq1xOQZ6a0mwwKUlY= -github.com/elazarl/goproxy v1.7.1/go.mod h1:82vkLNir0ALaW14Rc399OTTjyNREgmdL2cVoIbS6XaE= +github.com/elazarl/goproxy v1.7.2 h1:Y2o6urb7Eule09PjlhQRGNsqRfPmYI3KKQLFpCAV3+o= +github.com/elazarl/goproxy v1.7.2/go.mod h1:82vkLNir0ALaW14Rc399OTTjyNREgmdL2cVoIbS6XaE= github.com/emicklei/go-restful v0.0.0-20170410110728-ff4f55a20633/go.mod h1:otzb+WCGbkyDHkqmQmT5YD2WR4BBwUdeQoFo8l/7tVs= github.com/emicklei/go-restful/v3 v3.11.0 h1:rAQeMHw1c7zTmncogyy8VvRZwtkmkZ4FxERmMY4rD+g= github.com/emicklei/go-restful/v3 v3.11.0/go.mod h1:6n3XBCmQQb25CM2LCACGz8ukIrRry+4bhvbpWn3mrbc= @@ -1574,8 +1574,8 @@ github.com/grafana/grafana-google-sdk-go v0.2.1 h1:XeFdKnkXBjOJjXc1gf4iMx4h5aCHT github.com/grafana/grafana-google-sdk-go v0.2.1/go.mod h1:RiITSHwBhqVTTd3se3HQq5Ncs/wzzhTB9OK5N0J0PEU= github.com/grafana/grafana-openapi-client-go v0.0.0-20231213163343-bd475d63fb79 h1:r+mU5bGMzcXCRVAuOrTn54S80qbfVkvTdUJZfSfTNbs= github.com/grafana/grafana-openapi-client-go v0.0.0-20231213163343-bd475d63fb79/go.mod h1:wc6Hbh3K2TgCUSfBC/BOzabItujtHMESZeFk5ZhdxhQ= -github.com/grafana/grafana-plugin-sdk-go v0.267.0 h1:4AcuLEE0UeFG0Eo3P8r1FDS89hgZZ73K550DRz1fgjQ= -github.com/grafana/grafana-plugin-sdk-go v0.267.0/go.mod h1:OuwS4c/JYgn0rr/w5zhJBpLo4gKm/vw15RsfpYAvK9Q= +github.com/grafana/grafana-plugin-sdk-go v0.272.0 h1:TmPIG+6e3lYGzkyfUfCHuaMaaiwDbkCacTZ7V/JaSeg= +github.com/grafana/grafana-plugin-sdk-go v0.272.0/go.mod h1:i/9KH9y/6m5hkRnG3H6aR2nOMPbJUmvo4XNrHjI15cU= github.com/grafana/grafana/apps/advisor v0.0.0-20250220163425-b4c4b9abbdc8 h1:mG/6nDlEBVxWlo2GQJVASzucw3ByPIBsec06XcPrjgQ= github.com/grafana/grafana/apps/advisor v0.0.0-20250220163425-b4c4b9abbdc8/go.mod h1:9I1dKV3Dqr0NPR9Af0WJGxOytp5/6W3JLiNChOz8r+c= github.com/grafana/grafana/apps/alerting/notifications v0.0.0-20250220163425-b4c4b9abbdc8 h1:w42GlvkmHG4nM/p1kb2nKmROVP+AHtL3qWEYMhnhCVM= @@ -2490,11 +2490,11 @@ go.opentelemetry.io/contrib/detectors/gcp v1.33.0/go.mod h1:ZHrLmr4ikK2AwRj9QL+c go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.59.0 h1:rgMkmiGfix9vFJDcDi1PK8WEQP4FLQwLDfhp5ZLpFeE= go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.59.0/go.mod h1:ijPqXp5P6IRRByFVVg9DY8P5HkxkHE5ARIa+86aXPf4= go.opentelemetry.io/contrib/instrumentation/net/http/httptrace/otelhttptrace v0.55.0/go.mod h1:rsg1EO8LXSs2po50PB5CeY/MSVlhghuKBgXlKnqm6ks= -go.opentelemetry.io/contrib/instrumentation/net/http/httptrace/otelhttptrace v0.59.0 h1:iQZYNQ7WwIcYXzOPR46FQv9O0dS1PW16RjvR0TjDOe8= -go.opentelemetry.io/contrib/instrumentation/net/http/httptrace/otelhttptrace v0.59.0/go.mod h1:54CaSNqYEXvpzDh8KPjiMVoWm60t5R0dZRt0leEPgAs= +go.opentelemetry.io/contrib/instrumentation/net/http/httptrace/otelhttptrace v0.60.0 h1:0tY123n7CdWMem7MOVdKOt0YfshufLCwfE5Bob+hQuM= +go.opentelemetry.io/contrib/instrumentation/net/http/httptrace/otelhttptrace v0.60.0/go.mod h1:CosX/aS4eHnG9D7nESYpV753l4j9q5j3SL/PUYd2lR8= go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.55.0/go.mod h1:DQAwmETtZV00skUwgD6+0U89g80NKsJE3DCKeLLPQMI= -go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.59.0 h1:CV7UdSGJt/Ao6Gp4CXckLxVRRsRgDHoI8XjbL3PDl8s= -go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.59.0/go.mod h1:FRmFuRJfag1IZ2dPkHnEoSFVgTVPUd2qf5Vi69hLb8I= +go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.60.0 h1:sbiXRNDSWJOTobXh5HyQKjq6wUC5tNybqjIqDpAY4CU= +go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.60.0/go.mod h1:69uWxva0WgAA/4bu2Yy70SLDBwZXuQ6PbBpbsa5iZrQ= go.opentelemetry.io/contrib/propagators/jaeger v1.34.0 h1:D3htJISCUU/wOVlKwisVKancWm+2U4h9xDEaiMkiyRE= go.opentelemetry.io/contrib/propagators/jaeger v1.34.0/go.mod h1:DAX1bsj+uDm2ZuOQH/RgZRx7RQZWyzV5W2WR/0UX8JA= go.opentelemetry.io/contrib/samplers/jaegerremote v0.28.0 h1:Xx1N6cDr8iWy1Cz6OcY7oS0ACdt/6HDYTdu4KskuC7s= @@ -2502,8 +2502,8 @@ go.opentelemetry.io/contrib/samplers/jaegerremote v0.28.0/go.mod h1:iWS+NvC948Fy go.opentelemetry.io/otel v1.17.0/go.mod h1:I2vmBGtFaODIVMBSTPVDlJSzBDNf93k60E6Ft0nyjo0= go.opentelemetry.io/otel v1.21.0/go.mod h1:QZzNPQPm1zLX4gZK4cMi+71eaorMSGT3A4znnUvNNEo= go.opentelemetry.io/otel v1.30.0/go.mod h1:tFw4Br9b7fOS+uEao81PJjVMjW/5fvNCbpsDIXqP0pc= -go.opentelemetry.io/otel v1.34.0 h1:zRLXxLCgL1WyKsPVrgbSdMN4c0FMkDAskSTQP+0hdUY= -go.opentelemetry.io/otel v1.34.0/go.mod h1:OWFPOQ+h4G8xpyjgqo4SxJYdDQ/qmRH+wivy7zzx9oI= +go.opentelemetry.io/otel v1.35.0 h1:xKWKPxrxB6OtMCbmMY021CqC45J+3Onta9MqjhnusiQ= +go.opentelemetry.io/otel v1.35.0/go.mod h1:UEqy8Zp11hpkUrL73gSlELM0DupHoiq72dR+Zqel/+Y= go.opentelemetry.io/otel/exporters/jaeger v1.17.0 h1:D7UpUy2Xc2wsi1Ras6V40q806WM07rqoCWzXu7Sqy+4= go.opentelemetry.io/otel/exporters/jaeger v1.17.0/go.mod h1:nPCqOnEH9rNLKqH/+rrUjiMzHJdV1BlpKcTwRTyKkKI= go.opentelemetry.io/otel/exporters/otlp/otlptrace v1.34.0 h1:OeNbIYk/2C15ckl7glBlOBp5+WlYsOElzTNmiPW/x60= @@ -2517,19 +2517,19 @@ go.opentelemetry.io/otel/exporters/stdout/stdoutmetric v1.29.0/go.mod h1:BLbf7zb go.opentelemetry.io/otel/metric v1.17.0/go.mod h1:h4skoxdZI17AxwITdmdZjjYJQH5nzijUUjm+wtPph5o= go.opentelemetry.io/otel/metric v1.21.0/go.mod h1:o1p3CA8nNHW8j5yuQLdc1eeqEaPfzug24uvsyIEJRWM= go.opentelemetry.io/otel/metric v1.30.0/go.mod h1:aXTfST94tswhWEb+5QjlSqG+cZlmyXy/u8jFpor3WqQ= -go.opentelemetry.io/otel/metric v1.34.0 h1:+eTR3U0MyfWjRDhmFMxe2SsW64QrZ84AOhvqS7Y+PoQ= -go.opentelemetry.io/otel/metric v1.34.0/go.mod h1:CEDrp0fy2D0MvkXE+dPV7cMi8tWZwX3dmaIhwPOaqHE= +go.opentelemetry.io/otel/metric v1.35.0 h1:0znxYu2SNyuMSQT4Y9WDWej0VpcsxkuklLa4/siN90M= +go.opentelemetry.io/otel/metric v1.35.0/go.mod h1:nKVFgxBZ2fReX6IlyW28MgZojkoAkJGaE8CpgeAU3oE= go.opentelemetry.io/otel/sdk v1.17.0/go.mod h1:U87sE0f5vQB7hwUoW98pW5Rz4ZDuCFBZFNUBlSgmDFQ= go.opentelemetry.io/otel/sdk v1.21.0/go.mod h1:Nna6Yv7PWTdgJHVRD9hIYywQBRx7pbox6nwBnZIxl/E= -go.opentelemetry.io/otel/sdk v1.34.0 h1:95zS4k/2GOy069d321O8jWgYsW3MzVV+KuSPKp7Wr1A= -go.opentelemetry.io/otel/sdk v1.34.0/go.mod h1:0e/pNiaMAqaykJGKbi+tSjWfNNHMTxoC9qANsCzbyxU= -go.opentelemetry.io/otel/sdk/metric v1.32.0 h1:rZvFnvmvawYb0alrYkjraqJq0Z4ZUJAiyYCU9snn1CU= -go.opentelemetry.io/otel/sdk/metric v1.32.0/go.mod h1:PWeZlq0zt9YkYAp3gjKZ0eicRYvOh1Gd+X99x6GHpCQ= +go.opentelemetry.io/otel/sdk v1.35.0 h1:iPctf8iprVySXSKJffSS79eOjl9pvxV9ZqOWT0QejKY= +go.opentelemetry.io/otel/sdk v1.35.0/go.mod h1:+ga1bZliga3DxJ3CQGg3updiaAJoNECOgJREo9KHGQg= +go.opentelemetry.io/otel/sdk/metric v1.35.0 h1:1RriWBmCKgkeHEhM7a2uMjMUfP7MsOF5JpUCaEqEI9o= +go.opentelemetry.io/otel/sdk/metric v1.35.0/go.mod h1:is6XYCUMpcKi+ZsOvfluY5YstFnhW0BidkR+gL+qN+w= go.opentelemetry.io/otel/trace v1.17.0/go.mod h1:I/4vKTgFclIsXRVucpH25X0mpFSczM7aHeaz0ZBLWjY= go.opentelemetry.io/otel/trace v1.21.0/go.mod h1:LGbsEB0f9LGjN+OZaQQ26sohbOmiMR+BaslueVtS/qQ= go.opentelemetry.io/otel/trace v1.30.0/go.mod h1:5EyKqTzzmyqB9bwtCCq6pDLktPK6fmGf/Dph+8VI02o= -go.opentelemetry.io/otel/trace v1.34.0 h1:+ouXS2V8Rd4hp4580a8q23bg0azF2nI8cqLYnC8mh/k= -go.opentelemetry.io/otel/trace v1.34.0/go.mod h1:Svm7lSjQD7kG7KJ/MUHPVXSDGz2OX4h0M2jHBhmSfRE= +go.opentelemetry.io/otel/trace v1.35.0 h1:dPpEfJu1sDIqruz7BHFG3c7528f6ddfSWfFDVt/xgMs= +go.opentelemetry.io/otel/trace v1.35.0/go.mod h1:WUk7DtFp1Aw2MkvqGdwiXYDZZNvA/1J8o6xRXLrIkyc= go.opentelemetry.io/proto/otlp v0.7.0/go.mod h1:PqfVotwruBrMGOCsRd/89rSnXhoiJIqeYNgFYFoEGnI= go.opentelemetry.io/proto/otlp v0.15.0/go.mod h1:H7XAot3MsfNsj7EXtrA2q5xSNQ10UqI405h3+duxN4U= go.opentelemetry.io/proto/otlp v0.19.0/go.mod h1:H7XAot3MsfNsj7EXtrA2q5xSNQ10UqI405h3+duxN4U= @@ -2655,8 +2655,8 @@ golang.org/x/mod v0.8.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= golang.org/x/mod v0.9.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= golang.org/x/mod v0.12.0/go.mod h1:iBbtSCu2XBx23ZKBPSOrRkjjQPZFPuis4dIYUhu/chs= golang.org/x/mod v0.14.0/go.mod h1:hTbmBsO62+eylJbnUtE2MGJUyE7QWk4xUqPFrRgJ+7c= -golang.org/x/mod v0.22.0 h1:D4nJWe9zXqHOmWqj4VMOJhvzj7bEZg4wEYa759z1pH4= -golang.org/x/mod v0.22.0/go.mod h1:6SkKJ3Xj0I0BrPOZoBy3bdMptDDU9oJrpohJ3eWZ1fY= +golang.org/x/mod v0.23.0 h1:Zb7khfcRGKk+kqfxFaP5tZqCnDZMjC5VtUBs87Hr6QM= +golang.org/x/mod v0.23.0/go.mod h1:6SkKJ3Xj0I0BrPOZoBy3bdMptDDU9oJrpohJ3eWZ1fY= golang.org/x/net v0.0.0-20170114055629-f2499483f923/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= @@ -3052,8 +3052,8 @@ golang.org/x/tools v0.6.0/go.mod h1:Xwgl3UAJ/d3gWutnCtw505GrjyAbvKui8lOU390QaIU= golang.org/x/tools v0.7.0/go.mod h1:4pg6aUX35JBAogB10C9AtvVL+qowtN4pT3CGSQex14s= golang.org/x/tools v0.13.0/go.mod h1:HvlwmtVNQAhOuCjW7xxvovg8wbNq7LwfXh/k7wXUl58= golang.org/x/tools v0.17.0/go.mod h1:xsh6VxdV005rRVaS6SSAf9oiAqljS7UZUacMZ8Bnsps= -golang.org/x/tools v0.29.0 h1:Xx0h3TtM9rzQpQuR4dKLrdglAmCEN5Oi+P74JdhdzXE= -golang.org/x/tools v0.29.0/go.mod h1:KMQVMRsVxU6nHCFXrBPhDB8XncLNLM0lIy/F14RP588= +golang.org/x/tools v0.30.0 h1:BgcpHewrV5AUp2G9MebG4XPFI1E2W41zU1SaqVA9vJY= +golang.org/x/tools v0.30.0/go.mod h1:c347cR/OJfw5TI+GfX7RUPNMdDRRbjvYTS0jPyvsVtY= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= diff --git a/go.work b/go.work index 2d53f72c4df..df840ed9405 100644 --- a/go.work +++ b/go.work @@ -7,10 +7,12 @@ use ( . // skip:golangci-lint ./apps/advisor ./apps/alerting/notifications + ./apps/dashboard ./apps/investigations ./apps/playlist ./pkg/aggregator ./pkg/apimachinery + ./pkg/apis/secret // @grafana/grafana-operator-experience-squad ./pkg/apiserver ./pkg/build ./pkg/build/wire // skip:golangci-lint diff --git a/go.work.sum b/go.work.sum index acdb123b361..2062d7330a6 100644 --- a/go.work.sum +++ b/go.work.sum @@ -692,7 +692,6 @@ github.com/couchbase/ghistogram v0.1.0/go.mod h1:s1Jhy76zqfEecpNWJfWUiKZookAFaiG github.com/couchbase/moss v0.2.0 h1:VCYrMzFwEryyhRSeI+/b3tRBSeTpi/8gn5Kf6dxqn+o= github.com/couchbase/moss v0.2.0/go.mod h1:9MaHIaRuy9pvLPUJxB8sh8OrLfyDczECVL37grCIubs= github.com/cpuguy83/go-md2man v1.0.10 h1:BSKMNlYxDvnunlTymqtgONjNnaRV1sTpcovwwjF22jk= -github.com/cpuguy83/go-md2man/v2 v2.0.4/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o= github.com/creack/pty v1.1.18 h1:n56/Zwd5o6whRC5PMGretI4IdRLlmBXYNjScPaBgsbY= github.com/creack/pty v1.1.18/go.mod h1:MOBLtS5ELjhRRrroQr9kyvTxUAFNvYEK993ew/Vr4O4= github.com/creasty/defaults v1.8.0 h1:z27FJxCAa0JKt3utc0sCImAEb+spPucmKoOdLHvHYKk= @@ -776,6 +775,7 @@ github.com/elastic/go-windows v1.0.0/go.mod h1:TsU0Nrp7/y3+VwE82FoZF8gC/XFg/Elz6 github.com/elastic/go-windows v1.0.1 h1:AlYZOldA+UJ0/2nBuqWdo90GFCgG9xuyw9SYzGUtJm0= github.com/elastic/go-windows v1.0.1/go.mod h1:FoVvqWSun28vaDQPbj2Elfc0JahhPB7WQEGa3c814Ss= github.com/elazarl/goproxy v1.3.0/go.mod h1:X/5W/t+gzDyLfHW4DrMdpjqYjpXsURlBt9lpBDxZZZQ= +github.com/elazarl/goproxy v1.7.1/go.mod h1:82vkLNir0ALaW14Rc399OTTjyNREgmdL2cVoIbS6XaE= github.com/emicklei/go-restful v0.0.0-20170410110728-ff4f55a20633 h1:H2pdYOb3KQ1/YsqVWoWNLQO+fusocsw354rqGTZtAgw= github.com/envoyproxy/protoc-gen-validate v1.0.4/go.mod h1:qys6tmnRsYrQqIhm2bvKZH4Blx/1gTIZ2UKVY1M+Yew= github.com/envoyproxy/protoc-gen-validate v1.1.0/go.mod h1:sXRDRVmzEbkM7CVcM06s9shE/m23dg3wzjl0UWqJ2q4= @@ -907,6 +907,7 @@ github.com/grafana/cog v0.0.23/go.mod h1:jrS9indvWuDs60RHEZpLaAkmZdgyoLKMOEUT0ji github.com/grafana/go-gelf/v2 v2.0.1 h1:BOChP0h/jLeD+7F9mL7tq10xVkDG15he3T1zHuQaWak= github.com/grafana/go-gelf/v2 v2.0.1/go.mod h1:lexHie0xzYGwCgiRGcvZ723bSNyNI8ZRD4s0CLobh90= github.com/grafana/grafana-plugin-sdk-go v0.263.0/go.mod h1:U43Cnrj/9DNYyvFcNdeUWNjMXTKNB0jcTcQGpWKd2gw= +github.com/grafana/grafana-plugin-sdk-go v0.267.0/go.mod h1:OuwS4c/JYgn0rr/w5zhJBpLo4gKm/vw15RsfpYAvK9Q= github.com/grafana/grafana/apps/advisor v0.0.0-20250123151950-b066a6313173/go.mod h1:goSDiy3jtC2cp8wjpPZdUHRENcoSUHae1/Px/MDfddA= github.com/grafana/grafana/apps/advisor v0.0.0-20250220154326-6e5de80ef295/go.mod h1:9I1dKV3Dqr0NPR9Af0WJGxOytp5/6W3JLiNChOz8r+c= github.com/grafana/grafana/apps/alerting/notifications v0.0.0-20250121113133-e747350fee2d/go.mod h1:AvleS6icyPmcBjihtx5jYEvdzLmHGBp66NuE0AMR57A= @@ -923,6 +924,7 @@ github.com/grafana/tail v0.0.0-20230510142333-77b18831edf0/go.mod h1:7t5XR+2IA8P github.com/gregjones/httpcache v0.0.0-20190611155906-901d90724c79 h1:+ngKgrYPPJrOjhax5N+uePQ0Fh1Z7PheYoUI/0nzkPA= github.com/gregjones/httpcache v0.0.0-20190611155906-901d90724c79/go.mod h1:FecbI9+v66THATjSRHfNgh1IVFe/9kFxbXtjV0ctIMA= github.com/grpc-ecosystem/go-grpc-middleware v1.3.0/go.mod h1:z0ButlSOZa5vEBq9m2m2hlwIgKw+rp3sdCBRoJY+30Y= +github.com/grpc-ecosystem/go-grpc-middleware/v2 v2.3.0/go.mod h1:qOchhhIlmRcqk/O9uCo/puJlyo07YINaIqdZfZG3Jkc= github.com/grpc-ecosystem/grpc-gateway/v2 v2.19.1/go.mod h1:5SN9VR2LTsRFsrEC6FHgRbTWrTHu6tqPeKxEQv15giM= github.com/grpc-ecosystem/grpc-gateway/v2 v2.20.0/go.mod h1:P+Lt/0by1T8bfcF3z737NnSbmxQAppXMRziHUxPOC8k= github.com/grpc-ecosystem/grpc-gateway/v2 v2.22.0/go.mod h1:ggCgvZ2r7uOoQjOyu2Y1NhHmEPPzzuhWgcza5M1Ji1I= @@ -1197,7 +1199,6 @@ github.com/shurcooL/sanitized_anchor_name v1.0.0 h1:PdmoCO6wvbs+7yrJyMORt4/BmY5I github.com/sirupsen/logrus v1.8.1/go.mod h1:yWOB1SBYBC5VeMP7gHvWumXLIWorT60ONWic61uBYv0= github.com/spf13/afero v1.10.0/go.mod h1:UBogFpq8E9Hx+xc5CNTTEpTnuHVmXDwZcZcE1eb/UhQ= github.com/spf13/cast v1.6.0/go.mod h1:ancEpBxwJDODSW/UG4rDrAqiKolqNNh2DX3mk86cAdo= -github.com/spf13/cobra v1.8.1/go.mod h1:wHxEcudfqmLYa8iTfL+OuZPbBZkmvliBWKIezN3kD9Y= github.com/spf13/jwalterweatherman v1.1.0 h1:ue6voC5bR5F8YxI5S67j9i582FU4Qvo2bmqnqMYADFk= github.com/spkg/bom v0.0.0-20160624110644-59b7046e48ad h1:fiWzISvDn0Csy5H0iwgAuJGQTUpVfEMJJd4nRFXogbc= github.com/stoewer/go-strcase v1.2.0/go.mod h1:IBiWB2sKIp3wVVQ3Y035++gc+knqhUQag1KpM8ahLw8= @@ -1362,10 +1363,12 @@ go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.5 go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.54.0/go.mod h1:B9yO6b04uB80CzjedvewuqDhxJxi11s7/GtiGa8bAjI= go.opentelemetry.io/contrib/instrumentation/google.golang.org/grpc/otelgrpc v0.58.0/go.mod h1:HDBUsEjOuRC0EzKZ1bSaRGZWUBAzo+MhAcUUORSr4D0= go.opentelemetry.io/contrib/instrumentation/net/http/httptrace/otelhttptrace v0.58.0/go.mod h1:uosvgpqTcTXtcPQORTbEkZNDQTCDOgTz1fe6aLSyqrQ= +go.opentelemetry.io/contrib/instrumentation/net/http/httptrace/otelhttptrace v0.59.0/go.mod h1:54CaSNqYEXvpzDh8KPjiMVoWm60t5R0dZRt0leEPgAs= go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.49.0/go.mod h1:p8pYQP+m5XfbZm9fxtSKAbM6oIllS7s2AfxrChvc7iw= go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.53.0/go.mod h1:jjdQuTGVsXV4vSs+CJ2qYDeDPf9yIJV23qlIzBm73Vg= go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.54.0/go.mod h1:L7UH0GbB0p47T4Rri3uHjbpCFYrVrwc1I25QhNPiGK8= go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.58.0/go.mod h1:umTcuxiv1n/s/S6/c2AT/g2CQ7u5C59sHDNmfSwgz7Q= +go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp v0.59.0/go.mod h1:FRmFuRJfag1IZ2dPkHnEoSFVgTVPUd2qf5Vi69hLb8I= go.opentelemetry.io/contrib/propagators/b3 v1.27.0 h1:IjgxbomVrV9za6bRi8fWCNXENs0co37SZedQilP2hm0= go.opentelemetry.io/contrib/propagators/b3 v1.27.0/go.mod h1:Dv9obQz25lCisDvvs4dy28UPh974CxkahRDUPsY7y9E= go.opentelemetry.io/contrib/propagators/jaeger v1.33.0/go.mod h1:ku/EpGk44S5lyVMbtJRK2KFOnXEehxf6SDnhu1eZmjA= @@ -1407,6 +1410,7 @@ go.opentelemetry.io/otel/sdk v1.30.0/go.mod h1:p14X4Ok8S+sygzblytT1nqG98QG2KYKv+ go.opentelemetry.io/otel/sdk v1.32.0/go.mod h1:LqgegDBjKMmb2GC6/PrTnteJG39I8/vJCAP9LlJXEjU= go.opentelemetry.io/otel/sdk/metric v1.29.0/go.mod h1:6zZLdCl2fkauYoZIOn/soQIDSWFmNSRcICarHfuhNJQ= go.opentelemetry.io/otel/sdk/metric v1.30.0/go.mod h1:waS6P3YqFNzeP01kuo/MBBYqaoBJl7efRQHOaydhy1Y= +go.opentelemetry.io/otel/sdk/metric v1.32.0/go.mod h1:PWeZlq0zt9YkYAp3gjKZ0eicRYvOh1Gd+X99x6GHpCQ= go.opentelemetry.io/otel/trace v1.24.0/go.mod h1:HPc3Xr/cOApsBI154IU0OI0HJexz+aw5uPdbs3UCjNU= go.opentelemetry.io/otel/trace v1.26.0/go.mod h1:4iDxvGDQuUkHve82hJJ8UqrwswHYsZuWCBllGV2U2y0= go.opentelemetry.io/otel/trace v1.28.0/go.mod h1:jPyXzNPg6da9+38HEwElrQiHlVMTnVfM3/yv2OlIHaI= @@ -1447,6 +1451,7 @@ golang.org/x/mod v0.17.0/go.mod h1:hTbmBsO62+eylJbnUtE2MGJUyE7QWk4xUqPFrRgJ+7c= golang.org/x/mod v0.18.0/go.mod h1:hTbmBsO62+eylJbnUtE2MGJUyE7QWk4xUqPFrRgJ+7c= golang.org/x/mod v0.19.0/go.mod h1:hTbmBsO62+eylJbnUtE2MGJUyE7QWk4xUqPFrRgJ+7c= golang.org/x/mod v0.21.0/go.mod h1:6SkKJ3Xj0I0BrPOZoBy3bdMptDDU9oJrpohJ3eWZ1fY= +golang.org/x/mod v0.22.0/go.mod h1:6SkKJ3Xj0I0BrPOZoBy3bdMptDDU9oJrpohJ3eWZ1fY= golang.org/x/net v0.0.0-20201202161906-c7110b5ffcbb/go.mod h1:sp8m0HH+o8qH0wwXwYZr8TS3Oi6o0r6Gce1SSxlDquU= golang.org/x/net v0.0.0-20210726213435-c6fcb2dbf985/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20211123203042-d83791d6bcd9/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= diff --git a/hack/update-codegen.sh b/hack/update-codegen.sh index 57841bbbeb2..661a588ca62 100755 --- a/hack/update-codegen.sh +++ b/hack/update-codegen.sh @@ -86,6 +86,7 @@ grafana:codegen:lsdirs() { grafana::codegen:run pkg grafana::codegen:run pkg/apimachinery grafana::codegen:run pkg/aggregator +grafana::codegen:run apps/dashboard/pkg if [ -d "pkg/extensions/apis" ]; then grafana::codegen:run pkg/extensions diff --git a/package.json b/package.json index a2028d9dbf7..58f7c90ac2f 100644 --- a/package.json +++ b/package.json @@ -73,7 +73,7 @@ "devDependencies": { "@babel/core": "7.26.9", "@babel/preset-env": "7.26.9", - "@babel/runtime": "7.26.9", + "@babel/runtime": "7.26.10", "@betterer/betterer": "5.4.0", "@betterer/cli": "5.4.0", "@cypress/webpack-preprocessor": "6.0.2", @@ -270,7 +270,7 @@ "@grafana/flamegraph": "workspace:*", "@grafana/google-sdk": "0.1.2", "@grafana/lezer-logql": "0.2.7", - "@grafana/llm": "0.12.0", + "@grafana/llm": "0.13.2", "@grafana/monaco-logql": "^0.0.8", "@grafana/o11y-ds-frontend": "workspace:*", "@grafana/plugin-ui": "0.10.1", diff --git a/packages/README.md b/packages/README.md index 5b84585fcef..e7c9d6df315 100644 --- a/packages/README.md +++ b/packages/README.md @@ -1,6 +1,14 @@ # Grafana frontend packages -This document contains information about Grafana frontend package versioning and releases. +## Exporting code conventions + +`@grafana/ui` makes use of `exports` in package.json to define three entrypoints that Grafana core and Grafana plugins can access. Before exposing anything in this package please consider the table below. + +| Entrypoint Name | Import Path | Description | Available to Grafana | Available to plugins | +| --------------- | ---------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------- | -------------------- | +| `./` | `@grafana/ui` | The public API entrypoint. If the code is stable and you want to share it everywhere, this is the place to export it. | ✅ | ✅ | +| `./unstable` | `@grafana/ui/unstable` | The public API entrypoint for all experimental code. If you want to iterate and test code from Grafana and plugins, this is the place to export it. | ✅ | ✅ | +| `./internal` | `@grafana/ui/internal` | The private API entrypoint for internal code shared with Grafana. If you need to import code in Grafana but don't want to expose it to plugins, this is the place to export it. | ✅ | ❌ | ## Versioning diff --git a/packages/grafana-data/src/datetime/rangeutil.ts b/packages/grafana-data/src/datetime/rangeutil.ts index 3168e24dc6f..2a93c282551 100644 --- a/packages/grafana-data/src/datetime/rangeutil.ts +++ b/packages/grafana-data/src/datetime/rangeutil.ts @@ -293,7 +293,7 @@ export function calculateInterval(range: TimeRange, resolution: number, lowLimit }; } -const interval_regex = /(-?\d+(?:\.\d+)?)(ms|[Mwdhmsy])/; +const interval_regex = /^(-?\d+(?:\.\d+)?)(ms|[Mwdhmsy])/; // histogram & trends const intervals_in_seconds: Record = { y: 31536000, diff --git a/packages/grafana-data/src/themes/themeDefinitions/desertbloom.ts b/packages/grafana-data/src/themes/themeDefinitions/desertbloom.ts index 0d8ce37e045..8c08ca75da1 100644 --- a/packages/grafana-data/src/themes/themeDefinitions/desertbloom.ts +++ b/packages/grafana-data/src/themes/themeDefinitions/desertbloom.ts @@ -61,9 +61,10 @@ const desertBloomTheme: NewThemeOptions = { disabledBackground: 'rgba(168, 156, 134, 0.06)', disabledOpacity: 0.38, }, + gradients: { - brandHorizontal: 'linear-gradient(270deg, #FF6F61 0%, #ece0d1 100%)', - brandVertical: 'linear-gradient(0.01deg, #FF6F61 0.01%, #ece0d1 99.99%)', + brandHorizontal: 'linear-gradient(270deg,rgba(255, 111, 97, 1) 0%, rgba(255, 167, 58, 1) 100%)', + brandVertical: 'linear-gradient(0deg, rgba(255, 111, 97, 1) 0%, rgba(255, 167, 58, 1) 100%)', }, contrastThreshold: 3, hoverFactor: 0.03, diff --git a/packages/grafana-data/src/transformations/fieldReducer.ts b/packages/grafana-data/src/transformations/fieldReducer.ts index 56006b7b43e..ace45415bfc 100644 --- a/packages/grafana-data/src/transformations/fieldReducer.ts +++ b/packages/grafana-data/src/transformations/fieldReducer.ts @@ -132,7 +132,7 @@ export enum ReducerID { } export function getFieldTypeForReducer(id: ReducerID, fallback: FieldType): FieldType { - return id === ReducerID.count + return id === ReducerID.count || id === ReducerID.distinctCount || id === ReducerID.changeCount ? FieldType.number : id === ReducerID.allIsNull || id === ReducerID.allIsZero ? FieldType.boolean diff --git a/packages/grafana-data/src/transformations/transformers/filterByName.ts b/packages/grafana-data/src/transformations/transformers/filterByName.ts index 0f58d0b3f95..8f41b4a6e1a 100644 --- a/packages/grafana-data/src/transformations/transformers/filterByName.ts +++ b/packages/grafana-data/src/transformations/transformers/filterByName.ts @@ -47,7 +47,7 @@ export const getMatcherConfig = ( if (byVariable && variable) { const stringOfNames = variable; - if (/\{.*\}/.test(stringOfNames)) { + if (/^\{.*\}$/.test(stringOfNames)) { const namesFromString = stringOfNames.slice(1).slice(0, -1).split(','); return { id: FieldMatcherID.byNames, options: { names: namesFromString } }; } diff --git a/packages/grafana-data/src/types/config.ts b/packages/grafana-data/src/types/config.ts index 6cec302e4b4..bc679cd8a0d 100644 --- a/packages/grafana-data/src/types/config.ts +++ b/packages/grafana-data/src/types/config.ts @@ -195,7 +195,6 @@ export interface GrafanaConfig { passwordHint: string; loginError?: string; viewersCanEdit: boolean; - editorsCanAdmin: boolean; disableSanitizeHtml: boolean; trustedTypesDefaultPolicyEnabled: boolean; cspReportOnlyEnabled: boolean; diff --git a/packages/grafana-data/src/types/featureToggles.gen.ts b/packages/grafana-data/src/types/featureToggles.gen.ts index edadbb77c33..5e008a732e7 100644 --- a/packages/grafana-data/src/types/featureToggles.gen.ts +++ b/packages/grafana-data/src/types/featureToggles.gen.ts @@ -163,7 +163,6 @@ export interface FeatureToggles { oauthRequireSubClaim?: boolean; newDashboardWithFiltersAndGroupBy?: boolean; cloudWatchNewLabelParsing?: boolean; - accessActionSets?: boolean; disableNumericMetricsSortingInExpressions?: boolean; grafanaManagedRecordingRules?: boolean; queryLibrary?: boolean; @@ -225,7 +224,6 @@ export interface FeatureToggles { alertingUIOptimizeReducer?: boolean; azureMonitorEnableUserAuth?: boolean; alertingNotificationsStepMode?: boolean; - useV2DashboardsAPI?: boolean; feedbackButton?: boolean; unifiedStorageSearchUI?: boolean; elasticsearchCrossClusterSearch?: boolean; @@ -257,6 +255,7 @@ export interface FeatureToggles { assetSriChecks?: boolean; alertRuleRestore?: boolean; grafanaManagedRecordingRulesDatasources?: boolean; + infinityRunQueriesInParallel?: boolean; inviteUserExperimental?: boolean; extraLanguages?: boolean; } diff --git a/packages/grafana-eslint-rules/rules/no-untranslated-strings.cjs b/packages/grafana-eslint-rules/rules/no-untranslated-strings.cjs index 4e8737afe6e..02621e361c6 100644 --- a/packages/grafana-eslint-rules/rules/no-untranslated-strings.cjs +++ b/packages/grafana-eslint-rules/rules/no-untranslated-strings.cjs @@ -1,12 +1,28 @@ // @ts-check +/** @typedef {import('@typescript-eslint/utils').TSESTree.Node} Node */ +/** @typedef {import('@typescript-eslint/utils').TSESTree.JSXElement} JSXElement */ +/** @typedef {import('@typescript-eslint/utils').TSESTree.JSXFragment} JSXFragment */ +/** @typedef {import('@typescript-eslint/utils').TSESLint.RuleModule<'noUntranslatedStrings' | 'noUntranslatedStringsProp' | 'wrapWithTrans' | 'wrapWithT', [{ forceFix: string[] }]>} RuleDefinition */ + +const { + getNodeValue, + getTFixers, + getTransFixers, + canBeFixed, + elementIsTrans, + shouldBeFixed, +} = require('./translation-utils.cjs'); + const { ESLintUtils, AST_NODE_TYPES } = require('@typescript-eslint/utils'); const createRule = ESLintUtils.RuleCreator( (name) => `https://github.com/grafana/grafana/blob/main/packages/grafana-eslint-rules/README.md#${name}` ); +/** @type {string[]} */ const propsToCheck = ['label', 'description', 'placeholder', 'aria-label', 'title', 'text', 'tooltip']; +/** @type {RuleDefinition} */ const noUntranslatedStrings = createRule({ create(context) { return { @@ -17,31 +33,74 @@ const noUntranslatedStrings = createRule({ const isUntranslatedProp = (node.value.type === 'Literal' && node.value.value !== '') || - (node.value.type === 'JSXExpressionContainer' && + (node.value.type === AST_NODE_TYPES.JSXExpressionContainer && (node.value.expression.type === 'Literal' || node.value.expression.type === 'TemplateLiteral')); if (isUntranslatedProp) { + const errorShouldBeFixed = shouldBeFixed(context); + const errorCanBeFixed = canBeFixed(node, context); return context.report({ node, messageId: 'noUntranslatedStringsProp', + fix: errorShouldBeFixed && errorCanBeFixed ? getTFixers(node, context) : undefined, + suggest: errorCanBeFixed + ? [ + { + messageId: 'wrapWithT', + fix: getTFixers(node, context), + }, + ] + : undefined, }); } }, - JSXText(node) { - const ancestors = context.sourceCode.getAncestors(node); - const isEmpty = !node.value.trim(); - const hasTransAncestor = ancestors.some((ancestor) => { - return ( - ancestor.type === AST_NODE_TYPES.JSXElement && - ancestor.openingElement.type === AST_NODE_TYPES.JSXOpeningElement && - ancestor.openingElement.name.type === AST_NODE_TYPES.JSXIdentifier && - ancestor.openingElement.name.name === 'Trans' - ); + /** + * @param {JSXElement|JSXFragment} node + */ + 'JSXElement, JSXFragment'(node) { + const parent = node.parent; + const children = node.children; + const untranslatedTextNodes = children.filter((child) => { + if (child.type === AST_NODE_TYPES.JSXText) { + const hasValue = child.value.trim(); + if (!hasValue) { + return false; + } + const ancestors = context.sourceCode.getAncestors(node); + const hasTransAncestor = + elementIsTrans(node) || + ancestors.some((ancestor) => { + return elementIsTrans(ancestor); + }); + return !hasTransAncestor; + } + return false; }); - if (!isEmpty && !hasTransAncestor) { + + const parentHasChildren = + parent.type === AST_NODE_TYPES.JSXElement || parent.type === AST_NODE_TYPES.JSXFragment; + + // We don't want to report if the parent has a text node, + // as we'd end up doing it twice. This makes it awkward for us to auto fix + const parentHasText = parentHasChildren + ? parent.children.some((child) => child.type === AST_NODE_TYPES.JSXText && getNodeValue(child).trim()) + : false; + + if (untranslatedTextNodes.length && !parentHasText) { + const errorShouldBeFixed = shouldBeFixed(context); + const errorCanBeFixed = canBeFixed(node, context); context.report({ node, messageId: 'noUntranslatedStrings', + fix: errorShouldBeFixed && errorCanBeFixed ? getTransFixers(node, context) : undefined, + suggest: errorCanBeFixed + ? [ + { + messageId: 'wrapWithTrans', + fix: getTransFixers(node, context), + }, + ] + : undefined, }); } }, @@ -50,16 +109,34 @@ const noUntranslatedStrings = createRule({ name: 'no-untranslated-strings', meta: { type: 'suggestion', + hasSuggestions: true, + fixable: 'code', docs: { description: 'Check untranslated strings', }, messages: { noUntranslatedStrings: 'No untranslated strings. Wrap text with ', noUntranslatedStringsProp: `No untranslated strings in text props. Wrap text with or use t()`, + wrapWithTrans: 'Wrap text with for manual key assignment', + wrapWithT: 'Wrap text with t() for manual key assignment', }, - schema: [], + schema: [ + { + type: 'object', + properties: { + forceFix: { + type: 'array', + items: { + type: 'string', + }, + uniqueItems: true, + }, + }, + additionalProperties: false, + }, + ], }, - defaultOptions: [], + defaultOptions: [{ forceFix: [] }], }); module.exports = noUntranslatedStrings; diff --git a/packages/grafana-eslint-rules/rules/translation-utils.cjs b/packages/grafana-eslint-rules/rules/translation-utils.cjs new file mode 100644 index 00000000000..3b23b8dd9ba --- /dev/null +++ b/packages/grafana-eslint-rules/rules/translation-utils.cjs @@ -0,0 +1,310 @@ +// @ts-check +/** @typedef {import('@typescript-eslint/utils').TSESTree.Node} Node */ +/** @typedef {import('@typescript-eslint/utils').TSESTree.JSXAttribute} JSXAttribute */ +/** @typedef {import('@typescript-eslint/utils').TSESTree.JSXElement} JSXElement */ +/** @typedef {import('@typescript-eslint/utils').TSESTree.JSXFragment} JSXFragment */ +/** @typedef {import('@typescript-eslint/utils').TSESTree.JSXText} JSXText */ +/** @typedef {import('@typescript-eslint/utils').TSESTree.JSXChild} JSXChild */ +/** @typedef {import('@typescript-eslint/utils/ts-eslint').RuleFixer} RuleFixer */ +/** @typedef {import('@typescript-eslint/utils/ts-eslint').RuleContext<'noUntranslatedStrings' | 'noUntranslatedStringsProp' | 'wrapWithTrans' | 'wrapWithT', [{forceFix: string[]}]>} RuleContextWithOptions */ + +const { AST_NODE_TYPES } = require('@typescript-eslint/utils'); + +/** + * @param {Node} node + */ +const elementIsTrans = (node) => { + return ( + node.type === AST_NODE_TYPES.JSXElement && + node.openingElement.type === AST_NODE_TYPES.JSXOpeningElement && + node.openingElement.name.type === AST_NODE_TYPES.JSXIdentifier && + node.openingElement.name.name === 'Trans' + ); +}; + +/** + * Converts a string to kebab case + * @param {string} str The string to convert + * @returns {string} The kebab case string + */ +function toKebabCase(str) { + return str + .replace(/([a-z])([A-Z])/g, '$1-$2') + .toLowerCase() + .replace(/\s+/g, '-'); +} + +/** + * Checks if we _should_ fix an error automatically + * @param {RuleContextWithOptions} context + * @returns {boolean} Whether the node should be fixed + */ +function shouldBeFixed(context) { + const pathsThatAreFixable = context.options[0]?.forceFix || []; + return pathsThatAreFixable.some((path) => context.filename.includes(path)); +} + +/** + * Checks if a node can be fixed automatically + * @param {JSXAttribute|JSXElement|JSXFragment} node The node to check + * @param {RuleContextWithOptions} context + * @returns {boolean} Whether the node can be fixed + */ +function canBeFixed(node, context) { + if (!getTranslationPrefix(context)) { + return false; + } + + // We can only fix JSX attribute strings that are within a function, + // otherwise the `t` function call will be made too early + + if (node.type === AST_NODE_TYPES.JSXAttribute) { + const ancestors = context.sourceCode.getAncestors(node); + const isInFunction = ancestors.some((anc) => { + return [ + AST_NODE_TYPES.ArrowFunctionExpression, + AST_NODE_TYPES.FunctionDeclaration, + AST_NODE_TYPES.ClassDeclaration, + ].includes(anc.type); + }); + if (!isInFunction) { + return false; + } + if (node.value?.type === AST_NODE_TYPES.JSXExpressionContainer) { + return false; + } + } + + const values = + node.type === AST_NODE_TYPES.JSXElement || node.type === AST_NODE_TYPES.JSXFragment + ? node.children.map((child) => { + return getNodeValue(child); + }) + : [getNodeValue(node)]; + + const stringIsTooLong = values.some((value) => value.trim().split(' ').length > 10); + // If we have more than 10 words, + // we don't want to fix it automatically as the chance of a duplicate key is higher, + // and it's better for a user to manually decide the key + if (stringIsTooLong) { + return false; + } + const stringIsNonAlphanumeric = values.some((value) => !/[a-zA-Z0-9]/.test(value)); + const stringContainsHTMLEntities = values.some((value) => /(&[a-zA-Z0-9]+;)/.test(value)); + // If node only contains non-alphanumeric characters, + // or contains HTML character entities, then we don't want to autofix + if (stringIsNonAlphanumeric || stringContainsHTMLEntities) { + return false; + } + + return true; +} + +/** + * Gets the translation prefix from the filename + * @param {RuleContextWithOptions} context + * @returns {string|null} The translation prefix or null + */ +function getTranslationPrefix(context) { + const filename = context.getFilename(); + const match = filename.match(/public\/app\/features\/([^/]+)/); + if (match) { + return match[1]; + } + return null; +} + +/** + * Gets the i18n key for a node + * @param {JSXAttribute|JSXText} node The node + * @param {RuleContextWithOptions} context + * @returns {string} The i18n key + */ +const getI18nKey = (node, context) => { + const prefixFromFilePath = getTranslationPrefix(context); + const stringValue = getNodeValue(node); + + const componentNames = getComponentNames(node, context); + const words = stringValue + .trim() + .replace(/[^\a-zA-Z\s]/g, '') + .trim() + .split(/\s+/); + + const maxWordsForKey = 6; + + // If we have more than 6 words, filter out the words that are less than 4 characters + // This heuristic tends to result in a good balance between unique and descriptive keys + const filteredWords = words.length > maxWordsForKey ? words.filter((word) => word.length > 4) : words; + + // If we've filtered everything out, use the original words, deduplicated + const wordsToUse = filteredWords.length === 0 ? words : filteredWords; + const uniqueWords = [...new Set(wordsToUse)].slice(0, maxWordsForKey); + + let kebabString = toKebabCase(uniqueWords.join(' ')); + + if (node.type === AST_NODE_TYPES.JSXAttribute) { + const propName = node.name.name; + const attribute = node.parent?.attributes.find( + (attr) => + attr.type === AST_NODE_TYPES.JSXAttribute && + attr.name.type === AST_NODE_TYPES.JSXIdentifier && + attr && + ['id', 'data-testid'].includes(attr.name?.name) + ); + const potentialId = + attribute && + attribute.type === AST_NODE_TYPES.JSXAttribute && + attribute.value && + attribute.value.type === AST_NODE_TYPES.Literal + ? attribute.value.value + : undefined; + kebabString = [potentialId, propName, kebabString].filter(Boolean).join('-'); + } + + const fullPrefix = [prefixFromFilePath, ...componentNames, kebabString].filter(Boolean).join('.'); + + return fullPrefix; +}; + +/** + * Gets component names from ancestors + * @param {JSXAttribute|JSXText} node The node + * @param {RuleContextWithOptions} context + * @returns {string[]} The component names + */ +function getComponentNames(node, context) { + const names = []; + const ancestors = context.sourceCode.getAncestors(node); + + for (const ancestor of ancestors) { + if ( + ancestor.type === AST_NODE_TYPES.VariableDeclarator || + ancestor.type === AST_NODE_TYPES.FunctionDeclaration || + ancestor.type === AST_NODE_TYPES.ClassDeclaration + ) { + const name = ancestor.id?.type === AST_NODE_TYPES.Identifier ? ancestor.id.name : ''; + // Remove the word "component" from the name, as this is a bit + // redundant in a translation key + const sanitizedName = name.replace(/component/gi, ''); + names.push(toKebabCase(sanitizedName)); + } + } + + return names; +} + +/** + * Gets the import fixer for a node + * @param {JSXElement|JSXFragment|JSXAttribute} node + * @param {RuleFixer} fixer The fixer + * @param {string} importName The import name + * @param {RuleContextWithOptions} context + * @returns {import('@typescript-eslint/utils/ts-eslint').RuleFix|undefined} The fix + */ +function getImportsFixer(node, fixer, importName, context) { + const body = context.sourceCode.ast.body; + + const existingAppCoreI18n = body.find( + (node) => node.type === AST_NODE_TYPES.ImportDeclaration && node.source.value === 'app/core/internationalization' + ); + + // If there's no existing import at all, add it + if (!existingAppCoreI18n) { + return fixer.insertTextBefore(body[0], `import { ${importName} } from 'app/core/internationalization';\n`); + } + + // To keep the typechecker happy - we have to explicitly check the type + // so we can infer it further down + if (existingAppCoreI18n.type !== AST_NODE_TYPES.ImportDeclaration) { + return; + } + + // If there's an existing import, and it already has the importName, do nothing + if ( + existingAppCoreI18n.specifiers.some((s) => { + return ( + s.type === AST_NODE_TYPES.ImportSpecifier && + s.imported.type === AST_NODE_TYPES.Identifier && + s.imported.name === importName + ); + }) + ) { + return; + } + const lastSpecifier = existingAppCoreI18n.specifiers[existingAppCoreI18n.specifiers.length - 1]; + /** @type {[number, number]} */ + const range = [lastSpecifier.range[1], lastSpecifier.range[1]]; + return fixer.insertTextAfterRange(range, `, ${importName}`); +} + +/** + * @param {JSXElement|JSXFragment} node + * @param {RuleContextWithOptions} context + * @returns {(fixer: RuleFixer) => import('@typescript-eslint/utils/ts-eslint').RuleFix[]} + */ +const getTransFixers = (node, context) => (fixer) => { + const fixes = []; + const children = node.children; + children.forEach((child) => { + if (child.type === AST_NODE_TYPES.JSXText) { + const i18nKey = getI18nKey(child, context); + const value = getNodeValue(child); + fixes.push(fixer.replaceText(child, `${value}`)); + } + }); + + const importsFixer = getImportsFixer(node, fixer, 'Trans', context); + if (importsFixer) { + fixes.push(importsFixer); + } + return fixes; +}; + +/** + * @param {JSXAttribute} node + * @param {RuleContextWithOptions} context + * @returns {(fixer: RuleFixer) => import('@typescript-eslint/utils/ts-eslint').RuleFix[]} + */ +const getTFixers = (node, context) => (fixer) => { + const fixes = []; + const i18nKey = getI18nKey(node, context); + const value = getNodeValue(node); + const wrappingQuotes = value.includes('"') ? "'" : '"'; + + fixes.push( + fixer.replaceText(node, `${node.name.name}={t("${i18nKey}", ${wrappingQuotes}${value}${wrappingQuotes})}`) + ); + + const importsFixer = getImportsFixer(node, fixer, 't', context); + if (importsFixer) { + fixes.push(importsFixer); + } + return fixes; +}; + +/** + * Gets the value of a node + * @param {JSXAttribute|JSXText|JSXElement|JSXFragment|JSXChild} node The node + * @returns {string} The node value + */ +function getNodeValue(node) { + if (node.type === AST_NODE_TYPES.JSXAttribute && node.value?.type === AST_NODE_TYPES.Literal) { + return String(node.value.value) || ''; + } + if (node.type === AST_NODE_TYPES.JSXText) { + // Return the raw value if we can, so we can work out if there are any HTML entities + return node.raw; + } + return ''; +} + +module.exports = { + getNodeValue, + getTFixers, + getTransFixers, + getTranslationPrefix, + canBeFixed, + shouldBeFixed, + elementIsTrans, +}; diff --git a/packages/grafana-eslint-rules/tests/no-untranslated-strings.test.js b/packages/grafana-eslint-rules/tests/no-untranslated-strings.test.js new file mode 100644 index 00000000000..b180e67af7a --- /dev/null +++ b/packages/grafana-eslint-rules/tests/no-untranslated-strings.test.js @@ -0,0 +1,453 @@ +import { RuleTester } from 'eslint'; + +import noUntranslatedStrings from '../rules/no-untranslated-strings.cjs'; + +RuleTester.setDefaultConfig({ + languageOptions: { + ecmaVersion: 2018, + sourceType: 'module', + parserOptions: { + ecmaFeatures: { + jsx: true, + }, + }, + }, +}); + +const filename = 'public/app/features/some-feature/SomeFile.tsx'; + +const ruleTester = new RuleTester(); + +ruleTester.run('eslint no-untranslated-strings', noUntranslatedStrings, { + test: [], + valid: [ + { + name: 'Text in Trans component', + code: `const Foo = () => Translated text`, + }, + { + name: 'Text in Trans component with whitespace/JSXText elements', + code: `const Foo = () => + + Translated text + `, + }, + { + name: 'Empty component', + code: `
`, + }, + { + name: 'Text using t() function', + code: `
{t('translated.key', 'Translated text')}
`, + }, + { + name: 'Prop using t() function', + code: `
`, + }, + { + name: 'Variable interpolation', + code: `
{variable}
`, + }, + ], + invalid: [ + /** + * FIXABLE CASES + */ + // Basic happy path case: + // untranslated text, in a component, in a file location where we can extract a prefix, + // and it can be fixed + { + name: 'Basic untranslated text in component', + code: ` +const Foo = () =>
Untranslated text
`, + filename, + errors: [ + { + messageId: 'noUntranslatedStrings', + suggestions: [ + { + messageId: 'wrapWithTrans', + output: ` +import { Trans } from 'app/core/internationalization'; +const Foo = () =>
Untranslated text
`, + }, + ], + }, + ], + }, + + { + name: 'Text inside JSXElement, not in a function', + code: `const thing =
foo
`, + filename, + errors: [ + { + messageId: 'noUntranslatedStrings', + suggestions: [ + { + messageId: 'wrapWithTrans', + output: `import { Trans } from 'app/core/internationalization'; +const thing =
foo
`, + }, + ], + }, + ], + }, + + { + name: 'Fixes medium length strings', + code: ` +const Foo = () =>
This is a longer string that we will translate
`, + filename, + errors: [ + { + messageId: 'noUntranslatedStrings', + suggestions: [ + { + messageId: 'wrapWithTrans', + output: ` +import { Trans } from 'app/core/internationalization'; +const Foo = () =>
This is a longer string that we will translate
`, + }, + ], + }, + ], + }, + + { + name: 'Fixes short strings with many words', + code: ` +const Foo = () =>
lots of sho rt word s to be filt ered
`, + filename, + errors: [ + { + messageId: 'noUntranslatedStrings', + suggestions: [ + { + messageId: 'wrapWithTrans', + output: ` +import { Trans } from 'app/core/internationalization'; +const Foo = () =>
lots of sho rt word s to be filt ered
`, + }, + ], + }, + ], + }, + + { + name: 'expression', + code: ` +const foo = <>hello`, + filename, + errors: [ + { + messageId: 'noUntranslatedStrings', + suggestions: [ + { + messageId: 'wrapWithTrans', + output: ` +import { Trans } from 'app/core/internationalization'; +const foo = <>hello`, + }, + ], + }, + ], + }, + + { + name: 'Fixes strings in JSX in props', + code: ` +const Foo = () =>
Test} />
`, + filename, + errors: [ + { + messageId: 'noUntranslatedStrings', + suggestions: [ + { + messageId: 'wrapWithTrans', + output: ` +import { Trans } from 'app/core/internationalization'; +const Foo = () =>
Test} />
`, + }, + ], + }, + ], + }, + + { + name: 'Fixes and uses ID from attribute if exists', + code: ` +import { t } from 'app/core/internationalization'; +const Foo = () =>
`, + filename, + errors: [ + { + messageId: 'noUntranslatedStringsProp', + suggestions: [ + { + messageId: 'wrapWithT', + output: ` +import { t } from 'app/core/internationalization'; +const Foo = () =>
`, + }, + ], + }, + ], + }, + + { + name: 'Fixes correctly when Trans import already exists', + code: ` +import { Trans } from 'app/core/internationalization'; +const Foo = () =>
Untranslated text
`, + filename, + errors: [ + { + messageId: 'noUntranslatedStrings', + suggestions: [ + { + messageId: 'wrapWithTrans', + output: ` +import { Trans } from 'app/core/internationalization'; +const Foo = () =>
Untranslated text
`, + }, + ], + }, + ], + }, + + { + name: 'Fixes correctly when t() import already exists', + code: ` +import { t } from 'app/core/internationalization'; +const Foo = () =>
`, + filename, + errors: [ + { + messageId: 'noUntranslatedStringsProp', + suggestions: [ + { + messageId: 'wrapWithT', + output: ` +import { t } from 'app/core/internationalization'; +const Foo = () =>
`, + }, + ], + }, + ], + }, + + { + name: 'Fixes correctly when import exists but needs to add t()', + code: ` +import { Trans } from 'app/core/internationalization'; +const Foo = () =>
`, + filename, + errors: [ + { + messageId: 'noUntranslatedStringsProp', + suggestions: [ + { + messageId: 'wrapWithT', + output: ` +import { Trans, t } from 'app/core/internationalization'; +const Foo = () =>
`, + }, + ], + }, + ], + }, + + { + name: 'Fixes correctly with a Class component', + code: ` +class Foo extends React.Component { + render() { + return
untranslated text
; + } +}`, + filename, + errors: [ + { + messageId: 'noUntranslatedStrings', + suggestions: [ + { + messageId: 'wrapWithTrans', + output: ` +import { Trans } from 'app/core/internationalization'; +class Foo extends React.Component { + render() { + return
untranslated text
; + } +}`, + }, + ], + }, + ], + }, + + { + name: 'Fixes basic prop case', + code: ` +const Foo = () =>
`, + filename, + errors: [ + { + messageId: 'noUntranslatedStringsProp', + suggestions: [ + { + messageId: 'wrapWithT', + output: ` +import { t } from 'app/core/internationalization'; +const Foo = () =>
`, + }, + ], + }, + ], + }, + + { + name: 'Fixes prop case with double quotes in value', + code: ` +const Foo = () =>
`, + filename, + errors: [ + { + messageId: 'noUntranslatedStringsProp', + suggestions: [ + { + messageId: 'wrapWithT', + output: ` +import { t } from 'app/core/internationalization'; +const Foo = () =>
`, + }, + ], + }, + ], + }, + + { + name: 'Fixes case with nested functions/components', + code: ` +import { Trans } from 'app/core/internationalization'; +const Foo = () => { + const getSomething = () => { + return
foo
; + } + + return
{getSomething()}
; +} +`, + filename, + errors: [ + { + messageId: 'noUntranslatedStrings', + suggestions: [ + { + messageId: 'wrapWithTrans', + output: ` +import { Trans } from 'app/core/internationalization'; +const Foo = () => { + const getSomething = () => { + return
foo
; + } + + return
{getSomething()}
; +} +`, + }, + ], + }, + ], + }, + + /** + * UNFIXABLE CASES + */ + + { + name: 'Multiple untranslated strings in one element', + code: `const Foo = () =>
test {name} example
`, + filename, + errors: [ + { + messageId: 'noUntranslatedStrings', + }, + ], + }, + + { + name: 'Cannot fix entirely non-alphanumeric text', + code: `const Foo = () =>
-
`, + filename, + errors: [{ messageId: 'noUntranslatedStrings' }], + }, + { + name: 'Cannot fix text with expression sibling', + code: `const Foo = () =>
{name} Hello
`, + filename, + errors: [{ messageId: 'noUntranslatedStrings' }], + }, + + { + name: 'Cannot fix text with expression sibling in fragment', + code: ` +const Foo = () => { + const bar = { + baz: (<>Hello {name}) + } +}`, + filename, + errors: [{ messageId: 'noUntranslatedStrings' }], + }, + + { + name: 'Cannot fix text containing HTML entities', + code: `const Foo = () =>
Something 
`, + filename, + errors: [{ messageId: 'noUntranslatedStrings' }], + }, + + { + name: 'Cannot fix text that is too long', + code: `const Foo = () =>
This is something with lots of text that we don't want to translate automatically
`, + filename, + errors: [{ messageId: 'noUntranslatedStrings' }], + }, + + { + name: 'Cannot fix prop text that is too long', + code: `const Foo = () =>
`, + filename, + errors: [{ messageId: 'noUntranslatedStringsProp' }], + }, + + { + name: 'Cannot fix text with HTML sibling', + code: `const Foo = () =>
something foo bar
`, + filename, + errors: [{ messageId: 'noUntranslatedStrings' }], + }, + + { + name: 'JSXAttribute not in a function', + code: `
`, + filename, + errors: [{ messageId: 'noUntranslatedStringsProp' }], + }, + + { + name: 'Cannot fix JSXExpression in attribute', + code: `const Foo = () =>
`, + filename, + errors: [{ messageId: 'noUntranslatedStringsProp' }], + }, + + { + name: 'Cannot fix text outside correct directory location', + code: `const Foo = () =>
Untranslated text
`, + filename: 'public/something-else/foo/SomeOtherFile.tsx', + errors: [{ messageId: 'noUntranslatedStrings' }], + }, + ], +}); diff --git a/packages/grafana-o11y-ds-frontend/src/IntervalInput/IntervalInput.tsx b/packages/grafana-o11y-ds-frontend/src/IntervalInput/IntervalInput.tsx index 2b29cbea1de..863a6157314 100644 --- a/packages/grafana-o11y-ds-frontend/src/IntervalInput/IntervalInput.tsx +++ b/packages/grafana-o11y-ds-frontend/src/IntervalInput/IntervalInput.tsx @@ -3,7 +3,7 @@ import { useDebounce } from 'react-use'; import { InlineField, Input } from '@grafana/ui'; -import { validateInterval, validateIntervalRegex } from './validation'; +import { validateInterval } from './validation'; interface Props { value: string; @@ -28,14 +28,13 @@ interface FieldProps { } export const IntervalInput = (props: Props) => { - const validationRegex = props.validationRegex || validateIntervalRegex; const [intervalIsInvalid, setIntervalIsInvalid] = useState(() => { - return props.value ? validateInterval(props.value, validationRegex) : false; + return props.value ? validateInterval(props.value, props.validationRegex) : false; }); useDebounce( () => { - setIntervalIsInvalid(validateInterval(props.value, validationRegex)); + setIntervalIsInvalid(validateInterval(props.value, props.validationRegex)); }, 500, [props.value] diff --git a/packages/grafana-o11y-ds-frontend/src/IntervalInput/validation.test.ts b/packages/grafana-o11y-ds-frontend/src/IntervalInput/validation.test.ts index 8de4e2d4327..5d6b3365f21 100644 --- a/packages/grafana-o11y-ds-frontend/src/IntervalInput/validation.test.ts +++ b/packages/grafana-o11y-ds-frontend/src/IntervalInput/validation.test.ts @@ -1,28 +1,28 @@ -import { validateInterval, validateIntervalRegex } from './validation'; +import { validateInterval } from './validation'; describe('Validation', () => { it('should validate incorrect values correctly', () => { - expect(validateInterval('-', validateIntervalRegex)).toBeTruthy(); - expect(validateInterval('1', validateIntervalRegex)).toBeTruthy(); - expect(validateInterval('test', validateIntervalRegex)).toBeTruthy(); - expect(validateInterval('1ds', validateIntervalRegex)).toBeTruthy(); - expect(validateInterval('10Ms', validateIntervalRegex)).toBeTruthy(); - expect(validateInterval('-9999999', validateIntervalRegex)).toBeTruthy(); + expect(validateInterval('-')).toBeTruthy(); + expect(validateInterval('1')).toBeTruthy(); + expect(validateInterval('test')).toBeTruthy(); + expect(validateInterval('1ds')).toBeTruthy(); + expect(validateInterval('10Ms')).toBeTruthy(); + expect(validateInterval('-9999999')).toBeTruthy(); }); it('should validate correct values correctly', () => { - expect(validateInterval('1y', validateIntervalRegex)).toBeFalsy(); - expect(validateInterval('1M', validateIntervalRegex)).toBeFalsy(); - expect(validateInterval('1w', validateIntervalRegex)).toBeFalsy(); - expect(validateInterval('1d', validateIntervalRegex)).toBeFalsy(); - expect(validateInterval('2h', validateIntervalRegex)).toBeFalsy(); - expect(validateInterval('4m', validateIntervalRegex)).toBeFalsy(); - expect(validateInterval('8s', validateIntervalRegex)).toBeFalsy(); - expect(validateInterval('80ms', validateIntervalRegex)).toBeFalsy(); - expect(validateInterval('-80ms', validateIntervalRegex)).toBeFalsy(); + expect(validateInterval('1y')).toBeFalsy(); + expect(validateInterval('1M')).toBeFalsy(); + expect(validateInterval('1w')).toBeFalsy(); + expect(validateInterval('1d')).toBeFalsy(); + expect(validateInterval('2h')).toBeFalsy(); + expect(validateInterval('4m')).toBeFalsy(); + expect(validateInterval('8s')).toBeFalsy(); + expect(validateInterval('80ms')).toBeFalsy(); + expect(validateInterval('-80ms')).toBeFalsy(); }); it('should not return error if no value provided', () => { - expect(validateInterval('', validateIntervalRegex)).toBeFalsy(); + expect(validateInterval('')).toBeFalsy(); }); }); diff --git a/packages/grafana-o11y-ds-frontend/src/IntervalInput/validation.ts b/packages/grafana-o11y-ds-frontend/src/IntervalInput/validation.ts index 44fd754fa2b..28a1ce10393 100644 --- a/packages/grafana-o11y-ds-frontend/src/IntervalInput/validation.ts +++ b/packages/grafana-o11y-ds-frontend/src/IntervalInput/validation.ts @@ -1,6 +1,6 @@ export const validateIntervalRegex = /^(-?\d+(?:\.\d+)?)(ms|[Mwdhmsy])$/; -export const validateInterval = (val: string, regex: RegExp) => { +export const validateInterval = (val: string, regex = validateIntervalRegex) => { const matches = val.match(regex); return matches || !val ? false : true; }; diff --git a/packages/grafana-plugin-configs/tsconfig.json b/packages/grafana-plugin-configs/tsconfig.json index 81e50af6c47..1790c28c284 100644 --- a/packages/grafana-plugin-configs/tsconfig.json +++ b/packages/grafana-plugin-configs/tsconfig.json @@ -3,12 +3,14 @@ "jsx": "react-jsx", "alwaysStrict": true, "declaration": false, - "resolveJsonModule": true + "resolveJsonModule": true, + "moduleResolution": "bundler" }, "ts-node": { "compilerOptions": { "module": "commonjs", "target": "es5", + "moduleResolution": "Node", "esModuleInterop": true }, "transpileOnly": true diff --git a/packages/grafana-prometheus/src/datasource.ts b/packages/grafana-prometheus/src/datasource.ts index fe1607693b7..44e93ebb7d1 100644 --- a/packages/grafana-prometheus/src/datasource.ts +++ b/packages/grafana-prometheus/src/datasource.ts @@ -691,7 +691,7 @@ export class PrometheusDatasource // By implementing getTagKeys and getTagValues we add ad-hoc filters functionality async getTagValues(options: DataSourceGetTagValuesOptions) { const requestId = `[${this.uid}][${options.key}]`; - if (config.featureToggles.promQLScope) { + if (config.featureToggles.promQLScope && (options?.scopes?.length ?? 0) > 0) { return ( await this.languageProvider.fetchSuggestions( options.timeRange, diff --git a/packages/grafana-runtime/src/config.ts b/packages/grafana-runtime/src/config.ts index dd179ea36a6..b0fb666f7f5 100644 --- a/packages/grafana-runtime/src/config.ts +++ b/packages/grafana-runtime/src/config.ts @@ -103,7 +103,6 @@ export class GrafanaBootConfig implements GrafanaConfig { passwordHint = ''; loginError: string | undefined = undefined; viewersCanEdit = false; - editorsCanAdmin = false; disableSanitizeHtml = false; trustedTypesDefaultPolicyEnabled = false; cspReportOnlyEnabled = false; @@ -229,7 +228,6 @@ export class GrafanaBootConfig implements GrafanaConfig { env: 'production', }, viewersCanEdit: false, - editorsCanAdmin: false, disableSanitizeHtml: false, }; diff --git a/packages/grafana-runtime/src/services/ScopesContext.ts b/packages/grafana-runtime/src/services/ScopesContext.ts index 0c7faade62c..5c6a18226e4 100644 --- a/packages/grafana-runtime/src/services/ScopesContext.ts +++ b/packages/grafana-runtime/src/services/ScopesContext.ts @@ -1,14 +1,19 @@ -import { createContext, useContext } from 'react'; +import { createContext, useContext, useMemo } from 'react'; import { useObservable } from 'react-use'; import { Observable } from 'rxjs'; import { Scope } from '@grafana/data'; export interface ScopesContextValueState { + // Whether the drawer with the related dashboards is open drawerOpened: boolean; enabled: boolean; + + // loading state of the scopes loading: boolean; readOnly: boolean; + + // Currently selected scopes value: Scope[]; } @@ -49,13 +54,18 @@ export function useScopes(): ScopesContextValue | undefined { useObservable(context?.stateObservable ?? new Observable(), context?.state); - return context - ? { - state: context.state, - stateObservable: context.stateObservable, - changeScopes: context.changeScopes, - setReadOnly: context.setReadOnly, - setEnabled: context.setEnabled, - } - : undefined; + return useMemo(() => { + return context + ? { + state: context.state, + stateObservable: context.stateObservable, + changeScopes: context.changeScopes, + setReadOnly: context.setReadOnly, + setEnabled: context.setEnabled, + } + : undefined; + // Not sure why it thinks the context?.state is not required, but we want to recreate this when the state changes. + // context.stateObservable is readOnly so that is not needed, others are methods which should not change. + // eslint-disable-next-line react-hooks/exhaustive-deps + }, [context, context?.state]); } diff --git a/packages/grafana-runtime/src/unstable.ts b/packages/grafana-runtime/src/unstable.ts index 5cf9253a7c4..84075dbb08a 100644 --- a/packages/grafana-runtime/src/unstable.ts +++ b/packages/grafana-runtime/src/unstable.ts @@ -9,5 +9,4 @@ * and be subject to the standard policies */ -// Dummy export to make it a valid module. Remove when we have real exports. -export const unstable = {}; +export { useTranslate, setUseTranslateHook } from './utils/i18n'; diff --git a/packages/grafana-runtime/src/utils/i18n.ts b/packages/grafana-runtime/src/utils/i18n.ts new file mode 100644 index 00000000000..f67f63316e5 --- /dev/null +++ b/packages/grafana-runtime/src/utils/i18n.ts @@ -0,0 +1,21 @@ +type UseTranslateHook = () => (id: string, defaultMessage: string, values?: Record) => string; + +/** + * Provides a i18next-compatible translation function. + */ +export let useTranslate: UseTranslateHook = () => { + // Fallback implementation that should be overridden by setUseT + const errorMessage = 'useTranslate is not set. useTranslate must not be called before Grafana is initialized.'; + if (process.env.NODE_ENV === 'development') { + throw new Error(errorMessage); + } + + console.error(errorMessage); + return (id: string, defaultMessage: string) => { + return defaultMessage; + }; +}; + +export function setUseTranslateHook(hook: UseTranslateHook) { + useTranslate = hook; +} diff --git a/packages/grafana-schema/src/schema/dashboard/v2alpha0/dashboard.schema.cue b/packages/grafana-schema/src/schema/dashboard/v2alpha0/dashboard.schema.cue index bb799f4053e..846d0cabd8f 100644 --- a/packages/grafana-schema/src/schema/dashboard/v2alpha0/dashboard.schema.cue +++ b/packages/grafana-schema/src/schema/dashboard/v2alpha0/dashboard.schema.cue @@ -553,6 +553,7 @@ RowsLayoutRowSpec: { title?: string collapsed: bool repeat?: RowRepeatOptions + conditionalRendering?: ConditionalRenderingGroupKind layout: GridLayoutKind | ResponsiveGridLayoutKind | TabsLayoutKind } @@ -575,6 +576,7 @@ ResponsiveGridLayoutItemKind: { ResponsiveGridLayoutItemSpec: { element: ElementReference repeat?: ResponsiveGridRepeatOptions + conditionalRendering?: ConditionalRenderingGroupKind } TabsLayoutKind: { @@ -913,3 +915,42 @@ AdhocVariableKind: { kind: "AdhocVariable" spec: AdhocVariableSpec } + +ConditionalRenderingGroupKind: { + kind: "ConditionalRenderingGroup" + spec: ConditionalRenderingGroupSpec +} + +ConditionalRenderingGroupSpec: { + condition: "and" | "or" + items: [...ConditionalRenderingVariableKind | ConditionalRenderingDataKind | ConditionalRenderingTimeIntervalKind] +} + +ConditionalRenderingVariableKind: { + kind: "ConditionalRenderingVariable" + spec: ConditionalRenderingVariableSpec +} + +ConditionalRenderingVariableSpec: { + variable: string + operator: "equals" | "notEquals" + value: string +} + +ConditionalRenderingDataKind: { + kind: "ConditionalRenderingData" + spec: ConditionalRenderingDataSpec +} + +ConditionalRenderingDataSpec: { + value: bool +} + +ConditionalRenderingTimeIntervalKind: { + kind: "ConditionalRenderingTimeInterval" + spec: ConditionalRenderingTimeIntervalSpec +} + +ConditionalRenderingTimeIntervalSpec: { + value: string +} \ No newline at end of file diff --git a/packages/grafana-schema/src/schema/dashboard/v2alpha0/types.gen.ts b/packages/grafana-schema/src/schema/dashboard/v2alpha0/types.gen.ts index 77bb17e5d4f..895014f6b6c 100644 --- a/packages/grafana-schema/src/schema/dashboard/v2alpha0/types.gen.ts +++ b/packages/grafana-schema/src/schema/dashboard/v2alpha0/types.gen.ts @@ -825,6 +825,7 @@ export interface RowsLayoutRowSpec { title?: string; collapsed: boolean; repeat?: RowRepeatOptions; + conditionalRendering?: ConditionalRenderingGroupKind; layout: GridLayoutKind | ResponsiveGridLayoutKind | TabsLayoutKind; } @@ -868,6 +869,7 @@ export const defaultResponsiveGridLayoutItemKind = (): ResponsiveGridLayoutItemK export interface ResponsiveGridLayoutItemSpec { element: ElementReference; repeat?: ResponsiveGridRepeatOptions; + conditionalRendering?: ConditionalRenderingGroupKind; } export const defaultResponsiveGridLayoutItemSpec = (): ResponsiveGridLayoutItemSpec => ({ @@ -1401,3 +1403,81 @@ export const defaultAdhocVariableKind = (): AdhocVariableKind => ({ spec: defaultAdhocVariableSpec(), }); +export interface ConditionalRenderingGroupKind { + kind: "ConditionalRenderingGroup"; + spec: ConditionalRenderingGroupSpec; +} + +export const defaultConditionalRenderingGroupKind = (): ConditionalRenderingGroupKind => ({ + kind: "ConditionalRenderingGroup", + spec: defaultConditionalRenderingGroupSpec(), +}); + +export interface ConditionalRenderingGroupSpec { + condition: "and" | "or"; + items: (ConditionalRenderingVariableKind | ConditionalRenderingDataKind | ConditionalRenderingTimeIntervalKind)[]; +} + +export const defaultConditionalRenderingGroupSpec = (): ConditionalRenderingGroupSpec => ({ + condition: "and", + items: [], +}); + +export interface ConditionalRenderingVariableKind { + kind: "ConditionalRenderingVariable"; + spec: ConditionalRenderingVariableSpec; +} + +export const defaultConditionalRenderingVariableKind = (): ConditionalRenderingVariableKind => ({ + kind: "ConditionalRenderingVariable", + spec: defaultConditionalRenderingVariableSpec(), +}); + +export interface ConditionalRenderingVariableSpec { + variable: string; + operator: "equals" | "notEquals"; + value: string; +} + +export const defaultConditionalRenderingVariableSpec = (): ConditionalRenderingVariableSpec => ({ + variable: "", + operator: "equals", + value: "", +}); + +export interface ConditionalRenderingDataKind { + kind: "ConditionalRenderingData"; + spec: ConditionalRenderingDataSpec; +} + +export const defaultConditionalRenderingDataKind = (): ConditionalRenderingDataKind => ({ + kind: "ConditionalRenderingData", + spec: defaultConditionalRenderingDataSpec(), +}); + +export interface ConditionalRenderingDataSpec { + value: boolean; +} + +export const defaultConditionalRenderingDataSpec = (): ConditionalRenderingDataSpec => ({ + value: false, +}); + +export interface ConditionalRenderingTimeIntervalKind { + kind: "ConditionalRenderingTimeInterval"; + spec: ConditionalRenderingTimeIntervalSpec; +} + +export const defaultConditionalRenderingTimeIntervalKind = (): ConditionalRenderingTimeIntervalKind => ({ + kind: "ConditionalRenderingTimeInterval", + spec: defaultConditionalRenderingTimeIntervalSpec(), +}); + +export interface ConditionalRenderingTimeIntervalSpec { + value: string; +} + +export const defaultConditionalRenderingTimeIntervalSpec = (): ConditionalRenderingTimeIntervalSpec => ({ + value: "", +}); + diff --git a/packages/grafana-schema/src/schema/dashboard/v2alpha1/types.spec.gen.ts b/packages/grafana-schema/src/schema/dashboard/v2alpha1/types.spec.gen.ts index 477ec4e63ad..9ed8a4765df 100644 --- a/packages/grafana-schema/src/schema/dashboard/v2alpha1/types.spec.gen.ts +++ b/packages/grafana-schema/src/schema/dashboard/v2alpha1/types.spec.gen.ts @@ -692,6 +692,7 @@ export const defaultRowsLayoutRowKind = (): RowsLayoutRowKind => ({ export interface RowsLayoutRowSpec { title?: string; collapsed: boolean; + conditionalRendering?: ConditionalRenderingGroupKind; repeat?: RowRepeatOptions; layout: GridLayoutKind | ResponsiveGridLayoutKind | TabsLayoutKind; } @@ -701,6 +702,84 @@ export const defaultRowsLayoutRowSpec = (): RowsLayoutRowSpec => ({ layout: defaultGridLayoutKind(), }); +export interface ConditionalRenderingGroupKind { + kind: "ConditionalRenderingGroup"; + spec: ConditionalRenderingGroupSpec; +} + +export const defaultConditionalRenderingGroupKind = (): ConditionalRenderingGroupKind => ({ + kind: "ConditionalRenderingGroup", + spec: defaultConditionalRenderingGroupSpec(), +}); + +export interface ConditionalRenderingGroupSpec { + condition: "and" | "or"; + items: (ConditionalRenderingVariableKind | ConditionalRenderingDataKind | ConditionalRenderingTimeIntervalKind)[]; +} + +export const defaultConditionalRenderingGroupSpec = (): ConditionalRenderingGroupSpec => ({ + condition: "and", + items: [], +}); + +export interface ConditionalRenderingVariableKind { + kind: "ConditionalRenderingVariable"; + spec: ConditionalRenderingVariableSpec; +} + +export const defaultConditionalRenderingVariableKind = (): ConditionalRenderingVariableKind => ({ + kind: "ConditionalRenderingVariable", + spec: defaultConditionalRenderingVariableSpec(), +}); + +export interface ConditionalRenderingVariableSpec { + variable: string; + operator: "equals" | "notEquals"; + value: string; +} + +export const defaultConditionalRenderingVariableSpec = (): ConditionalRenderingVariableSpec => ({ + variable: "", + operator: "equals", + value: "", +}); + +export interface ConditionalRenderingDataKind { + kind: "ConditionalRenderingData"; + spec: ConditionalRenderingDataSpec; +} + +export const defaultConditionalRenderingDataKind = (): ConditionalRenderingDataKind => ({ + kind: "ConditionalRenderingData", + spec: defaultConditionalRenderingDataSpec(), +}); + +export interface ConditionalRenderingDataSpec { + value: boolean; +} + +export const defaultConditionalRenderingDataSpec = (): ConditionalRenderingDataSpec => ({ + value: false, +}); + +export interface ConditionalRenderingTimeIntervalKind { + kind: "ConditionalRenderingTimeInterval"; + spec: ConditionalRenderingTimeIntervalSpec; +} + +export const defaultConditionalRenderingTimeIntervalKind = (): ConditionalRenderingTimeIntervalKind => ({ + kind: "ConditionalRenderingTimeInterval", + spec: defaultConditionalRenderingTimeIntervalSpec(), +}); + +export interface ConditionalRenderingTimeIntervalSpec { + value: string; +} + +export const defaultConditionalRenderingTimeIntervalSpec = (): ConditionalRenderingTimeIntervalSpec => ({ + value: "", +}); + export interface ResponsiveGridLayoutKind { kind: "ResponsiveGridLayout"; spec: ResponsiveGridLayoutSpec; @@ -736,6 +815,7 @@ export const defaultResponsiveGridLayoutItemKind = (): ResponsiveGridLayoutItemK export interface ResponsiveGridLayoutItemSpec { element: ElementReference; repeat?: ResponsiveGridRepeatOptions; + conditionalRendering?: ConditionalRenderingGroupKind; } export const defaultResponsiveGridLayoutItemSpec = (): ResponsiveGridLayoutItemSpec => ({ diff --git a/packages/grafana-ui/package.json b/packages/grafana-ui/package.json index f40abc40963..ac504ce2cc8 100644 --- a/packages/grafana-ui/package.json +++ b/packages/grafana-ui/package.json @@ -18,6 +18,22 @@ }, "main": "src/index.ts", "types": "src/index.ts", + "module": "src/index.ts", + "exports": { + "./package.json": "./package.json", + ".": { + "import": "./src/index.ts", + "require": "./src/index.ts" + }, + "./internal": { + "import": "./src/internal/index.ts", + "require": "./src/internal/index.ts" + }, + "./unstable": { + "import": "./src/unstable.ts", + "require": "./src/unstable.ts" + } + }, "publishConfig": { "main": "./dist/cjs/index.cjs", "module": "./dist/esm/index.mjs", diff --git a/packages/grafana-ui/src/components/Combobox/Combobox.story.tsx b/packages/grafana-ui/src/components/Combobox/Combobox.story.tsx index fe3c9bca3f5..4a2ee2c627f 100644 --- a/packages/grafana-ui/src/components/Combobox/Combobox.story.tsx +++ b/packages/grafana-ui/src/components/Combobox/Combobox.story.tsx @@ -7,7 +7,7 @@ import { Field } from '../Forms/Field'; import { Combobox, ComboboxProps } from './Combobox'; import mdx from './Combobox.mdx'; -import { fakeSearchAPI, generateOptions } from './storyUtils'; +import { fakeSearchAPI, generateGroupingOptions, generateOptions } from './storyUtils'; import { ComboboxOption } from './types'; type PropsAndCustomArgs = ComboboxProps & { @@ -107,6 +107,14 @@ export const CustomValue: Story = { render: BaseCombobox, }; +export const Groups: Story = { + args: { + options: await generateGroupingOptions(500), + value: '34', + }, + render: BaseCombobox, +}; + export const ManyOptions: Story = { args: { numberOfOptions: 1e5, diff --git a/packages/grafana-ui/src/components/Combobox/Combobox.test.tsx b/packages/grafana-ui/src/components/Combobox/Combobox.test.tsx index e54c94d1977..9058f716ccf 100644 --- a/packages/grafana-ui/src/components/Combobox/Combobox.test.tsx +++ b/packages/grafana-ui/src/components/Combobox/Combobox.test.tsx @@ -151,6 +151,49 @@ describe('Combobox', () => { expect(screen.getByRole('option', { name: 'Default' })).toHaveAttribute('aria-selected', 'true'); }); + describe('groups', () => { + it('renders group headers', async () => { + const options = [ + { label: 'Option 1', value: '1', group: 'Group 1' }, + { label: 'Option 2', value: '2', group: 'Group 1' }, + { label: 'Option 3', value: '3', group: 'Group 2' }, + { label: 'Option 4', value: '4', group: 'Group 2' }, + ]; + + render(); + + const input = screen.getByRole('combobox'); + await userEvent.click(input); + + expect(screen.getByText('Group 1')).toBeInTheDocument(); + expect(screen.getByText('Group 2')).toBeInTheDocument(); + }); + + it('sorts options within groups', async () => { + const options = [ + { label: 'Option 1', value: '1', group: 'Group 1' }, + { label: 'Option 2', value: '2', group: 'Group 2' }, + { label: 'Option 3', value: '3', group: 'Group 1' }, + { label: 'Option 4', value: '4', group: 'Group 2' }, + { label: 'Option 5', value: '5', group: 'Group 2' }, + { label: 'Option 6', value: '6', group: 'Group 1' }, + ]; + + render(); + + const input = screen.getByRole('combobox'); + await userEvent.click(input); + + const allHeaders = await screen.findAllByRole('presentation'); + expect(allHeaders).toHaveLength(2); + + const listbox = await screen.findByRole('listbox'); + expect(listbox).toHaveTextContent( + ['Group 1', 'Option 1', 'Option 3', 'Option 6', 'Group 2', 'Option 2', 'Option 4', 'Option 5'].join('') + ); + }); + }); + describe('size support', () => { it('should require minWidth to be set with auto width', () => { // @ts-expect-error diff --git a/packages/grafana-ui/src/components/Combobox/Combobox.tsx b/packages/grafana-ui/src/components/Combobox/Combobox.tsx index 2a1ea6ae28c..e7096544fe7 100644 --- a/packages/grafana-ui/src/components/Combobox/Combobox.tsx +++ b/packages/grafana-ui/src/components/Combobox/Combobox.tsx @@ -1,7 +1,7 @@ import { cx } from '@emotion/css'; -import { useVirtualizer } from '@tanstack/react-virtual'; +import { useVirtualizer, type Range } from '@tanstack/react-virtual'; import { useCombobox } from 'downshift'; -import { useId, useMemo } from 'react'; +import { useCallback, useId, useMemo } from 'react'; import { useStyles2 } from '../../themes'; import { t } from '../../utils/i18n'; @@ -17,6 +17,7 @@ import { getComboboxStyles, MENU_OPTION_HEIGHT, MENU_OPTION_HEIGHT_DESCRIPTION } import { ComboboxOption } from './types'; import { useComboboxFloat } from './useComboboxFloat'; import { useOptions } from './useOptions'; +import { isNewGroup } from './utils'; // TODO: It would be great if ComboboxOption["label"] was more generic so that if consumers do pass it in (for async), // then the onChange handler emits ComboboxOption with the label as non-undefined. @@ -129,9 +130,11 @@ export const Combobox = (props: ComboboxProps) => // Value can be an actual scalar Value (string or number), or an Option (value + label), so // get a consistent Value from it const value = typeof valueProp === 'object' ? valueProp?.value : valueProp; + const baseId = useId().replace(/:/g, '--'); const { options: filteredOptions, + groupStartIndices, updateOptions, asyncLoading, asyncError, @@ -167,20 +170,52 @@ export const Combobox = (props: ComboboxProps) => return typeof valueProp === 'object' ? valueProp : { value: valueProp, label: valueProp.toString() }; }, [selectedItemIndex, isAsync, valueProp, allOptions]); - const menuId = `downshift-${useId().replace(/:/g, '--')}-menu`; - const labelId = `downshift-${useId().replace(/:/g, '--')}-label`; + const menuId = `${baseId}-downshift-menu`; + const labelId = `${baseId}-downshift-label`; const styles = useStyles2(getComboboxStyles); - const virtualizerOptions = { + // Injects the group header for the first rendered item into the range to render. + // Accepts the range that useVirtualizer wants to render, and then returns indexes + // to actually render. + const rangeExtractor = useCallback( + (range: Range) => { + const startIndex = Math.max(0, range.startIndex - range.overscan); + const endIndex = Math.min(filteredOptions.length - 1, range.endIndex + range.overscan); + const rangeToReturn = Array.from({ length: endIndex - startIndex + 1 }, (_, i) => startIndex + i); + + // If the first item doesn't have a group, no need to find a header for it + const firstDisplayedOption = filteredOptions[rangeToReturn[0]]; + if (firstDisplayedOption?.group) { + const groupStartIndex = groupStartIndices.get(firstDisplayedOption.group); + if (groupStartIndex !== undefined && groupStartIndex < rangeToReturn[0]) { + rangeToReturn.unshift(groupStartIndex); + } + } + + return rangeToReturn; + }, + [filteredOptions, groupStartIndices] + ); + + const rowVirtualizer = useVirtualizer({ count: filteredOptions.length, getScrollElement: () => scrollRef.current, - estimateSize: (index: number) => - filteredOptions[index].description ? MENU_OPTION_HEIGHT_DESCRIPTION : MENU_OPTION_HEIGHT, + estimateSize: (index: number) => { + const firstGroupItem = isNewGroup(filteredOptions[index], index > 0 ? filteredOptions[index - 1] : undefined); + const hasDescription = 'description' in filteredOptions[index]; + let itemHeight = MENU_OPTION_HEIGHT; + if (hasDescription) { + itemHeight = MENU_OPTION_HEIGHT_DESCRIPTION; + } + if (firstGroupItem) { + itemHeight += MENU_OPTION_HEIGHT; + } + return itemHeight; + }, overscan: VIRTUAL_OVERSCAN_ITEMS, - }; - - const rowVirtualizer = useVirtualizer(virtualizerOptions); + rangeExtractor, + }); const { isOpen, @@ -271,8 +306,8 @@ export const Combobox = (props: ComboboxProps) => const { inputRef, floatingRef, floatStyles, scrollRef } = useComboboxFloat(filteredOptions, isOpen); const isAutoSize = width === 'auto'; - const InputComponent = isAutoSize ? AutoSizeInput : Input; + const placeholder = (isOpen ? itemToString(selectedItem) : null) || placeholderProp; const suffixIcon = asyncLoading ? 'spinner' @@ -281,7 +316,29 @@ export const Combobox = (props: ComboboxProps) => ? 'search' : 'angle-down'; - const placeholder = (isOpen ? itemToString(selectedItem) : null) || placeholderProp; + const inputSuffix = ( + <> + {value && value === selectedItem?.value && isClearable && ( + { + selectItem(null); + }} + onKeyDown={(e) => { + if (e.key === 'Enter' || e.key === ' ') { + selectItem(null); + } + }} + /> + )} + + + + ); return (
@@ -294,36 +351,10 @@ export const Combobox = (props: ComboboxProps) => loading={loading} invalid={invalid} className={styles.input} - suffix={ - <> - {!!value && value === selectedItem?.value && isClearable && ( - { - selectItem(null); - }} - onKeyDown={(e) => { - if (e.key === 'Enter' || e.key === ' ') { - selectItem(null); - } - }} - /> - )} - - - - } + suffix={inputSuffix} {...getInputProps({ ref: inputRef, - /* Empty onCall to avoid TS error - * See issue here: https://github.com/downshift-js/downshift/issues/718 - * Downshift repo: https://github.com/downshift-js/downshift/tree/master - */ - onChange: noop, + onChange: noop, // Empty onCall to avoid TS error https://github.com/downshift-js/downshift/issues/718 'aria-labelledby': ariaLabelledBy, // Label should be handled with the Field component placeholder, })} @@ -331,9 +362,7 @@ export const Combobox = (props: ComboboxProps) =>
(props: ComboboxProps) => {isOpen && ( {!asyncError && ( -
    - {rowVirtualizer.getVirtualItems().map((virtualRow) => { +
    + {rowVirtualizer.getVirtualItems().map((virtualRow, index, allVirtualRows) => { const item = filteredOptions[virtualRow.index]; + const startingNewGroup = isNewGroup(item, filteredOptions[virtualRow.index - 1]); + + // Find the item that renders the group header. It can be this same item if this is rendering it. + const groupHeaderIndex = allVirtualRows.find((row) => { + const rowItem = filteredOptions[row.index]; + return rowItem.group === item.group; + }); + const groupHeaderItem = groupHeaderIndex && filteredOptions[groupHeaderIndex.index]; + + const itemId = `${baseId}-option-${item.value}`; + // If we're rendering the group header, this is the ID for it. Otherwise its used on + // the option for aria-describedby. + const groupHeaderId = groupHeaderItem + ? `${baseId}-option-group-${groupHeaderItem.value}` + : undefined; return ( -
  • -
    - {item.label ?? item.value} - {item.description && {item.description}} + {startingNewGroup && ( + + )} + +
    +
    + {item.label ?? item.value} + {item.description && {item.description}} +
    -
  • +
    ); })} -
+
)} +
{asyncError && } {filteredOptions.length === 0 && !asyncError && } diff --git a/packages/grafana-ui/src/components/Combobox/MultiCombobox.tsx b/packages/grafana-ui/src/components/Combobox/MultiCombobox.tsx index 7d18074910a..561cffbf2c2 100644 --- a/packages/grafana-ui/src/components/Combobox/MultiCombobox.tsx +++ b/packages/grafana-ui/src/components/Combobox/MultiCombobox.tsx @@ -27,6 +27,7 @@ import { useComboboxFloat } from './useComboboxFloat'; import { MAX_SHOWN_ITEMS, useMeasureMulti } from './useMeasureMulti'; import { useMultiInputAutoSize } from './useMultiInputAutoSize'; import { useOptions } from './useOptions'; +import { isNewGroup } from './utils'; interface MultiComboboxBaseProps extends Omit, 'value' | 'onChange'> { value?: T[] | Array>; @@ -353,6 +354,7 @@ export const MultiCombobox = (props: MultiComboboxPro const itemProps = getItemProps({ item, index }); const isSelected = isOptionSelected(item); const id = 'multicombobox-option-' + item.value.toString(); + const groupHeaderid = 'multicombobox-option-group-' + item.value.toString(); const isAll = item.value === ALL_OPTION_VALUE; // TODO: fix bug where if the search filtered items list is the @@ -373,7 +375,7 @@ export const MultiCombobox = (props: MultiComboboxPro
@@ -453,17 +455,3 @@ function isComboboxOptions( ): value is Array> { return typeof value[0] === 'object'; } - -const isNewGroup = (option: ComboboxOption, prevOption?: ComboboxOption) => { - const currentGroup = option.group; - - if (!currentGroup) { - return prevOption?.group ? true : false; - } - - if (!prevOption) { - return true; - } - - return prevOption.group !== currentGroup; -}; diff --git a/packages/grafana-ui/src/components/Combobox/OptionListItem.tsx b/packages/grafana-ui/src/components/Combobox/OptionListItem.tsx index 3a929be51a9..bf06e00d823 100644 --- a/packages/grafana-ui/src/components/Combobox/OptionListItem.tsx +++ b/packages/grafana-ui/src/components/Combobox/OptionListItem.tsx @@ -1,12 +1,13 @@ import { cx } from '@emotion/css'; +import { ReactNode } from 'react'; import { useStyles2 } from '../../themes'; import { getComboboxStyles } from './getComboboxStyles'; interface Props { - label: string; - description?: string; + label: ReactNode; + description?: ReactNode; id: string; isGroup?: boolean; } diff --git a/packages/grafana-ui/src/components/Combobox/getComboboxStyles.ts b/packages/grafana-ui/src/components/Combobox/getComboboxStyles.ts index 7bee7c19199..7f721a51d53 100644 --- a/packages/grafana-ui/src/components/Combobox/getComboboxStyles.ts +++ b/packages/grafana-ui/src/components/Combobox/getComboboxStyles.ts @@ -32,6 +32,27 @@ export const getComboboxStyles = (theme: GrafanaTheme2) => { label: 'combobox-menu-ul-container', listStyle: 'none', }), + + // New class for on the virtual list item. Should be on the wrapper around the group header and option. + listItem: css({ + label: 'list-item', + width: '100%', + position: 'absolute', + }), + + // New class used in single combobox group headers + newOptionGroup: css({ + label: 'combobox-new-option-group', + textOverflow: 'ellipsis', + overflow: 'hidden', + letterSpacing: 0, + color: theme.colors.text.secondary, + fontSize: theme.typography.bodySmall.fontSize, + fontWeight: theme.typography.fontWeightLight, + padding: MENU_ITEM_PADDING, + borderTop: `1px solid ${theme.colors.border.weak}`, + }), + optionBasic: css({ label: 'combobox-option', position: 'absolute', @@ -55,6 +76,8 @@ export const getComboboxStyles = (theme: GrafanaTheme2) => { }, }, }), + + /** @deprecated - only used in multicombobox, will refactor it */ optionGroup: css({ cursor: 'default', padding: MENU_ITEM_PADDING, @@ -74,8 +97,10 @@ export const getComboboxStyles = (theme: GrafanaTheme2) => { overflow: 'hidden', fontSize: MENU_ITEM_FONT_SIZE, fontWeight: MENU_ITEM_FONT_WEIGHT, + lineHeight: MENU_ITEM_LINE_HEIGHT, letterSpacing: 0, // pr todo: text in grafana has a slightly different letter spacing, which causes measureText() to be ~5% off }), + /** @deprecated - only used in multicombobox, will refactor it */ optionLabelGroup: css({ label: 'combobox-option-label-group', color: theme.colors.text.secondary, @@ -93,7 +118,7 @@ export const getComboboxStyles = (theme: GrafanaTheme2) => { }), optionFocused: css({ label: 'combobox-option-focused', - top: 0, + // top: 0, background: theme.colors.action.focus, '@media (forced-colors: active), (prefers-contrast: more)': { border: `1px solid ${theme.colors.primary.border}`, diff --git a/packages/grafana-ui/src/components/Combobox/storyUtils.ts b/packages/grafana-ui/src/components/Combobox/storyUtils.ts index d39040a6121..481b147b4ea 100644 --- a/packages/grafana-ui/src/components/Combobox/storyUtils.ts +++ b/packages/grafana-ui/src/components/Combobox/storyUtils.ts @@ -42,6 +42,6 @@ export async function generateGroupingOptions(amount: number): Promise ({ label: 'Option ' + index, value: index.toString(), - group: index % 9 !== 0 ? 'Group ' + Math.floor(index / 10) : undefined, + group: index % 19 !== 0 ? 'Group ' + Math.floor(index / 20) : undefined, })); } diff --git a/packages/grafana-ui/src/components/Combobox/useOptions.ts b/packages/grafana-ui/src/components/Combobox/useOptions.ts index fffad1613cb..7801fe5b007 100644 --- a/packages/grafana-ui/src/components/Combobox/useOptions.ts +++ b/packages/grafana-ui/src/components/Combobox/useOptions.ts @@ -92,43 +92,64 @@ export function useOptions(rawOptions: AsyncOptions>) => { - const groupedOptions = new Map>>(); - for (const option of options) { - const groupExists = groupedOptions.has(option.group); - if (groupExists) { - groupedOptions.get(option.group)?.push(option); - } else { - groupedOptions.set(option.group, [option]); - } - } - - // Reorganize options to have groups first, then undefined group - const reorganizeOptions = []; - for (const [group, groupOptions] of groupedOptions) { - if (!group) { - continue; - } - reorganizeOptions.push(...groupOptions); - } - - const undefinedGroupOptions = groupedOptions.get(undefined); - if (undefinedGroupOptions) { - reorganizeOptions.push(...undefinedGroupOptions); - } - return reorganizeOptions; - }, []); - const stringifiedOptions = useMemo(() => { return isAsync ? [] : rawOptions.map(itemToString); }, [isAsync, rawOptions]); - const finalOptions = useMemo(() => { - const currentOptions = isAsync ? asyncOptions : fuzzyFind(rawOptions, stringifiedOptions, userTypedSearch); - const currentOptionsOrganised = organizeOptionsByGroup(currentOptions); + // Create a list of options filtered by the current search. + // If async, just returns the async options. + const filteredOptions = useMemo(() => { + if (isAsync) { + return asyncOptions; + } - return addCustomValue(currentOptionsOrganised); - }, [isAsync, organizeOptionsByGroup, addCustomValue, asyncOptions, rawOptions, userTypedSearch, stringifiedOptions]); + return fuzzyFind(rawOptions, stringifiedOptions, userTypedSearch); + }, [asyncOptions, isAsync, rawOptions, stringifiedOptions, userTypedSearch]); - return { options: finalOptions, updateOptions, asyncLoading, asyncError }; + const [finalOptions, groupStartIndices] = useMemo(() => { + const { options, groupStartIndices } = sortByGroup(filteredOptions); + + return [addCustomValue(options), groupStartIndices]; + }, [filteredOptions, addCustomValue]); + + return { options: finalOptions, groupStartIndices, updateOptions, asyncLoading, asyncError }; +} + +function sortByGroup(options: Array>) { + const groupedOptions = new Map>>(); + for (const option of options) { + const groupExists = groupedOptions.has(option.group); + if (groupExists) { + groupedOptions.get(option.group)?.push(option); + } else { + groupedOptions.set(option.group, [option]); + } + } + + // Create a map to track the starting index of each group + const groupStartIndices = new Map(); + let currentIndex = 0; + + // Reorganize options to have groups first, then undefined group + const reorganizeOptions = []; + for (const [group, groupOptions] of groupedOptions) { + if (!group) { + continue; + } + + groupStartIndices.set(group, currentIndex); + reorganizeOptions.push(...groupOptions); + currentIndex += groupOptions.length; + } + + const undefinedGroupOptions = groupedOptions.get(undefined); + if (undefinedGroupOptions) { + groupStartIndices.set('undefined', currentIndex); + reorganizeOptions.push(...undefinedGroupOptions); + } + + return { + options: reorganizeOptions, + groupStartIndices, + }; } diff --git a/packages/grafana-ui/src/components/Combobox/utils.ts b/packages/grafana-ui/src/components/Combobox/utils.ts new file mode 100644 index 00000000000..e335e572ce0 --- /dev/null +++ b/packages/grafana-ui/src/components/Combobox/utils.ts @@ -0,0 +1,15 @@ +import { ComboboxOption } from './types'; + +export const isNewGroup = (option: ComboboxOption, prevOption?: ComboboxOption) => { + const currentGroup = option.group; + + if (!currentGroup) { + return prevOption?.group ? true : false; + } + + if (!prevOption) { + return true; + } + + return prevOption.group !== currentGroup; +}; diff --git a/packages/grafana-ui/src/components/DataSourceSettings/DataSourceHttpSettings.story.tsx b/packages/grafana-ui/src/components/DataSourceSettings/DataSourceHttpSettings.story.tsx index a1b51c6e78a..3557ef84dd6 100644 --- a/packages/grafana-ui/src/components/DataSourceSettings/DataSourceHttpSettings.story.tsx +++ b/packages/grafana-ui/src/components/DataSourceSettings/DataSourceHttpSettings.story.tsx @@ -32,7 +32,7 @@ const settingsMock: HttpSettingsProps['dataSourceConfig'] = { password: true, }, secureJsonFields: {}, - readOnly: true, + readOnly: false, }; const meta: Meta = { diff --git a/packages/grafana-ui/src/components/DataSourceSettings/DataSourceHttpSettings.tsx b/packages/grafana-ui/src/components/DataSourceSettings/DataSourceHttpSettings.tsx index e4f0b29f2bd..cfaaf990d37 100644 --- a/packages/grafana-ui/src/components/DataSourceSettings/DataSourceHttpSettings.tsx +++ b/packages/grafana-ui/src/components/DataSourceSettings/DataSourceHttpSettings.tsx @@ -1,5 +1,5 @@ -import { css, cx } from '@emotion/css'; -import { useState, useCallback, useId } from 'react'; +import { css } from '@emotion/css'; +import { useState, useCallback, useId, useMemo } from 'react'; import { SelectableValue } from '@grafana/data'; import { selectors } from '@grafana/e2e-selectors'; @@ -7,12 +7,13 @@ import { selectors } from '@grafana/e2e-selectors'; import { useTheme2 } from '../../themes'; import { t, Trans } from '../../utils/i18n'; import { Alert } from '../Alert/Alert'; -import { FormField } from '../FormField/FormField'; -import { InlineFormLabel } from '../FormLabel/FormLabel'; +import { Button } from '../Button'; +import { Field } from '../Forms/Field'; import { InlineField } from '../Forms/InlineField'; -import { Input } from '../Forms/Legacy/Input/Input'; +import { RadioButtonGroup } from '../Forms/RadioButtonGroup/RadioButtonGroup'; import { Icon } from '../Icon/Icon'; -import { Select } from '../Select/Select'; +import { Input } from '../Input/Input'; +import { Stack } from '../Layout/Stack/Stack'; import { InlineSwitch } from '../Switch/Switch'; import { TagsInput } from '../TagsInput/TagsInput'; import { Text } from '../Text/Text'; @@ -24,26 +25,16 @@ import { SecureSocksProxySettings } from './SecureSocksProxySettings'; import { TLSAuthSettings } from './TLSAuthSettings'; import { HttpSettingsProps } from './types'; -const ACCESS_OPTIONS: Array> = [ - { - label: t('grafana-ui.data-source-http-settings.access-options-proxy', 'Server (default)'), - value: 'proxy', - }, - { - label: t('grafana-ui.data-source-http-settings.access-options-browser', 'Browser'), - value: 'direct', - }, -]; - -const DEFAULT_ACCESS_OPTION = { - label: t('grafana-ui.data-source-http-settings.access-options-proxy', 'Server (default)'), - value: 'proxy', -}; +const ACCESS_HELP_ID = 'grafana-http-access-help'; const HttpAccessHelp = () => { return ( - // eslint-disable-next-line @grafana/no-untranslated-strings - +

Access mode controls how requests to the data source will be handled. @@ -79,6 +70,9 @@ const HttpAccessHelp = () => { const LABEL_WIDTH = 26; +/** + * @deprecated Use components from `@grafana/plugin-ui` instead, according to the [migration guide](https://github.com/grafana/plugin-ui/blob/main/src/components/ConfigEditor/migrating-from-datasource-http-settings.md). + */ export const DataSourceHttpSettings = (props: HttpSettingsProps) => { const { defaultUrl, @@ -94,6 +88,22 @@ export const DataSourceHttpSettings = (props: HttpSettingsProps) => { urlDocs, } = props; + const ACCESS_OPTIONS: Array> = useMemo( + () => [ + { + label: t('grafana-ui.data-source-http-settings.server-mode-label', 'Server (default)'), + value: 'proxy', + }, + { + label: t('grafana-ui.data-source-http-settings.browser-mode-label', 'Browser'), + value: 'direct', + }, + ], + [] + ); + + const DEFAULT_ACCESS_OPTION = useMemo(() => ACCESS_OPTIONS[0], [ACCESS_OPTIONS]); + const [isAccessHelpVisible, setIsAccessHelpVisible] = useState(false); const [azureAuthEnabled, setAzureAuthEnabled] = useState(false); const theme = useTheme2(); @@ -160,246 +170,235 @@ export const DataSourceHttpSettings = (props: HttpSettingsProps) => { ); } - const accessSelect = ( - onSettingsChange({ url: event.currentTarget.value })} - disabled={dataSourceConfig.readOnly} - /> - ); - return ( -

- <> + +

HTTP

-
-
- -
- {showAccessOptions && ( - <> -
-
- -
-
- -
-
- {isAccessHelpVisible && } - - )} - {dataSourceConfig.access === 'proxy' && ( -
-
- - Allowed cookies - - - onSettingsChange({ jsonData: { ...dataSourceConfig.jsonData, keepCookies: cookies } }) + + onSettingsChange({ url: event.currentTarget.value })} + /> + + + {showAccessOptions && ( + <> + + + o.value === dataSourceConfig.access)?.value || + DEFAULT_ACCESS_OPTION.value } - disabled={dataSourceConfig.readOnly} + onChange={(selectedValue) => onSettingsChange({ access: selectedValue })} /> -
-
- { - onSettingsChange({ - jsonData: { ...dataSourceConfig.jsonData, timeout: parseInt(event.currentTarget.value, 10) }, - }); - }} - disabled={dataSourceConfig.readOnly} - /> -
-
- )} -
- + + + - <> + {isAccessHelpVisible && } + + )} + {dataSourceConfig.access === 'proxy' && ( + <> + + + onSettingsChange({ jsonData: { ...dataSourceConfig.jsonData, keepCookies: cookies } }) + } + disabled={dataSourceConfig.readOnly} + /> + + + + { + onSettingsChange({ + jsonData: { ...dataSourceConfig.jsonData, timeout: parseInt(event.currentTarget.value, 10) }, + }); + }} + /> + + + )} +
+ +

Auth

-
-
- - { - onSettingsChange({ basicAuth: event!.currentTarget.checked }); - }} - /> - - - - { - onSettingsChange({ withCredentials: event!.currentTarget.checked }); - }} - /> - -
- - {azureAuthSettings?.azureAuthSupported && ( -
+ +
+
+ { + onSettingsChange({ basicAuth: event!.currentTarget.checked }); + }} + /> + + + { - onSettingsChange( - azureAuthSettings.setAzureAuthEnabled(dataSourceConfig, event!.currentTarget.checked) - ); + onSettingsChange({ withCredentials: event!.currentTarget.checked }); }} /> + + {azureAuthSettings?.azureAuthSupported && ( + + { + onSettingsChange( + azureAuthSettings.setAzureAuthEnabled(dataSourceConfig, event!.currentTarget.checked) + ); + }} + /> + + )} + + {sigV4AuthToggleEnabled && ( + + { + onSettingsChange({ + jsonData: { ...dataSourceConfig.jsonData, sigV4Auth: event!.currentTarget.checked }, + }); + }} + /> + + )}
+ + {dataSourceConfig.access === 'proxy' && ( + onSettingsChange({ jsonData })} + showForwardOAuthIdentityOption={azureAuthEnabled ? false : showForwardOAuthIdentityOption} + /> + )} +
+ + {dataSourceConfig.basicAuth && ( +
+ + Basic Auth Details + + + +
)} - {sigV4AuthToggleEnabled && ( -
- - { - onSettingsChange({ - jsonData: { ...dataSourceConfig.jsonData, sigV4Auth: event!.currentTarget.checked }, - }); - }} - /> - -
+ {azureAuthSettings?.azureAuthSupported && azureAuthEnabled && azureAuthSettings.azureSettingsUI && ( + + )} + + {dataSourceConfig.jsonData.sigV4Auth && sigV4AuthToggleEnabled && renderSigV4Editor} + {(dataSourceConfig.jsonData.tlsAuth || dataSourceConfig.jsonData.tlsAuthWithCACert) && ( + )} {dataSourceConfig.access === 'proxy' && ( - onSettingsChange({ jsonData })} - showForwardOAuthIdentityOption={azureAuthEnabled ? false : showForwardOAuthIdentityOption} - /> + )} -
- {dataSourceConfig.basicAuth && ( - <> -
- Basic Auth Details -
-
- -
- - )} - - {azureAuthSettings?.azureAuthSupported && azureAuthEnabled && azureAuthSettings.azureSettingsUI && ( - - )} - - {dataSourceConfig.jsonData.sigV4Auth && sigV4AuthToggleEnabled && renderSigV4Editor} - {(dataSourceConfig.jsonData.tlsAuth || dataSourceConfig.jsonData.tlsAuthWithCACert) && ( - - )} - - {dataSourceConfig.access === 'proxy' && ( - - )} - + +
{secureSocksDSProxyEnabled && } -
+ ); }; diff --git a/packages/grafana-ui/src/components/DataSourceSettings/HttpProxySettings.tsx b/packages/grafana-ui/src/components/DataSourceSettings/HttpProxySettings.tsx index 8281c3b8ed0..ae570dc4769 100644 --- a/packages/grafana-ui/src/components/DataSourceSettings/HttpProxySettings.tsx +++ b/packages/grafana-ui/src/components/DataSourceSettings/HttpProxySettings.tsx @@ -1,5 +1,11 @@ +import { css } from '@emotion/css'; + +import { GrafanaTheme2 } from '@grafana/data'; + +import { useStyles2 } from '../../themes'; import { t } from '../../utils/i18n'; import { InlineField } from '../Forms/InlineField'; +import { Stack } from '../Layout/Stack/Stack'; import { InlineSwitch } from '../Switch/Switch'; import { HttpSettingsBaseProps } from './types'; @@ -11,9 +17,10 @@ export const HttpProxySettings = ({ onChange, showForwardOAuthIdentityOption = true, }: HttpSettingsBaseProps) => { + const gridLayout = useStyles2(getGridLayout); return ( - <> -
+
+ -
-
+ + + onChange({ ...dataSourceConfig.jsonData, tlsSkipVerify: event!.currentTarget.checked })} + /> + + {showForwardOAuthIdentityOption && ( - onChange({ ...dataSourceConfig.jsonData, tlsSkipVerify: event!.currentTarget.checked }) + onChange({ ...dataSourceConfig.jsonData, oauthPassThru: event!.currentTarget.checked }) } /> -
- {showForwardOAuthIdentityOption && ( -
- - - onChange({ ...dataSourceConfig.jsonData, oauthPassThru: event!.currentTarget.checked }) - } - /> - -
)} - +
); }; + +const getGridLayout = (theme: GrafanaTheme2) => + css({ + display: 'grid', + gridTemplateColumns: 'auto', + gap: 0, // Inline field has a margin + }); diff --git a/packages/grafana-ui/src/components/DataSourceSettings/SecureSocksProxySettings.tsx b/packages/grafana-ui/src/components/DataSourceSettings/SecureSocksProxySettings.tsx index 67a1d74d934..56e82d8a494 100644 --- a/packages/grafana-ui/src/components/DataSourceSettings/SecureSocksProxySettings.tsx +++ b/packages/grafana-ui/src/components/DataSourceSettings/SecureSocksProxySettings.tsx @@ -16,7 +16,7 @@ export function SecureSocksProxySettings({ onOptionsChange, }: Props): JSX.Element { return ( - <> +

Secure Socks Proxy

@@ -44,6 +44,6 @@ export function SecureSocksProxySettings({
- +
); } diff --git a/packages/grafana-ui/src/components/ElementSelectionContext/ElementSelectionContext.tsx b/packages/grafana-ui/src/components/ElementSelectionContext/ElementSelectionContext.tsx index 2e6b1b9fd46..8ba48a7eeda 100644 --- a/packages/grafana-ui/src/components/ElementSelectionContext/ElementSelectionContext.tsx +++ b/packages/grafana-ui/src/components/ElementSelectionContext/ElementSelectionContext.tsx @@ -9,6 +9,7 @@ export interface ElementSelectionContextState { /** List of currently selected elements */ selected: ElementSelectionContextItem[]; onSelect: (item: ElementSelectionContextItem, multi?: boolean) => void; + onClear: () => void; } export interface ElementSelectionContextItem { @@ -21,6 +22,7 @@ export interface UseElementSelectionResult { isSelected?: boolean; isSelectable?: boolean; onSelect?: (evt: React.PointerEvent) => void; + onClear?: () => void; } export function useElementSelection(id: string | undefined): UseElementSelectionResult { @@ -48,5 +50,13 @@ export function useElementSelection(id: string | undefined): UseElementSelection [context, id] ); - return { isSelected, onSelect, isSelectable: context.enabled }; + const onClear = useCallback(() => { + if (!context.enabled) { + return; + } + + context.onClear(); + }, [context]); + + return { isSelected, onSelect, onClear, isSelectable: context.enabled }; } diff --git a/packages/grafana-ui/src/components/FormField/FormField.tsx b/packages/grafana-ui/src/components/FormField/FormField.tsx index 4de155dcfb2..a0bc181d284 100644 --- a/packages/grafana-ui/src/components/FormField/FormField.tsx +++ b/packages/grafana-ui/src/components/FormField/FormField.tsx @@ -21,8 +21,9 @@ export interface Props extends InputHTMLAttributes { /** * Default form field including label used in Grafana UI. Default input element is simple . You can also pass * custom inputEl if required in which case inputWidth and inputProps are ignored. - * @deprecated Please use the {@link Field} component, {@link https://developers.grafana.com/ui/latest/index.html?path=/story/forms-field--simple See Storybook}. + * * For inline fields, use {@link InlineField}, {@link https://developers.grafana.com/ui/latest/index.html?path=/story/forms-inlinefield--basic See Storybook}. + * @deprecated Please use the {@link Field} component, {@link https://developers.grafana.com/ui/latest/index.html?path=/story/forms-field--simple See Storybook}. */ export const FormField = ({ label, diff --git a/packages/grafana-ui/src/components/Forms/Field.test.tsx b/packages/grafana-ui/src/components/Forms/Field.test.tsx index 768bc3095cf..24d47c23bf1 100644 --- a/packages/grafana-ui/src/components/Forms/Field.test.tsx +++ b/packages/grafana-ui/src/components/Forms/Field.test.tsx @@ -1,7 +1,7 @@ import { render, screen } from '@testing-library/react'; +import { Combobox } from '../Combobox/Combobox'; import { Input } from '../Input/Input'; -import { Select } from '../Select/Select'; import { Field } from './Field'; @@ -27,9 +27,13 @@ describe('Field', () => { }); it('renders with the inputId of its children', () => { + const comboboxOptions = [ + { label: 'Option 1', value: 'option-1' }, + { label: 'Option 2', value: 'option-2' }, + ]; render( - - - - - {isGrafanaManagedGroup && props.folderUrl && ( - - )} - - )} - - Evaluation group - - } - invalid={!!errors.groupName} - error={errors.groupName?.message} - > - - - - Evaluation interval - - } - invalid={Boolean(errors.groupInterval) ? true : undefined} - error={errors.groupInterval?.message} - > - + {!props.hideFolder && ( + + + {nameSpaceLabel} + + } + invalid={Boolean(errors.namespaceName) ? true : undefined} + error={errors.namespaceName?.message} + > - setValue('groupInterval', value, { shouldValidate: true, shouldDirty: true })} - /> - - - - {/* if we're dealing with a Grafana-managed group, check if the evaluation interval is valid / permitted */} - {isGrafanaManagedGroup && checkEvaluationIntervalGlobalLimit(watch('groupInterval')).exceedsLimit && ( - - )} - - {!hasSomeNoRecordingRules &&
This group does not contain alert rules.
} - {hasSomeNoRecordingRules && ( - <> -
List of rules that belong to this group
-
- #Eval column represents the number of evaluations needed before alert starts firing. -
- - - )} - {error && {stringifyErrorLike(error)}} -
- - - - -
- + icon="folder-open" + target="_blank" + /> + )} + + )} + + Evaluation group + + } + invalid={!!errors.groupName} + error={errors.groupName?.message} + > + + + + Evaluation interval + + } + invalid={Boolean(errors.groupInterval) ? true : undefined} + error={errors.groupInterval?.message} + > + + + setValue('groupInterval', value, { shouldValidate: true, shouldDirty: true })} + /> + + + + {/* if we're dealing with a Grafana-managed group, check if the evaluation interval is valid / permitted */} + {isGrafanaManagedGroup && checkEvaluationIntervalGlobalLimit(watch('groupInterval')).exceedsLimit && ( + + )} + + {!hasSomeNoRecordingRules &&
This group does not contain alert rules.
} + {hasSomeNoRecordingRules && ( + <> +
List of rules that belong to this group
+
+ #Eval column represents the number of evaluations needed before alert starts firing. +
+ + + )} + {error && {stringifyErrorLike(error)}} +
+ + + + +
); diff --git a/public/app/features/alerting/unified/components/rules/Filter/RulesFilter.v2.tsx b/public/app/features/alerting/unified/components/rules/Filter/RulesFilter.v2.tsx index 1c682cc689e..aa5c9edafec 100644 --- a/public/app/features/alerting/unified/components/rules/Filter/RulesFilter.v2.tsx +++ b/public/app/features/alerting/unified/components/rules/Filter/RulesFilter.v2.tsx @@ -158,54 +158,52 @@ const SavedSearches = () => { const applySearch = useCallback((name: string) => {}, []); return ( - <> - - - - columns={[ - { - id: 'name', - header: 'Saved search name', - cell: ({ row }) => ( - - {row.original.name} - {row.original.default ? : null} - - ), - }, - { - id: 'actions', - cell: ({ row }) => ( - - - - - ), - }, - ]} - data={[ - { - name: 'My saved search', - default: true, - }, - { - name: 'Another saved search', - }, - { - name: 'This one has a really long name and some emojis too 🥒', - }, - ]} - getRowId={(row) => row.name} - /> - - - + + + + columns={[ + { + id: 'name', + header: 'Saved search name', + cell: ({ row }) => ( + + {row.original.name} + {row.original.default ? : null} + + ), + }, + { + id: 'actions', + cell: ({ row }) => ( + + + + + ), + }, + ]} + data={[ + { + name: 'My saved search', + default: true, + }, + { + name: 'Another saved search', + }, + { + name: 'This one has a really long name and some emojis too 🥒', + }, + ]} + getRowId={(row) => row.name} + /> + + ); }; diff --git a/public/app/features/alerting/unified/components/rules/NoRulesCTA.tsx b/public/app/features/alerting/unified/components/rules/NoRulesCTA.tsx index 38a4da4ce30..37d977b004d 100644 --- a/public/app/features/alerting/unified/components/rules/NoRulesCTA.tsx +++ b/public/app/features/alerting/unified/components/rules/NoRulesCTA.tsx @@ -1,8 +1,65 @@ -import { EmptyState, LinkButton, Stack, TextLink } from '@grafana/ui'; -import { Trans } from 'app/core/internationalization'; +import { config } from '@grafana/runtime'; +import { Dropdown, EmptyState, LinkButton, Menu, MenuItem, Stack, TextLink } from '@grafana/ui'; +import { Trans, t } from 'app/core/internationalization'; import { useRulesAccess } from '../../utils/accessControlHooks'; +const RecordingRulesButtons = () => { + const { canCreateGrafanaRules, canCreateCloudRules } = useRulesAccess(); + const grafanaRecordingRulesEnabled = config.featureToggles.grafanaManagedRecordingRules; + const canCreateAll = canCreateGrafanaRules && canCreateCloudRules && grafanaRecordingRulesEnabled; + + // User can create Grafana and DS-managed recording rules, show a dropdown + if (canCreateAll) { + return ( + + + + + } + > + + New recording rule + + + ); + } + + // ...Otherwise, just show the buttons for each type of recording rule + // (this will just be one or the other) + return ( + <> + {canCreateGrafanaRules && grafanaRecordingRulesEnabled && ( + + + New Grafana-managed recording rule + + + )} + {canCreateCloudRules && ( + + + New data source-managed recording rule + + + )} + + ); +}; + export const NoRulesSplash = () => { const { canCreateGrafanaRules, canCreateCloudRules } = useRulesAccess(); const canCreateAnything = canCreateGrafanaRules || canCreateCloudRules; @@ -14,32 +71,26 @@ export const NoRulesSplash = () => { variant="call-to-action" button={ canCreateAnything ? ( - + {canCreateAnything && ( New alert rule )} - {canCreateCloudRules && ( - - New recording rule - - )} + ) : null } > - <> - - You can also define rules through file provisioning or Terraform.{' '} - - Learn more - - - + + You can also define rules through file provisioning or Terraform.{' '} + + Learn more + +
); diff --git a/public/app/features/alerting/unified/components/rules/RuleConfigStatus.tsx b/public/app/features/alerting/unified/components/rules/RuleConfigStatus.tsx index c0ed270d66f..8b10c1388bf 100644 --- a/public/app/features/alerting/unified/components/rules/RuleConfigStatus.tsx +++ b/public/app/features/alerting/unified/components/rules/RuleConfigStatus.tsx @@ -3,7 +3,7 @@ import { useMemo } from 'react'; import { GrafanaTheme2 } from '@grafana/data/src'; import { config } from '@grafana/runtime/src'; -import { Icon, Tooltip, useStyles2 } from '@grafana/ui/src'; +import { Icon, Tooltip, useStyles2 } from '@grafana/ui'; import { CombinedRule } from '../../../../../types/unified-alerting'; import { checkEvaluationIntervalGlobalLimit } from '../../utils/config'; diff --git a/public/app/features/alerting/unified/components/rules/RulesFilter.test.tsx b/public/app/features/alerting/unified/components/rules/RulesFilter.test.tsx index 1484cfaa4ec..720e0ed1275 100644 --- a/public/app/features/alerting/unified/components/rules/RulesFilter.test.tsx +++ b/public/app/features/alerting/unified/components/rules/RulesFilter.test.tsx @@ -16,7 +16,7 @@ jest.mock('./MultipleDataSourcePicker', () => { const original = jest.requireActual('./MultipleDataSourcePicker'); return { ...original, - MultipleDataSourcePicker: () => <>, + MultipleDataSourcePicker: () => null, }; }); diff --git a/public/app/features/alerting/unified/components/rules/central-state-history/CentralHistoryRuntimeDataSource.ts b/public/app/features/alerting/unified/components/rules/central-state-history/CentralHistoryRuntimeDataSource.ts index b6fef8062f4..3013b097e16 100644 --- a/public/app/features/alerting/unified/components/rules/central-state-history/CentralHistoryRuntimeDataSource.ts +++ b/public/app/features/alerting/unified/components/rules/central-state-history/CentralHistoryRuntimeDataSource.ts @@ -1,8 +1,9 @@ import { useEffect, useMemo } from 'react'; -import { DataQuery, DataQueryRequest, DataQueryResponse, TestDataSourceResponse } from '@grafana/data'; +import { DataQueryRequest, DataQueryResponse, TestDataSourceResponse } from '@grafana/data'; import { getTemplateSrv } from '@grafana/runtime'; import { RuntimeDataSource, sceneUtils } from '@grafana/scenes'; +import { DataQuery } from '@grafana/schema'; import { getTimeSrv } from 'app/features/dashboard/services/TimeSrv'; import { dispatch } from 'app/store/store'; diff --git a/public/app/features/alerting/unified/components/rules/central-state-history/EventDetails.tsx b/public/app/features/alerting/unified/components/rules/central-state-history/EventDetails.tsx index a037703c420..cfc14895d4c 100644 --- a/public/app/features/alerting/unified/components/rules/central-state-history/EventDetails.tsx +++ b/public/app/features/alerting/unified/components/rules/central-state-history/EventDetails.tsx @@ -220,19 +220,17 @@ const Annotations = ({ rule }: AnnotationsProps) => { return null; } return ( - <> -
- {Object.entries(annotations).map(([name, value]) => { - const capitalizedName = capitalize(name); - return ( - - {capitalizedName} - - - ); - })} -
- +
+ {Object.entries(annotations).map(([name, value]) => { + const capitalizedName = capitalize(name); + return ( + + {capitalizedName} + + + ); + })} +
); }; interface ValueInTransitionProps { diff --git a/public/app/features/alerting/unified/components/rules/state-history/LokiStateHistory.tsx b/public/app/features/alerting/unified/components/rules/state-history/LokiStateHistory.tsx index 76ba417dd20..a449b7ceee3 100644 --- a/public/app/features/alerting/unified/components/rules/state-history/LokiStateHistory.tsx +++ b/public/app/features/alerting/unified/components/rules/state-history/LokiStateHistory.tsx @@ -114,16 +114,14 @@ const LokiStateHistory = ({ ruleUID }: Props) => { )} {isEmpty(frameSubset) ? ( - <> -
- {emptyStateMessage} - {totalRecordsCount > 0 && ( - - )} -
- +
+ {emptyStateMessage} + {totalRecordsCount > 0 && ( + + )} +
) : ( <>
diff --git a/public/app/features/alerting/unified/home/Insights.tsx b/public/app/features/alerting/unified/home/Insights.tsx index 9d85797751b..14bd54b0682 100644 --- a/public/app/features/alerting/unified/home/Insights.tsx +++ b/public/app/features/alerting/unified/home/Insights.tsx @@ -176,24 +176,22 @@ export function getInsightsScenes() { component: SectionSubheader, props: { children: ( - <> - - Monitor the status of your system{' '} - - Alerting insights provides pre-built dashboards to monitor your alerting data. -
-
- You can identify patterns in why things go wrong and discover trends in alerting performance - within your organization. -
- } - > - - - - + + Monitor the status of your system{' '} + + Alerting insights provides pre-built dashboards to monitor your alerting data. +
+
+ You can identify patterns in why things go wrong and discover trends in alerting performance within + your organization. +
+ } + > + + + ), }, }), diff --git a/public/app/features/alerting/unified/home/PluginIntegrations.tsx b/public/app/features/alerting/unified/home/PluginIntegrations.tsx index bb0e0cbda24..f07a0738934 100644 --- a/public/app/features/alerting/unified/home/PluginIntegrations.tsx +++ b/public/app/features/alerting/unified/home/PluginIntegrations.tsx @@ -1,8 +1,7 @@ import { css } from '@emotion/css'; import { GrafanaTheme2 } from '@grafana/data/'; -import { Stack, Text } from '@grafana/ui'; -import { useStyles2 } from '@grafana/ui/'; +import { Stack, Text, useStyles2 } from '@grafana/ui'; import { useAlertingHomePageExtensions } from '../plugins/useAlertingHomePageExtensions'; diff --git a/public/app/features/alerting/unified/plugins/PluginOriginBadge.tsx b/public/app/features/alerting/unified/plugins/PluginOriginBadge.tsx index 4f7a853fc95..03c1eca7620 100644 --- a/public/app/features/alerting/unified/plugins/PluginOriginBadge.tsx +++ b/public/app/features/alerting/unified/plugins/PluginOriginBadge.tsx @@ -1,7 +1,7 @@ import { useAsync } from 'react-use'; import { Badge, IconSize, Tooltip } from '@grafana/ui'; -import { getSvgSize } from '@grafana/ui/src/components/Icon/utils'; +import { getSvgSize } from '@grafana/ui/internal'; import { getPluginSettings } from '../../../plugins/pluginSettings'; diff --git a/public/app/features/alerting/unified/rule-list/components/RuleGroupActionsMenu.tsx b/public/app/features/alerting/unified/rule-list/components/RuleGroupActionsMenu.tsx index 7c2735ea5cd..5b61f83d543 100644 --- a/public/app/features/alerting/unified/rule-list/components/RuleGroupActionsMenu.tsx +++ b/public/app/features/alerting/unified/rule-list/components/RuleGroupActionsMenu.tsx @@ -3,20 +3,18 @@ import { t } from 'app/core/internationalization'; export function RuleGroupActionsMenu() { return ( - <> - - - - - - - - } - > - - - + + + + + + + + } + > + + ); } diff --git a/public/app/features/alerting/unified/utils/rule-form.ts b/public/app/features/alerting/unified/utils/rule-form.ts index 7a95be75c1a..194b7bec552 100644 --- a/public/app/features/alerting/unified/utils/rule-form.ts +++ b/public/app/features/alerting/unified/utils/rule-form.ts @@ -1,7 +1,5 @@ import { - DataQuery, DataSourceInstanceSettings, - DataSourceRef, IntervalValues, RelativeTimeRange, ScopedVars, @@ -14,7 +12,7 @@ import { PromQuery } from '@grafana/prometheus'; import { config, getDataSourceSrv } from '@grafana/runtime'; import { ExpressionDatasourceRef } from '@grafana/runtime/src/utils/DataSourceWithBackend'; import { VizPanel, sceneGraph } from '@grafana/scenes'; -import { DataSourceJsonData } from '@grafana/schema'; +import { DataQuery, DataSourceJsonData, DataSourceRef } from '@grafana/schema'; import { DashboardModel } from 'app/features/dashboard/state/DashboardModel'; import { PanelModel } from 'app/features/dashboard/state/PanelModel'; import { diff --git a/public/app/features/bookmarks/BookmarksPage.tsx b/public/app/features/bookmarks/BookmarksPage.tsx index 810baa17ed9..067b52e3d34 100644 --- a/public/app/features/bookmarks/BookmarksPage.tsx +++ b/public/app/features/bookmarks/BookmarksPage.tsx @@ -1,15 +1,17 @@ import { css } from '@emotion/css'; import { GrafanaTheme2, NavModelItem } from '@grafana/data'; +import { useTranslate } from '@grafana/runtime/src/unstable'; import { EmptyState, useStyles2 } from '@grafana/ui'; import { usePinnedItems } from 'app/core/components/AppChrome/MegaMenu/hooks'; import { findByUrl } from 'app/core/components/AppChrome/MegaMenu/utils'; import { NavLandingPageCard } from 'app/core/components/NavLandingPage/NavLandingPageCard'; import { Page } from 'app/core/components/Page/Page'; -import { t, Trans } from 'app/core/internationalization'; +import { Trans } from 'app/core/internationalization'; import { useSelector } from 'app/types'; export function BookmarksPage() { + const t = useTranslate(); const styles = useStyles2(getStyles); const pinnedItems = usePinnedItems(); const navTree = useSelector((state) => state.navBarTree); diff --git a/public/app/features/browse-dashboards/api/browseDashboardsAPI.ts b/public/app/features/browse-dashboards/api/browseDashboardsAPI.ts index 51f08201927..df579fcdf62 100644 --- a/public/app/features/browse-dashboards/api/browseDashboardsAPI.ts +++ b/public/app/features/browse-dashboards/api/browseDashboardsAPI.ts @@ -8,11 +8,10 @@ import { createBaseQuery, handleRequestError } from 'app/api/createBaseQuery'; import appEvents from 'app/core/app_events'; import { contextSrv } from 'app/core/core'; import { getDashboardAPI } from 'app/features/dashboard/api/dashboard_api'; -import { isV1DashboardCommand, isV2DashboardCommand } from 'app/features/dashboard/api/utils'; +import { isDashboardV2Resource, isV1DashboardCommand, isV2DashboardCommand } from 'app/features/dashboard/api/utils'; import { SaveDashboardCommand } from 'app/features/dashboard/components/SaveDashboard/types'; import { dashboardWatcher } from 'app/features/live/dashboard/dashboardWatcher'; import { - DashboardDTO, DescendantCount, DescendantCountDTO, FolderDTO, @@ -240,26 +239,16 @@ export const browseDashboardsAPI = createApi({ // Move all the dashboards sequentially // TODO error handling here for (const dashboardUID of selectedDashboards) { - if (config.featureToggles.useV2DashboardsAPI) { - const fullDash = await getDashboardAPI('v2').getDashboardDTO(dashboardUID); - - await getDashboardAPI('v2').saveDashboard({ - dashboard: fullDash.spec, - folderUid: destinationUID, - overwrite: false, - message: '', - k8s: fullDash.metadata, - }); - } else { - const fullDash: DashboardDTO = await getDashboardAPI().getDashboardDTO(dashboardUID); - - await getDashboardAPI().saveDashboard({ - dashboard: fullDash.dashboard, - folderUid: destinationUID, - overwrite: false, - message: '', - }); - } + const fullDash = await getDashboardAPI().getDashboardDTO(dashboardUID); + const dashboard = isDashboardV2Resource(fullDash) ? fullDash.spec : fullDash.dashboard; + const k8s = isDashboardV2Resource(fullDash) ? fullDash.metadata : undefined; + await getDashboardAPI().saveDashboard({ + dashboard, + folderUid: destinationUID, + overwrite: false, + message: '', + k8s, + }); } return { data: undefined }; }, @@ -308,21 +297,20 @@ export const browseDashboardsAPI = createApi({ const name = response?.title; if (name) { - const payload = - config.featureToggles.useV2DashboardsAPI || config.featureToggles.kubernetesDashboards - ? ['Dashboard moved to Recently deleted'] - : [ - t('browse-dashboards.soft-delete.success', 'Dashboard {{name}} moved to Recently deleted', { - name, - }), - ]; + const payload = config.featureToggles.kubernetesDashboards + ? ['Dashboard moved to Recently deleted'] + : [ + t('browse-dashboards.soft-delete.success', 'Dashboard {{name}} moved to Recently deleted', { + name, + }), + ]; appEvents.publish({ type: AppEvents.alertSuccess.name, payload, }); } - } else if (config.featureToggles.useV2DashboardsAPI || config.featureToggles.kubernetesDashboards) { + } else if (config.featureToggles.kubernetesDashboards) { appEvents.publish({ type: AppEvents.alertSuccess.name, payload: ['Dashboard deleted'], @@ -344,8 +332,7 @@ export const browseDashboardsAPI = createApi({ saveDashboard: builder.mutation>({ queryFn: async (cmd) => { try { - // When we use the `useV2DashboardsAPI` flag, we can save 'v2' schema dashboards - if (config.featureToggles.useV2DashboardsAPI && isV2DashboardCommand(cmd)) { + if (isV2DashboardCommand(cmd)) { const response = await getDashboardAPI('v2').saveDashboard(cmd); return { data: response }; } diff --git a/public/app/features/browse-dashboards/components/NameCell.tsx b/public/app/features/browse-dashboards/components/NameCell.tsx index dbdc60eba51..6316f767cf2 100644 --- a/public/app/features/browse-dashboards/components/NameCell.tsx +++ b/public/app/features/browse-dashboards/components/NameCell.tsx @@ -4,7 +4,7 @@ import Skeleton from 'react-loading-skeleton'; import { GrafanaTheme2 } from '@grafana/data'; import { reportInteraction } from '@grafana/runtime'; import { Icon, IconButton, Link, Spinner, useStyles2, Text } from '@grafana/ui'; -import { getSvgSize } from '@grafana/ui/src/components/Icon/utils'; +import { getSvgSize } from '@grafana/ui/internal'; import { t } from 'app/core/internationalization'; import { getIconForItem } from 'app/features/search/service/utils'; diff --git a/public/app/features/browse-dashboards/permissions.ts b/public/app/features/browse-dashboards/permissions.ts index 3347fb9f442..49eff8d69ff 100644 --- a/public/app/features/browse-dashboards/permissions.ts +++ b/public/app/features/browse-dashboards/permissions.ts @@ -12,16 +12,6 @@ function checkCanCreateFolders(folderDTO?: FolderDTO) { return false; } - if (!config.featureToggles.accessActionSets) { - if (!folderDTO || folderDTO.uid === 'general') { - return checkFolderPermission(AccessControlAction.FoldersCreate); - } - return ( - checkFolderPermission(AccessControlAction.FoldersCreate) && - checkFolderPermission(AccessControlAction.FoldersWrite, folderDTO) - ); - } - return checkFolderPermission(AccessControlAction.FoldersCreate, folderDTO); } diff --git a/public/app/features/canvas/elements/metricValue.tsx b/public/app/features/canvas/elements/metricValue.tsx index 0ddec47734a..24174962d2c 100644 --- a/public/app/features/canvas/elements/metricValue.tsx +++ b/public/app/features/canvas/elements/metricValue.tsx @@ -6,8 +6,7 @@ import { of } from 'rxjs'; import { DataFrame, FieldNamePickerConfigSettings, GrafanaTheme2, StandardEditorsRegistryItem } from '@grafana/data'; import { TextDimensionMode } from '@grafana/schema'; import { usePanelContext, useStyles2 } from '@grafana/ui'; -import { FieldNamePicker } from '@grafana/ui/src/components/MatchersUI/FieldNamePicker'; -import { frameHasName, getFrameFieldsDisplayNames } from '@grafana/ui/src/components/MatchersUI/utils'; +import { FieldNamePicker, frameHasName, getFrameFieldsDisplayNames } from '@grafana/ui/internal'; import { DimensionContext } from 'app/features/dimensions/context'; import { ColorDimensionEditor } from 'app/features/dimensions/editors/ColorDimensionEditor'; import { TextDimensionEditor } from 'app/features/dimensions/editors/TextDimensionEditor'; diff --git a/public/app/features/dashboard-scene/conditional-rendering/ConditionHeader.tsx b/public/app/features/dashboard-scene/conditional-rendering/ConditionHeader.tsx new file mode 100644 index 00000000000..0112e96334e --- /dev/null +++ b/public/app/features/dashboard-scene/conditional-rendering/ConditionHeader.tsx @@ -0,0 +1,20 @@ +import { IconButton, Stack, Text } from '@grafana/ui'; +import { t } from 'app/core/internationalization'; + +type Props = { + title: string; + onDelete: () => void; +}; + +export const ConditionHeader = ({ title, onDelete }: Props) => { + return ( + + {title} + onDelete()} + /> + + ); +}; diff --git a/public/app/features/dashboard-scene/conditional-rendering/ConditionalRendering.tsx b/public/app/features/dashboard-scene/conditional-rendering/ConditionalRendering.tsx new file mode 100644 index 00000000000..bc37e726cb3 --- /dev/null +++ b/public/app/features/dashboard-scene/conditional-rendering/ConditionalRendering.tsx @@ -0,0 +1,50 @@ +import { SceneComponentProps, SceneObjectBase, SceneObjectState } from '@grafana/scenes'; +import { ConditionalRenderingGroupKind } from '@grafana/schema/dist/esm/schema/dashboard/v2alpha0'; + +import { ConditionalRenderingGroup } from './ConditionalRenderingGroup'; + +export interface ConditionalRenderingState extends SceneObjectState { + rootGroup: ConditionalRenderingGroup; +} + +export class ConditionalRendering extends SceneObjectBase { + public static Component = ConditionalRenderingRenderer; + + public constructor(state: ConditionalRenderingState) { + super(state); + + this.addActivationHandler(() => this._activationHandler()); + } + + private _activationHandler() { + // This ensures that all children are activated when conditional rendering is activated + // We need this in order to allow children to subscribe to variable changes etc. + this.forEachChild((child) => { + if (!child.isActive) { + this._subs.add(child.activate()); + } + }); + } + + public evaluate(): boolean { + return this.state.rootGroup.evaluate(); + } + + public notifyChange() { + this.parent?.forceRender(); + } + + public static createEmpty(): ConditionalRendering { + return new ConditionalRendering({ rootGroup: ConditionalRenderingGroup.createEmpty() }); + } + + public serialize(): ConditionalRenderingGroupKind { + return this.state.rootGroup.serialize(); + } +} + +function ConditionalRenderingRenderer({ model }: SceneComponentProps) { + const { rootGroup } = model.useState(); + + return ; +} diff --git a/public/app/features/dashboard-scene/conditional-rendering/ConditionalRenderingBase.tsx b/public/app/features/dashboard-scene/conditional-rendering/ConditionalRenderingBase.tsx new file mode 100644 index 00000000000..265372e54ec --- /dev/null +++ b/public/app/features/dashboard-scene/conditional-rendering/ConditionalRenderingBase.tsx @@ -0,0 +1,64 @@ +import { ReactNode } from 'react'; + +import { SceneComponentProps, sceneGraph, SceneObjectBase, SceneObjectState } from '@grafana/scenes'; + +import { ConditionalRendering } from './ConditionalRendering'; +import { ConditionalRenderingGroup } from './ConditionalRenderingGroup'; +import { ConditionalRenderingKindTypes } from './serializers'; +import { ConditionValues } from './shared'; + +export interface ConditionalRenderingBaseState extends SceneObjectState { + value: V; +} + +export abstract class ConditionalRenderingBase< + S extends ConditionalRenderingBaseState, +> extends SceneObjectBase { + public static Component = ConditionalRenderingBaseRenderer; + + public constructor(state: S) { + super(state); + + this.addActivationHandler(() => this._baseActivationHandler()); + } + + private _baseActivationHandler() { + // Similarly to the ConditionalRendering activation handler, + // this ensures that all children are activated when conditional rendering is activated + // We need this in order to allow children to subscribe to variable changes etc. + this.forEachChild((child) => { + if (!child.isActive) { + this._subs.add(child.activate()); + } + }); + } + + public abstract readonly title: string; + + public abstract serialize(): ConditionalRenderingKindTypes; + + public abstract evaluate(): boolean; + + public abstract render(): ReactNode; + + public abstract onDelete(): void; + + public getConditionalLogicRoot(): ConditionalRendering { + return sceneGraph.getAncestor(this, ConditionalRendering); + } + + public getRootGroup(): ConditionalRenderingGroup { + return this.getConditionalLogicRoot().state.rootGroup; + } + + public setStateAndNotify(state: Partial) { + this.setState(state); + this.getConditionalLogicRoot().notifyChange(); + } +} + +function ConditionalRenderingBaseRenderer({ + model, +}: SceneComponentProps>) { + return model.render(); +} diff --git a/public/app/features/dashboard-scene/conditional-rendering/ConditionalRenderingData.tsx b/public/app/features/dashboard-scene/conditional-rendering/ConditionalRenderingData.tsx new file mode 100644 index 00000000000..47e60687dc6 --- /dev/null +++ b/public/app/features/dashboard-scene/conditional-rendering/ConditionalRenderingData.tsx @@ -0,0 +1,149 @@ +import { ReactNode, useMemo } from 'react'; + +import { PanelData, SelectableValue } from '@grafana/data'; +import { SceneComponentProps, SceneDataProvider, sceneGraph } from '@grafana/scenes'; +import { ConditionalRenderingDataKind } from '@grafana/schema/dist/esm/schema/dashboard/v2alpha0'; +import { RadioButtonGroup, Stack } from '@grafana/ui'; +import { t } from 'app/core/internationalization'; + +import { ResponsiveGridItem } from '../scene/layout-responsive-grid/ResponsiveGridItem'; +import { RowItem } from '../scene/layout-rows/RowItem'; + +import { ConditionHeader } from './ConditionHeader'; +import { ConditionalRenderingBase, ConditionalRenderingBaseState } from './ConditionalRenderingBase'; +import { handleDeleteNonGroupCondition } from './shared'; + +export type DataConditionValue = boolean; + +type ConditionalRenderingDataState = ConditionalRenderingBaseState; + +export class ConditionalRenderingData extends ConditionalRenderingBase { + public get title(): string { + return t('dashboard.conditional-rendering.data.label', 'Data'); + } + + public constructor(state: ConditionalRenderingDataState) { + super(state); + + this.addActivationHandler(() => this._activationHandler()); + } + + private _activationHandler() { + let panelDataProviders: SceneDataProvider[] = []; + const item = this.getConditionalLogicRoot().parent; + if (item instanceof ResponsiveGridItem) { + const panelData = sceneGraph.getData(item.state.body); + if (panelData) { + panelDataProviders.push(panelData); + } + } + // extract multiple panel data from RowItem + if (item instanceof RowItem) { + const panels = item.getLayout().getVizPanels(); + for (const panel of panels) { + const panelData = sceneGraph.getData(panel); + if (panelData) { + panelDataProviders.push(panelData); + } + } + } + panelDataProviders.forEach((d) => { + this._subs.add( + d.subscribeToState(() => { + this.getConditionalLogicRoot().notifyChange(); + }) + ); + }); + } + + public evaluate(): boolean { + const { value } = this.state; + + // enable/disable condition + if (!value) { + return true; + } + + let data: PanelData[] = []; + + // get ResponsiveGridItem or RowItem + const item = this.getConditionalLogicRoot().parent; + + // extract single panel data from ResponsiveGridItem + if (item instanceof ResponsiveGridItem) { + const panelData = sceneGraph.getData(item.state.body).state.data; + if (panelData) { + data.push(panelData); + } + } + + // extract multiple panel data from RowItem + if (item instanceof RowItem) { + const panels = item.getLayout().getVizPanels(); + for (const panel of panels) { + const panelData = sceneGraph.getData(panel).state.data; + if (panelData) { + data.push(panelData); + } + } + } + + // early return if no panel data + if (!data.length) { + return false; + } + + for (let panelDataIdx = 0; panelDataIdx < data.length; panelDataIdx++) { + const series = data[panelDataIdx]?.series ?? []; + + for (let seriesIdx = 0; seriesIdx < series.length; seriesIdx++) { + if (series[seriesIdx].length > 0) { + return true; + } + } + } + + return false; + } + + public render(): ReactNode { + return ; + } + + public onDelete() { + handleDeleteNonGroupCondition(this); + } + + public serialize(): ConditionalRenderingDataKind { + return { + kind: 'ConditionalRenderingData', + spec: { + value: this.state.value, + }, + }; + } +} + +function ConditionalRenderingDataRenderer({ model }: SceneComponentProps) { + const { value } = model.useState(); + + const enableConditionOptions: Array> = useMemo( + () => [ + { label: t('dashboard.conditional-rendering.data.enable', 'Enable'), value: true }, + { label: t('dashboard.conditional-rendering.data.disable', 'Disable'), value: false }, + ], + [] + ); + + return ( + + model.onDelete()} /> + model.setStateAndNotify({ value: value })} + /> + + ); +} diff --git a/public/app/features/dashboard-scene/conditional-rendering/ConditionalRenderingEditor.tsx b/public/app/features/dashboard-scene/conditional-rendering/ConditionalRenderingEditor.tsx new file mode 100644 index 00000000000..510f3c50d0d --- /dev/null +++ b/public/app/features/dashboard-scene/conditional-rendering/ConditionalRenderingEditor.tsx @@ -0,0 +1,24 @@ +import { t } from 'app/core/internationalization'; +import { OptionsPaneCategoryDescriptor } from 'app/features/dashboard/components/PanelEditor/OptionsPaneCategoryDescriptor'; +import { OptionsPaneItemDescriptor } from 'app/features/dashboard/components/PanelEditor/OptionsPaneItemDescriptor'; + +import { ConditionalRendering } from './ConditionalRendering'; + +export function useConditionalRenderingEditor( + conditionalRendering?: ConditionalRendering +): OptionsPaneCategoryDescriptor | null { + if (!conditionalRendering) { + return null; + } + + return new OptionsPaneCategoryDescriptor({ + title: t('dashboard.conditional-rendering.title', 'Conditional rendering options'), + id: 'conditional-rendering-options', + isOpenDefault: true, + }).addItem( + new OptionsPaneItemDescriptor({ + title: t('dashboard.conditional-rendering.title', 'Conditional rendering options'), + render: () => , + }) + ); +} diff --git a/public/app/features/dashboard-scene/conditional-rendering/ConditionalRenderingGroup.tsx b/public/app/features/dashboard-scene/conditional-rendering/ConditionalRenderingGroup.tsx new file mode 100644 index 00000000000..14bf66c40b5 --- /dev/null +++ b/public/app/features/dashboard-scene/conditional-rendering/ConditionalRenderingGroup.tsx @@ -0,0 +1,175 @@ +import { css } from '@emotion/css'; +import { Fragment, ReactNode, useMemo } from 'react'; + +import { GrafanaTheme2, SelectableValue } from '@grafana/data'; +import { SceneComponentProps } from '@grafana/scenes'; +import { ConditionalRenderingGroupKind } from '@grafana/schema/dist/esm/schema/dashboard/v2alpha0'; +import { Divider, Dropdown, Field, Menu, RadioButtonGroup, Stack, ToolbarButton, useStyles2 } from '@grafana/ui'; +import { t, Trans } from 'app/core/internationalization'; + +import { ConditionHeader } from './ConditionHeader'; +import { ConditionalRenderingBase, ConditionalRenderingBaseState } from './ConditionalRenderingBase'; +import { ConditionalRenderingData } from './ConditionalRenderingData'; +import { ConditionalRenderingInterval } from './ConditionalRenderingInterval'; +import { ConditionalRenderingVariable } from './ConditionalRenderingVariable'; +import { ConditionalRenderingConditions } from './shared'; + +export type GroupConditionValue = ConditionalRenderingConditions[]; +export interface ConditionalRenderingGroupState extends ConditionalRenderingBaseState { + condition: 'and' | 'or'; +} + +export class ConditionalRenderingGroup extends ConditionalRenderingBase { + public get title(): string { + return t('dashboard.conditional-rendering.group.label', 'Group'); + } + + public evaluate(): boolean { + if (this.state.value.length === 0) { + return true; + } + + if (this.state.condition === 'and') { + return this.state.value.every((entry) => entry.evaluate()); + } + + return this.state.value.some((entry) => entry.evaluate()); + } + + public render(): ReactNode { + return ; + } + + public changeCondition(condition: 'and' | 'or') { + this.setStateAndNotify({ condition }); + } + + public addItem(item: ConditionalRenderingConditions) { + // We don't use `setStateAndNotify` here because + // We need to set a parent and activate the new condition before notifying the root + this.setState({ value: [...this.state.value, item] }); + + if (this.isActive && !item.isActive) { + item.activate(); + } + + this.getConditionalLogicRoot().notifyChange(); + } + + public static createEmpty(): ConditionalRenderingGroup { + return new ConditionalRenderingGroup({ condition: 'and', value: [] }); + } + + public onDelete() { + const rootGroup = this.getRootGroup(); + if (this === rootGroup) { + this.getConditionalLogicRoot().setState({ rootGroup: ConditionalRenderingGroup.createEmpty() }); + } else { + rootGroup.setState({ value: rootGroup.state.value.filter((condition) => condition !== this) }); + } + this.getConditionalLogicRoot().notifyChange(); + } + + public serialize(): ConditionalRenderingGroupKind { + if (this.state.value.some((item) => item instanceof ConditionalRenderingGroup)) { + throw new Error('ConditionalRenderingGroup cannot contain nested ConditionalRenderingGroups'); + } + return { + kind: 'ConditionalRenderingGroup', + spec: { + condition: this.state.condition, + items: this.state.value + .map((condition) => condition.serialize()) + .filter((item) => item.kind !== 'ConditionalRenderingGroup'), + }, + }; + } +} + +function ConditionalRenderingGroupRenderer({ model }: SceneComponentProps) { + const styles = useStyles2(getStyles); + const { condition, value } = model.useState(); + + const conditionsOptions: Array> = useMemo( + () => [ + { label: t('dashboard.conditional-rendering.group.condition.meet-all', 'Meet all'), value: 'and' }, + { label: t('dashboard.conditional-rendering.group.condition.meet-any', 'Meet any'), value: 'or' }, + ], + [] + ); + + return ( + + model.onDelete()} /> + + model.changeCondition(value!)} + /> + + + + + {value.map((entry) => ( + + {/* @ts-expect-error */} + + +
+ +

{condition}

+ +
+
+ ))} + +
+ + model.addItem(new ConditionalRenderingData({ value: true }))} + /> + model.addItem(new ConditionalRenderingInterval({ value: '7d' }))} + /> + + model.addItem(new ConditionalRenderingVariable({ value: { name: '', operator: '=', value: '' } })) + } + /> + + } + > + + Add condition based on + + +
+
+ ); +} + +const getStyles = (theme: GrafanaTheme2) => ({ + entryDivider: css({ + display: 'flex', + flexDirection: 'row', + alignItems: 'center', + }), + entryDividerText: css({ + margin: 0, + padding: theme.spacing(0, 2), + textTransform: 'capitalize', + }), + addButtonContainer: css({ + display: 'flex', + flexDirection: 'row', + justifyContent: 'center', + alignItems: 'center', + }), +}); diff --git a/public/app/features/dashboard-scene/conditional-rendering/ConditionalRenderingInterval.tsx b/public/app/features/dashboard-scene/conditional-rendering/ConditionalRenderingInterval.tsx new file mode 100644 index 00000000000..d22ccd3a91e --- /dev/null +++ b/public/app/features/dashboard-scene/conditional-rendering/ConditionalRenderingInterval.tsx @@ -0,0 +1,93 @@ +import { ReactNode, useState } from 'react'; + +import { rangeUtil } from '@grafana/data'; +import { SceneComponentProps, sceneGraph } from '@grafana/scenes'; +import { ConditionalRenderingTimeIntervalKind } from '@grafana/schema/dist/esm/schema/dashboard/v2alpha0'; +import { Field, Input, Stack } from '@grafana/ui'; +import { t } from 'app/core/internationalization'; + +import { ConditionHeader } from './ConditionHeader'; +import { ConditionalRenderingBase, ConditionalRenderingBaseState } from './ConditionalRenderingBase'; +import { handleDeleteNonGroupCondition } from './shared'; + +export type IntervalConditionValue = string; +type ConditionalRenderingIntervalState = ConditionalRenderingBaseState; + +export class ConditionalRenderingInterval extends ConditionalRenderingBase { + public get title(): string { + return t('dashboard.conditional-rendering.interval.label', 'Time range interval'); + } + + public constructor(state: ConditionalRenderingIntervalState) { + super(state); + + this.addActivationHandler(() => this._activationHandler()); + } + + private _activationHandler() { + this._subs.add( + sceneGraph.getTimeRange(this).subscribeToState(() => { + this.getConditionalLogicRoot().notifyChange(); + }) + ); + } + + public evaluate(): boolean { + try { + const interval = rangeUtil.intervalToSeconds(this.state.value); + + const timeRange = sceneGraph.getTimeRange(this); + + if (timeRange.state.value.to.unix() - timeRange.state.value.from.unix() <= interval) { + return true; + } + } catch { + return false; + } + + return false; + } + + public render(): ReactNode { + return ; + } + + public onDelete() { + handleDeleteNonGroupCondition(this); + } + + public serialize(): ConditionalRenderingTimeIntervalKind { + return { + kind: 'ConditionalRenderingTimeInterval', + spec: { + value: this.state.value, + }, + }; + } +} + +function ConditionalRenderingIntervalRenderer({ model }: SceneComponentProps) { + const { value } = model.useState(); + const [isValid, setIsValid] = useState(validateIntervalRegex.test(value)); + + return ( + + model.onDelete()} /> + + { + setIsValid(validateIntervalRegex.test(e.currentTarget.value)); + model.setStateAndNotify({ value: e.currentTarget.value }); + }} + /> + + + ); +} + +export const validateIntervalRegex = /^(-?\d+(?:\.\d+)?)(ms|[Mwdhmsy])?$/; diff --git a/public/app/features/dashboard-scene/conditional-rendering/ConditionalRenderingVariable.tsx b/public/app/features/dashboard-scene/conditional-rendering/ConditionalRenderingVariable.tsx new file mode 100644 index 00000000000..7a2b15d296b --- /dev/null +++ b/public/app/features/dashboard-scene/conditional-rendering/ConditionalRenderingVariable.tsx @@ -0,0 +1,138 @@ +import { css } from '@emotion/css'; +import { ReactNode, useMemo } from 'react'; + +import { GrafanaTheme2 } from '@grafana/data'; +import { SceneComponentProps, sceneGraph, VariableDependencyConfig } from '@grafana/scenes'; +import { ConditionalRenderingVariableKind } from '@grafana/schema/dist/esm/schema/dashboard/v2alpha0'; +import { Combobox, ComboboxOption, Field, Input, Stack, useStyles2 } from '@grafana/ui'; +import { t } from 'app/core/internationalization'; + +import { ConditionHeader } from './ConditionHeader'; +import { ConditionalRenderingBase, ConditionalRenderingBaseState } from './ConditionalRenderingBase'; +import { handleDeleteNonGroupCondition } from './shared'; + +export type VariableConditionValue = { + name: string; + operator: '=' | '!='; + value: string; +}; + +type ConditionalRenderingVariableState = ConditionalRenderingBaseState; + +export class ConditionalRenderingVariable extends ConditionalRenderingBase { + public get title(): string { + return t('dashboard.conditional-rendering.variable.label', 'Variable'); + } + + protected _variableDependency = new VariableDependencyConfig(this, { + onAnyVariableChanged: (v) => { + if (v.state.name === this.state.value.name) { + this.getConditionalLogicRoot().notifyChange(); + } + }, + }); + + public evaluate(): boolean { + if (!this.state.value.name) { + return true; + } + + const variable = sceneGraph.getVariables(this).state.variables.find((v) => v.state.name === this.state.value.name); + + // name is defined but no variable found - return false + if (!variable) { + return false; + } + const value = variable.getValue(); + + let hit = Array.isArray(value) ? value.includes(this.state.value.value) : value === this.state.value.value; + + if (this.state.value.operator === '!=') { + hit = !hit; + } + + return hit; + } + + public render(): ReactNode { + return ; + } + + public serialize(): ConditionalRenderingVariableKind { + return { + kind: 'ConditionalRenderingVariable', + spec: { + variable: this.state.value.name, + operator: this.state.value.operator === '=' ? 'equals' : 'notEquals', + value: this.state.value.value, + }, + }; + } + + public onDelete() { + handleDeleteNonGroupCondition(this); + } +} + +function ConditionalRenderingVariableRenderer({ model }: SceneComponentProps) { + const variables = useMemo(() => sceneGraph.getVariables(model), [model]); + const variableNames = useMemo( + () => variables.state.variables.map((v) => ({ value: v.state.name, label: v.state.label ?? v.state.name })), + [variables.state.variables] + ); + const operatorOptions: Array + model.onDelete()} /> + + + + model.setStateAndNotify({ value: { ...value, name: option.value } })} + /> + + + model.setStateAndNotify({ value: { ...value, operator: option.value } })} + /> + + + + model.setStateAndNotify({ value: { ...value, value: e.currentTarget.value } })} + /> + + + + ); +} + +const getStyles = (theme: GrafanaTheme2) => ({ + variableNameSelect: css({ + flexGrow: 1, + }), + operatorSelect: css({ + width: theme.spacing(12), + }), +}); diff --git a/public/app/features/dashboard-scene/conditional-rendering/serializers.ts b/public/app/features/dashboard-scene/conditional-rendering/serializers.ts new file mode 100644 index 00000000000..ab421d799d5 --- /dev/null +++ b/public/app/features/dashboard-scene/conditional-rendering/serializers.ts @@ -0,0 +1,96 @@ +import { Registry, RegistryItem } from '@grafana/data'; +import { + ConditionalRenderingGroupKind, + ConditionalRenderingVariableKind, + ConditionalRenderingDataKind, + ConditionalRenderingTimeIntervalKind, +} from '@grafana/schema/dist/esm/schema/dashboard/v2alpha0'; + +import { ConditionalRenderingData } from './ConditionalRenderingData'; +import { ConditionalRenderingGroup } from './ConditionalRenderingGroup'; +import { ConditionalRenderingInterval } from './ConditionalRenderingInterval'; +import { ConditionalRenderingVariable } from './ConditionalRenderingVariable'; + +export type ConditionalRenderingKindTypes = + | ConditionalRenderingGroupKind + | ConditionalRenderingVariableKind + | ConditionalRenderingDataKind + | ConditionalRenderingTimeIntervalKind; + +export interface ConditionalRenderingSerializer { + deserialize( + model: ConditionalRenderingKindTypes + ): ConditionalRenderingGroup | ConditionalRenderingVariable | ConditionalRenderingData | ConditionalRenderingInterval; +} + +interface ConditionalRenderingSerializerRegistryItem extends RegistryItem { + serializer: ConditionalRenderingSerializer; +} + +export class ConditionalRenderingGroupSerializer implements ConditionalRenderingSerializer { + deserialize(model: ConditionalRenderingGroupKind): ConditionalRenderingGroup { + return new ConditionalRenderingGroup({ + condition: model.spec.condition, + value: model.spec.items.map((item: ConditionalRenderingKindTypes) => { + const serializerRegistryItem = conditionalRenderingSerializerRegistry.getIfExists(item.kind); + if (!serializerRegistryItem) { + throw new Error(`No serializer found for conditional rendering kind: ${item.kind}`); + } + return serializerRegistryItem.serializer.deserialize(item); + }), + }); + } +} + +export class ConditionalRenderingVariableSerializer implements ConditionalRenderingSerializer { + deserialize(model: ConditionalRenderingVariableKind): ConditionalRenderingVariable { + return new ConditionalRenderingVariable({ + value: { + name: model.spec.variable, + operator: model.spec.operator === 'equals' ? '=' : '!=', + value: model.spec.value, + }, + }); + } +} + +export class ConditionalRenderingDataSerializer implements ConditionalRenderingSerializer { + deserialize(model: ConditionalRenderingDataKind): ConditionalRenderingData { + return new ConditionalRenderingData({ + value: model.spec.value, + }); + } +} + +export class ConditionalRenderingIntervalSerializer implements ConditionalRenderingSerializer { + deserialize(model: ConditionalRenderingTimeIntervalKind): ConditionalRenderingInterval { + return new ConditionalRenderingInterval({ + value: model.spec.value, + }); + } +} + +export const conditionalRenderingSerializerRegistry = new Registry(() => { + return [ + { + id: 'ConditionalRenderingGroup', + name: 'Group', + serializer: new ConditionalRenderingGroupSerializer(), + }, + { + id: 'ConditionalRenderingVariable', + name: 'Variable', + serializer: new ConditionalRenderingVariableSerializer(), + }, + { + id: 'ConditionalRenderingData', + name: 'Data', + serializer: new ConditionalRenderingDataSerializer(), + }, + { + id: 'ConditionalRenderingTimeInterval', + name: 'Time Interval', + serializer: new ConditionalRenderingIntervalSerializer(), + }, + ]; +}); diff --git a/public/app/features/dashboard-scene/conditional-rendering/shared.ts b/public/app/features/dashboard-scene/conditional-rendering/shared.ts new file mode 100644 index 00000000000..2a88ffc62b6 --- /dev/null +++ b/public/app/features/dashboard-scene/conditional-rendering/shared.ts @@ -0,0 +1,25 @@ +import { ConditionalRenderingData, DataConditionValue } from './ConditionalRenderingData'; +import { ConditionalRenderingGroup, GroupConditionValue } from './ConditionalRenderingGroup'; +import { ConditionalRenderingInterval, IntervalConditionValue } from './ConditionalRenderingInterval'; +import { ConditionalRenderingVariable, VariableConditionValue } from './ConditionalRenderingVariable'; + +export type ConditionValues = + | DataConditionValue + | VariableConditionValue + | GroupConditionValue + | IntervalConditionValue; + +export type ConditionalRenderingConditions = + | ConditionalRenderingData + | ConditionalRenderingVariable + | ConditionalRenderingInterval + | ConditionalRenderingGroup; + +type NonGroupConditions = Exclude; + +export const handleDeleteNonGroupCondition = (model: NonGroupConditions) => { + if (model.parent instanceof ConditionalRenderingGroup) { + model.parent.setState({ value: model.parent.state.value.filter((condition) => condition !== model) }); + model.getConditionalLogicRoot().notifyChange(); + } +}; diff --git a/public/app/features/dashboard-scene/edit-pane/DashboardEditPane.tsx b/public/app/features/dashboard-scene/edit-pane/DashboardEditPane.tsx index cef94e5be88..7fec9b3106b 100644 --- a/public/app/features/dashboard-scene/edit-pane/DashboardEditPane.tsx +++ b/public/app/features/dashboard-scene/edit-pane/DashboardEditPane.tsx @@ -21,7 +21,7 @@ import { DashboardAddPane } from './DashboardAddPane'; import { DashboardOutline } from './DashboardOutline'; import { ElementEditPane } from './ElementEditPane'; import { ElementSelection } from './ElementSelection'; -import { NewObjectAddedToCanvasEvent } from './shared'; +import { NewObjectAddedToCanvasEvent, ObjectRemovedFromCanvasEvent } from './shared'; import { useEditableElement } from './useEditableElement'; export interface DashboardEditPaneState extends SceneObjectState { @@ -39,6 +39,7 @@ export class DashboardEditPane extends SceneObjectBase { enabled: false, selected: [], onSelect: (item, multi) => this.selectElement(item, multi), + onClear: () => this.clearSelection(), }, }); @@ -53,6 +54,12 @@ export class DashboardEditPane extends SceneObjectBase { this.newObjectAddedToCanvas(payload); }) ); + + this._subs.add( + dashboard.subscribeToEvent(ObjectRemovedFromCanvasEvent, ({ payload }) => { + this.clearSelection(); + }) + ); } public enableSelection() { diff --git a/public/app/features/dashboard-scene/edit-pane/DashboardEditPaneSplitter.tsx b/public/app/features/dashboard-scene/edit-pane/DashboardEditPaneSplitter.tsx index f51540115c5..48d3ab22af2 100644 --- a/public/app/features/dashboard-scene/edit-pane/DashboardEditPaneSplitter.tsx +++ b/public/app/features/dashboard-scene/edit-pane/DashboardEditPaneSplitter.tsx @@ -67,8 +67,10 @@ export function DashboardEditPaneSplitter({ dashboard, isEditing, body, controls containerStyle.overflow = 'unset'; } - const onBodyRef = (ref: HTMLDivElement) => { - dashboard.onSetScrollRef(new DivScrollElement(ref)); + const onBodyRef = (ref: HTMLDivElement | null) => { + if (ref) { + dashboard.onSetScrollRef(new DivScrollElement(ref)); + } }; return ( diff --git a/public/app/features/dashboard-scene/edit-pane/DashboardEditableElement.tsx b/public/app/features/dashboard-scene/edit-pane/DashboardEditableElement.tsx index 7ccf14b4ff6..7d2c598c7ac 100644 --- a/public/app/features/dashboard-scene/edit-pane/DashboardEditableElement.tsx +++ b/public/app/features/dashboard-scene/edit-pane/DashboardEditableElement.tsx @@ -1,7 +1,7 @@ -import { useMemo } from 'react'; +import { ReactNode, useMemo } from 'react'; -import { Input, TextArea } from '@grafana/ui'; -import { t } from 'app/core/internationalization'; +import { Button, Icon, Input, Stack, TextArea } from '@grafana/ui'; +import { t, Trans } from 'app/core/internationalization'; import { OptionsPaneCategoryDescriptor } from 'app/features/dashboard/components/PanelEditor/OptionsPaneCategoryDescriptor'; import { OptionsPaneItemDescriptor } from 'app/features/dashboard/components/PanelEditor/OptionsPaneItemDescriptor'; @@ -60,6 +60,23 @@ export class DashboardEditableElement implements EditableDashboardElement { return [dashboardOptions]; } + + public renderActions(): ReactNode { + return ( + + ); + } } export function DashboardTitleInput({ dashboard }: { dashboard: DashboardScene }) { @@ -71,5 +88,5 @@ export function DashboardTitleInput({ dashboard }: { dashboard: DashboardScene } export function DashboardDescriptionInput({ dashboard }: { dashboard: DashboardScene }) { const { description } = dashboard.useState(); - return