* Sync nav_scope_path with url
* Let the current active scope remain if it is a child of the selected subscope
* Remove location updates based on nav_scope_path to maintain expanded folders
* Fix folder tests
* Remove console logs
* Better mock for changeScopes
* Update test to support the new calls
* Update test with function inputs
* Fix failinging test
* Add tests and add isEqual check for fetching new subscopes
* fix(table): add HTML title attribute to make truncated headings legible
* fix(table): avoid redundant display name calculation
Co-authored-by: Paul Marbach <paul.marbach@grafana.com>
---------
Co-authored-by: Paul Marbach <paul.marbach@grafana.com>
Docs: Update provisioning docs to reflect kubernetesDashboards defaults to true
The kubernetesDashboards feature toggle now defaults to true, so users
don't need to explicitly enable it in their configuration. Updated
documentation and UI to reflect this:
- Removed kubernetesDashboards from configuration examples
- Added notes explaining it's enabled by default
- Clarified that users only need to take action if they've explicitly
disabled it
- Kept validation checks to catch explicit disables
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-authored-by: Claude Sonnet 4.5 <noreply@anthropic.com>
* Dashboard: Make variables selectable in controls menu and improve spacing
- Add selection support for variables in controls menu (onPointerDown handler and selection classes)
- Add padding to variables and annotations in controls menu (theme.spacing(1))
- Reduce menu container padding from 1.5 to 1
- Remove margins between menu items
* fix: remove unused imports in DashboardControlsMenu
fix: update variable set state when variable hide property changes
When changing a variable's positioning to show in controls menu using the edit side pane, the state of dashboardControls does not immediately update. This makes it seem to the user that nothing was changed.
The issue was that when a variable's hide property changes, only the variable's state was updated, but not the parent SceneVariableSet state. Components that subscribe to the variable set state (like useDashboardControls) didn't detect the change because the variables array reference remained the same.
This fix updates the parent SceneVariableSet state when a variable's hide property changes, ensuring components that subscribe to the variable set will re-render immediately.
Co-authored-by: grafakus <marc.mignonsin@grafana.com>
* Fix the conversion shallowed error and normalize the conversion status
* Add unit tests to ensure all permutations data loss detection
* Fix counting issue
* Sparkline: Prevent infinite loop when rendering a sparkline with a single value
* some tests for this case
* refactor out utils, experiment with getting highlightIndex working
* add comments throughout for #112977
* remove unused import
* Update Sparkline.test.tsx
* fix points mode rendering
* Sparkline: Improve min/max logic to avoid issues for very narrow deltas
* spread all config
* defaults deep
* delete unused import
* remove go.work.sum delta
* line break at end of file
* Sparkline: Prevent infinite loop when rendering a sparkline with a single value
* some tests for this case
* refactor out utils, experiment with getting highlightIndex working
* add comments throughout for #112977
* remove unused import
* Update Sparkline.test.tsx
* fix points mode rendering
* feat: legacy ListIterator with batches
* chore: address code review
* chore: remove nil check in nextBatch
* chore: move close before count check
* chore: add err field to batchingIterator for its own errors
* chore: remove unused import
* fix: use dsIndexProvider cache on migrations
* chore: use same comment as before
* feat: org-aware TTL cache for schemaversion migration and warmup for single tenant
* chore: use LRU cache
* chore: change DefaultCacheTTL to 1 minute
* chore: address copilot reviews
* chore: use expirable cache
* chore: remove unused import
* Logs: Rename attributes field
* LogLine: emphasize log line body
* LogLine: improve light mode
* Lint
* Update tests
* Only override colors if displayed fields are used
* Fix small font size ignored with displayed fields
* Fix types
* Short Links: Change default expiration to never expire (-1)
Previously, short links defaulted to expiring after 7 days. This change
updates the default to -1 (never expire) to prevent automatic deletion
of shared dashboard links.
Changes:
- conf/defaults.ini: Set expire_time = -1 and update comment
- conf/sample.ini: Set expire_time = -1 and update comment
- pkg/setting/setting.go: Update MustInt default from 7 to -1
The cleanup logic already handles -1 correctly (only runs when > 0),
so no changes needed there.
This unblocks progress on short URL feature improvements by ensuring
shared links remain accessible indefinitely by default.
* fix go
* update docs / comments
* update missed comment in sample.ini
* Revert "fix go"
This reverts commit e0d099ae31.
* chore: update workspace dependencies
Run 'make update-workspace' to sync Go workspace dependencies.
This updates go.mod and go.sum files to match the current workspace state.
* chore: add modowner for apps/quotas dependency
Assign @grafana/grafana-search-and-storage as owner for apps/quotas
dependency to satisfy modowners CI check.
* initial generation
* went through doc to add new resource
* added dummy kind so grafana will run
* added dummy handler and custom route
* fix app name
* gets custom route working - still a dummy route
* adds groupOverride to manifest
* adds quotas to grpc client and server
* WIP - trying to get api recognized - not working
* Gets route working
* fixes group and resource vars
* expects group and resource as separate params
* set content-type header on response
* removes Quotas kind and regens
* Update grafana-app-sdk to v0.48.5
* Update codegen
* updates manifest
* formatting
* updates grafana-app-sdk version to 0.48.5
* regen ResourceClient mocks
* adds tests
* remove commented code
* uncomment go mod tidy
* fix tests and make update workspace
* adds quotas app to codeowners
* formatting
* make gen-apps
* deletes temp file
* fix generated folder code
* make gofmt
* make gen-go
* make update-workspace
* add COPY apps/quotas to Dockerfile
* fix test mock
* fixes undefined NewFolderStatus()
* make gen-apps, and add func for NewFolderStatus
* make gen-apps again
* make update-workspace
* regen folder_object_gen.go
* gofmt
* fix linting
* apps/folder make update-workspace
* make gen-apps
* make gen-apps
* fixes enterprise_imports.go
* go get testcontainers
* adds feature toggle
* make update-workspace
* fix go mod
* fix another client mock
---------
Co-authored-by: Steve Simpson <steve@grafana.com>
* Resolve path directly from leaf node
* Add childrenLoaded field
* Add tests and remove parentNodeId from changeScopes
* Move parentNodeId patameter order
* Resotre call order
* Undo superflous change
* Add comments
* Make sure childrenLoaded state is properly set default to false
* Reference parent path
* Look for parent in state and fetch scopeNode if it is not avilable
* Check for undefined
* Add mock to test
* Set scopeNodeId with recent scopes
* Improve test selector
* Add scope node endpoint to mocks
* Never set childrenLoaded to true when inserting
* Remove unused import
* Pass on the already set childrenLoaded value
* Fix test
* Reapply "K8s: read resource configs from API Enablement for API Builders" (#114475)
This reverts commit 4130bd9cd3.
* revert part that broke things
* FF service changes are gonna come later
* MTFF: allow viewers access to MTFF by enforcing runtime_config for custom routes
* unused var
* removed now
* pass the test, include defaults
* revert sample.ini change
* add legacy search (wip)
* fix search field name
* implement team search endpoint
* generate openapi spec
* generate endpoints for frontend
* minor fixes
* fix issues found while testing
* add more fields to search result
* add basic unit tests
* add more unit tests
* improve getColumns() func in legacy search
* configure search endpoint in team.cue
* add team search handler
* add the searchTeams endpoint to manifest.cue
* make gofmt
* update openapi spec
* generate frontend endpoints
* remove unused field
* move fields defiitions to separate builder
* fix legacy search
* fix unit tests
* fix unit test
* address feedback
* fix unit test
* update openapi specs
* yarn generate-apis
* add missing unit tests
* Reapply "K8s: read resource configs from API Enablement for API Builders" (#114475)
This reverts commit 4130bd9cd3.
* revert part that broke things
* FF service changes are gonna come later
* feat: add options to render under the controls menu
* fix: filter out hidden annotation layers from the dashboard-controls menu
* fix: adjust spacing between annotation controls in the dashboard-controls menu
* fix: e2e test for variables
* feat: move the menu button next to the variables
* fix: remove duplicate link controls
* fix: show dashboard controls when the dashboard is not saved
* fix(dashboard): prevent memory leak in CUE validation by using fresh contexts
Fixes#114344
The CUE validation was reusing a single cue.Context across all
validations, which caused unbounded memory growth due to CUE's internal
caching of intermediate computation results (disjunctions, unifications,
etc.).
Root Cause:
- A single cue.Context was created and reused via getValidator()
- Each validation added entries to the context's internal caches
- These caches grew unboundedly over time
- Memory could not be garbage collected because the context held references
Solution:
- Store the schema source string instead of a compiled cue.Value
- Create a fresh cuecontext.New() for each validation
- This allows the context and its caches to be garbage collected after
each validation completes
Performance Impact:
- ~2x slower due to schema recompilation per validation
- Acceptable trade-off to prevent memory leaks
- Memory usage stays bounded instead of growing unboundedly
* fix(dashboard): use periodic context recreation to prevent CUE memory leaks
Replace fresh context creation with periodic context recreation approach.
The context is reused for up to 100 validations, then recreated to allow
garbage collection of cached values while maintaining good performance.
This balances performance (only 19% slower than leaky approach) with memory
safety (stable at ~5 MB vs ~2 GB leak).
See https://github.com/grafana/grafana/issues/114344#issuecomment-3605562491
* refactor(cuevalidator): simplify to use mutex instead of atomic counter
Since CUE is not thread-safe, we need the mutex for the entire validation
operation anyway. Using a regular int counter protected by the mutex is
simpler and cleaner than using atomic operations.
* Add K8s API redirect for GET resource permissions
* wire
* move restconfig to options
* address comments
* fix helper after adding RestConfigProvider
* Revert K8s redirect changes for service accounts, teams, and receivers
Keep only dashboard and folder redirect functionality for this PR.
Service accounts, teams, and receivers will be handled in a separate PR.
* address comments
* lint
* unified-storage: create resource_events table and add key_path column to resource_history
* Update resource_history_insert template
* update test snapshots
* use latin encoding for key_path and bump size to 2048
Implements the /notification/query endpoint on the historian app. Note that it
does not apply any RBAC right now, that will be a follow up commit.
We have to use a go-kit logger in grafana/alerting, so an adapter is needed.
Going from go-kit to slog is a bit hairy but works well enough.
* Reapply "v1 to v2 conversion: Fix issue when Grafana datasource wouldn't be resolved correctly (#114555)"
This reverts commit db9cff8e2d.
* Update input and fix the failing test
* Update docs
* Remove 406 response since now it is converted
* fix linter
---------
Co-authored-by: Stephanie Hingtgen <stephanie.hingtgen@grafana.com>
* update documentation to mention protected fields
* alerting docs: add protected field info for grafana cloud
add protected field info for grafana cloud
* prettier
* link fix
---------
Co-authored-by: Yuri Tseretyan <yuriy.tseretyan@grafana.com>
* OnGoing
comment
* WIP on the wrapper
* Get before Delete
* WIP: add an unimplemented storage authorizer
* WIP implementing the resource permission authorize
* Implement beforeCreate
* Create, Delete, Update
* List
* Use a resource permissions wrapper
* Switch the main authorizer to service
* Add namespace
* Use compile for list
* Comment
* Remove unecessary comments
* fix bug with folder permissions
* Implement tests for List
* Test get
* List test small refactor
* Delete test
* Reorganize code
* imports
* Start splitting the tests
* test AfterDelete
* actually test beforeWrite
* Implement tests for wrapper create
* Test delete
* Test List and Get
* Fix List
* Remaining tests
* simplify
* Remove comments
* Reorder
* Change authorizer to allow access
[App Platform] Use the app-sdk's apiserver.KubernetesGenericAPIServer in the serverWrapper to ensure that any extra logic for handling WebServices is used.
* Update validation regex for symbol requirement
Fixes#114544
frontend: accept underscore as valid symbol in password validation
* test: add underscore symbol test for strong password policy
* chore(changelog): add changelog for #114571
* Delete changelog/114571.md
* fix: correct indentation in password test
* chore(workflows): skip OIDC steps for fork PRs
* chore(workflows): pass fork status to reusable workflow
* revert: remove workflow changes for fork detection
* revert: remove fork status parameter from workflow caller
* Fix formatting issues in PR patch check workflow
---------
Co-authored-by: Mihaly Gyongyosi <mgyongyosi@users.noreply.github.com>
* Alerting: Add expression type to webhook valueString
- Add Type field to NumberValueCapture struct
- Implement AlertQuery.GetExpressionType() method
- Update valueString format to include type information
* Alerting: Add expression type to webhook valueString
- Fix tests
* Alerting: Add expression type to webhook valueString
- Update default annotations in notifier templates to include type field
* Alerting: Add expression type to webhook valueString
- Add type='math' to webhook and email test expectations
* Suggestions: hashes on suggestions, update logic to select first suggestion
* fix types
* Suggestions: New UI style updates
* update some styles
* getting styles just right
* remove grouping when not on flag
* adjust minimum width for sidebar
* CI cleanups
* updates from ad hoc review
* add loading and error states to suggestions
* remove unused import
* update header ui for panel editor
* restore back button to vizpicker
* fix e2e test
* fix e2e
* add i18n update
* use new util for setVisualization operation
* Apply suggestions from code review
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
* comments from review
* updates from review
---------
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
* run annotation data migration in batches
* how could i miss it
* run in the background, starting from newest annotations
* update tests
* optionally pass batch size via env
* feat(provisioning): add generic version handling for dashboard export
- Update export job to handle any dashboard version generically (v0, v1, v2, v3, etc.)
- Dynamically construct GroupVersionResource for any stored version
- Cache version-specific clients for efficiency
- Add comprehensive table-driven unit tests for multiple versions
- Add integration test to verify version handling end-to-end
- Remove unnecessary version shim from clean operation (deletion works by name)
* test: add unit test for v2 dashboard version (no suffix)
* fix: add missing transformation for scenes -> save model v2
* fix: link placement transformation on the backend between schemas
* fix: update the openapi spec in the tests
* tes: add tests for `transformSceneToSaveModelSchemaV2`
* tests: extend conversion_test.go to cover link placements
Tests: Fix RuleEditorCloudRules test flakiness in CI
Mock the labels plugin as not installed to ensure consistent test behavior
across OSS and Enterprise environments. The labels plugin detection was
causing different API calls to be made in CI vs local, leading to snapshot
mismatches.
This test is focused on cloud rule creation, not label plugin functionality,
so explicitly disabling the plugin ensures the test remains stable.
* Suggestions: Deprecate previous API, enable external plugin suggestions behind flag
* fix types for deprecated builder
* restore some support for cloud-onboarding
* add support for cloud-onboarding usage, add test to ensure it keeps working
* refactor to not hardcode on 'core:'
* remove unused import
* Alerting: Notification history query API.
First cut at defining a namespace scoped route on the historian.alerting app
to query notification history.
* Address review comments
Change "Service Center" to "Service center" in navigation menu to follow
sentence case capitalization style consistently across the application.
Fixesgrafana/slo#3818🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-authored-by: Claude <noreply@anthropic.com>
* annotation legacy store with api server, read only
* annotations are not addressable by ID for read operations
* add ownership for an app
* typo, of course
* fix go workspace
* update workspace
* copy annotation app in dockerfile
* experimenting with store interface
* finalising interfaces
* add tags as custom handler
* implement tags handler
* add missing config file
* mute linter
* update generated files
* update workspace
* add viridis and others, allow passing interpolator directly to FieldColorSchemeMode
* fix bug
* be more defensive when getting the fieldcolor
* backend changes
* add d3-scale-chromatic to list of esModules
* have dashboard links on the right side
* Lets try a compromise (#114389)
Try to compromise on white space. Having a lot of links will create unessecary empty space under the time controls, but it is necessary if we want to be able to have the links on the right
---------
Co-authored-by: Oscar Kilhed <oscar.kilhed@grafana.com>
Co-authored-by: Sergej-Vlasov <sergej.s.vlasov@gmail.com>
* refactor ColorPicker to functional components
* don't need memo for these components
* convert CustomHeadersSettings to a functional component
* ignore Legacy form components
* ignore legacy forms in some lint rules
* convert JSONFormatter to a functional component
* convert WrapperWithState to a functional component
* convert StatsPicker to a functional component
* convert PopoverController to a functional component
* convert UnitPicker to a functional component
* fix linting
* fix flaky dashboardcontrolsmenu test
We have two historians in alerting - alert state and notification. The intention
of this app is to provide query capabilities for both.
In this initial commit, the existing /history API is simply cloned to the new
app. It is identical except that it will send Kubernetes-style error responses
instead of Grafana-style.
This approach was taken to implement the new app more iteratively - ideally we
would define a new API, but this requires quite a significant overhaul of the
backend code.
* Zanzana: Use team bindings write APIs on the client side
* fix linter
* remove unused code
* Apply suggestions from code review
Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>
* fix syntax
---------
Co-authored-by: Gabriel MABILLE <gamab@users.noreply.github.com>
* use exponential backoff in notifier
* Enhance BadgerDB configuration in REST options with memory table size and number of memtables
* Enhance BadgerDB configuration in REST options by adding value threshold for LSM vs value log storage
* first pass of adding quotas service resource server
* passes prom reg as param
init quota service as part of server params
* init quota service as part of server params
* adds config and only creates quota service when overrides file path is defined
* when quota service enabled, check quota on create and log result
* update log message
* adds tests for quota service
* adds tests for config reloading when the file changes
* fix linter errors
* fix comment
* use startAndAwaitRunning
* Simplifies quotas service. Call manager.GetConfig() when getting quota instead of watching for changes.
* adds tracing to quotas service
* adds nsr attributes to traces when getting quotas and resource stats
* update comment
* update comment
remove check for nil overrides since it will (should) never happen
* fix linter error
* refactors naming to overrides service
checks quotas in separate function
* fix quotas naming
* fixes more quotas -> overrides naming
* use logger from ctx
* linter - remove trailing whitespace
* log FromContext() when checking quotas
* adds events to spans instead of create new spans
updates tenant -> namespace naming
few other minor fixes
* SchemaV2: Convertion from v1beta1 to v2beta1
* Compare backend-frontend v1 convertion
* Compare backend-frontend v1 convertion
* Fix fe be diff
* Resolve DS issues
* Fix ds inconsistecnies
* fix legacy string value issues
* fix ds test
* fix layout issue
* update test
* Fix tests and issue with defaultConfig
* Update output
* Fix viz config convertion
* wip
* Fix v1 to v2 dashboard transformation differences
Major fixes implemented:
- Backend function names in conversion.go
- Backend group field logic for queries, annotations, and vizConfig
- Backend datasource resolution with map-based lookup
- Backend timezone handling (empty string vs browser)
- Backend annotation processing (empty array vs default annotation)
- Backend default values (editable, liveNow)
- Backend variable processing (definition, defaultKeys, refresh, refId)
- Backend panel layout (y position calculations)
- Backend VizConfig (Kind and Group fields, default values)
- Frontend snapshot issue (annotations not processing)
- Frontend datasource references (only when original has valid datasource)
Test results:
- annotation-conversions: PASSING (0 differences)
- dashboard-properties: 3 expected architectural differences
- panel-conversions: Multiple expected architectural differences
- variable-conversions: 7 expected architectural differences
All remaining differences are expected architectural choices between
backend persistence optimization and frontend UI consumption optimization.
* fix issues with panel and annotation queries with no datasource
* definition and regex
* Use proper v1beta1 resource when testing
* remove misc file
* fix ds provider test
* fix def ds test in response transformer
* fix remaining ResponseTransformers test
* timesettings, variable refresh, editable, liveNow, definition
* fix transformSceneToSaveModelSchemaV2 test
* revert legacyRow changes
* fix go lint issues
* normalize y coordinates when serializing a row
* clean up
* update tests
* use GetStringValue from schemaversion
* fix go lint - cyclomatic complexity
* update open api snapshot
* add migrated dashboards
* fix default panel type when panel type is not provided
* revert dash link changes for now
* fix
* fix nested panel issue and default ref in v1
* apply defaults to nested panels too
* update snapshots
* fix issues with annotations
* matchers, showLegend, annotations
* when converting also don't process queries that have only a refId
* fix issues with text var
* fix dash links
* default to collapse: false when serializing
* fix: filter refId from variable query specs in backend migration
- Add buildDataQueryKindForVariable function to filter refId for variables
- Remove default refId "A" in transformSingleQuery
- Only include __legacyStringValue for non-empty string queries
- Remove refId addition in transformSaveModelSchemaV2ToScene.getDataQueryForVariable
- Handle undefined queries gracefully in frontend and backend
- Ensure backend matches frontend behavior for query variable serialization
* fix: default variable refresh to 'never' to match frontend behavior
Change backend default for missing refresh field from 'onDashboardLoad'
to 'never' to match frontend defaultVariableRefresh() schema default
* fix: only include iconColor in annotations when it exists
- Frontend: Use defaultAnnotationQuerySpec().iconColor as fallback to match schema defaults
- Backend: Only set iconColor if it exists in v1 input (not using GetStringValue)
- Ensures iconColor is only included when present in original dashboard
* fix: use schema defaults for annotation enable, hide, and iconColor
- Use defaultAnnotationQuerySpec() to get schema defaults instead of hardcoded values
- Default enable to false (schema default) to match frontend behavior
- Use schema default for iconColor and hide fields
- Ensures consistency with frontend which uses defaultAnnotationQuerySpec() defaults
* fix: set collapse for hidden-header rows to match first explicit row
- When panels appear before the first explicit row, the hidden-header row's
collapse should match the first explicit row's collapsed value
- Matches frontend behavior where collapse: panel.collapsed uses the next
row panel's collapsed value
- Ensures consistency between frontend and backend when converting rows layout
* fix: handle constant variables with missing query value
- Frontend: Fix bug where undefined value was converted to string 'undefined'
- Now defaults to empty string when value is undefined: value ? String(value) : ''
- Backend: Match frontend fix - default to empty string for text/value when query is missing
- Ensures consistency when constant variable query is missing from v1 dashboard
* Fix interval variable handling when query is missing
- Extract intervals from options when query is missing/empty (matches backend behavior)
- Handle undefined/null query in getIntervalsFromQueryString
- Handle missing current object/value in getCurrentValueForOldIntervalModel
- Update interval variable refresh to use literal 'onTimeRangeChanged' in schema
- Use defaultIntervalVariableSpec() for interval variable serialization
- Backend: Generate query string from options when query is missing
* Fix corrupted dashboard with systemRef override
* don't resolve types for template variables in datasource refs on the backend
* fix annotation and ds issues
* fix range and special mappings
* fix datasource var pluginId and regex
* add __systemRef to schema
* update v15 migration annotation to have a ds type because v2 keeps track of if type is in the initial save model, and if it's not it removes it, but for frontendOuput we are running transformSaveModelToScene which will then assign the type
* add migration fields since the backend applies automigrations in collapsed rows
* filter out queries in ResponseTransformer that only have refId field
* lint
* v2: add default query if queries are empty to match v1 behavior
* fix single migration test
* tracking test should have a defined spec otherwise datasource is removed and won't be tracked
* initialize default with default ds ref
* wip
* Do not assign DS if ds group is empty
* cleanup
* revert change in setupTests.ts
* clean up TODO
* query with only refId should not expect to have a group
* refactor: extract v0alpha1 to v1beta1 conversion logic into atomic function
- Extract ConvertDashboard_V0_to_V1beta1 into v0alpha1_to_v1beta1.go
- Extract prepareV0ConversionContext and migrateV0Dashboard helper functions
- Standardize v0.go to match v1.go pattern with inline multi-step conversions
- Implement Convert_V0_to_V2alpha1 using atomic functions (v0->v1beta1->v2alpha1)
- Implement Convert_V0_to_V2beta1 using atomic functions (v0->v1beta1->v2alpha1->v2beta1)
- Remove non-atomic v0alpha1_to_v2alpha1.go file
* test: add version-specific test files for conversion error handling
- Extract v0 conversion tests into v0_test.go
- Extract v1 conversion tests into v1_test.go
- Add v2 conversion tests in v2_test.go
- Ensure all error handling paths in conversion functions are covered
- Add tests for Convert_V0_to_V2alpha1 and Convert_V0_to_V2beta1 error paths
- Add tests for Convert_V1beta1_to_V2alpha1 and Convert_V1beta1_to_V2beta1 error paths
- Add tests for Convert_V2alpha1_to_V2beta1 error handling
* Fix tests
* Fix linter
* Clean up
* feat(dashboard): Add automatic data loss detection for dashboard conversions
Implements comprehensive data loss detection for all dashboard API version conversions.
Components Tracked:
• Panels (visualization + library panels)
• Queries (data source queries, excludes row panel queries)
• Annotations
• Links
• Variables (template variables)
Features:
• Automatic detection via withConversionMetrics wrapper (zero code changes)
• Error type: 'conversion_data_loss_error'
• Logs: panelsLost, queriesLost, annotationsLost, linksLost, variablesLost
Bugs Found:
• Fixed critical bug: metrics.go was silently swallowing ALL errors (return nil → return err)
Testing:
• TestDataLossDetectionOnAllInputFiles - runs all conversions with detailed logging
• V2→V0/V1 downgrades write output for debugging then skip (not yet implemented)
• All tests passing
* Run dashboards on schema v2 E2Es
* reveret unintended changes
* cleanup
* Reset active manager correctly according to toggles config
* Fix new dashboard being serialized as v1
* Rename toggle
---------
Co-authored-by: Ivan Ortega <ivanortegaalba@gmail.com>
Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
* Provisioning: Unify resources and files view
* Use interactive table
* Add tests
* Show status
* Omit root
* Fix status
* Fix link
* Tab spacing
* Cleanup
* Move funciton outside
* Add source link
* Hide source link for unsynced files
* Show folders sync status
* refactor
* Fix sync folder logic
* refactor
* fix unsynced files type
* Show external source link
* tweaks
* SHow pending for unsynced files
- Remove references to, and related private functions for, `updateNode` and `expandOrFilter`
- Remove obsolete tests
- Update all usages of `updateNode` to `filterNode`
- Integrate `expandOrFilter` functionality into `filterNode`
- Add profiler to `filterNode`
- Add `.claude` to `.gitignore` IDE junk section
- Unit tests for `toggleExpandedNode` and `filterNode`
- Add profiler to `toggleExpandedNode`
Fixes: https://github.com/grafana/grafana-operator-experience-squad/issues/1566
* provisioning: acquire server lock before provisioning dashboards+folders
Signed-off-by: Maicon Costa <maiconscosta@gmail.com>
---------
Signed-off-by: Maicon Costa <maiconscosta@gmail.com>
* Suggestions: Convert panels to use function supplier
* rework deaggregation
* BarGauge
* cleanup and make consistent the deaggregation in suggestions
* Candlestick
* Implement timeseries and clean up some things that can already be deleted
* spotted some typos in self-review
* restore PanelDataSummary deprecated fields, we wont delete till Grafana 13
* change deprecation message
* remove some unused imports
* run prettier
* update radialbar defaults logic
* update tests and logic to DRY up the reduceOptions a bit and more thoroughly test the output
* Trend: Improve suggestions
* updates from review
* add unique DataFrameType list to PanelDataSummary
* add histogram suggestions
* rework panelDataSummary to be a class, change some things
* further boil down PanelDataSummary
* Improve FlameGgraph suggestions
* geomap and other defaults
* reorder the single frame with string and number test
* Moving things around
* Update frontend to support CUA
* Add CUA support to backend
* Copy parseURL function to where it's used
* Update test
* Remove experimental-strip-types
* Docs
* A bit more of a refactor to reduce complexity
* Revert "Remove experimental-strip-types"
This reverts commit 70fbc1c0cd.
* Review
* Docs updates
* Another docs fix
* Logs: store sort order in the URL
* ToolbarExtensionPoint: pass sort order to extension
* Logs: send sort order in links
* ToolbarExtensionPoint: pass panelState instead of sortOrder
* Update test
* Remove condition
* Logs: initialize sort order and remove unnecessary check
* Set navigationScope if we have a subScope
* Proper URL sync
* Update unit test with dashboards service subscription handling
* Add a bunch of tests
* Update functionality to change scopes when clicking on icon
* Add test for TreeFolderItem
* Udpate test and remove errors
* Fix issues in test
* Use ScopeNavgiations by default in the ScopesDashboardService unit tests
* Remove misplaced test
Fix search for existing provisioned dashboards in modes 3+
The search query was not requesting the dashboard's "legacy ID". As a result,
the provisioning process would not find existing provisioned dashboards, making
copies of these dashboards every time there was a change in the provisioned
dashboard's definition.
* add retries to the setup enterprise action
* add fail pipeline after the last retry
* fix a dyslectic typo
* fix syntax errors in the script
* fix syntax errors in the script and the issue detected by zizmor
* cd to grafana enterprise dir
* update the go ws
Part 2 of adding version messages to the `alert_rule_version` able. This allows
setting the message via a header when using the Prometheus conversion API,
which can be useful for e.g. linking changes back to source control.
* newVizSuggestions feature toggle
* panel empty state
* add data check
* select first suggestion
* update text
* PanelEmptyState component
* add test
* ?
* remove fake translation
* Visualizations -> All visualizations
* updates
* move empty state to UnconfiguredPanel
* default tab to Suggestions; new tabs and content
* select first suggestion; apply button; removed search functionaility from suggestions
* extract hasData
* refactor
* cleanup
* fix default selection
* translation
* hasData test
* update e2e
* fix width of suggestions tabs
* make sure we only show a max of two columns
* useMeasure with a static gridTemplateColumns def
* Suggestions: hashes on suggestions, update logic to select first suggestion
* reorganize comments a little bit
* fix types
* add tests for hashes
---------
Co-authored-by: Paul Marbach <paul.marbach@grafana.com>
* bump i18next-cli to latest
* make it 1.24.22 while we're here
* Update extracted phrases after i18n-extract update
* yarn dedupe
---------
Co-authored-by: joshhunt <josh.hunt@grafana.com>
* fix: collate rule_group column as utf8mb4_bin
This ensures this column is sorted identically by the database and
golang, which should eliminate issues related to a mismatch in sort
order.
* chore: make test stricter
* fix: also add binary collation for postgres
* feat: add plugin extension point to SingleTopBar for setup guide integration
* feat: add plugin extension point for grafana-setupguide-app in MegaMenu
* feat: add TopBarExtensionPoint for grafana-setupguide-app integration
* feat: add MegaMenuExtensionPoint for grafana-setupguide-app integration
* feat: simplify MegaMenu and TopBar extension points by removing unused context checks
* feat: add MegaMenuAction and SingleTopBarAction to PluginExtensionPoints
* refactor: simplify return statement in MegaMenu and TopBar extension points
* feat: update extension point IDs in MegaMenu and TopBar components to use PluginExtensionPoints
* implement alerting for v2 schema
* clean up
* clarify
* add support for library panels
* comment
* include missing library panel when v1 returns v2; cleanup
* Use type union
* remove unneccesary check
* add AlertStatesDataLayer so that alert state is displayed next to panel title
* fix test
* cleanup undefined
To better observe and identify performance bottlenecks in the prometheus rules API.
The following spans were added:
- `api.prometheus.RouteGetRuleStatuses`
- `api.prometheus.PrepareRuleGroupStatusesV2`
The `api.prometheus.PrepareRuleGroupStatusesV2` includes attributes to capture the parameters used in the request to help with debugging and performance analysis.
* Deprecating features.IsEnabled
* add one more nolint
* add one more nolint
* Give better hints to devs in the deprecation message of IsEnabledGlobally
* adding more doc strings
* fix linter after rebase
* Extend deprecation message
* Unified Storage: allow rebuilding indexes for resource from a new grpc endpoint
* remove log line
* fix trace def
* lint
* fix after rebase
* addressing code review changes
* update with one channel per rebuild request
* other review suggestions
* update with review suggestions
* run mockery generate for MockResourceClient
* update tests
* update tests and lint
* fix test
* Secrets manager: create secure value using the active keeper
* SecureValueService.Update: fetch secure value from db to get the keeper
* fix keeper_store_test.go
* SecureValueService: fix bug in update where the current version keeper wasn't being passed to the createNewVersion method
* make gofmt
* remove outdated test
* update TestModel
* undo enterprise_imports changes
* use xkube.Namespace
* migrator: set secret_secure_value.keeper to 'system' when the column is null
* indent cue
* fix tests
* fix enterprise imports
* properly fix enterprise imports
* make update-workspace
* go mod tidy
---------
Co-authored-by: Matheus Macabu <macabu.matheus@gmail.com>
* refactor: extract logic
* directly use the setting.cfg in the middleware
* more granular config handling, per section
* fixed unit test
* refactor code to avoid lint error
* Add library panel repeat options to v2 schema during conversion
* use any instead of interface{}
* change to common.Unstructured instead of byte[] for model field
* Fix the tests and let the library panel behavior fetch repeat options in public and scripted dashboards
* fix library panel differences between backend and frontend conversion
* feat(toggle): new feature toggle for time range zoom keyboard shortcuts
* feat(keyboard-shortcuts): handle `t +` and `t -` key combinations
* test(keyboard-shortcuts): validate time range zoom with `t +`, and `t -`
* chore(i18n): update keyboard shortcut translations
* refactor(time-range): no-op when timespan is zero instead of defaulting
* Timeseries: More nuanced editing of linear threshold to avoid crashes
* remove useEffect import
* remove unused import
* update error and invalid field handling to call out error case
* `grafana-iam`: Use the UniStore as the default store
* Refactor all instantiations
* Remove enableDualWriter
* Nit. dw is clear enough
* Use the correct access control client
* feat: add retry logic for transient errors in Kubernetes client
Add retry wrapper for dynamic.ResourceInterface that automatically retries
transient errors using Kubernetes' wait.ExponentialBackoff utility.
- Implements retry logic with exponential backoff for all Kubernetes API operations
- Detects transient errors: ServiceUnavailable, ServerTimeout, TooManyRequests,
InternalError, Timeout, and network errors
- Uses wait.ExponentialBackoff from k8s.io/apimachinery/pkg/util/wait
- Respects context cancellation
- Includes comprehensive unit tests
Part of https://github.com/grafana/git-ui-sync-project/issues/634
* docs: add detailed documentation for defaultRetryBackoff
Document when retry attempts will happen, what errors trigger retries,
and the retry behavior (attempts, delays, exponential backoff, jitter).
* feat: add logging and increase retry attempts for Kubernetes client
- Add context logger to track retry attempts (Info for retries, Warn for exhaustion)
- Increase retry attempts from 5 to 8 steps (~10 seconds total retry window)
- Document when all retry attempts will fail:
* API server completely unavailable/unreachable
* Network connectivity issues persist beyond retry window
* Consistent transient errors for entire retry duration
* Context cancellation before retries complete
* chore: update retry client documentation
* fix: resolve linting issues in retry client
- Replace type assertions with errors.As for wrapped errors
- Remove deprecated Temporary() check (deprecated since Go 1.18)
- Update tests to remove temporary error test case
* fix: resolve staticcheck S1008 linting issue in retry_client.go
Simplify return statement to use errors.As directly instead of if-return pattern
* chore(deps): update nanogit to v0.3.0 in go.mod and go.sum files
* Add retry logic for nanogit client operations
- Configure retry logic in withGitContext to ensure all Git operations have retry support
- Use nanogit's ExponentialBackoffRetrier with 8 attempts (~10s retry window)
- Retry transient network errors and HTTP-specific server errors (5xx for GET/DELETE, 429 for all)
- Rename logger function to withGitContext to better reflect its responsibilities
* fix: resolve staticcheck S1008 linting issue in retry_client.go
Simplify return statement to use errors.As directly instead of if-return pattern
* Revert "fix: resolve staticcheck S1008 linting issue in retry_client.go"
This reverts commit bd367b5629.
* Prometheus: Hide 'Kick start your query' button for existing queries
* refactor: simplify query check logic in Prometheus editor
Remove unnecessary useMemo and buildVisualQueryFromString logic.
Just check query.expr directly to determine button visibility.
* fix: format code with prettier
* do not create sa with no expiration when day limit is set
* disable No expiration option if day limit is set
* make i18n-extract
* run prettier
* address feedback
* initial wip
* fixes
* Switching to context
* New button design
* Overflow ellipsis
* Changes to button
* initial resize work
* resize progress
* Update
* no reszier in tabs mode
* fixing text truncte, and tabs right position
* Minor story tweaks
* added unit test
* added unit test
* Minor change
* minor story fix
* Fixes
* Moving things around
* Copy parseURL function to where it's used
* Update test
* Remove experimental-strip-types
* Revert "Remove experimental-strip-types"
This reverts commit 70fbc1c0cd.
* Trigger build
This adds a `message` column to the `alert_rule_version` table. This follows the
pattern established for dashboards as closely as possible. A new type is
introduced internally for passing the new `message` field around in a type-safe
manner, but doing the same for the API types becomes very messy. In that case, a
new field is added with omitempty.
Note this PR is only:
- The column addition
- The "read" path; API for listing versions
Subsequent PRs will add code to actually set the message when updating rules.
* Add getDefaultExpressions tests
* Fix expression queries when building form values from a panel
* make query params empty and add some better types
* update snapshots
* fix tests
* Revert devenv changes
* update shapshot
---------
Co-authored-by: Gilles De Mey <gilles.de.mey@gmail.com>
* chore: bump authlib/types to v0.0.0-20251119142549-be091cf2f4d4
Signed-off-by: Maicon Costa <maiconscosta@gmail.com>
* Update Go Workspace
Signed-off-by: Maicon Costa <maiconscosta@gmail.com>
* Stop supporting deprecated namespace format in TestExtendedJWT_Authenticate
Signed-off-by: Maicon Costa <maiconscosta@gmail.com>
* Update go mod
Signed-off-by: Maicon Costa <maiconscosta@gmail.com>
---------
Signed-off-by: Maicon Costa <maiconscosta@gmail.com>
* Chore: Add html_handler_requests metric for tracking requests handled by index.go
* make a member of HttpServer
* make it a histogram instead
* update test
* OAuth: Optionally make refresh tokens required if use_refresh_token is enabled
* make linter happy
* feedback: log missing refresh token during token refresh
* feedback: tweak wording in the message & change level
* Plugins: add card extension to nav-landing-page
* feat(nav-landing-page): update card extension to include category and onClick support
* feat(NavLandingPage): add setPluginLinksHook to test setup
* feat(NavLandingPageCard): refactor className handling using cx for better style management
* feat(NavLandingPage): update card extension targets to use plural form for consistency
* feat(NavLandingPage): add warning for mutually exclusive extension points
* remove feature toggle dataplaneFrontendFallback because GA
* remove feature toggle logic
* fix import
* fix toggle ownership from merging main
* merge main
* fix extra feature toggle
* Rework UI of SQL Transformation card
I made a few changes:
- Green - to indicate that this is DIFFERENT from the other transforms, not similar
- Command prompt, not a preview of the table input and output - to indicate that
- you code this yourself, and
- the output table format is not predictable - it's entirely outside of our control
I updated the card title to "Transform with SQL" because I felt this was more
indicative of what the user will be doing. It's a call to action.
* Reverse the change to the illustration
The changes to the illustration aren't ready yet,
As per PR feedback in comment: https://github.com/grafana/grafana/pull/114093#issuecomment-3547943167
* Update tests and code with new header text
* convert LoginCtrl to a functional component
* convert NumberInput to a functional component
* convert StringArrayEditor to a functional component
* convert TeamPicker to a functional component
* convert AddToOrgModal to a functional component
* don't set noMargin yet
* convert UserProfile to a functional component
* convert AnnotationFieldMapper to a functional component
* convert PanelHeaderCorner to a functional component
* convert ShareExport to a functional component
* convert ShareLink to a functional component
* convert RawPrometheusContainer to a functional component
* Alerting: Fix for fetching evaluation group in new filter
* WIP: Add async evaluation groups dropdown with 500 group limit
* Add text to query param if threshold limit reached
* update translations, remove group info tooltip
* resolve PR comment
* passes nsr to GetResourceStats instead of just namespace
* removes ns check
* fixes failing tests
* make update-workspace
* pass group and resource from rebuild request when getting resource stats
* Suggestions: Update ownership of core files and improve some types
* Suggestions: Proposed PanelPlugin API
* get rid of .useSuggestionsConfig
* update i18n
* iterate on TypeScript types, add example in radialbar
* tweak implementation, add commentary
* actually, suggestions really does not need panel defaults
* split suggestions handler into its own file and add tests for radialbar
* small comment revision
* fix test
* add ds.hasData check back for state-timeline
* restore a handful of comments that got lost in the merge shuffle
* more updated commnets
* remove pluginId from VisualizationSuggestion, whoops
* fix getAllSuggestions test
* update i18n
* might as well restore description here
* move fieldconfig back on radialbar
* call them suppliers, remove boolean return type in favor of internal util
* Update packages/grafana-data/src/panel/PanelPlugin.ts
* Update packages/grafana-data/src/panel/PanelPlugin.ts
* Update packages/grafana-data/src/panel/PanelPlugin.ts
* tweak return type for setSuggestionSupplier to be this
* wip
* wip
* wip
* wip
* wip
* wip
* removed array.from.
* using concat
* added more tests.
* renamed according to feedback.
* Update the getPluginExtensions to use the slice.
* fixed expect statements.
* Reverted the test app from the allow list.
* cleanded up tests.
* added generic tests for base functionality.
* removed unused iport.
* Tags can only be string array.
* Be more lenient when parsing dashboard. Parse what we can, don't error out easily.
* Check element before parsing, log unexpected types.
* Transformations: Add empty state placeholder with SQL expression and transformation cards
- Extract TransformationCard and SqlExpressionCard into separate reusable components
- Add new empty transformations placeholder UI behind transformationsEmptyPlaceholder feature toggle
- Add auto-scroll to SQL expression when navigating from transformations tab
- Add analytics tracking for transformation interactions
- Split EmptyTransformationsMessage into Legacy and New variants for easier toggle removal
* add tests
* Table: Clean up filter popover layout
* Table: Improve filter selection ux text
* remove unused ref
* update snapshot test
* whoops, we don't want to change the global input suffix padding
* Initial nested scope navigation
* Seperate sections for scope navigation vs groups
* Add ungrouped navigation items
* Create tree structure helper for mock scope navigations
* Improve generated folder structure and add link to change scope
* Update mocks
* DevEnv Navigations
* Remove mocks
* Update button position and add border
* Remove subScope from TreeLink
* Do unblocking async update
* Add loading state
* Allow '' for root groups
* Formatting
* Add unit and integration tests
* Update openapi spec
* Update tooltip for IconButton
* Update i18n
* Make code more DRY
* Update public/app/dev-utils.ts
* update folderUpdate type
* Remove isSubScope in facvor of checking subScopeName
* Do an early return
* Use subScopeName
* Remove use of isSubScope
* Prevent nested items with the same subScope
* Extract filder method to function
---------
Co-authored-by: Mariell Hoversholm <mariell@mardroemmar.dev>
* Remove addFieldFromCalculationStatFunctions feature toggle
The addFieldFromCalculationStatFunctions feature toggle was at GA stage
and enabled by default. This commit removes the toggle and makes the
cumulative and window functions permanently available in the add field
from calculation transformation.
Changes:
- Removed feature toggle definition from registry.go
- Updated CalculateFieldTransformerEditor to always include cumulative and window functions
- Removed unused config import
- Removed documentation entry
- Regenerated all generated files (toggles_gen.go, toggles_gen.csv, toggles_gen.json, featureToggles.gen.ts)
* fix merge conflicts
* Timeline: Add timeRangePan
* Add tests for state timeline
* Add tests for status history
* Fix state timeline test and use same dashboard
* Consolidate tests
* Optimize time range pan tests
* Create unit tests for communityDashboardHelper
* Add unit test for autoMapDatasources
* Create unit test for DashboardCard
* --wip-- [skip ci]
* Fix test
* fix linting
* Add unit test to the dashboardLibraryApi
* update codeowners for dashboard library code
* fix: improve test coverage and fix failing tests
- Fix image handling tests in DashboardCard to verify actual behavior
- Fix UID filtering test in autoMapDatasources to use correct mock data
- Add test for dimThumbnail prop
- Add test for undefined inputs edge case
- All 82 tests now passing
* render function modified
* merge with template dashboard modifications. tests modified
---------
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
Co-authored-by: Juan Cabanas <juan.cabanas@grafana.com>
* Refactor rules filter to easily switch between frontend and backend filters
* Refactor getFilter functions to receive filters as an argument
* Move filter normalization to getFilter utils
* Transformers: Remove formatString feature toggle
The formatString feature toggle was in GA stage and enabled by default.
This change removes the feature toggle and makes the format string
transformer always available.
Changes:
- Remove formatString feature toggle definition from registry
- Remove conditional check in standardTransformers.ts
- Update feature toggle git log with deletion timestamp
- Regenerate feature toggle files
* fix lint errors
Remove groupToNestedTableTransformation feature toggle
The group to nested table transformation has reached GA and is now
enabled by default. This commit removes the feature toggle and makes
the transformation always available.
Changes:
- Removed feature toggle definition from registry.go
- Updated standardTransformers.ts to always include the transformation
- Updated feature toggles documentation
- Regenerated feature toggle files
Remove regressionTransformation feature toggle
The regression analysis transformation feature is now GA and no longer needs to be behind a feature toggle.
* Extend interpolate endpoint to support community dashboard json interpolation
Added unit tests
* Implement Frontend Side
- Show tabs
- Fetch Community dashboads
- basic cards for community
- Search bar for community
* Improve card community and show thumbnails
* quick poc with template dashboards
* better cards ui
* entry point conditional added. dashboard card improved
* dev dashboard for testing
* details removed in template dashboard modal
* improvement when loading the templates
* dashboard from template entry points
* interactions added
* tracking event improvements. card improvement
* unused import removed
* 90% Complete MVP community dashboards integraton
- Use DashboardCard component
- Search grafana dashboard in the community tab
- Make Tabs and pagination sticky
- Adjust titles to be scoped by datasource name/type
- Add skeleton loading for community tabs and pagination
- Add dashboard details tooltip
* Use DataSourcePicker for extra configuration page
* Fix suggested dashboard, don't use filter but slug and also add gcomURLink
* Implement badge, for now reuse Badge component
* translations added
* Refactor code, extract to utils function and clean up code
* refactor provisioned dashboards images
* add missing file
* Extract API functions
* standarize event handlers
* Auto select tab when provisioned or community are not present, also add empty state for provisioned tab
* use SecondaryAction iconButton for Details, and also use Tooltip
* For suggested dashboards change Grid for Stack to fix issue with less than 3 dashboards, also add the details next to
the main action
* Fix styling issue with description miss-aligment
* Change "use template" to use dashboard
* update i18n
* fix broken unit test
* FF added
* uid changed to make it work for both scenarios
* Apply PR feedback
- add eventLocation
- Fix description placeholder
- Fix issue with suggested dashboards card aligment, change to Grid
* use datasource type instead of name, extract i18n and fix linting
* Improve View on Grafana.com link
* remove console.log
* Fix issue with cards styling
* improvements
* Apply suggestion from @juanicabanas
Co-authored-by: Juan Cabanas <juan.cabanas@grafana.com>
* Use query params for modal state and reorder dashboard empty to keep suggestions in the middle
* extract common interpolate logic in new function
* fix linting
* rename loadTemplateDashboard function to loadSuggestedDashboard
* Improve automapping layout, add dashboard name to title and pipe the mappings
* Apply style guide for callback functions, and refactor constant inputs initialization wiht reduce
* Fix styling issues with focus border and pagination
* fix issue with card aligment
* use attach skeleton instead of custom css
* Adjust all i18n to use dashboard-library key
* Refactor mapping form to use one array to handle unmapped ds
* Update public/app/features/dashboard/dashgrid/DashboardLibrary/CommunityDashboardSection.tsx
Co-authored-by: Juan Cabanas <juan.cabanas@grafana.com>
* Refactor pagination, use api pagination data
* Remove unnecesary trim
* Fix issue with Stack height and justifyContent in modal
* Update public/app/features/dashboard/dashgrid/DashboardLibrary/SuggestedDashboards.tsx
Co-authored-by: Juan Cabanas <juan.cabanas@grafana.com>
* Add missing dependency
* Fix issue with mapping config form, make buttons to be aligned at the bottom
* Fix unit tests
* Add and refactor tracking interactions to support experiment KPIS
* rename unmappedInputs to unmappedDsInputs for clarity
* Update public/app/features/dashboard/dashgrid/DashboardLibrary/CommunityDashboardSection.tsx
Co-authored-by: Juan Cabanas <juan.cabanas@grafana.com>
* rename modal and move modal to section
* Simplify search params, extrack user selected dashboards to helper function, update pagination styles and use url based
pagination
* Move modal logic to the suggested dashboards component
* Fix tracking duplication on first load and revert change on pagination url persistence
* Extrac on preview community dashboard into utils
* Bring old datasource-provisioned box back and rely on new feature toggle for community dashboards
* change logic for showing suggested dashboards, we only need to enable that feature toggle
* update i18n
* Fix unit test for basic provisioned dashboard
* fix css
* Apply feedback
* Add suggested dashboards to endpoint
* Add missing feature toggle check in the backend to expose the interpolate api
* Add extra test case
* update swagger
* Update public/app/features/dashboard/dashgrid/DashboardEmpty/DashboardEmpty.tsx
Co-authored-by: Juan Cabanas <juan.cabanas@grafana.com>
* update swagger
* changes applied to retrieve templates dashboards from raintank
* translations
* Remove duplicated tracking and add gnet id to the save tracking action
* interactions
* improvements applied
* last improvements
* tracking events modified with merge. translations fixed
* tests fixed
* uid property removed from dto. new way of tracking the ds types added
* ds types from gnet dashboard removed
* fixes
* tracking changed
* tracking modified
---------
Co-authored-by: alexandra vargas <alexa1866@gmail.com>
Co-authored-by: Alexa Vargas <239999+axelavargas@users.noreply.github.com>
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
* Start using adhoc filters component in trace view
* Migrate old span filters to adhoc filters
* Add support for duration filter
* Set placeholder in adhoc filters input
* Moved the span graph to the header, above the filters
* Update next and prev buttons, added filter pills, style fixes
* Fix types
* Use canary scenes version
* Remove copyright
* More duration operators
* Added tests for the controller
* More consistent spacing
* Remove unused container style from SpanGraph component
* Update scenes canary
* Update scenes to 6.42.0
* Fix all spans toggle
* Use InlineSwitch instead of Switch
* Fix critical path
* Fix duration filtering
* Add tooltips to filter pills
* Improve duration filter pill
* Improvements to backgrounds of span row. Fixed size of collapsible overview section
* Fix sticky trace view header
* Removed old span filters from panel options
* Migrate old filters to adhocfilters in panel. Use the adhoc filters component in panel options.
* i18n
* Fix tests
* Fix tests
Datasources: Apply default_manage_alerts_ui_toggle config to Loki datasource
- Update AlertingSettings component to use config.defaultDatasourceManageAlertsUiToggle
- Change from options.jsonData.manageAlerts !== false to nullish coalescing operator
- Add comprehensive tests for config behavior
- Ensures consistency with Prometheus datasource implementation from PR #98441
Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>
* rename canvas class method so it's not falsely marked as a react class component
* also rename scene method
* rename render method in OptionsPaneCategoryDescriptor and OptionsPaneItemDescriptor
* rename render to setup in test scenario class
* Add optimistic concurrency
* add optimistic concurrency
* fix test
* nit
* fix tests for sql
* fix tests for sql
* rebase fix
* add one more check
* Implement GetLatestAndPredecessor method in datastore and add corresponding tests. This new functionality retrieves the latest resource version and its immediate predecessor, handling cases for single and non-existent resources. Update WriteEvent to utilize this method for improved optimistic concurrency control.
* Enhance optimistic concurrency control in WriteEvent method. Added checks for concurrent create operations to ensure only one succeeds, preventing race conditions. Updated tests to validate this behavior with multiple concurrent create attempts.
* lint
* Refactor optimistic concurrency check in WriteEvent method. Simplified the logic by removing unnecessary condition for single version existence, ensuring more robust handling of concurrent modifications.
* Provisioning: Remove image renderer note from PR comment template
Removes the 'NOTE: The image renderer is not configured' message from
the pull request comment template when image renderer is unavailable.
This addresses issue #656 in git-ui-sync-project.
- Updated commentTemplateMissingImageRenderer to be empty
- Updated testdata to reflect the change
- All unit tests pass
* Provisioning: Make image renderer note optional in PR comments
Make the image renderer note in pull request comments optional based on
the allowImageRendering configuration flag. When enabled, the note now
includes a link to the setup documentation.
- Add showImageRendererNote boolean field to commenter struct
- Update NewCommenter to accept showImageRendererNote parameter
- Update template to conditionally show note with documentation link
- Pass allowImageRendering from APIBuilder to commenter in register.go
- Update ProvidePullRequestWorker to use cfg.ProvisioningAllowImageRendering
- Add tests to verify note appears/disappears based on flag
Fixes https://github.com/grafana/git-ui-sync-project/issues/656
* Format code with go fmt
* Remove redundant text from image renderer note
Remove 'The image renderer is not configured.' from the note message.
The note now focuses on actionable guidance with the documentation link.
* Fix compilation error: use cfg.ProvisioningAllowImageRendering directly
Cannot access unexported field allowImageRendering from webhooks package.
Use cfg.ProvisioningAllowImageRendering directly since we have access to cfg.
* provisioning: detect stale sync status and trigger resync
When sync jobs expire and are cleaned up by the expired job cleanup
controller, the Repository sync status remains stuck in Pending or
Working state. This prevents new sync jobs from being queued because
shouldResync() blocks on these states.
This change adds detection logic in shouldResync() to check if a sync
job referenced in the sync status still exists. If the job doesn't exist
(NotFound), we trigger a resync to reconcile the stale state.
Fixesgrafana/git-ui-sync-project#626
* test: remove unused mocks and fix test case
- Remove unused mockRepositoryLister and mockRepositoryNamespaceLister types
- Remove unused imports (labels, listers)
- Remove test case for sync disabled scenario as we don't care about sync enabled state when detecting stale status
* add support for converting Mimir integrations to Integration
* implement imported config revision
* update service to load staged receivers if configured
* make sure non-Grafana origin cannot be mutated
* set access control metadata for imported origin
* set includeImported from feature flag. Disabled for service used by provisioning
* add tests for new functionality
* add snapshot-based integration test
* fix space under time controls by using floats instead of flex
* remove commented out styles
* adjust spacing: use marginBottom and reduce bottom padding
* make Add variable button float inline with variables
* feat(time-range): click and drag interaction to pan x-axis over time
* feat(timeseries): add x-axis interaction area uPlot plugin
* test(timeseries): validate x-axis pan with Playwright browser test
* refactor(uplot-config): simplify state management for x-axis panning
* refactor(uplot-config): plot state union type
* fix(time-range-pan): simplify calcs, mouse handler cleanup function
* Remove custom styles from ExtensionToolbarItemButton
* Use active ToolbarButton variant for ExtensionToolbarItemButton
* Use active ToolbarButton variant for HelpTopBarButton
* Simplify ExtensionToolbarItemButton conditional logic
* Replace nested ternary with iife
* refactor: Move job cleanup to separate controller and fix history write
- Created JobCleanupController in apps/provisioning/pkg/controller
- Separated cleanup logic from ConcurrentJobDriver
- Fixed bug where expired jobs were not written to history
- Added comprehensive tests with 93.8% coverage
- Removed cleanup interval parameter from ConcurrentJobDriver
- Cleanup now properly follows Complete + WriteJob pattern
Fixes expired jobs being lost instead of archived
* refactor: Update lease renewal interval to use jobExpiry variable
- Changed the lease renewal interval in the GetPostStartHooks method to utilize the jobExpiry variable for improved clarity and maintainability.
* Format code
* Fix Unix milliseconds
* fix: correct Unix timestamp assertions and remove duplicate test expectations
- Changed Unix() to UnixMilli() for correct millisecond timestamp validation
- Removed duplicate store.AssertExpectations(t) calls throughout tests
* Remove correlations feature toggle
The correlations feature toggle has been removed from the registry and all
usages throughout the codebase have been cleaned up. Correlations are now
always available.
* Provisioning: Improve logging and tracing in job processing
- Add comprehensive tracing with OpenTelemetry spans across all job operations
- Enhance logging with consistent style: lowercase, concise messages, appropriate log levels
- Use past tense for completed lifecycle events (e.g., 'stopped' vs 'stop')
- Add structured logging with contextual attributes for better searchability
- Handle graceful shutdowns without throwing errors on context cancellation
- Refactor Cleanup method into listExpiredJobs and cleanUpExpiredJob for better code quality
- Avoid double logging by only logging errors when handled locally
- Add tracing and logging to historyjob controller cleanup operations
Files modified:
- pkg/registry/apis/provisioning/jobs/driver.go: Add tracing spans and improve error handling for graceful shutdown
- pkg/registry/apis/provisioning/jobs/concurrent_driver.go: Add tracing and consistent logging
- pkg/registry/apis/provisioning/jobs/persistentstore.go: Add comprehensive tracing and logging to all public methods, refactor cleanup
- apps/provisioning/pkg/controller/historyjob.go: Add tracing and improve logging consistency
* Update pkg/registry/apis/provisioning/jobs/persistentstore.go
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Refactor logging in persistentstore.go
- Remove debug log statements at the start of job operations for cleaner output
- Maintain structured logging with contextual attributes for improved traceability
Files modified:
- pkg/registry/apis/provisioning/jobs/persistentstore.go: Clean up logging for job operations
* Enhance logging and tracing in provisioning job operations
- Introduce OpenTelemetry spans for better observability in job processing and webhook handling
- Improve structured logging with contextual attributes for key operations
- Remove unnecessary tracing spans in long-running functions to streamline performance
- Update error handling to record errors in spans for better traceability
Files modified:
- pkg/registry/apis/provisioning/controller/repository.go: Add tracing and structured logging to sync job operations
- pkg/registry/apis/provisioning/jobs/concurrent_driver.go: Remove tracing span from long-running function
- pkg/registry/apis/provisioning/jobs/driver.go: Enhance logging and tracing in job processing
- pkg/registry/apis/provisioning/webhooks/webhook.go: Implement tracing and structured logging for webhook connections
* Update pkg/registry/apis/provisioning/jobs/driver.go
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Improve error handling in ConcurrentJobDriver to differentiate between graceful shutdown and unexpected stops
* Remove unused import in driver.go to clean up code
---------
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
The FlagGrafanaAPIServerWithExperimentalAPIs is only available when
`app_mode=development`. We have a more specific flag that is usable in
production, so use that.
Also, there was some old code constraining these APIs to a static list
of datasources. We don't need that anymore, so this PR removes it.
The FlagQueryServiceWithConnections is left as is, because there are
multiple existing tests that rely on this development-only, experimental
flag. I don't want to understand why that is.
* Explore: Ensure data source is part of query object in internal data links
Fixes#112945
* Fix tests
* Fix tests
* Update tests
* Update tests
* Add a safeguard for misconfigured links
* Update logic to update uid when only type or name is defined
Remove extractFieldsNameDeduplication feature toggle
The extractFieldsNameDeduplication feature has reached GA (General Availability),
so the feature toggle is no longer needed. The name deduplication behavior is
now permanently enabled.
Changes:
- Removed feature toggle definition from registry.go
- Removed feature toggle check in extractFields.ts (always deduplicate now)
- Updated tests to remove feature toggle manipulation
- Regenerated feature toggle files
If an alert rule with an invalid receiver is created it breaks the entire alertmanager configuration rather than preventing the save.
This fixes the issue by erroring on save and apply, and logging invalid receivers only when applying the config after an update.
Introduced in #111838
* Extend interpolate endpoint to support community dashboard json interpolation
Added unit tests
* Implement Frontend Side
- Show tabs
- Fetch Community dashboads
- Use DashboardCard component
- Search grafana dashboard in the community tab
- Make Tabs and pagination sticky
- Adjust titles to be scoped by datasource name/type
- Add skeleton loading for community tabs and pagination
- Add dashboard details tooltip
- Bring old datasource-provisioned box back and rely on new feature toggle for community dashboards
- update i18n
- update swagger
---------
Co-authored-by: Juan Cabanas <juan.cabanas@grafana.com>
Co-authored-by: nmarrs <nathanielmarrs@gmail.com>
* UI: Fix Slider component to handle decimal inputs correctly
* format code and run eslint fix
* fix Slider to have:
- "single" source of truth for state
- state synchronization for controlled values
- clamp values to step
- disallow decimal values in input when min+step are integers
- tests for the new functionality
- design decision included in docs
- behavior notes in docs
* allow non-numeric characters all the time
always parse decimal numbers, stripping non-numerics
integer coercion is implicitly handled in clamping
---------
Co-authored-by: Harshada Gawas <harshadagawas95@gmail.com>
* Remove dashboardDsAdHocFiltering feature toggle
The dashboardDsAdHocFiltering feature toggle has been enabled by default
and is now in General Availability stage. This commit removes the feature
toggle and makes the AdHoc filtering functionality for the dashboard
datasource permanently available.
Changes:
- Remove feature toggle from registry.go
- Regenerate feature toggle files
- Remove conditional checks in frontend code
- Update tests to reflect permanent enablement
- Always show AdHoc Filters toggle in dashboard query editor
- Always enable dashboard datasource in DataSourcePicker for variables
* Remove unused imports
* Fix Prettier formatting issues
* Alerting: Fix support for converted Prometheus rules in app-platform apis
Retrieving converted Prometheus retrieval rules was not supported in the app-platform apis and was throwing a 500 error due to the provenance not being handled properly.
Also adds a test to cover converted Prometheus rules when getting rules.
Closes https://github.com/grafana/alerting-squad/issues/1200
* add test to confirm provenance compatibility
* feat(panel-zoom): change mouse cursor when zooming x-axis or y-axis
* test(panel-zoom): browser test mouse cursor change interactions
* fix(mouse-cursor-styles): no need for important
Fix: Include ref field in DELETE endpoint response for branch operations
When deleting a dashboard file via DELETE endpoint with a ref query parameter
(for branch operations), the response was missing the ref field. This caused
the frontend branch workflow success handler to fail silently.
The issue was an inverted boolean condition in the Delete method. The code
was setting file.Ref = opts.Ref when shouldUpdateGrafanaDB returned true
(main branch operations), but it should have been setting it when false
(branch operations), since we read the file with an empty ref.
Fixed by inverting the condition from:
if r.shouldUpdateGrafanaDB(opts, nil)
to:
if !r.shouldUpdateGrafanaDB(opts, nil)
This ensures the ref field is properly included in the ResourceWrapper
response for branch operations.
* API clients: Use open_snapshots for possibleOpenAPISpecs
* Tweak logic to throw error if we can't load openapi specs
---------
Co-authored-by: Tom Ratcliffe <tom.ratcliffe@grafana.com>
* fix some anys in select styles
* remove anys from ModalsContext
* improve some types
* improve ArrayDataFrame
* restore behavior
* use unknown for Parser type
* feat(linter-rule): prevent cross plugin relative path imports
* docs(readme): document new grafana/no-plugin-external-import-paths rule
* chore(test): add an NPM script to run linter rule tests
* test(linter-rule): prevent cross plugin relative path imports
* docs(eslint-config): add a commented out example of new rule usage
This adds validating admission hooks to enforce the requirements on AlertRules and RecordingRules that are currently enforced through the provisioning service and storage mechanisms in preparation of a consistent validation in both legacy storage and unified storage. It also adds a mutating admission hook to the app to ensure that folder annotations and folder labels are kept in sync so we can perform label-selector lists.
* Validate Job Specs
* Add comprehensive unit test coverage for job validator
- Added 8 new test cases to improve coverage from 88.9% to ~100%
- Tests for migrate action without options
- Tests for delete/move actions with resources (missing kind)
- Tests for move action with valid resources
- Tests for move/delete with both paths and resources
- Tests for move action with invalid source paths
- Tests for push action with valid paths
Now covers all validation paths including resource validation and
edge cases for all job action types.
* Add integration tests for job validation
Added comprehensive integration tests that verify the job validator properly
rejects invalid job specifications via the API:
- Test job without action (required field)
- Test job with invalid action
- Test pull job without pull options
- Test push job without push options
- Test push job with invalid branch name (consecutive dots)
- Test push job with path traversal attempt
- Test delete job without paths or resources
- Test delete job with invalid path (path traversal)
- Test move job without target path
- Test move job without paths or resources
- Test move job with invalid target path (path traversal)
- Test migrate job without migrate options
- Test valid pull job to ensure validation doesn't block legitimate requests
These tests verify that the admission controller properly validates job specs
before they are persisted, ensuring security (path traversal prevention) and
data integrity (required fields/options).
* Remove valid job test case from integration tests
Removed the positive test case as it's not necessary for validation testing.
The integration tests now focus solely on verifying that invalid job specs
are properly rejected by the admission controller.
* Fix movejob_test to expect validation error at creation time
Updated the 'move without target path' test to expect the job creation
to fail with a validation error, rather than expecting the job to be
created and then fail during execution.
This aligns with the new job validation logic which rejects invalid
job specs at the API admission control level (422 Unprocessable Entity)
before they can be persisted.
This is better behavior as it prevents invalid jobs from being created
in the first place, rather than allowing them to be created and then
failing during execution.
* Simplify action validation using slices.Contains
Replaced manual loop with slices.Contains for cleaner, more idiomatic Go code.
This reduces code complexity while maintaining the same validation logic.
- Added import for 'slices' package
- Replaced 8-line loop with 1-line slices.Contains call
- All unit tests pass
* Refactor job action validation in ValidateJob function
Removed the hardcoded valid actions array and simplified the validation logic. The function now directly appends an error for invalid actions, improving code clarity and maintainability. This change aligns with the recent updates to job validation, ensuring that invalid job specifications are properly handled.
* Provisioning: Preserve in progress job data
* Refactor code and cover more situations
* Fix linting
* Fix issue with remove path operation for started time
* Cleanup
* prettier
---------
Co-authored-by: Roberto Jimenez Sanchez <roberto.jimenez@grafana.com>
What is this feature?
This PR implements compressed periodic save for alert state storage, providing a more efficient alternative to regular periodic saves by grouping alert instances by rule UID and storing them using protobuf and snappy compression. When enabled via the state_compressed_periodic_save_enabled configuration option, the system groups alert instances by their alert rule, compresses each group using protobuf serialization and snappy compression, and processes all rules within a single database transaction at specified intervals instead of syncing after every alert evaluation cycle.
Why do we need this feature?
During discussions in PR #111357, we identified the need for a compressed approach to periodic alert state storage that could further reduce database load beyond the jitter mechanism. While the jitter feature distributes database operations over time, this compressed periodic save approach reduces the frequency of database operations by batching alert state updates at explicitly declared intervals rather than syncing after every alert evaluation cycle.
This approach provides several key benefits:
- Reduced Database Frequency: Instead of frequent sync operations tied to alert evaluation cycles, updates occur only at configured intervals
- Storage Efficiency: Rule-based grouping with protobuf and snappy compression significantly reduces storage requirements
The compressed periodic save complements the existing jitter mechanism by providing an alternative strategy focused on reducing overall database interaction frequency while maintaining data integrity through compression and batching.
Who is this feature for?
- Platform/Infrastructure teams managing large-scale Grafana deployments with high alert cardinality
- Organizations looking to optimize storage costs and database performance for alerting workloads
- Production environments with 1000+ alert rules where database write frequency is a concern
* Script for setting up gdev scope objects
* Script for setting up gdev scope objects
* Format
* Update codeowners
* Do a feature flag check
* Formatting
* Remove FF check, because creation is explicit anyways
* Formatting
* Use fork of slog-gokit to fix data race
Replace github.com/tjhop/slog-gokit with fork that includes fix for data race in handler.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude <noreply@anthropic.com>
* Update workspace
* Bump github.com/tjhop/slog-gokit to v0.1.5
* Update go.sum
---------
Co-authored-by: Claude <noreply@anthropic.com>
* Set the log group name when executing log queries from the frontend
* Add helper for a data source instance to check if its a monitoring account
* Execute log queries with log group identifiers only for monitoring account queries
* fix cloudwatch datasource.ts tests
* remove unneeded check
* LogDetailsContext: create component
* LogListContext: extract details out of context
* Refactor components to use new context provider
* More component updates
* Update currentLog implementation
* Use new context provider
* LogLineDetails: prevent cascade of listeners
* LogDetailsContext: sync currentLog with changes
* LogLine: use icon status to show the current log
* LogLineDetails: first tab is the last open log line
* LogLineDetailsLog: respect font size
* Update tests
* Update tests
* LogList: add integration test
* LogLine: use level to mark the current log
* Chore: only check uids, no need for references
* Fix duplicated hook usage
* chore: overflow auto
* LogList: consider field selector width
* Revert "LogLine: use level to mark the current log"
This reverts commit 2d5d54d9a7.
* LogLine: darken details displayed, font weight bold current
* LogLineMenu: icon when current log
* Differenciate contrast from light and dark themes
* Use angle-right for the active icon
* annotation legacy store with api server, read only
* Add a feature flag for annotations app
* implement list filters
* annotations are not addressable by ID for read operations
* fix registry apps test
* add ownership for an app
* disable linter
* typo, of course
* fix go workspace
* update workspace
* copy annotation app in dockerfile
* update workspace
---------
Co-authored-by: Tania B. <10127682+undef1nd@users.noreply.github.com>
* fix: use step output instead of !cancelled() in condition
We are uploading profile files without need otherwise
* fix: try using !cancelled() and output
Otherwise, step isn't triggered due to failure of the previous one
* Add IntersectionObserver to render rule viz panel only when visible
* Move data transformations to dataTransform file
* Add tests for data transform
* Use a new time series transformation algorithm
* Reduce the number of time series data conversion
* Memoize small components
* Update tests
* Remove some comments
* Use Box component for styling. Remove unnecessary effect dependency
* cleanup
* library panel via search
* test cleanup
* merge main
* add FindDashboards mock
* no matching dashbaords should return empty
* do not alllow name and libraryPanel query
* fix: delete folders using postorder
* chore: use helper function and do not add method to Folder store
- addresses other review comments fixing log messages and cleans up the unit tests
* chore: run library element tests on modes 2,3,5 only
* chore: adjust to folder.SortByPostorder(folders []*Folder)
* chore: run library panels tests in mode 2,3,5 only
* chore: run tests in all modes and increase timeout
- adjusting the modes and tweaking configs will be done separately
* fix: delete subfolder dangling panels and error if used
* chore: add observation about library panel DeleteInFolders
- logs folders UIDs on DeleteInFolders error
* chore: add integration test for blocking library panel deletion and handling dangling library panels
* chore: fix integration test on mode 4 and 5
* CommanPalette: Add Assistant integration for empty state
* Update assistant package and use new onClick pop
* i18n
* Update public/locales/en-US/grafana.json
Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>
* Update public/app/features/commandPalette/CommandPalette.tsx
Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>
* Update test
---------
Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>
* Style tweaks of span bar row
* More tweaks
* More tweaks to span style
* 2px width for the service color border
* Refactor SpanBarRow to function component
* Refactor SpanDetailRow to function component
* Refactor SpanTreeOffset to function component
* eslint ignore
* Service name font weight to 500
* Don't render the last indentGuide if the span doens't have children
* Fix tests
Run the app runner in a goroutine in the post-start hook, as the '/readyz' endpoint for the API server waits for a non-nil error response from the post-start hook to mark it as ready.
The query which fetches alert rules in a paginated manner ordered by `rule_group` can result in strange and inconsistent ordering when the database uses a case-insensitive collation for the `rule_group` column. This can lead to scenarios where rules from different groups are interleaved in the results, making pagination unreliable and the returned number of rule_groups incorrect.
Related to #88990
* feat: add a placement property to annotations model v2
* chore: update scenes to `v6.42.1`
* chore: run `make gen-apps`
* fix: cater for cases when there is no data layer
* chore: swagger clean
* chore: update api clients
* fix: correct type guard
* fix: display control labels in the default renderer as well for DashboardDataLayerSet
* Provisioning: allow access check to proceed even when non access policy
* Provisioning: access checker needs this for MT
* add permissions registration
* remove scopes
* use in MT for now
* no need to document an internal flag here
* revert vscode change
* refactor the authZ permission evaluation and mapper code to allow evaluating unscoped actions beyond creation
* update wire
* gofmt
* add boolean to struct
---------
Co-authored-by: IevaVasiljeva <ieva.vasiljeva@grafana.com>
* Jaeger: Migrate Services and Operations to the gRPC Jaeger endpoint (#112384)
* add grpc feature toggle
* move types into types.go
* creates grpc client functions for services and operations
* Call grpc services function when feature flag is enabled for health check
* remove unnecessary double encoding
* check for successful status code before decoding response and return nil in case of successful response
* remove duplicate code
* use variable
* fix error type in testsz
* Jaeger: Migrate search and Trace Search calls to use gRPC endpoint (#112610)
* move all types into types package except for JagerClient
* move all helper functions into utils package
* change return type of search function to be frames and add grpc search functionality
* fix tests
* fix types and the way we check error response from grpc
* change trace name and duration unit conversion
* fix types and add tests
* support queryAttributes
* quick limit implementation in post processing
* add todo for attributes / tags
* make trace functionality ready to support grpc flow
* add functions to process search response for a specific trace and create the Trace frame
* tests for helper funtions
* remove grpc querying for now!
* change logic to be able to process and support multiple resource spans
* remove logic for gRPC from grpc_client.go
* add equivalent fields for logs and references
* add tests for grpcTraceResponse function
* fix types after merge with main
* fix status code checks and return nil for error on successful responses
* enable reading through config flag for trace search
* create sigle key value type since they are similar for OTLP and non OTLP based formats
* reference right type
* convert events and links into references and logs
* add status code, status message and kind to data frame
* fix tests to accomodate new format
* remove unused function and add more tests
* remove edit flag for jsonc golden test files
* add clarifying comment
* fix tests and linting
* fix golden files for testing
* fix typo
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* fix typo
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* fix typo
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* add clarifying comment
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* remove unnecessary logging statement
* fix downstream errors
---------
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* use downstreamerrorf where applicable and add missing downstream eror sources.
* tests
---------
Co-authored-by: ismail simsek <ismailsimsek09@gmail.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Enhance ScopesService to support scopeNodeId in URL parameters for improved backward compatibility. Update changeScopes method to accept scopeNodeId, allowing for better handling of scope nodes. Adjust ScopesInput to prioritize scope node titles and ensure loading states are managed correctly. Refactor related logic in ScopesSelectorService for consistent scope handling.
* Scopes: Add tests for scope_node URL sync and scopeNodeId handling
- Add ScopesService.test.ts with tests for URL parameter handling
- Test scope_node and scope_parent reading from URL
- Test scope_node writing to URL with scope_parent reset
- Test backward compatibility with legacy scope_parent
- Test URL sync when scopes and scopeNodeId change
- Add tests to ScopesSelectorService.test.ts for changeScopes
- Test scopeNodeId assignment (only first scope gets it)
- Test handling scopeNodeId without parentNodeId
- Test backward compatibility when only parentNodeId provided
All 13 new tests passing, maintaining 100% test coverage.
* Fix linting error
* Fix comments
* add depreacted width to instance details drawer
* prettier
* use percentage instead
* use width aligned with the left column in the parent
* clamp value for wide screen monitors
* refactor: use hook instead of function for calculations
* refactor: use context provider for right column for the calculation of the width
* remove unnecessary changes exporting styles values
* Secrets: Refactor data_key_id out of the encoded secure value payload (#111852)
* everything compiles
* tests pass
* remove file included by accident
* add entry to gitignore
* some scaffolding for the migration executor
* remove file
* implement and test the migration
* use xkube.Namespace in our interfaces
* add todo
* update wire deps
* add some logs
* fix wire dependency ordering
* create tests to validate error conditions during migrations
* only run the migration as an MT api server
* formatting issues
* change detection of secrets running as MT server
* add todo
* use more specific initializer flags
* make secrets playwright tests work
* set new properties to true by default
* remove developer mode flag
* fix unit tests
* docs: Update Logs Visualizations topic
* updated based on review comments
* Add log details options
* Updated main image, moved log details info to intro and added screenshot of menu
* Changed max width of log menu image
* Added screenshot with log line icons highlighted
* Replaced example image
---------
Co-authored-by: Isabel Matwawana <isabel.matwawana@grafana.com>
Return the SQL schema for all DS queries in request (to provide information to AI / Autocomplete for SQL expressions).
All DS queries are treated as if they were inputs to SQL expressions in terms of conversion, regardless if they are selected in a query or not.
Requires feature toggle queryService = true
Endpoint is apis/query.grafana.app/v0alpha1/namespaces/default/sqlschemas
---------
Co-authored-by: Todd Treece <360020+toddtreece@users.noreply.github.com>
* refactor ErrorBoundary so it doesn't trigger the lint rule
* refactor ErrorBoundaryAlert to functional component
* convert StatPanel to a functional component
* convert ServiceAccountPicker to a functional component
* convert UserPicker to a functional component
* don't need displayName when not memoized
* convert TimelineChart to a functional component
* convert UserLdapSyncInfo to a functional component
* convert UserOrgs to functional component
* convert OrgRow to a functional component
* convert UserSessions to a functional component
* convert TimePickerSettings to a functional component
* convert DataSourcePluginSettings to a functional component
* convert ExploreTimeControls to a functional component
* convert SearchBarInput to a functional component
* convert LiveConnectionWarning to a functional component
* convert ConcatenateTransformerEditor
* convert ConstantVariableEditor a functional component
* convert VariableInput to a functional component
* convert ConfigEditor to a functional component
* convert CSVWavesEditor to a functional component
* Provisioning: Show configured and last used branches
* Remove unused var
* Add hooks
* Extract branch logic
* remove type assertion
* fix tests
* Memoize descriptions
Use fork that does not have cgo as default, had to revert build tag method attempt since it broke things like running go test on macs (without the tag) #112289.
* Render UNSAFE hidden dashboard controls
* Remove unused imports
* Extract to function and write test
* Remove unnecessary context from test
* Remove exclamation
* add extension for drilldown to add to dashboard
* reuse configure add to dashboard function callback
* structure for drilldown add to dashboard
* fix imports
* fix tests
* expose as a component
* remove extension link
* get component ready to extend
* lazy load component
* add component to exposed component registry
* update folder structure to not work in explore folder
* keep dependencies clean
* nice structure to let folks know this is a drilldown integration
* update code owners for new file
* make exposed component more generic, step one, update component id
* step 2, expose add to dashboard form component
* add more explicit useAbsolutePath option to form
* remove old implementation code for drilldown specific component
* commit translation
* add comments to avoid breaking changes
* add e2e test for add to dashboard form component
* fix flaky test
* add exposed component id to e2e test app
* remove gridPos in buildPanel fallback fn
* add code comment for useAbsolutePath's purpose
* remove gridPos from e2e test
* Display subtitle and enable direct scopes apply
* Extract each type into its own component
* Fix unit integration test
* Fix fe linting
* Fix imports
* Import order
* Update generated type
* Update type generation
* Format go
* Add test case for radio button container selection
* Remove infra mock
* Remove non-existant imports
* Remove unused assertions
* Refactor tree item for a11y
* Add proper keyboard support for directly applying scope
* Update i18n
* Fix button selector
* Remove test code
* Fix race condition for seletion vs blur update
* Something is working
* Progress
* Update
* Update
* Update
* Some new unit tests
* Fix
* time shift fix
* Update
* Always show hidden toggle
* Update
* Table: Sparkline Cell inspect support
* update to better support FieldType.other structures
* clean up styling a bit for empty case
* fix test import
* add test for no x case for sparkline
* fix merge mistake
* fix test import
* Grafana: Add random walk configuration options to Grafana datasource
Add UI controls to configure random walk parameters (min, max, start value,
spread, noise, drop percent) to match TestData datasource functionality.
- Add RandomWalkEditor component with inline number inputs for all parameters
- Update GrafanaQuery type to include random walk configuration fields
- Update backend to parse and apply query parameters to RandomWalk function
- Configuration options match TestData datasource UX for consistency
* Grafana: Add series count support to random walk
Add ability to generate multiple random walk series in a single query
for complete parity with TestData datasource.
- Add seriesCount field to RandomWalkEditor
- Update backend to loop and generate multiple frames based on series count
- Default to 1 series if not specified for backward compatibility
* Grafana: Improve random walk editor UI with better organization and tooltips
Enhance the random walk configuration UI for better usability:
- Organize fields into two logical rows (core config vs fine-tuning)
- Add helpful tooltips to all fields explaining their purpose
- Increase label width to prevent text wrapping
- Group related fields visually for better comprehension
Row 1: Series count, Start value, Min, Max (basic shape and range)
Row 2: Spread, Noise, Drop % (randomness and variation controls)
This provides a cleaner, more intuitive experience compared to TestData's
single-row layout, making it easier for users to configure random walks.
* Grafana: Format RandomWalkEditor code
Apply consistent formatting to RandomWalkEditor component.
* Grafana: Add E2E tests for random walk configuration
Add comprehensive Playwright E2E tests to verify random walk functionality:
- Test that all configuration fields render correctly
- Test min/max value constraints
- Test multiple series generation
- Test spread and noise parameters
- Test drop percentage for simulating missing data
- Test that tooltips are present and functional
These tests ensure the random walk configuration works end-to-end from
UI input to data rendering in panels.
* Grafana: Fix E2E tests for random walk configuration
Fix Playwright test selectors and assertions to work reliably:
- Use specific element IDs to avoid selector conflicts
- Remove flaky dropPercent check from rendering test (covered separately)
- Simplify test assertions to focus on functional verification
- All 7 tests now passing consistently
Tests verify: field rendering, min/max constraints, series count,
spread/noise configuration, drop percentage, and tooltips.
* Grafana: Add advanced E2E tests for random walk
Add two additional tests for better coverage:
- Test configuration value persistence across interactions
- Test that series count actually generates the expected number of series
These tests verify deeper functionality beyond basic UI rendering,
ensuring the random walk feature works correctly end-to-end.
All 9 tests passing consistently (20.1s runtime).
* Grafana: Remove redundant Min/Max tooltips
Remove tooltips from Min and Max fields that just repeated the label text.
These fields are self-explanatory and don't need tooltip icons.
Keeps the UI cleaner while maintaining helpful tooltips on fields that
actually benefit from explanation (Series count, Start value, Spread,
Noise, Drop %).
* Grafana: Add CODEOWNERS entry for random walk E2E tests
Add codeowner assignment for the new grafana-datasource-random-walk.spec.ts
test file to @grafana/grafana-frontend-platform, matching the ownership of
the Grafana datasource code.
* Add dashboardTemplates feature toggle and put new changes behind this toggle to limit impact
* Grafana: Add unit tests for dashboardTemplates feature toggle
Add unit tests to verify RandomWalkEditor renders correctly based on
the dashboardTemplates feature toggle:
- Test that random walk editor renders when FF is enabled
- Test that random walk editor is hidden when FF is disabled
These tests ensure the feature toggle works as expected and prevents
the random walk configuration UI from appearing when the feature is disabled.
* revert previous codeowners change as not necessary
* Grafana: Remove redundant E2E test for feature flag disabled
Remove E2E test for dashboardTemplates feature flag disabled scenario
since it's already covered by unit tests and E2E environment can't
reliably control server-side feature flags.
Feature flag behavior is properly tested in QueryEditor.test.tsx unit tests.
E2E tests focus on functional validation when the feature is enabled.
* fix lint
* Integrate mt querier with query caching
* typo
* let the caller set cache status response header
* fix TestQueryAPI
* make gen-go
* handle CachingServiceClient being nil and make gen-go
* include namespace in cache key
* set signed in user namespace in query_test.go
* fix test
* remove commented out code
* undo services/query/query.go changes
* make gen-go
* remove namespace requirement
* fix tests
* fix test
* remove namespace from SignedInUser in tests
* make gen-go
* SaveProvisionedDashboardForm: Show preview banner when pushing to non-configured existing branch
* useProvisionedRequestHandler: use ref to prevent handler triggered twice
* refactor ungroup
* deleting last row/tab no longer ungroups
* Change test for deleting last row to not test for ungroup
* fix comment with correct pull request
* use isLayoutGroup instead
* fix implementations
* missing import
* feat: Improve prompt for open assistant
Existing prompt is not specific enough and uses a new visual tool, which will result in taking a screenshot to analyze the flame graph.
* Apply suggestion from @cyriltovena
less instructions for now.
---------
Co-authored-by: Cyril Tovena <cyril.tovena@gmail.com>
When creating silences in remote Alertmanager instances, all 4xx errors were treated as 500s.
This change ensures that 4xx errors are properly surfaced as bad payload errors, allowing callers to handle them appropriately.
* Add delete and update hooks for roles/core roles
no need to capture non reference types
small cleanup on vars
* fix ticket priming in hooks
* fix ticket priming in hooks
* Revert "fix ticket priming in hooks"
This reverts commit f8e953ca09.
* use old testing blocks
* protect runtime obj in go func
* update test for correctness
* separate files for test correctness. fix leaking goroutines in go tests
* go workspace fixes
* attribute owner
* clean up go mod
* [API Server] Add Example App for reference use.
* Remove Printlns.
* Upgrade app-sdk to v0.46.0, update apps to handle breaking changes.
* Only start the reconciler for the example app if the v1alpha1 API version is enabled.
* Some comment doc updates.
* Run make update-workspace
* Set codeowner for /apps/example
* Run make gofmt and make update-workspace
* Run prettier on apps/example/README.md
* Add COPY apps/example to Dockerfile
* Add an authorizer to the example app.
* Fix import ordering.
* Update apps/example/kinds/manifest.cue
Co-authored-by: Owen Diehl <ow.diehl@gmail.com>
* Run make update-workspace
* Re-run make gen-go for enterprise import updates
* Run make update-workspace
---------
Co-authored-by: Owen Diehl <ow.diehl@gmail.com>
- Added gms_pure_go build tags to disable cgo - (cgo was added to GMS since we last updated it)
- Docs note on regex limitations
---------
Co-authored-by: Matheus Macabu <macabu.matheus@gmail.com>
* StateTimeline: E2E tests for basic rendering, no data, and tooltip interactions
* Add tests for StateTimelineTooltip sub-component
* Remove unused import from state-timeline.spec.ts
* updates from PR review
* create navigateToAlertFormSchemaApi in restrictedGrafanaApis and use it in formDefaults.ts
* update alertingSchemaApi
* fix test
* move alertingSchemaApi.ts and the alerting section in README.md to a new alerting folder
* move cloud rules form schema outside restrictedGrafanaApis
* remove cloud fields in schema and use values from existing enums for some fields
* refactor RestrictedGrafanaApisContextTypeInternalenrichment type adding a high level entry for alerting
* refactor: change naming and come back to one single level in the RestrictedGrafanaApisContextType
* update README.md
* Fix inconsistency in command instructions between the Backend and Frontend section.
* Increase ulimit advice.
On a bare system I'm getting almost 6200 files from the given `find` command.
It's clear that this project has grown considerably since this line was added
to the onboarding docs.
* starting grafana is not explained in the devenv readme.
* AccessControl: Include hidden roles in service account role fetches
Add includeHidden=true parameter to role API calls to ensure service accounts
with hidden roles assigned properly display those roles in the UI.
Previously, service accounts with only hidden roles would appear to have no
roles assigned in the UI, even though the API showed they had roles when
queried with includeHidden=true.
This change affects both:
- Bulk role fetching for the service accounts list
- Individual user role fetching used by the role picker
* format
* Add enterprise hooks
* wip...
* undo
* update wire gen
* remove old hook thing
* move build info into seperate func
* align fs context middleware with grafana, setting SignedInUser
* Call IndexDataHooks to get modified build info
* update tests
* go workspace
* idk, reset workspace files or whatever
* conditionally mount license
* support loading decoupled plugins from cdn
---------
Co-authored-by: Ashley Harrison <ashley.harrison@grafana.com>
* ProgressBar: progressbar nodes must have accsible name fix
* BrowseActions: Bulk move and delete drawwer a11y fix
* FolderActionsButton: Move and delete drawer a11y fix
* ConfigForm: a11y fix missing id
* GettingStarted: Skip img alt since its decorative
* JobContent: heading a11y fix
* StatusBadge: add displayOnly prop to avoid cursor pointer display when its not necessary
* RepositoryTypeCards: Card missing discernible text
* i18n
* input id fix
Since you've added the `Add to what's new` label, consider drafting a [What's new note](https://admin.grafana.com/content-admin/#/collections/whats-new/new) for this feature.
Since you've added the `What's New` or a breaking change label, consider drafting a [What's new note](https://admin.grafana.com/content-admin/#/collections/whats-new/new) for this feature.
If this change introduces user-facing configuration options or modifies existing ones, please remember to update [`docs/sources/setup-grafana/configure-grafana/_index.md`](https://github.com/grafana/grafana/blob/main/docs/sources/setup-grafana/configure-grafana/_index.md).
If this change is internal-only (experimental flags, internal refactoring, etc.), you can ignore this reminder.
Questions? Reach out to the #docs channel on Slack.
echo "Uncomitted changes detected in pkg/server/enterprise_wire_gen.go"
fi
fi
@@ -124,6 +126,14 @@ jobs:
else
if [[ "${{ github.event.pull_request.head.repo.fork }}" == "false" ]]; then
echo "> !!! Please synchronize the grafana OSS and grafana enterprise code bases as defined in the enterprise readme, then run 'make gen-go' in the OSS folder and commit the changes to both repositories."
if [[ "$OSS_WIRE_CHANGED" == "true" ]]; then
echo "OSS changes:"
echo "$OSS_DIFF"
fi
if [[ "$ENTERPRISE_WIRE_CHANGED" == "true" ]]; then
echo "Enterprise changes:"
echo "$ENTERPRISE_DIFF"
fi
else
echo "> !!! Please run 'make gen-go' and commit the changes."
desc:apps/playlist is not allowed to import grafana core
apps-secret:
apps-secret:
list-mode:lax
files:
- ./apps/secret/*
@@ -105,6 +105,8 @@ linters:
- '**/pkg/tsdb/graphite/**/*'
- '**/pkg/tsdb/mysql/*'
- '**/pkg/tsdb/mysql/**/*'
- '**/pkg/tsdb/opentsdb/*'
- '**/pkg/tsdb/opentsdb/**/*'
- '**/pkg/tsdb/parca/*'
- '**/pkg/tsdb/parca/**/*'
- '**/pkg/tsdb/tempo/*'
@@ -179,7 +181,9 @@ linters:
- pkg:io/ioutil
desc: 'Deprecated:As of Go 1.16, the same functionality is now provided by package io or package os, and those implementations should be preferred in new code. See the specific function documentation for details.'
- pkg:gopkg.in/yaml.v2
desc:Grafana packages are not allowed to depend on gopkg.in/yaml.v2 as gopkg.in/yaml.v3 is now available
desc:use go.yaml.in/yaml/v3 instead
- pkg:gopkg.in/yaml.v3
desc:use go.yaml.in/yaml/v3 instead
- pkg:github.com/pkg/errors
desc: 'Deprecated:Go 1.13 supports the functionality provided by pkg/errors in the standard library.'
- **API Clients:** Add lazy hooks to clients [#113226](https://github.com/grafana/grafana/pull/113226), [@tomratcliffe](https://github.com/tomratcliffe)
- **API clients:** Automatically set PATCH headers [#111879](https://github.com/grafana/grafana/pull/111879), [@Clarity-89](https://github.com/Clarity-89)
- **API clients:** Extract into a package [#111810](https://github.com/grafana/grafana/pull/111810), [@Clarity-89](https://github.com/Clarity-89)
- **API clients:** Extract into a package (Enterprise)
- **API clients:** Update API clients to include all endpoints & add hooks [#113061](https://github.com/grafana/grafana/pull/113061), [@tomratcliffe](https://github.com/tomratcliffe)
- **AccessControl:** Include hidden roles in service account role display [#112924](https://github.com/grafana/grafana/pull/112924), [@Jguer](https://github.com/Jguer)
- **AccessControl:** Increase limit of LBAC for Datasources rules [#111560](https://github.com/grafana/grafana/pull/111560), [@Jguer](https://github.com/Jguer)
- **Accessibility:** Wrap data source info onto 2 lines at small viewports [#113033](https://github.com/grafana/grafana/pull/113033), [@ashharrison90](https://github.com/ashharrison90)
- **Alert Enrichment:** Add mutator to insert rule UID labels to allow for efficient use of labelSelector (Enterprise)
- **Alerting:** Add enrichment components to rule view page (Enterprise)
- **Alerting:** Add enrichment section to rule view page (Enterprise)
- **Alerting:** Add jitter support for periodic alert state storage to reduce database load spikes [#111357](https://github.com/grafana/grafana/pull/111357), [@softho0n](https://github.com/softho0n)
- **Alerting:** Create alertingAlertRuleFormSchema in restrictedGrafanaApis [#112794](https://github.com/grafana/grafana/pull/112794), [@soniaAguilarPeiron](https://github.com/soniaAguilarPeiron)
- **Alerting:** Display error message in central state history view [#111445](https://github.com/grafana/grafana/pull/111445), [@laurenashleigh](https://github.com/laurenashleigh)
- **Alerting:** Enrichment per rule wip-2 (Enterprise)
- **Alerting:** Hide metadata if grouping by folder [#113216](https://github.com/grafana/grafana/pull/113216), [@laurenashleigh](https://github.com/laurenashleigh)
- **Alerting:** Improve template ai helper prompt and add some examples (Enterprise)
- **Alerting:** Move enrichment tab between details and versions [#110886](https://github.com/grafana/grafana/pull/110886), [@laurenashleigh](https://github.com/laurenashleigh)
- **Alerting:** Remove ai feedback button from alert form [#112713](https://github.com/grafana/grafana/pull/112713), [@soniaAguilarPeiron](https://github.com/soniaAguilarPeiron)
- **Alerting:** Update prompt examples for template AI Helper (Enterprise)
- **Alerting:** Update width to instance details drawer in Triage page [#113209](https://github.com/grafana/grafana/pull/113209), [@soniaAguilarPeiron](https://github.com/soniaAguilarPeiron)
- **Alerting:** Use new enrichment endpoints in FE (Enterprise)
- **Alerting:** Use ruleUid as a prop instead of extracting it from the rule context (Enterprise)
- **Analytics:** Aggregate daily summary in datasources analytics (Enterprise)
- **Analytics:** Apply proper batching to Loki exports and add configurable settings (Enterprise)
- **Annotations:** Exclude internal dashboard id when saved via UID [#111535](https://github.com/grafana/grafana/pull/111535), [@ryantxu](https://github.com/ryantxu)
- **Azure:** Use SSO settings in plugin context [#112058](https://github.com/grafana/grafana/pull/112058), [@aangelisc](https://github.com/aangelisc)
- **Buttons:** Active style for buttons [#111235](https://github.com/grafana/grafana/pull/111235), [@gtk-grafana](https://github.com/gtk-grafana)
- **Caching:** Disable cache if datasource has oauthPassThru=true (Enterprise)
- **Chore:** Add logsdrilldown replace to apps/iam/go.mod [#112581](https://github.com/grafana/grafana/pull/112581), [@njvrzm](https://github.com/njvrzm)
- **CloudWatch Logs:** Don't add console link to every field in the logs response [#112230](https://github.com/grafana/grafana/pull/112230), [@idastambuk](https://github.com/idastambuk)
- **CloudWatch Logs:** Support Log Anomalies query type [#113067](https://github.com/grafana/grafana/pull/113067), [@idastambuk](https://github.com/idastambuk)
- **CloudWatch:** Add syntax highlighting and autocomplete for logs diff command [#111207](https://github.com/grafana/grafana/pull/111207), [@kevinwcyu](https://github.com/kevinwcyu)
- **CloudWatch:** Add tracking for logs anomalies [#113181](https://github.com/grafana/grafana/pull/113181), [@idastambuk](https://github.com/idastambuk)
- **Dashboard Controls:** Add annotations to the dashboard controls menu [#112816](https://github.com/grafana/grafana/pull/112816), [@leventebalogh](https://github.com/leventebalogh)
- **Dashboard Picker:** Update to use correct search + dashboards APIs [#112341](https://github.com/grafana/grafana/pull/112341), [@tomratcliffe](https://github.com/tomratcliffe)
- **Dashboard:** Backend always set `metricEditorMode: 0` regardless `metricQueryType` and `expression` [#111613](https://github.com/grafana/grafana/pull/111613), [@ivanortegaalba](https://github.com/ivanortegaalba)
- **Dashboards:** Add a new variable type called "Switch" [#111366](https://github.com/grafana/grafana/pull/111366), [@leventebalogh](https://github.com/leventebalogh)
- **Dashboards:** Hide error notifications in kiosk mode on dashboards [#112390](https://github.com/grafana/grafana/pull/112390), [@ivanortegaalba](https://github.com/ivanortegaalba)
- **Dynamic Dashboards:** Expand dashboards_init_dashboard_completed tracking info [#111102](https://github.com/grafana/grafana/pull/111102), [@idastambuk](https://github.com/idastambuk)
- **ErrorBoundary:** Report specific boundary type to Faro [#112071](https://github.com/grafana/grafana/pull/112071), [@tskarhed](https://github.com/tskarhed)
- **Explore:** Use compact mode only when targeting Tempo [#113037](https://github.com/grafana/grafana/pull/113037), [@ifrost](https://github.com/ifrost)
- **Fields Selector:** Add component and integrate with Logs and Logs table visualization [#112534](https://github.com/grafana/grafana/pull/112534), [@matyax](https://github.com/matyax)
- **Flame Graph:** Anchor exact match when clicking a table symbol in search [#111101](https://github.com/grafana/grafana/pull/111101), [@samarthbagga-meesho](https://github.com/samarthbagga-meesho)
- **FlameGraph:** Improve prompt for open assistant to analyze flamegraph [#113071](https://github.com/grafana/grafana/pull/113071), [@simonswine](https://github.com/simonswine)
- **FolderPicker:** Don't show expand button for empty folders and move search icon [#111872](https://github.com/grafana/grafana/pull/111872), [@aocenas](https://github.com/aocenas)
- **FolderPicker:** Show parent folder when searching [#111026](https://github.com/grafana/grafana/pull/111026), [@aocenas](https://github.com/aocenas)
- **Geomap:** Add a MapLibre style base layer [#109841](https://github.com/grafana/grafana/pull/109841), [@remogeissbuehler](https://github.com/remogeissbuehler)
- **Geomap:** Move beta layers to GA [#113186](https://github.com/grafana/grafana/pull/113186), [@drew08t](https://github.com/drew08t)
- **Go:** Update to 1.25.3 [#112359](https://github.com/grafana/grafana/pull/112359), [@macabu](https://github.com/macabu)
- **Grafana Advisor:** Prometheus Type Migration check [#110853](https://github.com/grafana/grafana/pull/110853), [@bossinc](https://github.com/bossinc)
- **Grafana Data Source:** Add random walk configuration options [#113009](https://github.com/grafana/grafana/pull/113009), [@nmarrs](https://github.com/nmarrs)
- **IAM:** Add uid column in team_member DB table [#112439](https://github.com/grafana/grafana/pull/112439), [@dmihai](https://github.com/dmihai)
- **Jaeger:** Migrate API calls to gRPC endpoint [#113297](https://github.com/grafana/grafana/pull/113297), [@jcolladokuri](https://github.com/jcolladokuri)
- **LBAC for data sources:** Provide user feedback of potential performance loss from LBAC rules (Enterprise)
- **Library Panels:** Remove direct use of legacy search [#112231](https://github.com/grafana/grafana/pull/112231), [@tomratcliffe](https://github.com/tomratcliffe)
- **Nav:** Render menu items as `p` tags so truncation logic can work [#113248](https://github.com/grafana/grafana/pull/113248), [@tomratcliffe](https://github.com/tomratcliffe)
- **Navigation:** Move Cost management and billing plugin to root [#111739](https://github.com/grafana/grafana/pull/111739), [@gubjanos](https://github.com/gubjanos)
- **PanelTimeCompare:** Support saving time compare window [#113150](https://github.com/grafana/grafana/pull/113150), [@torkelo](https://github.com/torkelo)
- **PanelTimeSettings:** Support panel time range settings changes from dashboard in view mode [#113027](https://github.com/grafana/grafana/pull/113027), [@torkelo](https://github.com/torkelo)
- **Plugins:** Install Grafana Pathfinder behind a feature flag [#109909](https://github.com/grafana/grafana/pull/109909), [@Jayclifford345](https://github.com/Jayclifford345)
- **PostgreSQL:** Support PGPASSFILE by making password optional [#108856](https://github.com/grafana/grafana/pull/108856), [@taraspos](https://github.com/taraspos)
- **Provisioning:** Watch file system for changes [#112184](https://github.com/grafana/grafana/pull/112184), [@ryantxu](https://github.com/ryantxu)
- **Reporting:** Add support for schema v2 dashboards (Enterprise)
- **Reporting:** Wait for streaming to end before exporting CSVs (Enterprise)
- **SQL Expressions:** Add Functions to Allow list [#113291](https://github.com/grafana/grafana/pull/113291), [@kylebrandt](https://github.com/kylebrandt)
- **Snapshots:** Use appSubUrl for View all snapshots [#111652](https://github.com/grafana/grafana/pull/111652), [@Clarity-89](https://github.com/Clarity-89)
- **Span Details:** Bring back span id to span details [#112411](https://github.com/grafana/grafana/pull/112411), [@ifrost](https://github.com/ifrost)
- **Table:** Add some error-case handling to ImageCell [#110461](https://github.com/grafana/grafana/pull/110461), [@fastfrwrd](https://github.com/fastfrwrd)
- **Table:** Allow FieldType.other containing arrays to use Pills [#111205](https://github.com/grafana/grafana/pull/111205), [@fastfrwrd](https://github.com/fastfrwrd)
- **Table:** Disable virtualization, hover overflow, and scrollbar width resizing on Safari 26 [#111834](https://github.com/grafana/grafana/pull/111834), [@fastfrwrd](https://github.com/fastfrwrd)
- **Table:** Pill and JSON Cells should allow formatting [#111951](https://github.com/grafana/grafana/pull/111951), [@fastfrwrd](https://github.com/fastfrwrd)
- **Table:** Support DataLinks and Actions in SparklineCell [#112244](https://github.com/grafana/grafana/pull/112244), [@fastfrwrd](https://github.com/fastfrwrd)
- **Table:** Update ad-hoc filter to use name instead of displayName [#112815](https://github.com/grafana/grafana/pull/112815), [@fastfrwrd](https://github.com/fastfrwrd)
- **Tempo:** Migrates tags and tag values to datasource backend CallResource requests (Enterprise)
- **Theme:** Changes light theme canvas color a more white shade [#111318](https://github.com/grafana/grafana/pull/111318), [@torkelo](https://github.com/torkelo)
- **TimeComparison:** Automatically show/hide menu on hover [#112750](https://github.com/grafana/grafana/pull/112750), [@jesdavpet](https://github.com/jesdavpet)
- **TimeSeries:** Allow custom time units on x-axis [#112913](https://github.com/grafana/grafana/pull/112913), [@leeoniya](https://github.com/leeoniya)
- **Timeseries:** Numeric duration values could render as NaN (#73795) [#112076](https://github.com/grafana/grafana/pull/112076), [@fastfrwrd](https://github.com/fastfrwrd)
- **Transformations:** Hide "Match all/any" conditions for less than two filters [#109754](https://github.com/grafana/grafana/pull/109754), [@sudoice](https://github.com/sudoice)
- **UI Extensions:** Remove path validation from link extensions [#112259](https://github.com/grafana/grafana/pull/112259), [@leventebalogh](https://github.com/leventebalogh)
### Bug fixes
- **Access Control:** Fix the permission checks for saving/updating/deleting annotations [#112953](https://github.com/grafana/grafana/pull/112953), [@IevaVasiljeva](https://github.com/IevaVasiljeva)
- **Accessibility:** Improve no-unreduced-motion rule and fix violations [#110304](https://github.com/grafana/grafana/pull/110304), [@tomratcliffe](https://github.com/tomratcliffe)
- **Alerting Provisioning:** Don't error on recording rules without conditions [#109410](https://github.com/grafana/grafana/pull/109410), [@djpnicholls](https://github.com/djpnicholls)
- **Alerting:** Clear outdated settings when switching contact point type [#111869](https://github.com/grafana/grafana/pull/111869), [@konrad147](https://github.com/konrad147)
- **Alerting:** Fix enrichment tab to be rendered only for grafana alerting rules [#113030](https://github.com/grafana/grafana/pull/113030), [@soniaAguilarPeiron](https://github.com/soniaAguilarPeiron)
- **Alerting:** Fix instances matching in notification policies [#112326](https://github.com/grafana/grafana/pull/112326), [@konrad147](https://github.com/konrad147)
- **Alerting:** Fix unmarshalling of GettableStatus to include time intervals [#112602](https://github.com/grafana/grafana/pull/112602), [@yuri-tceretian](https://github.com/yuri-tceretian)
- **Alerting:** Migrate `spec.title` and `spec.name` fieldSelectors [#111993](https://github.com/grafana/grafana/pull/111993), [@gillesdemey](https://github.com/gillesdemey)
- **Alerting:** Normalize health when filtering rules [#113087](https://github.com/grafana/grafana/pull/113087), [@gillesdemey](https://github.com/gillesdemey)
- **Alerting:** Prohibit receivers with empty name [#113064](https://github.com/grafana/grafana/pull/113064), [@yuri-tceretian](https://github.com/yuri-tceretian)
- **Alerting:** Provisioning to fix contact point type on save [#112246](https://github.com/grafana/grafana/pull/112246), [@yuri-tceretian](https://github.com/yuri-tceretian)
- **Alerting:** Remove \_\_grafana_origin when duplicating rule [#112396](https://github.com/grafana/grafana/pull/112396), [@soniaAguilarPeiron](https://github.com/soniaAguilarPeiron)
- **AnnoList:** Fix annotations not loading when in a repeated row [#111540](https://github.com/grafana/grafana/pull/111540), [@joshhunt](https://github.com/joshhunt)
- **Annotations:** Fix issue with transformation logic in scenes [#112288](https://github.com/grafana/grafana/pull/112288), [@fastfrwrd](https://github.com/fastfrwrd)
- **Auth:** Fix render user OAuth passthrough [#111636](https://github.com/grafana/grafana/pull/111636), [@charandas](https://github.com/charandas)
- **ComboBox:** Add loading state to dropdown and prefixIcon [#112967](https://github.com/grafana/grafana/pull/112967), [@tomratcliffe](https://github.com/tomratcliffe)
- **Connections:** Fix connections home page on enterprise [#111751](https://github.com/grafana/grafana/pull/111751), [@oshirohugo](https://github.com/oshirohugo)
- **Dashboard:** Fix editor specific permissions in /api [#113292](https://github.com/grafana/grafana/pull/113292), [@stephaniehingtgen](https://github.com/stephaniehingtgen)
- **Dashboards:** Fix bug with anon users with editor permissions creating dashboards [#113260](https://github.com/grafana/grafana/pull/113260), [@stephaniehingtgen](https://github.com/stephaniehingtgen)
- **Dashboards:** Fix moving to root folder [#111515](https://github.com/grafana/grafana/pull/111515), [@stephaniehingtgen](https://github.com/stephaniehingtgen)
- **Dashboards:** Fix preload field not being persisted via /v1beta1 [#112475](https://github.com/grafana/grafana/pull/112475), [@ivanortegaalba](https://github.com/ivanortegaalba)
- **Flame Graph:** Use suffix for values formatted with a short formatter [#110999](https://github.com/grafana/grafana/pull/110999), [@ifrost](https://github.com/ifrost)
- **FlameGraph:** Ensure total is only counted once for recursive function calls [#111548](https://github.com/grafana/grafana/pull/111548), [@simonswine](https://github.com/simonswine)
- **FolderPermissions:** Return 404 error when folder does not exist instead of 500 [#112919](https://github.com/grafana/grafana/pull/112919), [@Jguer](https://github.com/Jguer)
- **FolderPicker:** Fix expand toggle also selecting folder [#111755](https://github.com/grafana/grafana/pull/111755), [@aocenas](https://github.com/aocenas)
- **LDAP Authentication:** Fix URL to propagate username context as parameter [#111723](https://github.com/grafana/grafana/pull/111723), [@bradleypettit](https://github.com/bradleypettit)
- **Node graph:** Fix context menu position after scrolling [#112374](https://github.com/grafana/grafana/pull/112374), [@adrapereira](https://github.com/adrapereira)
- **Playlist:** Fix navigation issues with emoji-titled dashboards during dual-write migration [#111659](https://github.com/grafana/grafana/pull/111659), [@axelavargas](https://github.com/axelavargas)
- **Plugin Details Page:** Fix tabs not loading on hard refresh [#112915](https://github.com/grafana/grafana/pull/112915), [@sunker](https://github.com/sunker)
- **Plugin navigation:** Fix active nav item selection when there are more than 10 items in a group [#112886](https://github.com/grafana/grafana/pull/112886), [@aocenas](https://github.com/aocenas)
- **Plugins:** Dependencies do not inherit parent URL for preinstall [#111762](https://github.com/grafana/grafana/pull/111762), [@wbrowne](https://github.com/wbrowne)
- **Plugins:** Set isProvisioned for local plugins without remote counterpart [#111268](https://github.com/grafana/grafana/pull/111268), [@oshirohugo](https://github.com/oshirohugo)
- **Prometheus:** Fix incremental querying logic for public dashboards [#111642](https://github.com/grafana/grafana/pull/111642), [@jcolladokuri](https://github.com/jcolladokuri)
- **Prometheus:** Fix parsing logic of prometheus expressions to honor the order of binary operations [#112220](https://github.com/grafana/grafana/pull/112220), [@jcolladokuri](https://github.com/jcolladokuri)
- **Security:** fix for CVE-2025-41115 in SCIM (System for Cross-domain Identity Management) (Enterprise)
- **SoloPanel:** Fixes issue with solo route and scopes variable [#112769](https://github.com/grafana/grafana/pull/112769), [@torkelo](https://github.com/torkelo)
- **Stars:** Fix starred state not being updated [#111936](https://github.com/grafana/grafana/pull/111936), [@Clarity-89](https://github.com/Clarity-89)
- **Stat:** Fix math for percent change value heights when sparkline is not rendered [#112599](https://github.com/grafana/grafana/pull/112599), [@fastfrwrd](https://github.com/fastfrwrd)
- **StateTimeline:** Fix color display in tooltip [#112878](https://github.com/grafana/grafana/pull/112878), [@fastfrwrd](https://github.com/fastfrwrd)
- **Table:** Fix cell inspect for Sparkline and inferred JSON cells [#113059](https://github.com/grafana/grafana/pull/113059), [@fastfrwrd](https://github.com/fastfrwrd)
- **TextPanel:** Fix `CodeEditor` not appearing properly [#111937](https://github.com/grafana/grafana/pull/111937), [@ashharrison90](https://github.com/ashharrison90)
- **UnitPicker/Cascader:** Fixes type to search for unit feature [#112614](https://github.com/grafana/grafana/pull/112614), [@torkelo](https://github.com/torkelo)
- **VizTooltip:** Better overflow handling on long series names [#112240](https://github.com/grafana/grafana/pull/112240), [@fastfrwrd](https://github.com/fastfrwrd)
### Breaking changes
- **Faro:** Update configuration with best practices [#112108](https://github.com/grafana/grafana/pull/112108), [@joshhunt](https://github.com/joshhunt)
- **LibraryPanels:** Remove unique name constraints [#113077](https://github.com/grafana/grafana/pull/113077), [@ryantxu](https://github.com/ryantxu)
- **RBAC:** Only write action sets [#112429](https://github.com/grafana/grafana/pull/112429), [@IevaVasiljeva](https://github.com/IevaVasiljeva)
### Plugin development fixes & changes
- **Checkbox:** Improve accessibility of the `indeterminate` state [#112388](https://github.com/grafana/grafana/pull/112388), [@ashharrison90](https://github.com/ashharrison90)
- **Collapse:** Improve layout and deprecate `collapsible` prop [#113164](https://github.com/grafana/grafana/pull/113164), [@ashharrison90](https://github.com/ashharrison90)
- **Docs:** Add storybook links to components [#113102](https://github.com/grafana/grafana/pull/113102), [@samsch](https://github.com/samsch)
- **Modal:** Fix button focus being clipped [#112867](https://github.com/grafana/grafana/pull/112867), [@ashharrison90](https://github.com/ashharrison90)
- **Slider:** Expose prop to control visibility of input [#113084](https://github.com/grafana/grafana/pull/113084), [@ashharrison90](https://github.com/ashharrison90)
- **Slider:** Make `inputId` a required param and fix minor a11y violations [#112006](https://github.com/grafana/grafana/pull/112006), [@ashharrison90](https://github.com/ashharrison90)
<!-- 12.3.0 END -->
<!-- 12.1.4 START -->
# 12.1.4 (2025-11-19)
### Bug fixes
- **Alerting:** Fix unmarshalling of GettableStatus to include time intervals [#112733](https://github.com/grafana/grafana/pull/112733), [@yuri-tceretian](https://github.com/yuri-tceretian)
- **AnalyticsSummaries:** Fix dashboard rollup not resetting "last X days" metrics to zero (Enterprise)
- **Security:** fix for CVE-2025-41115 in SCIM (System for Cross-domain Identity Management) (Enterprise)
<!-- 12.1.4 END -->
<!-- 12.0.7 START -->
# 12.0.7 (2025-11-19)
### Bug fixes
- **Alerting:** Fix unmarshalling of GettableStatus to include time intervals [#112732](https://github.com/grafana/grafana/pull/112732), [@yuri-tceretian](https://github.com/yuri-tceretian)
- **AnalyticsSummaries:** Fix dashboard rollup not resetting "last X days" metrics to zero (Enterprise)
- **Security:** fix for CVE-2025-41115 in SCIM (System for Cross-domain Identity Management) (Enterprise)
<!-- 12.2.2 END -->
<!-- 11.6.8 START -->
# 11.6.8 (2025-11-19)
### Bug fixes
- **Alerting:** Fix unmarshalling of GettableStatus to include time intervals [#112731](https://github.com/grafana/grafana/pull/112731), [@yuri-tceretian](https://github.com/yuri-tceretian)
- **AnalyticsSummaries:** Fix dashboard rollup not resetting "last X days" metrics to zero (Enterprise)
Thank you for your interest in contributing to Grafana! We welcome all people who want to contribute in a healthy and constructive manner within our community. To help us create a safe and positive community experience for all, we require all participants to adhere to the [Code of Conduct](CODE_OF_CONDUCT.md).
This document is a guide to help you through the process of contributing to Grafana. Be sure to check out the [Grafana Champions program](https://grafana.com/community/champions/?src=github&camp=community-cross-platform-engagement) as you start to contribute. It’s designed to recognize and empower individuals who are actively contributing to the growth and success of the Grafana ecosystem.
This document is a guide to help you through the process of contributing to Grafana. Be sure to check out the [Grafana Champions program](https://grafana.com/community/champions/?src=github&camp=community-cross-platform-engagement) as you start to contribute. It's designed to recognize and empower individuals who are actively contributing to the growth and success of the Grafana ecosystem.
> **Help us improve!** We'd love to hear about your contributor experience. Take a moment to share your feedback in our [Open Source Contributor Experience Survey](https://gra.fan/ome). Your input helps us make contributing to Grafana better for everyone.
Whether you're a new contributor or a seasoned veteran, we hope these resources help you connect with the community.
@@ -108,7 +110,7 @@ If you believe you've found a security vulnerability, please read our [security
### Suggest features
If you have an idea of how to improve Grafana, submit a [feature request](https://github.com/grafana/grafana/issues/new?template=1-feature_requests.md).
If you have an idea of how to improve Grafana, submit a [feature request](https://github.com/grafana/grafana/issues/new?template=1-feature_requests.md). To learn how to write an effective feature request, refer to [Create a feature request](contribute/create-feature-request.md).
We want to make Grafana accessible to even more people. Submit an [accessibility issue](https://github.com/grafana/grafana/issues/new?template=2-accessibility.md) to help us understand what we can improve.
Grafana allows you to query, visualize, alert on and understand your metrics no matter where they are stored. Create, explore, and share dashboards with your team and foster a data-driven culture:
@@ -36,6 +35,8 @@ If you're interested in contributing to the Grafana project:
rawSchemaCheckv0alpha1=[]byte(`{"spec":{"properties":{"data":{"additionalProperties":{"type":"string"},"description":"Generic data input that a check can receive","type":"object"}},"type":"object"},"status":{"properties":{"additionalFields":{"description":"additionalFields is reserved for future use","type":"object","x-kubernetes-preserve-unknown-fields":true},"operatorStates":{"additionalProperties":{"properties":{"descriptiveState":{"description":"descriptiveState is an optional more descriptive state field which has no requirements on format","type":"string"},"details":{"description":"details contains any extra information that is operator-specific","type":"object","x-kubernetes-preserve-unknown-fields":true},"lastEvaluation":{"description":"lastEvaluation is the ResourceVersion last evaluated","type":"string"},"state":{"description":"state describes the state of the lastEvaluation.\nIt is limited to three possible states for machine evaluation.","enum":["success","in_progress","failed"],"type":"string"}},"required":["lastEvaluation","state"],"type":"object"},"description":"operatorStates is a map of operator ID to operator state evaluations.\nAny operator which consumes this kind SHOULD add its state evaluation information to this field.","type":"object"},"report":{"properties":{"count":{"description":"Number of elements analyzed","type":"integer"},"failures":{"description":"List of failures","items":{"properties":{"item":{"description":"Human readable identifier of the item that failed","type":"string"},"itemID":{"description":"ID of the item that failed","type":"string"},"links":{"description":"Links to actions that can be taken to resolve the failure","items":{"properties":{"message":{"description":"Human readable error message","type":"string"},"url":{"description":"URL to a page with more information about the error","type":"string"}},"required":["url","message"],"type":"object"},"type":"array"},"moreInfo":{"description":"More information about the failure, not meant to be displayed to the user. Used for LLM suggestions.","type":"string"},"severity":{"description":"Severity of the failure","enum":["high","low"],"type":"string"},"stepID":{"description":"Step ID that the failure is associated with","type":"string"}},"required":["severity","stepID","item","itemID","links"],"type":"object"},"type":"array"}},"required":["count","failures"],"type":"object"}},"required":["report"],"type":"object"}}`)
rawSchemaCheckv0alpha1=[]byte(`{"Check":{"properties":{"spec":{"$ref":"#/components/schemas/spec"},"status":{"$ref":"#/components/schemas/status"}},"required":["spec"]},"ErrorLink":{"additionalProperties":false,"properties":{"message":{"description":"Human readable error message","type":"string"},"url":{"description":"URL to a page with more information about the error","type":"string"}},"required":["url","message"],"type":"object"},"OperatorState":{"additionalProperties":false,"properties":{"descriptiveState":{"description":"descriptiveState is an optional more descriptive state field which has no requirements on format","type":"string"},"details":{"additionalProperties":{"additionalProperties":{},"type":"object"},"description":"details contains any extra information that is operator-specific","type":"object"},"lastEvaluation":{"description":"lastEvaluation is the ResourceVersion last evaluated","type":"string"},"state":{"description":"state describes the state of the lastEvaluation.\nIt is limited to three possible states for machine evaluation.","enum":["success","in_progress","failed"],"type":"string"}},"required":["lastEvaluation","state"],"type":"object"},"Report":{"additionalProperties":false,"properties":{"count":{"description":"Number of elements analyzed","type":"integer"},"failures":{"description":"List of failures","items":{"$ref":"#/components/schemas/ReportFailure"},"type":"array"}},"required":["count","failures"],"type":"object"},"ReportFailure":{"additionalProperties":false,"properties":{"item":{"description":"Human readable identifier of the item that failed","type":"string"},"itemID":{"description":"ID of the item that failed","type":"string"},"links":{"description":"Links to actions that can be taken to resolve the failure","items":{"$ref":"#/components/schemas/ErrorLink"},"type":"array"},"moreInfo":{"description":"More information about the failure, not meant to be displayed to the user. Used for LLM suggestions.","type":"string"},"severity":{"description":"Severity of the failure","enum":["high","low"],"type":"string"},"stepID":{"description":"Step ID that the failure is associated with","type":"string"}},"required":["severity","stepID","item","itemID","links"],"type":"object"},"spec":{"additionalProperties":false,"properties":{"data":{"additionalProperties":{"type":"string"},"description":"Generic data input that a check can receive","type":"object"}},"type":"object"},"status":{"additionalProperties":false,"properties":{"additionalFields":{"additionalProperties":{"additionalProperties":{},"type":"object"},"description":"additionalFields is reserved for future use","type":"object"},"operatorStates":{"additionalProperties":{"$ref":"#/components/schemas/OperatorState"},"description":"operatorStates is a map of operator ID to operator state evaluations.\nAny operator which consumes this kind SHOULD add its state evaluation information to this field.","type":"object"},"report":{"$ref":"#/components/schemas/Report"}},"required":["report"],"type":"object"}}`)
rawSchemaCheckTypev0alpha1=[]byte(`{"spec":{"properties":{"name":{"type":"string"},"steps":{"items":{"properties":{"description":{"type":"string"},"resolution":{"type":"string"},"stepID":{"type":"string"},"title":{"type":"string"}},"required":["title","description","stepID","resolution"],"type":"object"},"type":"array"}},"required":["name","steps"],"type":"object"},"status":{"properties":{"additionalFields":{"description":"additionalFields is reserved for future use","type":"object","x-kubernetes-preserve-unknown-fields":true},"operatorStates":{"additionalProperties":{"properties":{"descriptiveState":{"description":"descriptiveState is an optional more descriptive state field which has no requirements on format","type":"string"},"details":{"description":"details contains any extra information that is operator-specific","type":"object","x-kubernetes-preserve-unknown-fields":true},"lastEvaluation":{"description":"lastEvaluation is the ResourceVersion last evaluated","type":"string"},"state":{"description":"state describes the state of the lastEvaluation.\nIt is limited to three possible states for machine evaluation.","enum":["success","in_progress","failed"],"type":"string"}},"required":["lastEvaluation","state"],"type":"object"},"description":"operatorStates is a map of operator ID to operator state evaluations.\nAny operator which consumes this kind SHOULD add its state evaluation information to this field.","type":"object"}},"type":"object"}}`)
rawSchemaCheckTypev0alpha1=[]byte(`{"CheckType":{"properties":{"spec":{"$ref":"#/components/schemas/spec"},"status":{"$ref":"#/components/schemas/status"}},"required":["spec"]},"OperatorState":{"additionalProperties":false,"properties":{"descriptiveState":{"description":"descriptiveState is an optional more descriptive state field which has no requirements on format","type":"string"},"details":{"additionalProperties":{"additionalProperties":{},"type":"object"},"description":"details contains any extra information that is operator-specific","type":"object"},"lastEvaluation":{"description":"lastEvaluation is the ResourceVersion last evaluated","type":"string"},"state":{"description":"state describes the state of the lastEvaluation.\nIt is limited to three possible states for machine evaluation.","enum":["success","in_progress","failed"],"type":"string"}},"required":["lastEvaluation","state"],"type":"object"},"Step":{"additionalProperties":false,"properties":{"description":{"type":"string"},"resolution":{"type":"string"},"stepID":{"type":"string"},"title":{"type":"string"}},"required":["title","description","stepID","resolution"],"type":"object"},"spec":{"additionalProperties":false,"properties":{"name":{"type":"string"},"steps":{"items":{"$ref":"#/components/schemas/Step"},"type":"array"}},"required":["name","steps"],"type":"object"},"status":{"additionalProperties":false,"properties":{"additionalFields":{"additionalProperties":{"additionalProperties":{},"type":"object"},"description":"additionalFields is reserved for future use","type":"object"},"operatorStates":{"additionalProperties":{"$ref":"#/components/schemas/OperatorState"},"description":"operatorStates is a map of operator ID to operator state evaluations.\nAny operator which consumes this kind SHOULD add its state evaluation information to this field.","type":"object"}},"type":"object"}}`)
@@ -57,6 +61,62 @@ var appManifestData = app.ManifestData{
Schema:&versionSchemaCheckTypev0alpha1,
},
},
Routes:app.ManifestVersionRoutes{
Namespaced:map[string]spec3.PathProps{
"/register":{
Post:&spec3.Operation{
OperationProps:spec3.OperationProps{
OperationId:"createRegister",
Responses:&spec3.Responses{
ResponsesProps:spec3.ResponsesProps{
Default:&spec3.Response{
ResponseProps:spec3.ResponseProps{
Description:"Default OK response",
Content:map[string]*spec3.MediaType{
"application/json":{
MediaTypeProps:spec3.MediaTypeProps{
Schema:&spec.Schema{
SchemaProps:spec.SchemaProps{
Type:[]string{"object"},
Properties:map[string]spec.Schema{
"apiVersion":{
SchemaProps:spec.SchemaProps{
Type:[]string{"string"},
Description:"APIVersion defines the versioned schema of this representation of an object. Servers should convert recognized schemas to the latest internal value, and may reject unrecognized values. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#resources",
},
},
"kind":{
SchemaProps:spec.SchemaProps{
Type:[]string{"string"},
Description:"Kind is a string value representing the REST resource this object represents. Servers may infer this from the endpoint the client submits requests to. Cannot be updated. In CamelCase. More info: https://git.k8s.io/community/contributors/devel/sig-architecture/api-conventions.md#types-kinds",
// ManifestCustomRouteResponsesAssociator returns the associated response go type for a given kind, version, custom route path, and method, if one exists.
// kind may be empty for custom routes which are not kind subroutes. Leading slashes are removed from subroute paths.
// If there is no association for the provided kind, version, custom route path, and method, exists will return false.
// Resource routes (those without a kind) should prefix their route with "<namespace>/" if the route is namespaced (otherwise the route is assumed to be cluster-scope)
rawSchemaDummyv0alpha1=[]byte(`{"Dummy":{"properties":{"spec":{"$ref":"#/components/schemas/spec"},"status":{"$ref":"#/components/schemas/status"}},"required":["spec"]},"OperatorState":{"additionalProperties":false,"properties":{"descriptiveState":{"description":"descriptiveState is an optional more descriptive state field which has no requirements on format","type":"string"},"details":{"additionalProperties":{"additionalProperties":{},"type":"object"},"description":"details contains any extra information that is operator-specific","type":"object"},"lastEvaluation":{"description":"lastEvaluation is the ResourceVersion last evaluated","type":"string"},"state":{"description":"state describes the state of the lastEvaluation.\nIt is limited to three possible states for machine evaluation.","enum":["success","in_progress","failed"],"type":"string"}},"required":["lastEvaluation","state"],"type":"object"},"spec":{"additionalProperties":false,"description":"Spec is the schema of our resource. The spec should include all the user-editable information for the kind.","properties":{"dummyField":{"type":"integer"}},"required":["dummyField"],"type":"object"},"status":{"additionalProperties":false,"properties":{"additionalFields":{"additionalProperties":{"additionalProperties":{},"type":"object"},"description":"additionalFields is reserved for future use","type":"object"},"operatorStates":{"additionalProperties":{"$ref":"#/components/schemas/OperatorState"},"description":"operatorStates is a map of operator ID to operator state evaluations.\nAny operator which consumes this kind SHOULD add its state evaluation information to this field.","type":"object"}},"type":"object"}}`)
// ManifestCustomRouteResponsesAssociator returns the associated response go type for a given kind, version, custom route path, and method, if one exists.
// kind may be empty for custom routes which are not kind subroutes. Leading slashes are removed from subroute paths.
// If there is no association for the provided kind, version, custom route path, and method, exists will return false.
// Resource routes (those without a kind) should prefix their route with "<namespace>/" if the route is namespaced (otherwise the route is assumed to be cluster-scope)
returnEntry{},fmt.Errorf("failed to unmarshal entry [%s]: %w",s.T,err)
}
iflokiEntry.SchemaVersion!=1{
returnEntry{},fmt.Errorf("unsupported schema version [%s]: %d",s.T,lokiEntry.SchemaVersion)
}
outcome:=OutcomeSuccess
varentryError*string
iflokiEntry.Error!=""{
outcome=OutcomeError
entryError=&lokiEntry.Error
}
groupLabels:=lokiEntry.GroupLabels
ifgroupLabels==nil{
groupLabels=make(map[string]string)
}
alerts:=make([]EntryAlert,len(lokiEntry.Alerts))
fori,a:=rangelokiEntry.Alerts{
alerts[i]=EntryAlert{
Status:a.Status,
Labels:a.Labels,
Annotations:a.Annotations,
StartsAt:a.StartsAt,
EndsAt:a.EndsAt,
}
}
returnEntry{
Timestamp:s.T,
Receiver:lokiEntry.Receiver,
Status:Status(lokiEntry.Status),
Outcome:outcome,
GroupKey:lokiEntry.GroupKey,
GroupLabels:groupLabels,
Alerts:alerts,
Retry:lokiEntry.Retry,
Error:entryError,
Duration:lokiEntry.Duration,
PipelineTime:lokiEntry.PipelineTime,
},nil
}
Some files were not shown because too many files have changed in this diff
Show More
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.