* processing: display nanoseconds if present
* Nanoseconds: add control in log line menu
* virtualization: adapt to timestamp format
* Translations
* LogLine: update test
* virtualization: update test
* LogLineMenu: update test
* LogListControls: add third state for new logs panel timestamps
* Logs Panel: expose as a new panel option
* Translations
* Logs Panel: set timestamp resolution from panel config
* Module: add default value
* LogLine: update test
* Spelling
* chore: rename setter
* LogListControls: use custom button for resolution
* Translations
* Translations
* Prettier
* Logs Panel: conditionally show timestamp and details options
* Add integration test
* Table: Frozen columns
* i18n extract
* clamp the frozen columns by the total number of cols visible
* future-proof a bit: frozenColumns.left, add to kitchenSink
* Chore: Apply proper database settings to integration tests
* add logging
* join host and port in database config to override default ports
* apply test fixes from the original pr
* host might contain port already
* increase timeout
* increase timeout even more
* even larger timeouts
* Use eventually for stats
* Use eventually also for listing settings as index takes some time
---------
Co-authored-by: Roberto Jimenez Sanchez <roberto.jimenez@grafana.com>
* More clean up around waiting for jobs
* Add comment to trigger enterprise integration tests
* Trigger integration tests
* Collect error
* Move tests in wrong spot
* Clean up test
* Remove Eventually
* Remove duplicate not nil check
* Delete comment in infra tests
* Helper to create repository
* Use helper for move
* Dashboard Migrations: V31 LabelsToFields-Merge Migration
* Dashboard Migrations: V32 No-op migration
* simplify
* Refactor to reduce nesting
* Dashboard Migrations: V30 value mappings and tooltip options
* Do not automigrate since graph is migrated in v27
* Refactor to reduce nesting
* Add test case for invalid mapping
* migrate to v29
* wip
* Fix tests
* fix output
* wip
* fix min version issue
* fix wire
* ignore gauge logic as it never get's executed
* add panel migration to test
* improvements
* update
* cleanup
* address mappings inconsistencies
* cleanup
* fix lint issues
* add cfg when initializing
* v27 migration
* migrate to v26
* preallocate array
* remove logic for grafana-singlestat because it's shared with stat logic; improve error handling and testing
* fix go lint
* don't preallocate; cleanup comments
* cleanup
* wip
* run internal provider function when getting a single panel
* clean up; add tests
* add tests for panel plugin service
* remove obsolete mock for getting panel plugin
* add tests for the whole pipeline
* fix test and lint
* migrate to v23
* migrate to v22
* refactor
* fix test
---------
Co-authored-by: Ivan Ortega <ivanortegaalba@gmail.com>
* TableNG: Markdown cell, plus custom row height
* tab indentation in cue file
* fix i18n
* trying an auto height with the updated RDG
* get auto cellHeight working
* i18n updates
* hoor disable_sanitize_html flag in MarkdownCell
* update react-data-grid version to attempt to support page up and down
* removing custom height
* use the latest experimental RDG with paging up and down
* TableNG: Wrap text for DataLinks and Pills; groundwork for max wrap length
* disable editing max wrapped lines for now
* disable wrap text line limit e2e
* new i18n extract after commenting out input
* wip
* kill max wrapped lines for now
* more cleanup
* remove targeting classes added for max wrapped lines
* fix Pill test
* couple more style cleanups
* Table: Move cell-specific styles out to their own methods
* move styles into their own file
* combine renderer and style declarations to make auto cells work better, complete cleanup of internal cell elements
* fix e2es given these updates
* add a couple tests
* wip: tests
* add tests
* bump up capital letters in lorem ipsum
* fix copy-pasta mistake
* whoops, mis-merged the selector
* use a local count instead of getCellLinks
* use react-data-grid on react-18 branch
* fix linting on test
* gdev dashboard and smoketest for Markdown table
* remove cellHeightCustom
* restore bugfix from adversarial AI-generated JSON
* reorganize in light of recent and upcoming changes
* cleanup
* override the whitespace for markdown
* what are these auto imports about...
* fix cell height selector from merge
* also remove cellHeightCustom
* i18n
* avoid the important override in markdown cell styles
* revert some betterer config autoformatting
* slight code cleanup
* s/cat/grot, add color link panel to kitchen sink, fix color link/image link style issues
* update panelid for empty table panel test
* link styles outside of cell style setup
* flesh out kitchen sink examples, update ImageCell and applyToRow
* clean up some inconsistent states
* fix lint issue
* gdev update
* format JSON to satisfy linter
* shortening the text in the long text field
---------
Co-authored-by: Leon Sorokin <leeoniya@gmail.com>
* Unistore/dualwriter: delegate SetDefaultPermissions to Unified on Mode3
Signed-off-by: Maicon Costa <maiconscosta@gmail.com>
---------
Signed-off-by: Maicon Costa <maiconscosta@gmail.com>
* Dashboard Migrations: V31 LabelsToFields-Merge Migration
* Dashboard Migrations: V32 No-op migration
* simplify
* Refactor to reduce nesting
* Dashboard Migrations: V30 value mappings and tooltip options
* Do not automigrate since graph is migrated in v27
* Refactor to reduce nesting
* Add test case for invalid mapping
* migrate to v29
* wip
* Fix tests
* fix output
* wip
* fix min version issue
* fix wire
* ignore gauge logic as it never get's executed
* add panel migration to test
* improvements
* update
* cleanup
* address mappings inconsistencies
* cleanup
* fix lint issues
* add cfg when initializing
* v27 migration
* migrate to v26
* preallocate array
* remove logic for grafana-singlestat because it's shared with stat logic; improve error handling and testing
* fix go lint
* don't preallocate; cleanup comments
* cleanup
* wip
* run internal provider function when getting a single panel
* clean up; add tests
* add tests for panel plugin service
* remove obsolete mock for getting panel plugin
* add tests for the whole pipeline
* fix test and lint
* fix test
* Fix missing scenarios
---------
Co-authored-by: Ivan Ortega <ivanortegaalba@gmail.com>
* add the plan
* feat: Add plugin extension points for DataSource configuration components
- Add DataSourceConfigActions and DataSourceConfigStatus extension points
- Add PluginExtensionDataSourceConfigActionsContext and PluginExtensionDataSourceConfigStatusContext types
- Update EditDataSourceActions.tsx with plugin extension support and allowlist filtering
- Update DataSourceTestingStatus.tsx with dual extension point support (new + backward compatible)
- Create getDataSourceExtensionConfigs.tsx with example core extensions
- Update getCoreExtensionConfigurations.ts to include datasource extensions
- Implement grafana-owned plugin allowlist for security and quality control
- Support context-aware extensions based on datasource type and testing status
- Maintain backward compatibility with existing DataSourceConfigErrorStatus extension point
- Add proper TypeScript types and export them in index.ts
This enables grafana-owned plugins to provide contextual actions and status-specific integrations
within the datasource configuration workflow while maintaining security through plugin filtering.
* docs: Update specs.md with implementation status and lessons learned
- Add comprehensive implementation status section with completed features
- Document critical lessons learned during implementation:
* Translation limitations in extension configurations
* Plugin security through allowlist filtering
* Extension registration timing constraints
* TypeScript context type patterns
- Update implementation checklist with actual completion status
- Add detailed next steps and recommendations
- Include plugin development guidelines (do's and don'ts)
- Document architectural insights and patterns discovered
- Transform specs from theoretical design to practical implementation guide
This update serves as both historical record and developer guide for future
plugin extension work in Grafana.
* Add comprehensive tests for DataSource plugin extensions
- Add EditDataSourceActions.test.tsx with 12 tests covering:
* Core Grafana actions functionality and permissions
* Plugin extension rendering and interaction
* Plugin allowlist filtering and security
* Context passing and URL generation
- Add getDataSourceExtensionConfigs.test.tsx with 14 tests covering:
* Core extension configurations for both extension points
* Context filtering logic (datasource type, severity)
* Error handling and graceful failures
* Extension structure validation and type safety
Total: 26 tests passing, providing comprehensive coverage of the
DataSourceConfigActions and DataSourceConfigStatus extension points
implemented in previous commits.
* Update specs.md to reflect completed test implementation
- Mark unit testing phase as complete (26 tests added)
- Add comprehensive Test Implementation section documenting:
* Test file details and coverage areas
* Testing challenges and solutions discovered
* Performance metrics and execution strategy
* Command examples for running tests
- Update Success Metrics with concrete testing validation
- Update Next Steps to reflect testing completion
- Document new test files in Files Modified section
The plugin extensions implementation now has complete unit test
coverage for both DataSourceConfigActions and DataSourceConfigStatus
extension points with 26 passing tests.
* rm specs file
* lint
* refactor: replace 'any' types with proper TypeScript types in datasource extension tests
* tsc
* prettier: fix
* Fix datasource extension path format to resolve CI test failure
The troubleshooting link extension was using an invalid path format
'/docs/troubleshooting/datasources' which caused console.error during
test execution. Updated to proper Grafana core extension path format
'/a/grafana/docs/troubleshooting/datasources' to comply with plugin
extension validation rules.
* fix: DataSourceTestingStatus test failures
- Fix incorrect data-testid expectations to use proper e2e selectors
- Add contextSrv mock for hasAccessToExplore() dependency
- Create proper plugin links mock handling different extension points
- Update plugin link tests to use allowed plugin IDs
- Fix test logic to match actual component behavior for status/error links
- Add test coverage for non-allowed plugin filtering
All 10 tests now pass successfully.
* lint fix
* refactor: replace any types with proper TypeScript types in DataSourceTestingStatus test
- Replace any[] with PluginExtensionLink[] for statusLinks and errorLinks parameters
- Replace any with UsePluginLinksOptions for setPluginLinksHook callback parameter
- Add proper imports for PluginExtensionLink and UsePluginLinksOptions
- Improve type safety and IntelliSense support in tests
* rm brittle tests
* DataSource: Replace individual buttons with dropdown menu in EditDataSourceActions
- Convert LinkButton components to dropdown with Menu.Item components
- Add conditional rendering: show simple button when only one action, dropdown when multiple
- Use LinkButton for navigation and Button with dropdown icon for menu trigger
- Replace Trans components with t() function calls for Menu.Item labels
- Prevent PageHeader crowding when multiple plugin extensions are registered
- Maintain all existing functionality and tracking calls
* refactor: use configure() for dynamic datasource extension URLs
- Replace onClick handler with configure() function for dynamic path generation
- Use context to build monitoring tool URL with datasource UID
- Follows extension system design patterns for declarative configuration
- Removes manual window.open() in favor of automatic path handling
* refactor: use DataSourceConfigErrorStatus extension point for troubleshooting guide
Use the specific DataSourceConfigErrorStatus extension point instead of
DataSourceConfigStatus with conditional logic in configure function.
This simplifies the code by leveraging the right abstraction level.
* extract i18n
* lint:fix
* Revert "lint:fix"
This reverts commit 23cdb39672.
* lint:fix
* fix: mock plugin extensions registry in variables utils test
Fixes console.error calls during test execution caused by plugin extension
registration failures. The test was failing on CI because the extensions
registry was trying to register link extensions with invalid configurations
during module import.
Solution: Mock the entire plugin extensions registry setup to prevent
side effects from interfering with the test execution.
* fix: mock plugin extensions registry in explore query test
Fixes console.error calls during test execution caused by plugin extension
registration failures. The test was failing on CI because the extensions
registry was trying to register link extensions with invalid configurations
during module import.
This applies the same fix as the variables utils test - mocking the entire
plugin extensions registry setup to prevent side effects from interfering
with the test execution.
* better fix
* Fix EditDataSourceActions test by mocking utils and handling dropdown UI
- Add missing mock for constructDataSourceExploreUrl from ../utils
- Update tests to interact with dropdown menu structure instead of expecting direct text
- Fix test logic to match component behavior: Actions dropdown when user has explore rights
* lint:fix
* refactor: extract duplicated allowedPluginIds to single source of truth
- Add ALLOWED_DATASOURCE_EXTENSION_PLUGINS constant to constants.ts
- Remove duplicate allowedPluginIds arrays from DataSourceTestingStatus and EditDataSourceActions
- Update both components to import and use the shared constant
- Improves maintainability and ensures consistency across datasource config components
* refactor: update datasource extension link configurations
- Change title and description for the metrics drilldown link to improve clarity
- Update the path for the metrics drilldown link to reflect the new routing structure
- Remove the troubleshooting guide link configuration to streamline the extension options
* removing unused config
* better dropdown
* fix: update EditDataSourceActions tests to match component implementation
- Fixed tests to expect core actions as separate buttons instead of dropdown
- Updated plugin extension tests to use 'Extensions' dropdown instead of 'Actions'
- Added test for Extensions dropdown visibility logic
- All 12 tests now passing
* lint:fix
* remove extra check
* Update ALLOWED_DATASOURCE_EXTENSION_PLUGINS documentation to clarify plugin contributions to datasource configuration pages
* feat: Convert Explore data button to dropdown when extensions are available
- When hasActions is empty: shows normal Explore data and Build dashboard buttons
- When hasActions is not empty: converts Explore data to dropdown with angle-down icon
- First dropdown item: 'Open in Explore View'
- Following items: extension links
- Build dashboard button remains unchanged
- Maintains existing tracking functionality and internationalization
* test: Update EditDataSourceActions tests for new dropdown implementation
- Update tests to work with new Explore data dropdown that includes extensions
- Replace references to 'Extensions' button with 'Explore data' dropdown
- Add test for 'Open in Explore View' menu item in dropdown
- Verify correct behavior when extensions are present vs absent
- All 13 tests now passing
* test: Add comprehensive test coverage for dropdown explore functionality
- Add test to verify explore action href when extensions are present
- Ensure both dropdown and direct link behaviors are tested
- Complete test coverage for new dropdown implementation
* translation
* compass icon for the explore item
* feat: refactor AlertSuccessMessage to accept extension links as props
- Move extension links from inline definition to props for better reusability
- Add proper TypeScript support for PluginExtensionLink types
- Improve component architecture by separating concerns
- Add extensionLinks styling to getStyles function for consistency
- Support both real extension links and custom link rendering in success messages
This improves the component's flexibility while maintaining type safety.
* lint:fix