* Extend User type
* Render licensed roles and org units
* Combine admin icon with units
* Extract search users to a new service
* Fix wire provider
* remove mock data
* Fix icon margin
* Fix common_test and remove RouteRegister
* Remove old endpoints
* Fix test
* Add indexes to dashboards and orgs tables
* Fix lint
* Revert docs changes
* undo docs formatting
* Change order of input and filters
* Abstract aria-label into a function
* Add accessible info about user's membership
* UI tweaks
Co-authored-by: spinillos <selenepinillos@gmail.com>
* Fix(A11y): add label to explore short url button
* Grafana-UI(A11y): Set Selects images alt attribute to their option label
* Update packages/grafana-ui/src/components/Select/SingleValue.tsx
Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
* Prometheus: Run Explore both queries trough backend
* Refactor, simplify
* Set default values for query type selector
* Run multiple queries as one query trough backend
* Remove trailing newlines
* Pass utcOffset
* Remove trailing comma
* Add meta to frames only at 1 place
* Set exemplars to falsee if they are disabled
* Revert "Set exemplars to falsee if they are disabled"
This reverts commit e7b697c9f3.
* working version but with duplications.
* refactor(Plugins/Admin): use "fr" instead of "repeat" for grid columns
Co-authored-by: Jack Westbrook <jack.westbrook@gmail.com>
* fix(Plugins/Admin): use PluginIconName instead of IconName
* refactor(Plugins/Admin): store the display-mode on the state
* refactor(Plugins/Admin): use && for conditional rendering
* refactor(Plugins/Admin): rename variable
* refactor(Plugins/Admin): share code between card and row components
* test(PluginListItemRow): add tests
* test(Plugins/Admin): add a simple test for the display-mode switching
* fix(Plugins/Admin): compose styles with css``
* refactor(Plugins/Admin): rename "table" to "grid" for display modes
* test(Plugins/Browse): follow up on renaming "table" to "grid"
Co-authored-by: Levente Balogh <balogh.levente.hu@gmail.com>
Co-authored-by: Jack Westbrook <jack.westbrook@gmail.com>
* Expose FilterInput from grafana/ui
* Make table filter case insensitive
* Update packages/grafana-ui/src/components/Table/FilterList.tsx
Co-authored-by: Hugo Häggmark <hugo.haggmark@grafana.com>
Co-authored-by: Oscar Kilhed <oscar.kilhed@grafana.com>
Co-authored-by: Hugo Häggmark <hugo.haggmark@grafana.com>
* adding working version of notificaion banner trigger.
* Move it to enterprise
* Fixing csss, none of the pages showed our CustomScrollbar or had double scrollbars
* fixing explore
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
* added possibility to track if remote plugins could be fetched.
* adding hook to detect if remote plugins are available.
* feat(catalog): disable installed/all filter if remote plugins are unavailable
* feat(Plugins/Admin): hide the install controls if GCOM is not available
* refactor(Plugins/Admin): group `@grafana` dependencies
* fix(Plugins/Admin): don't show an error alert if a remote plugin is not available
* feat(Plugins/Admin): prefer to use the local version of the readme
* chore(Plugins/Admin): type the mocked state properly
* test(Plugins/Admin): add tests for the Plugin Details when GCOM is not available
* test(Plugins/Admin): add tests for the Browse when GCOM is not available
Co-authored-by: Marcus Andersson <marcus.andersson@grafana.com>
Co-authored-by: Levente Balogh <balogh.levente.hu@gmail.com>
* feat(catalog): introduce id and href to PluginDetailsTabs
* feat(catalog): add hrefs and ids to PluginDetails tabs. Pass queryParams to PluginDetailsBody
* feat(catalog): pass queryParams to PluginsDetailsBody and add page param to PluginListCard
* fix(catalog): prevent flicker of content by waiting for fetch details to finish loading
* feat(catalog): add tab icons to PluginDetails page
* feat(catalog): make breadcrumbs in PluginDetailsHeader aware of page queryparam
* fix(catalog): fix deeplinking to PluginDetails by comparing tabs length
* test(catalog): update tests with correct props and wrap in router
* influxdb: flux: handle $__interval and $__interval_ms in alert-queries
* influxdb: flux: do not handle interval-variable in the frontend
* $__interval should be rounded
* added comment
* PlaylistPage: removes search due to no wildcard support
* PlaylistPage: adds back search input and wildcard search support
* makes banner to appear only when playlist does not exist
* Chore: small refactor
* Chore: some code refactoring to make it readable
* fixes focus leaving input when query is cleared
* adds styling to the emptyQueryList banner
* extracts emptyQueryListBanner component to a separate file
* adds debounce to search
* use new theme for styling
* Chore: some nit fix
* fixes empty list banner showing for a second before the full list is loaded
* Fix: removes search when playlist is empty
Co-authored-by: Ash <ashharrison90@gmail.com>
Co-authored-by: Hugo Häggmark <hugo.haggmark@gmail.com>
* Explore: prevent eplore from hiding errors containing refId
* Update public/app/features/explore/ResponseErrorContainer.tsx
Co-authored-by: Gábor Farkas <gabor.farkas@gmail.com>
Co-authored-by: Gábor Farkas <gabor.farkas@gmail.com>
* Disable external user's change role in admin
* Missing part of the tooltip text
* Disable change button with the tooltip instead dropdown
* Missing refactor
* Apply suggestion
* refactor(Plugins/Admin): add an extra line-break between tests
* test(Plugins/Admin): add a couple of more tests for Plugin Details
* fix(Plugins/Admin): fix accidental linting issue
* Add filtering for Silences page
* Add tests Silences and SilenceEditor
* pr feedback: add field validation and test refactor
* Add test for checking content
* fix overflow for validation error message
* increase login threshold for pa11y
* Make silence filter state its own type and function
* test(Plugins/Admin): add tests for the helper functions
* chore(Plugins/Admin): add `error` field to the CatalogPlugin mock
* test(Plugins/Admin): add new properties `error` & `isDisabled` to test expectations
* refactor(Plugins/Admin): make the `errors` param optional everywhere
* fix(Plugins/Admin): fix a rebase bug
* add create and add buttons that will be linked to enterprise
* wip
* wip
* clean up
* Co-authored-by: Travis Patterson <masslessparticle@gmail.com>
Added Query Modal that can be accessed from enterprise.
* reset docs
* reset docs
* docs changing
* docs
* docs
* unexporting props
* added generic ways to add more query actions and create actions
* cleanup
* adding internal tag
* adding onAddQuery to props so actions can add queries
* created a single query action component
* adding partial to query
* casting dataquery
Co-authored-by: Travis Patterson <travis.patterson@grafana.com>
* Prometheus: Add running of instant queries trough backend
* Rename response, keep zero length frames
* Remove debug log
* Simplify and fix value text
* Update duplicated and redundant go test
* Update public/app/plugins/datasource/prometheus/datasource.ts
Co-authored-by: Giordano Ricci <me@giordanoricci.com>
* Refactor using model to create Promquery
* Fix the response length
Co-authored-by: Giordano Ricci <me@giordanoricci.com>
* added errors in plugin list.
* added error to details page.
* adding badge on details page.
* added some more tests.
* Renamed to disabled and will handle the scenario in the plugin catalog.
* Update public/app/features/plugins/admin/components/PluginDetailsDisabledError.tsx
Co-authored-by: Levente Balogh <balogh.levente.hu@gmail.com>
* fixing some nits
* added missing isDisabeld to the mock.
* adding tests to verify scenarios when plugin is disabled.
* fixed issue with formatting after file changed on GH.
Co-authored-by: Levente Balogh <balogh.levente.hu@gmail.com>
* Run Explore range queries trough backend
* Remove trailing comma
* Add timeRange step alignment to backend
* Remove creation of instant query on backend as it is not supported ATM
* Remove non-related frontend changes
* Pass offset to calculate aligned range trough prom query
* Update order in query error message
* tableRefIds shouldn't contain undefined refIds
* Remove cloning of dataframes when processing
* Don't mutate response
* Remove ordering of processed frames
* Remove df because not needed
* Chore: More TypeScript strict fixes
* Chore: Use filter instead of reduce to fix TypeScript error
* Chore: Retype AzureResultFormat as string
* Chore: Account for getBlocks() poor typings of reduce
* Chore: Need to explicitly check for undefined here since '' is falsey
* feat(Plugins/Admin): show a confirmation modal when uninstalling a plugin
* refactor(Plugins/Admin): use a helper function for showing/hiding the modal
* test(Plugins/Admin): test if the modal disappears after an uninstall
* POC/Thresholds: Allow thresholds modification directly from the time series panel
* Snapshot updates
* Optimize styles memoization
* change threshold from graph
* renames and logging
* using useeffect to update graph
* Fix react worning about setting state on unmounted component
* revert panelrenderer
* using onFieldConfig change
* use a useeffect
* simplied fieldConfig state
* Do not use plot context in ThresholdControlsPlugin
* Do not throw setState warnings when drag handle is dropped
* Update thresholds position on the graph when updating threshold drag handle
* fix issues with rerenders
* prevent thresholds on conditions with range
* only edit the first threshold
Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
* WIP
* Functional without custom wrapper component, needs highlight
* Remove latency from explore
* Sync eventbus
* Some cleanup & removal of unused code
* Avoid clearing queries when running all empty queries
* Run remaining queries when removing one
* Update snapshots
* fix failing tests
* type cleanup
* Refactor QueryRows
* update snapshot
* Remove highlighter expressions
* minor fixes in queryrows
* remove unwanted change
* fix failing e2e test
* Persist refId in explore url state
* make traces test slightly more robust
* add test for query duplication
* Refactor log query handling
* Add link to config page
* Change message about missing xray to alert
* Add xrayTraceLinks
* Fix typo in field name
* Fix tests and lint
* Move test
* Add test for trace id link
* lint
* refactor(Plugins/Admin): add a type for version coming back from the API
* refactor(Plugins/Admin): only add necessary version information to the state
* test(Plugins/Admin): add a mock for a CatalogPlugin
* test(Plugins/ADmin): add a mock for a LocalPlugin
* test(Plugins/Admin): add a test for a RemotePlugin
* test(Plugins/Admin): add helpers for mocking plugin states
* refactor(Plugins/Admin): mock the Redux state instead of the API responses
This makes it simpler to add new test cases and also makes
the tests easier to reason about.
* refactor(Plugins/Admin): mock the Redux state instead of the API responses
* Navigation: Implement active state for items in the Sidemenu
* Navigation: Improve logic for when link is active and extract isSearchActive into a util function
* Navigation: Implement custom rule for dashboards under /d/ and fix minor bugs
* Navigation: only show first matching active state + strip query params from link urls
* Move SplitOpenFn type to grafana-data
* Use panel renderer instead of Timeseries panel for graph in Explore
* rename splitopen props on panel context
* feat(catalog): add update info to PluginListCard
* refactor(catalog): use IconName enum and minor styling changes to PluginHeaderDependencies
* fix(catalog): add a semver range to grafanaVersion for dependency checks in InstallControls
* fix(@grafana/data): add a missing optional field to the plugin types
* refactor(Plugins/ADmin): use the type from @grafana/data for plugin dependencies
* fix(Datasources/Graphite): add missing `state` to useEffect dependencies
* refactor(Plugins/Admin): remove unnecessary comment
* feat(Plugins/Admin): add plugin and grafana dependencies to the CatalogPluginDetails
* feat(Plugins/ADmin): show Grafana dependency under plugin details
* feat(Plugins/Admin): show grafana and plugin dependencies for a plugin
* test(Plugins/Admin): add a smoke test for plugin dependencies
* refactor(Plugins/Admin): remove unused style from the header
* Normalize alert state name for UI descriptor retrieval
* Bring back alert state and metric values to annotation tooltip
* Make sure alert state is only shown when present
* Update test
* Handle Error alerting satte
* Revert "Prometheus: add functionality to specify desired step interval in dashboards panels (#36422)"
This reverts commit ddf5b65c51.
Co-authored-by: Ivana Huckova <ivana.huckova@gmail.com>
* Revert "Explore: add functionality for supporting different step modes in prometheus (#37829)"
This reverts commit f433cfd8d9.
Co-authored-by: Ivana Huckova <ivana.huckova@gmail.com>
* Revert stepMode BE implementation from #36796
Co-authored-by: "Ivana Huckova" <ivana.huckova@gmail.com>
* feat(Plugins/Catalog): start adding necessary apis
* feat(PLugins/Catalog): add extra helpers for merging local & remote plugins
* feat(Plugins/Catalog): add plugin details as an optional field of CatalogPlugin
* feat(PLugins/Catalog): add scaffolding for the new redux model
* feat(PLugins/Catalog): export reducers based on a feature-flag
* refactor(Plugins/Admin): rename api methods
* feat(Plugin/Catalog): add an api method for fetching a single plugin
* feat(Plugins/Admin): try cleaning stuff around plugin fetching
* ffeat(Plugins/Catalog): return the catalog reducer when the feature flag is set
* refactor(Plugins/Admin): fix typings
* feat(Plugins/Admin): use the new reducer for the browse page
* feat(catalog): introduce selectors to search and filter plugins list
* refactor(Plugins/Details): rename page prop type
* refactor(Plugins/Admin): add a const for a state prefix
* refactor(Plugins/Admin): use the state prefix in the actions
* feat(Plugins/Admin): add types for the requests
* refactor(Plugins/Admin): add request info to the reducer
* refactor(Plugins/Admin): add request handling to the hooks & selectors
* refactor(Plugins/Details): start using the data stored in Redux
* refactor(Plugins/Admin): rename selector to start with "select"
* fix(Plugins/Admin): only fetch plugins once
* refactor(Plugins/Admin): make the tab selection work in details
* refactor(catalog): put back loading and error states in plugin list
* refactor(Plugins/Admin): use CatalogPlugin for <PluginDetailsSignature />
* feat(Plugins/Admin): add an api method for fetching plugin details
* refactor(Plugins/Admin): add action for updating the details
* irefactor(Plugins/Admin): show basic plugin details info
* refactor(Plugin Details): migrate the plugin details header
* refactor(Plugins/Admin): make the config and dashboards tabs work
* refactor(Plugins/Admin): add old reducer state to the new one
* feat(catalog): introduce actions, reducers and hooks for install & uninstall
* refactor(catalog): wire up InstallControls component to redux
* refactor(catalog): move parentUrl inside PluginDetailsHeader and uncomment InstallControls
* feat(catalog): introduce code for plugin updates to install action
* refactor(Plugins/Admin): add backward compatible actions
* test(catalog): update PluginDetails and Browse tests to work with catalog store
* refactor(Plugins/Admin): make the dashboards and panels work again
* refactor(Plugins/Admin): fix linter and typescript errors
* fix(Plugins/Admin): put the local-only plugins to the beginning of the list
* fix(Plugins/Admin): fix the mocks in the tests for PluginDetails
* refactor(Plugins/Admin): remove unecessary hook usePluginsByFilter()
* refactor(Plugins/Admin): extract the useTabs() hook to its own file
* refactor(Plugins/Admin): remove unused helpers and types
* fix(Plugins/Admin): show the first tab when uninstalling an app plugin
This can cause the user to find themselves on a dissappeared tab, as the
config and dashboards tabs are removed.
* fix(catalog): correct logic for checking if activeTabIndex is greater than total tabs
* fix(Plugins/Admin): fix race-condition between fetching plugin details and all plugins
* fix(Plugins): fix strict type errors
* chore(catalog): remove todos
* feat(catalog): render an alert in PluginDetails when a plugin cannot be found
* feat(catalog): use the proper store state
* refactor(Plugins/Admin): fetch local and remote plugins in parallell
Co-authored-by: Marcus Andersson <marcus.andersson@grafana.com>
* style(catalog): fix prettier error in api
* fix(catalog): prevent throwing error if InstallControlsButton is unmounted during install
* refactor(Plugins/Admin): add a separate hook for filtering & sorting plugins
Co-authored-by: Jack Westbrook <jack.westbrook@gmail.com>
Co-authored-by: Marcus Andersson <marcus.andersson@grafana.com>
* Transform dataframe to jaeger format
* Transform dataframe to Zipkin format
* Add endpoint type and shared to Zipkin
* Transform dataframe to OTLP format
* Add data tab tests and note in inspector docs
* Remove comments and logs
* Resolve typescript strict errors
* Update docs/sources/explore/explore-inspector.md
Co-authored-by: achatterjee-grafana <70489351+achatterjee-grafana@users.noreply.github.com>
* Update docs
* Improve OTLP conversion to include service info and additional tags
Co-authored-by: achatterjee-grafana <70489351+achatterjee-grafana@users.noreply.github.com>
* Docs: Updated 'Whitelisted' to 'Accepted' to match what's shown in the frontend now.
* Apply suggestions from code review
Co-authored-by: Ursula Kallio <73951760+osg-grafana@users.noreply.github.com>
* Docs: Update frontend to match docs
* kick drone
Co-authored-by: Ursula Kallio <73951760+osg-grafana@users.noreply.github.com>
* convert SQLs to use sdk contracts
* make draft
* postgres
* intermedia
* get datasourceinfo filled at the beginning of the service
* move the interval into package because of cyclict import and fix all postgres tests
* fix mysql test
* fix mssql
* fix the test for pr https://github.com/grafana/grafana/issues/35839
* fix some issue about intervalv2 package
* update sql test
* wire migration for SQLs
* add sqls to the background process
* make it register instead of register and start
* revert formatting
* fix tests
* fix linter
* remove integration test
* Postgres test fix
Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com>
* Dashboard: Fix UID not preserved on import
* Import Dashboard: add e2e test to verify uid is preserved when importing dashboard
* E2e: Use dynamic uid
* Tests: fixes e2e test
* Chore: adds back waits
Co-authored-by: Hugo Häggmark <hugo.haggmark@gmail.com>
* Add UMLs
* Add rendered diagrams
* Move QueryCtrl to flux
* Remove redundant param in the reducer
* Use named imports for lodash and fix typing for GraphiteTagOperator
* Add missing async/await
* Extract providers to a separate file
* Clean up async await
* Rename controller functions back to main
* Simplify creating actions
* Re-order controller functions
* Separate helpers from actions
* Rename vars
* Simplify helpers
* Move controller methods to state reducers
* Remove docs (they are added in design doc)
* Move actions.ts to state folder
* Add docs
* Add old methods stubs for easier review
* Check how state dependencies will be mapped
* Rename state to store
* Rename state to store
* Rewrite spec tests for Graphite Query Controller
* Update docs
* Update docs
* Add GraphiteTextEditor
* Add play button
* Add AddGraphiteFunction
* Use Segment to simplify AddGraphiteFunction
* Memoize function defs
* Fix useCallback deps
* Update public/app/plugins/datasource/graphite/state/helpers.ts
Co-authored-by: Giordano Ricci <me@giordanoricci.com>
* Update public/app/plugins/datasource/graphite/state/helpers.ts
Co-authored-by: Giordano Ricci <me@giordanoricci.com>
* Update public/app/plugins/datasource/graphite/state/helpers.ts
Co-authored-by: Giordano Ricci <me@giordanoricci.com>
* Update public/app/plugins/datasource/graphite/state/providers.ts
Co-authored-by: Giordano Ricci <me@giordanoricci.com>
* Update public/app/plugins/datasource/graphite/state/providers.ts
Co-authored-by: Giordano Ricci <me@giordanoricci.com>
* Update public/app/plugins/datasource/graphite/state/providers.ts
Co-authored-by: Giordano Ricci <me@giordanoricci.com>
* Update public/app/plugins/datasource/graphite/state/providers.ts
Co-authored-by: Giordano Ricci <me@giordanoricci.com>
* Update public/app/plugins/datasource/graphite/state/providers.ts
Co-authored-by: Giordano Ricci <me@giordanoricci.com>
* Update public/app/plugins/datasource/graphite/state/providers.ts
Co-authored-by: Giordano Ricci <me@giordanoricci.com>
* Add more type definitions
* Remove submitOnClickAwayOption
This behavior is actually needed to remove parameters in functions
* Load function definitions before parsing the target on initial load
* Add button padding
* Fix loading function definitions
* Change targetChanged to updateQuery to avoid mutating state directly
It's also needed for extra refresh/runQuery execution as handleTargetChanged doesn't handle changing the raw query
* Fix updating query after adding a function
* Simplify updating function params
* Migrate function editor to react
* Simplify setting Segment Select min width
* Remove unnecessary changes to SegmentInput
* Extract view logic to a helper and update types definitions
* Clean up types
* Update FuncDef types and add tests
* Show red border for unknown functions
* Autofocus on new params
* Extract params mapping to a helper
* Split code between params and function editor
* Focus on the first param when a function is added even if it's an optional argument
* Add function editor tests
* Remove todo marker
* Fix adding new functions
* Allow empty value in selects for removing function params
* Add placeholders and fix styling
* Add more docs
* Create basic implementation for metrics and tags
* Post merge fixes
These files are not .ts
* Remove mapping to Angular dropdowns
* Simplify mapping tag names, values and operators
* Simplify mapping metrics
* Fix removing tags and autocomplete
* Simplify debouncing providers
* Ensure options are loaded twice and segment is opened
* Remove focusing new segments logic (not supported by React's segment)
* Clean up
* Move debouncing to components
* Simplify mapping to selectable options
* Add docs
* Group all components
* Remove unused controller methods
* Create Dispatch context
* Group Series and Tags Sections
* Create Functions section
* Create Section component
* use getStyles
* remove redundant async/await
* Remove
* remove redundant async/await
* Remove console.log and silent test console output
* Do not display the name of the selected dropdown option
* Move Section to grafana-ui
* Update storybook
* Simplify SectionLabel
* Fix Influx tests
* Fix API Extractor warnings
* Fix API Extractor warnings
* Do not show hidden functions
* Use block docs for better doc generation
* Handle undefined values provided for autocomplete
* Basic integration
* Move creating state to context.tsx
* Update tests
* Rename test
* Clean up dependencies
panel.targets is not needed for interpolation - it happens in the data source itself. It was used only to show query ref in the the dropdown for the segment.
* Update time range when it changes
* Change action name
* Simplify segments cloning
* Remove redundant variable
* Use styles instead of direct css
* Update docs
* Remove angular wrappers
* Remove redundant tests
* Section -> SegmentSection
* Simplify section styling
* Remove redundant div
* Fix unit tests
* Simplify SegmentSection component
* Use theme.spacing
* Use empty label instead of a single space label
* Remove targetFull
It was used in the past two store the query interpolated with sub-queries inside the model and send both to the backed (interpolated and not interpolated). This has been changed though - the logic has been moved away from model to the data source where interpolation happens and now only interpolated query is passed meaning targetFull is not needed anymore.
* Revert "Remove targetFull"
This reverts commit 499f8b33
* Bring back calculating targetFull
* Clean up
* Add missing dep
* Add missing dep in tests
* Fix time range synchronization
* Fix warning message
* Remove unused type
* Synchronize changes to the query
Co-authored-by: Giordano Ricci <me@giordanoricci.com>
* Sidemenu: Refactor TopSectionItem and BottomNavLinks into SideMenuItem
* Update failing snapshot
* BottomSection: Convert tests to RTL + add some extra unit tests
* Setup filter
* Enable filtering users by active in last 30 days
* Add loading state
* Update last active age strings
* Tweak user list
* Use theme spacing
* Improve table's accessibility
* Add more aria-labels
* AccessControl: add one-dimensional permissions to datasources in the backend
* AccessControl: add one-dimensional permissions to datasources in the frontend (#38080)
Co-authored-by: Hugo Häggmark <hugo.haggmark@grafana.com>
* WIP: add delete functionality to playlist
* fixes deleted item to be removed instantly without manual refresh
* update confirmModal to reference playlist name
* refactor confirmModal message to be clear enough
* WIP: some unit tests for the playlistPage
* added more tests and did some cleanup
* some code refactoring
* adds ability for user roles to control playlist delete
* some abstraction to cleanup code
* modified alert message for delete button to correspond with action
* tried a better approach to modify the alert message
* fixes playlist lookup on each render
* update handlers to not use anonymous function
* exposed getBackendSrv().get api to fetch all playlist
* used better naming convention
* removes unecessary async/await construct
* some code refactoring
* used the correct param structure
* LibraryPanels: Separates name from panel title
* WIP
* Chore: fixes update for duplicate lib panels
* Chore: reverts implementation
* Chore: show library options only for library panels
* Chore: ui fixes after PR comments
* Chore: fixes issue when creating library panels
* prometheus: add monaco-based query-field
for now it is behind a feature-flag
* added new trigger character
* better separate grafana-specifc and prom-specific code
* better styling
* more styling
* more styling
* simpler monaco-import
* better imports
* simplified code
* simplified type imports
* refactor: group completion-provider files together
* renamed type
* simplify type-import
Co-authored-by: Piotr Jamróz <pm.jamroz@gmail.com>
* handle no-metric-name autocompletes
* updated comment
Co-authored-by: Piotr Jamróz <pm.jamroz@gmail.com>
* build(webpack): bump to v5 and successful yarn start compilation
* build(webpack): update postcss dependencies
* build(webpack): silence warnings about hash renamed to fullhash
* build(webpack): enable persistent cache to store generated webpack modules / chunks
* build(webpack): prefer eslintWebpackPlugin over tschecker so eslint doesn't block typechecking
* chore(yarn): run yarn-deduplicate to clean up dependencies
* chore(yarn): refresh lock file after clean install
* build(webpack): prefer output.clean over CleanWebpackPlugin
* build(webpack): prefer esbuild over babel-loader for dev config
* build(babel): turn off cache compression to improve build performance
* build(webpack): get production builds working
* build(webpack): remove phantomJS (removed from grafana in v7) specific loader
* build(webpack): put back babel for dev builds no performance gain in using esbuild in webpack
* build(webpack): prefer terser and optimise css plugins for prod. slower but smaller bundles
* build(webpack): clean up redundant code. inform postcss about node_modules
* build(webpack): remove deprecation warnings flag
* build(webpack): bump packages, dev performance optimisations, attempt to get hot working
* chore(storybook): use webpack 5 for dev and production builds
* build(storybook): speed up dev build
* chore(yarn): refresh lock file
* chore(webpack): bump webpack and related deps to latest
* refactor(webpack): put back inline-source-map, move start scripts out of grafana toolkit
* feat(webpack): prefer react-refresh over react-hot-loader
* build(webpack): update webpack.hot to use react-refresh
* chore: remove react-hot-loader from codebase
* refactor(queryeditorrow): fix circular dependency causing react-fast-refresh errors
* revert(webpack): remove stats.errorDetails from common config
* build(webpack): bump to v5 and successful yarn start compilation
* build(webpack): update postcss dependencies
* build(webpack): silence warnings about hash renamed to fullhash
* build(webpack): enable persistent cache to store generated webpack modules / chunks
* build(webpack): prefer eslintWebpackPlugin over tschecker so eslint doesn't block typechecking
* chore(yarn): run yarn-deduplicate to clean up dependencies
* chore(yarn): refresh lock file after clean install
* build(webpack): prefer output.clean over CleanWebpackPlugin
* build(webpack): prefer esbuild over babel-loader for dev config
* build(babel): turn off cache compression to improve build performance
* build(webpack): get production builds working
* build(webpack): remove phantomJS (removed from grafana in v7) specific loader
* build(webpack): put back babel for dev builds no performance gain in using esbuild in webpack
* build(webpack): prefer terser and optimise css plugins for prod. slower but smaller bundles
* build(webpack): clean up redundant code. inform postcss about node_modules
* build(webpack): remove deprecation warnings flag
* build(webpack): bump packages, dev performance optimisations, attempt to get hot working
* chore(storybook): use webpack 5 for dev and production builds
* build(storybook): speed up dev build
* chore(yarn): refresh lock file
* chore(webpack): bump webpack and related deps to latest
* refactor(webpack): put back inline-source-map, move start scripts out of grafana toolkit
* feat(webpack): prefer react-refresh over react-hot-loader
* build(webpack): update webpack.hot to use react-refresh
* chore: remove react-hot-loader from codebase
* refactor(queryeditorrow): fix circular dependency causing react-fast-refresh errors
* revert(webpack): remove stats.errorDetails from common config
* revert(webpack): remove include from babel-loader so symlinks (enterprise) work as before
* refactor(webpack): fix deprecation warnings in prod builds
* fix(storybook): fix failing builds due to replacing css-optimise webpack plugin
* fix(storybook): use raw-loader for svg icons
* build(webpack): fix dev script colors error
* chore(webpack): bump css-loader and react-refresh-webpack-plugin to latest versions
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
* Sidemenu: Attempt to refactor BottomNavLinks to use SideMenuDropDown
* BottomNavLinks: Rewrite existing enzyme tests in RTL
* BottomNavLinks: Use object spreading instead of slicing
* refaactor: extract the tab labels into a const
* feat: list - show signature badge for enterprise plugins as well
* feat(plugins): add a component for showing plugin signature details
* feat: add a component for showing signature info under details
* feat: add a component for displaying signature info in details header
* feat: extract the plugin details header into a separate component
* feat: show signature information on the plugins details page
* refactor(Plugins): use an enum instead of an object
* refactor(Plugins): use more strict typing for tabs
* refactor(Plugins): use function declaration instead of fat-arrow for components
* fix(Plugins): fix typo
* fix: make installed plugin config an optional param again
* refactor: cache plugin meta requests
* refactor: move PLUGIN_TAB_LABELS to the types module
* export datetimepicker
* minor fixes to the datetime picker
* correct datetime to picker
* move datetime calc to function
* set maxDate
* set maxDate
* wrap in useCallback
* TimeSeries: Use graph min/max as baseis for percentage threshold calculation.
* respect hard and soft axis limits for % threshold steps
* revert state-timeline changes
* enable by-threshold coloring in histogram and barchart
* revert yMin
Co-authored-by: Leon Sorokin <leeoniya@gmail.com>
* outline string to time
add stringToTime transformer
start to add format
add type and dateformat
rename stringToTime to fieldConversion
add more type support and use FieldNamePicker
add field conversion transformation
* adjust for performance feedback
rename and adjust labels and widths
shorten labels and null values
rename to convertFieldType
update test
* make updates
* Allow grid lines visibility control to XYChart and TimeSeries
* Move grid lines config to field config (axis)
* Fix merge
* Auto grid mode
* Fix ts
* Align naming
* Update packages/grafana-ui/src/components/uPlot/config/UPlotConfigBuilder.test.ts
Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>
* Update packages/grafana-ui/src/components/uPlot/config/UPlotConfigBuilder.test.ts
Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>
* remove 'grid' from props diff array since field.config.custom.* is handled by structureRev diffing
Co-authored-by: Zoltán Bedi <zoltan.bedi@gmail.com>
Co-authored-by: Leon Sorokin <leeoniya@gmail.com>
* Loki: add tests for addAdHocFilters
* Change description of test
Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
* Replace ADD_FILTER with "=" operator in test description
Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
* Loki: refafctor test for addAdHocFilter
* Loki: refactor tests for better readability
* Remove comments
Co-authored-by: Piotr Jamróz <pm.jamroz@gmail.com>
Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
Co-authored-by: Piotr Jamróz <pm.jamroz@gmail.com>
* Jaeger: add empty callback to QueryField onBlur to stop query from being run twice
* Jaeger: add wait call on 500ms to accomodate for debouncing by the QueryField component
* SideMenuDropDown: Refactor to be more component-ey + rewrite tests in RTL
* SideMenuDropDown: Rename childLinks -> items
* Rename mockChildLinks -> mockItems as well
* Relocate dashboard scuemata to grafana-schema
* Update assorted tests, vars with dashboard path
* Remove crufty commented var
* Not sure...why that failed
* Remove prefix from base dashboard path var
* Move cue/ui remnants into grafana-schema
* Update import paths in plugin models
* Remove mudball, add package statements
* Remove cuegen.sh
Wooooo we ain't got no codegen
* Revert "Remove mudball, add package statements"
This reverts commit 9bed3098f1.
* Tidy up all the cue files
* Move dashboard scuemata into scuemata/ subdir
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
* Jaeger: add QueryField component
* Remove unused imports
* Fix e2e test so that it checks for QueryField component
* Remove comments
* Fix failing e2e test
* QueryEditor: Don't use _.defaults as it mutates the query prop directly
* QueryEditor: Update the query type on mount if none exists
* QueryEditor: Mutate in the constructor instead of render
* Apply defaults immutably in render
* Annotation Panel: Fix annotation with end time not being centered
* Update public/app/plugins/panel/annolist/AnnoListPanel.tsx
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
* Group alertmangaer alerts by custom grouping
* Filter am groups
* Style filter components
* Style filter bar and add clear functionality
* rename components to alert group
* use query params for group filters
* filter style improvements
* add tests for group by
* Add grouping banner to better highlight groupings
* clean up hook logic
* Add Tempo search behind feature flag
* Add query fields for Tempo search
* Only show loki search if a logs-to-traces datasource is set up
* Refactor tempo search to use separate fields for service name, span name, and tags
* Add tests to buildSearchQuery
* Move search to separate component and rename type to native search
* Improve Tempo tokenizer syntax
* Postgres: For template queries return [] and not error
* remove the console error
* update mssql and mysql
Co-authored-by: Ying WANG <ying.wang@grafana.com>
* State timeline: fix mem leak caused by excessive plot re-init
* Update PlotTooltipInterpolator type
* Do not reference config object in the setCursor hook
* fix excessive BarChart re-init caused by shallow diff of text config
* one less error
Co-authored-by: Dominik Prokop <dominik.prokop@grafana.com>
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
* Add filter parsing to rule list filters
* Add unit tests for label parsing
* Make label operators an enum
* add example for parsing function
* Update labels operator regex
* Use tooltip for query syntax example
* refactor to use Matchers for filtering
* wip: initial alertmanager notifications panel
* Panel for alertmanager notificaitons
* add filtering for notifications list
* remove icon
* rename am notifications to alert groups
* naming fixes
* Feature toggle
* Add toggle for expand all
* add pluralize
* add action buttons
* test work in progress
* Tests for alert groups panel
* Add useEffect for expandAll prop change
* Set panel to alpha state
* Fix colors
* fix polling interval callback
Co-authored-by: Domas <domas.lapinskas@grafana.com>
Co-authored-by: Domas <domas.lapinskas@grafana.com>
* Alerting: update matchers field operators to Select
* Add matcher field to routes
* fix default values
* min-width for matcher operator
* dry up matcher field options
* change MatcherField name to MatcherValue
* Add UMLs
* Add rendered diagrams
* Move QueryCtrl to flux
* Remove redundant param in the reducer
* Use named imports for lodash and fix typing for GraphiteTagOperator
* Add missing async/await
* Extract providers to a separate file
* Clean up async await
* Rename controller functions back to main
* Simplify creating actions
* Re-order controller functions
* Separate helpers from actions
* Rename vars
* Simplify helpers
* Move controller methods to state reducers
* Remove docs (they are added in design doc)
* Move actions.ts to state folder
* Add docs
* Add old methods stubs for easier review
* Check how state dependencies will be mapped
* Rename state to store
* Rename state to store
* Rewrite spec tests for Graphite Query Controller
* Update docs
* Update docs
* Add GraphiteTextEditor
* Add play button
* Add AddGraphiteFunction
* Use Segment to simplify AddGraphiteFunction
* Memoize function defs
* Fix useCallback deps
* Update public/app/plugins/datasource/graphite/state/helpers.ts
Co-authored-by: Giordano Ricci <me@giordanoricci.com>
* Update public/app/plugins/datasource/graphite/state/helpers.ts
Co-authored-by: Giordano Ricci <me@giordanoricci.com>
* Update public/app/plugins/datasource/graphite/state/helpers.ts
Co-authored-by: Giordano Ricci <me@giordanoricci.com>
* Update public/app/plugins/datasource/graphite/state/providers.ts
Co-authored-by: Giordano Ricci <me@giordanoricci.com>
* Update public/app/plugins/datasource/graphite/state/providers.ts
Co-authored-by: Giordano Ricci <me@giordanoricci.com>
* Update public/app/plugins/datasource/graphite/state/providers.ts
Co-authored-by: Giordano Ricci <me@giordanoricci.com>
* Update public/app/plugins/datasource/graphite/state/providers.ts
Co-authored-by: Giordano Ricci <me@giordanoricci.com>
* Update public/app/plugins/datasource/graphite/state/providers.ts
Co-authored-by: Giordano Ricci <me@giordanoricci.com>
* Update public/app/plugins/datasource/graphite/state/providers.ts
Co-authored-by: Giordano Ricci <me@giordanoricci.com>
* Add more type definitions
* Remove submitOnClickAwayOption
This behavior is actually needed to remove parameters in functions
* Load function definitions before parsing the target on initial load
* Add button padding
* Fix loading function definitions
* Change targetChanged to updateQuery to avoid mutating state directly
It's also needed for extra refresh/runQuery execution as handleTargetChanged doesn't handle changing the raw query
* Fix updating query after adding a function
* Simplify updating function params
* Migrate function editor to react
* Simplify setting Segment Select min width
* Remove unnecessary changes to SegmentInput
* Extract view logic to a helper and update types definitions
* Clean up types
* Update FuncDef types and add tests
* Show red border for unknown functions
* Autofocus on new params
* Extract params mapping to a helper
* Split code between params and function editor
* Focus on the first param when a function is added even if it's an optional argument
* Add function editor tests
* Remove todo marker
* Fix adding new functions
* Allow empty value in selects for removing function params
* Add placeholders and fix styling
* Add more docs
* Create basic implementation for metrics and tags
* Post merge fixes
These files are not .ts
* Remove mapping to Angular dropdowns
* Simplify mapping tag names, values and operators
* Simplify mapping metrics
* Fix removing tags and autocomplete
* Simplify debouncing providers
* Ensure options are loaded twice and segment is opened
* Remove focusing new segments logic (not supported by React's segment)
* Clean up
* Move debouncing to components
* Simplify mapping to selectable options
* Add docs
* Group all components
* Remove unused controller methods
* Create Dispatch context
* Group Series and Tags Sections
* Create Functions section
* Create Section component
* use getStyles
* remove redundant async/await
* Remove
* remove redundant async/await
* Remove console.log and silent test console output
* Do not display the name of the selected dropdown option
* Move Section to grafana-ui
* Update storybook
* Simplify SectionLabel
* Fix Influx tests
* Fix API Extractor warnings
* Fix API Extractor warnings
* Do not show hidden functions
* Use block docs for better doc generation
* Handle undefined values provided for autocomplete
* Section -> SegmentSection
* Simplify section styling
* Remove redundant div
* Simplify SegmentSection component
* Use theme.spacing
* Use empty label instead of a single space label
Co-authored-by: Giordano Ricci <me@giordanoricci.com>
* Fix jsdoc description for datasourceRequest
* Align default subscription width with other fields
* AzureMonitor: Show error message when requesting default subscriptions in ConfigEditor
* update snapshots:
* move query migrations out of the angular controller
* Migrate queries in QueryEditor
* finish up migrations
* update deprecated comment
* remove comment
* Strip nulls (again)
* Add stripnulls script
* Add transformations field
* Close FieldConfig struct; proper plugin validating
* s/graph/viz/ field in histogram dashboard
* Use ui.GraphFieldConfig in histogram model
* Add models for stat, gauge, barguage panel plugins
Also toss necessary shared types into cue/ui/gen.cue, with TODOs to move
them appropriately later.
* Add required license headers
* Heap of updates to cue UI components
* Fix barchart types and one old devenv input
* Use the GraphFieldConfig directly for timeseries
* Add models.cue for a few panel plugins
Barchart, state-timeline, and status-history
* Enable the test validating all devenv dashboards!!
* Fix effects of not checking after making comments
* Update packages/grafana-ui/src/options/models.gen.ts
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
* Realign and unalign cue with ts types
* Update devenv test to sniff for null errors
Best option we have right now for helping people to know they need to
strip nulls from devenv dashboards.
* Add speculative default for barchart stacking
* Fixup some dated devenv dashboards
timeline-modes needed to be regenerated with the appropriate tooltip
values included, per typing requirements, and timeline-demo needed to
have the `mode` field removed, as it is not intended to be persisted.
* Add necessary missing options for various panels
* Regenerate devenv dashboards
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
* Add input to specify min step
* Add stepInterval to as input to component
* Add onBlur to Input component
* Loki: add functionality for min step
* Loki: change name on props to step to make it more clear
* Loki: add resolution as a query option
* Loki: Add min,max,exact as step options
* Loki: add functionality for different step modes
* Loki: fix bug where step function isn't working
* Loki: fix bug where exact step isn't working
* Loki: change width of step input field
* Loki: add tests for adjustInterval function
* Loki: add check for max step oprio to make sure it's not below the safe interval
* Loki: fix bug with some tests
* Loki: fix bug with tests
* Explore: add tooltip to loki step function
* Loki: remove resolution as a logs option
* Loki: update snapshots
* Fix failing tests
* Loki: add select component for choosing resolution
* Loki: add functionality for calculating correct interval with resolution applied
* Loki: remove functionality for step mode
* Loki: remove tests for step mode
* Loki: add tooltip to line limit and resolution
* Loki: add backend support for resolution
* Loki: fixed backend bug where resolution was undefined
* Loki: add check for resolution
* GraphNG: account for top canvas padding in gradient gen for color scheme/thresholds-by-value
* Updated test dashboard
* Added fix for issue when scaleMin was same as threshold
* fixed firefox issue
* revert docs changes
* update gdev dash for easier comparisons & regression spotting
* refactor
* optimize gradient re-gen/re-use and color more tinycolor.setAlpha() -> alpha(). update uPlot to dev build.
* fix percentage steps
* implement % threshold region rendering
* crisp threshold line rendering
* simplify
* WIP: hoverpoint dynamic color interpolation
* fix hover point color interp
* re-use gradient gen to draw threshold areas
* re-implement by-value color scales
* tweak comment
* mimic tinycolor behavior in colorManipulator.alpha() for empty colors
* explicitly disable hover points for BarChart and Histogram
* reduce test failures and required changes to tests
* fix barchart tests
* uPlot 1.6.15
Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
Co-authored-by: Ryan McKinley <ryantxu@gmail.com>
* Fixes wrong annotation when opening dashboard with URL encoded variable
Co-authored-by: Ashley Harrison, Hugo Haggmark, and Tobias Skarhed.
* added a more descriptive comment