Gábor Farkas
46eec85b1a
loki: better handle an empty-response ( #52397 )
2022-07-19 08:13:38 +02:00
Gábor Farkas
fd63ed540f
loki: fix bug in labels framing ( #51015 )
2022-06-17 12:50:10 +02:00
Gábor Farkas
109bc7e940
loki: add type=instant tests ( #51007 )
2022-06-17 09:47:49 +02:00
Gábor Farkas
ccc587dc0f
Loki: Handle data source configs with path in the url ( #50971 )
...
* loki: fixed param-name
* loki: handle datasource configs with path in the url
* lint fix
2022-06-17 07:47:31 +02:00
Serge Zaitsev
ae9491c3a7
Chore: Make test tracer noop and return no errors ( #50797 )
2022-06-15 12:40:41 +02:00
Gábor Farkas
8fd9cb4854
loki: add feature-toggle check to live-mode ( #49012 )
2022-06-13 08:33:46 +02:00
Todd Treece
64d93498de
Chore: Update grafana-plugin-sdk-go to v0.136.0 ( #50127 )
2022-06-03 08:25:52 -04:00
Gábor Farkas
46d6573968
loki: add cookie-handling functionality ( #49978 )
2022-06-02 11:52:27 +02:00
Todd Treece
94b9c524a8
Prometheus: Streaming JSON parser performance improvements ( #48792 )
2022-05-24 16:17:11 -04:00
Gábor Farkas
78e22aac59
loki: backend: better error-handling-tests ( #49213 )
2022-05-19 14:26:40 +02:00
Gábor Farkas
683c1c0f40
logs: use explicit frame-type-check ( #48940 )
2022-05-16 13:38:05 +02:00
Gábor Farkas
7b9929fffe
loki: framing_test: more infinity/nan test cases ( #48855 )
2022-05-09 11:47:50 +00:00
Gábor Farkas
da74dba7c8
Loki: backend: use streaming JSON parser, try2 ( #48752 )
...
* converter: remove __name__ customization because Loki does not do that
Loki does not handle __name__ in a special way.
for Prometheus, the caller can implement the formatting
by themselves
* converter: change labels-formatting
the labels.String() method does not handle strange values well
* loki: backend: use streaming-json parser
* more idiomatic code
Co-authored-by: Todd Treece <360020+toddtreece@users.noreply.github.com>
* simpler row-length check
* simpler code
* fixed converter/prom tests
Co-authored-by: Todd Treece <360020+toddtreece@users.noreply.github.com>
2022-05-05 13:09:01 +02:00
Gábor Farkas
02aa1cd1c5
loki backend mode forward-oauth ( #48401 )
...
* loki: backend: add forward oauth credentials functionality
* removed obsolete comment
2022-05-05 12:42:50 +02:00
Gábor Farkas
3cade2f669
Revert "Loki: backend: use streaming JSON parser ( #47656 )" ( #48747 )
...
This reverts commit 46b40b6e82
.
2022-05-05 12:02:53 +02:00
Gábor Farkas
46b40b6e82
Loki: backend: use streaming JSON parser ( #47656 )
...
* converter: remove __name__ customization because Loki does not do that
Loki does not handle __name__ in a special way.
for Prometheus, the caller can implement the formatting
by themselves
* converter: change labels-formatting
the labels.String() method does not handle strange values well
* loki: backend: use streaming-json parser
* more idiomatic code
Co-authored-by: Todd Treece <360020+toddtreece@users.noreply.github.com>
* simpler row-length check
* simpler code
Co-authored-by: Todd Treece <360020+toddtreece@users.noreply.github.com>
2022-05-05 08:47:40 +02:00
Gábor Farkas
7d369a1dea
Loki: backend: use json-field ( #48486 )
...
* fixed strings
* loki: backend: use json-field
2022-05-03 08:03:25 +02:00
Gábor Farkas
62cd722726
Loki: minor backend-dataframe-format changes ( #48320 )
...
* loki: backend: better dataframe field names
* loki: backend: add dataframe-type to metric dataframes
* loki: backend: only add stats to the first metric dataframe
2022-04-29 09:04:37 +02:00
Gábor Farkas
ae926c2144
loki: better resource-call urls ( #48250 )
2022-04-28 14:28:57 +02:00
Gábor Farkas
c73b9d1818
Loki: do not use the old labels-api ( #48185 )
...
* loki: do not use old labels-api
* adjust allowed-url-list
* fixed tests
2022-04-26 11:51:26 +02:00
Gábor Farkas
d8a754c4a0
loki: send metadata requests through backend ( #48063 )
2022-04-25 13:16:14 +02:00
Gábor Farkas
79c06fdddc
Loki: add backend-forward mode to queries, update log-row-context ( #47726 )
...
* loki: add helper function to sort dataframe by time
* loki: add direction-attribute to queries
* loki: make log-row-context code backward-compatible
* better comment
Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
* fixed test
* simplified code
Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
2022-04-20 13:52:15 +02:00
ying-jeanne
7ddae870e7
fix status code 200 ( #47818 )
2022-04-15 08:01:58 -04:00
Gábor Farkas
d95468a4bb
Loki: use millisecond-steps ( #47572 )
...
* loki: use millisecond-steps
* better comment
Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
* better comment
Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
2022-04-12 12:30:39 +02:00
Gábor Farkas
68511e7712
loki: use single-dataframe format on the backend ( #47069 )
2022-04-12 11:58:48 +02:00
Gábor Farkas
96987ac182
loki: add test to handle __name__ ( #47298 )
2022-04-05 11:56:54 +02:00
Gábor Farkas
a246381879
loki: backend-mode: add stats support ( #46526 )
...
* loki: backend-mode: add stats support
* refactor: rename variable
2022-03-31 17:50:27 +02:00
Gábor Farkas
c4404982dc
loki: backend-mode: add nanosecond-timestamps ( #45963 )
2022-03-04 09:42:18 +01:00
Ryan McKinley
796bc27f75
Loki: support live streaming ( #42804 )
2022-03-01 14:46:52 -08:00
Gábor Farkas
1cad35ea67
loki: backend mode: support all query types ( #45619 )
...
* loki: backend mode: support all query types
* loki: backend: adjust vector-parsing field-names
* loki: backend: no interval for streams-dataframes
* loki: backend: enable more query types
* better variable name
* removed unnecessary code
* improve frame-processing
* more unit tests
* improved code
Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
* remove unused code
Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
* simplify code
Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
* lint fix
Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
2022-02-25 09:14:17 +01:00
Gábor Farkas
5d704fd46e
Loki: backend: use custom http code ( #44643 )
...
* Loki: backend: use custom http code
* simplfied comment
Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
2022-02-18 14:35:39 +01:00
Torkel Ödegaard
a757a57c6e
Prometheus: Show executed query in inspector ( #45362 )
...
* Prometheus: Show executed query in inspector
* Loki: Improving test
2022-02-15 15:02:03 +01:00
Gábor Farkas
96ae44ee2c
loki: alerting: do not round timestamps to seconds ( #45057 )
2022-02-10 12:53:46 +01:00
Gábor Farkas
d9d1f8520e
loki: backend-queries: set interval-value in dataframe ( #44965 )
...
* loki: backend-queries: set interval-value in dataframe
* fixed unit test
* added interval-specific unit test
2022-02-07 13:02:04 +01:00
Gábor Farkas
3873c5e7b5
loki: alerting: better error-handling ( #44700 )
2022-02-01 13:34:03 +01:00
Gábor Farkas
6e071d030f
loki: added benchmark for metric-response processing ( #44539 )
2022-01-28 09:44:57 +01:00
Gábor Farkas
b42161a713
Loki: add from JSON to dataframes tests ( #44375 )
...
* Loki: add from JSON to dataframes tests
* fixed wrong content-type
* added -Inf test-case
2022-01-27 12:43:44 +01:00
Will Browne
7fbc7d019a
Plugins: Core plugins register via backend factory provider ( #43171 )
...
* refactoring store interface and init flow
* fix import
* fix linter
* refactor resource calling
* load with class
* re-order args
* fix tests
* fix linter
* remove old creator
* add custom config struct
* fix some tests
* cleanup
* fix
* tackle plugins
* fix linter
* refactor and fix test
* add connect failure error
* add fix for azure, cloud monitoring and test data
* restructure
* remove unused err
* add fake tracer for test
* fix grafana ds plugin
2022-01-20 18:16:22 +01:00
idafurjes
30aa24a183
Chore: Implement OpenTelemtry in Grafana ( #42674 )
...
* Separate Tracer interface to TracerService and Tracer
* Fix lint
* Fix:Make it possible to start spans for both opentracing and opentelemetry in ds proxy
* Add span methods, use span interface for rest of tracing
* Fix logs in tracing
* Fix tests that are related to tracing
* Fix resourcepermissions test
* Fix some tests
* Fix more tests
* Add TracingService to wire cli runner
* Remove GlobalTracer from bus
* Renaming test function
* Remove GlobalTracer from TSDB
* Replace GlobalTracer in api
* Adjust tests to the InitializeForTests func
* Remove GlobalTracer from services
* Remove GlobalTracer
* Remove bus.NewTest
* Remove Tracer interface
* Add InitializeForBus
* Simplify tests
* Clean up tests
* Rename TracerService to Tracer
* Update pkg/middleware/request_tracing.go
Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com>
* Initialize tracer before passing it to SQLStore initialization in commands
* Remove tests for opentracing
* Set span attributes correctly, remove unnecessary trace initiliazation form test
* Add tracer instance to newSQLStore
* Fix changes due to rebase
* Add modified tracing middleware test
* Fix opentracing implementation tags
Co-authored-by: Marcus Efraimsson <marcus.efraimsson@gmail.com>
2022-01-20 11:10:12 +01:00
Ryan McKinley
546818819b
Loki: use queryType rather than range|instant flags ( #43727 )
2022-01-07 10:00:11 -08:00
Will Browne
e4ba5f17dd
add core plugins thru store ( #43085 )
2021-12-14 15:22:40 +01:00
Gábor Farkas
a4cc1f6b39
loki: alerting: handle curly-braces-style variables ( #42933 )
2021-12-09 15:16:01 +01:00
Gábor Farkas
3232ae08c0
loki: removed unused variable ( #42909 )
2021-12-09 13:16:52 +01:00
Gábor Farkas
6686f8c345
loki: rename ResponseModel to QueryModel ( #42794 )
2021-12-07 07:57:52 +01:00
Gábor Farkas
24d4c8a9d1
Loki: alerting: handle variables like __interval and __range ( #42126 )
2021-11-24 16:56:53 +01:00
Gábor Farkas
fe84454bb0
loki: alerting: simplified config ( #42147 )
...
* loki: alerting: simplified config
* adjusted config handling
2021-11-24 11:52:33 +01:00
Gábor Farkas
037fd9cc8c
Loki: alerting: adjust step-calculation to be the same as in frontend ( #42033 )
...
* loki: alerting: adjust step-calculation to be the same as in frontend
* loki: simplified test
* lint fix
2021-11-22 14:28:51 +01:00
Gábor Farkas
2fbc6b1d2f
loki: simplify interval calculation ( #41857 )
2021-11-19 17:20:32 +01:00
Will Browne
b80fbe03f0
Plugins: Refactor Plugin Management ( #40477 )
...
* add core plugin flow
* add instrumentation
* move func
* remove cruft
* support external backend plugins
* refactor + clean up
* remove comments
* refactor loader
* simplify core plugin path arg
* cleanup loggers
* move signature validator to plugins package
* fix sig packaging
* cleanup plugin model
* remove unnecessary plugin field
* add start+stop for pm
* fix failures
* add decommissioned state
* export fields just to get things flowing
* fix comments
* set static routes
* make image loading idempotent
* merge with backend plugin manager
* re-use funcs
* reorder imports + remove unnecessary interface
* add some TODOs + remove unused func
* remove unused instrumentation func
* simplify client usage
* remove import alias
* re-use backendplugin.Plugin interface
* re order funcs
* improve var name
* fix log statements
* refactor data model
* add logic for dupe check during loading
* cleanup state setting
* refactor loader
* cleanup manager interface
* add rendering flow
* refactor loading + init
* add renderer support
* fix renderer plugin
* reformat imports
* track errors
* fix plugin signature inheritance
* name param in interface
* update func comment
* fix func arg name
* introduce class concept
* remove func
* fix external plugin check
* apply changes from pm-experiment
* fix core plugins
* fix imports
* rename interface
* comment API interface
* add support for testdata plugin
* enable alerting + use correct core plugin contracts
* slim manager API
* fix param name
* fix filter
* support static routes
* fix rendering
* tidy rendering
* get tests compiling
* fix install+uninstall
* start finder test
* add finder test coverage
* start loader tests
* add test for core plugins
* load core + bundled test
* add test for nested plugin loading
* add test files
* clean interface + fix registering some core plugins
* refactoring
* reformat and create sub packages
* simplify core plugin init
* fix ctx cancel scenario
* migrate initializer
* remove Init() funcs
* add test starter
* new logger
* flesh out initializer tests
* refactoring
* remove unused svc
* refactor rendering flow
* fixup loader tests
* add enabled helper func
* fix logger name
* fix data fetchers
* fix case where plugin dir doesn't exist
* improve coverage + move dupe checking to loader
* remove noisy debug logs
* register core plugins automagically
* add support for renderer in catalog
* make private func + fix req validation
* use interface
* re-add check for renderer in catalog
* tidy up from moving to auto reg core plugins
* core plugin registrar
* guards
* copy over core plugins for test infra
* all tests green
* renames
* propagate new interfaces
* kill old manager
* get compiling
* tidy up
* update naming
* refactor manager test + cleanup
* add more cases to finder test
* migrate validator to field
* more coverage
* refactor dupe checking
* add test for plugin class
* add coverage for initializer
* split out rendering
* move
* fixup tests
* fix uss test
* fix frontend settings
* fix grafanads test
* add check when checking sig errors
* fix enabled map
* fixup
* allow manual setup of CM
* rename to cloud-monitoring
* remove TODO
* add installer interface for testing
* loader interface returns
* tests passing
* refactor + add more coverage
* support 'stackdriver'
* fix frontend settings loading
* improve naming based on package name
* small tidy
* refactor test
* fix renderer start
* make cloud-monitoring plugin ID clearer
* add plugin update test
* add integration tests
* don't break all if sig can't be calculated
* add root URL check test
* add more signature verification tests
* update DTO name
* update enabled plugins comment
* update comments
* fix linter
* revert fe naming change
* fix errors endpoint
* reset error code field name
* re-order test to help verify
* assert -> require
* pm check
* add missing entry + re-order
* re-check
* dump icon log
* verify manager contents first
* reformat
* apply PR feedback
* apply style changes
* fix one vs all loading err
* improve log output
* only start when no signature error
* move log
* rework plugin update check
* fix test
* fix multi loading from cfg.PluginSettings
* improve log output #2
* add error abstraction to capture errors without registering a plugin
* add debug log
* add unsigned warning
* e2e test attempt
* fix logger
* set home path
* prevent panic
* alternate
* ugh.. fix home path
* return renderer even if not started
* make renderer plugin managed
* add fallback renderer icon, update renderer badge + prevent changes when renderer is installed
* fix icon loading
* rollback renderer changes
* use correct field
* remove unneccessary block
* remove newline
* remove unused func
* fix bundled plugins base + module fields
* remove unused field since refactor
* add authorizer abstraction
* loader only returns plugins expected to run
* fix multi log output
2021-11-01 10:53:33 +01:00
Ivana Huckova
f172701043
IntervalV2: Use maxDataPoints to calculate correct interval ( #39036 )
...
* Use max data points to calculate interval
* Fix mockCalculator to mach Calculator
* Fix incorrect merge, replace queryModel with query
2021-09-13 14:58:32 +02:00