Commit Graph
100 Commits
Author SHA1 Message Date
Gábor Farkas 53863c52ca sql: use logging functionality from plugin-sdk (#79294) 2023-12-14 09:42:06 +01:00
Gábor Farkas 5b4da3a7dc mssql: prepare logs-handling for decouple-datasource changes (#79214)
mssql: refactor logs-handling
2023-12-11 09:14:06 +01:00
Gábor Farkas 92044a9009 postgres: refactor logs-handling (#79147)
* postgres: refactor logs-handling

* fixed unit test
2023-12-07 13:18:49 +01:00
Gábor Farkas 9e71dc801d mysql: refactor logs handling (#79148)
* mysql: refactor logs handling

* fixed unit test
2023-12-07 12:17:41 +01:00
Gábor Farkas 9f0fc60477 sql: remove xorm dependency from postgres/mysql/mssql (#77870)
* sql: remove xorm

* sql: remove pkg/util dependency (#78821)

sql: removed md5-util dependency
2023-12-06 09:35:05 +01:00
Gábor Farkas 033446523b mysql/postgres: vendor in unit-test helper function (#78744) 2023-11-29 08:07:14 +01:00
Gábor Farkas 4f899e3576 sql: removed dependency on test-db-check (#78717) 2023-11-28 12:46:01 +01:00
Gábor Farkas 5be99912ff mssql: adjust unit test to minimize xorm-usage (#78597)
* mssql: adjust unit test to minimize xorm-usage

* lint fix
2023-11-24 13:12:19 +01:00
Gábor Farkas 710248674d postgres: update unit test to be ready for the xorm-removal (#78537)
postgres: removed xorm from unit tests
2023-11-24 11:11:18 +01:00
Gábor Farkas 6b6b209e1c better CODEOWNERS comment (#78034) 2023-11-16 11:56:02 +01:00
Gábor Farkas b97e485fe0 mysql: update unit test to be ready for the xorm-removal (#78064)
* mysql: update unit test to be ready for the xorm-removal

* removed unused code
2023-11-15 09:46:18 +01:00
Gábor Farkas fe18c63204 mysql: do not import httpClient from core grafana (#77628)
mysql: do not use core-only exports
2023-11-13 10:25:19 +01:00
Gábor Farkas 2d391c1bf5 postgresql: change plugin id (#77444)
* postgres: change plugin id

* fixed cue file

* codeowners update

* fixed backend test
2023-11-13 08:49:26 +01:00
Gábor Farkas 4a6b209d64 sql: refactor code, eliminate from-core-grafana import (#77810) 2023-11-08 14:08:20 +01:00
Gábor Farkas 03bb6d6f74 devenv: postgres: make it work (#76323) 2023-10-13 08:53:38 +02:00
Gábor Farkas dc8b07d46f postgres/mysql: improved imports in unit tests (#75980)
* postgres/mysql: improved imports in unit tests

* simpler mock approach
2023-10-11 10:38:38 +02:00
Gábor Farkas c869844a78 sql: added lint-rule againts wrong imports (#75881) 2023-10-05 08:04:10 +02:00
Gábor Farkas eea95c2ddf postgres/mysql: removed from-grafana-core import (#75826) 2023-10-05 07:46:24 +02:00
Gábor Farkas cbfd1d53ee mysql: config: fixed import and removed unused code (#75883)
* mysql: removed obsolete import

* removed unnecessary check
2023-10-05 07:46:05 +02:00
523d1b46d4 sql: numeric inputs: use it's own simple implementation (#74904)
* sql: numeric inputs: use it's own simple implementation

* simpler approach

* Update connection limit styles (#75226)

* lint fixes

* replace ConfigSection with ConfigSubSection

---------

Co-authored-by: Gareth Dawson <email@garethdawson.xyz>
Co-authored-by: Gareth Dawson <gwdawson.work@gmail.com>
2023-10-03 13:54:51 +02:00
Gábor Farkas 8dafc28988 sql: remove grafana-core import (#75558)
* sql: remove initialCustomVariableModelState

* added fix for mysql too

* linter fixes
2023-09-29 13:43:28 +02:00
Gábor Farkas 24350521be sql: improve imports in test (#75006) 2023-09-19 09:19:28 +02:00
Gábor Farkas fb0357947f sql: add more tests (#74919) 2023-09-18 14:11:11 +02:00
Gábor Farkas 1f6f866a36 sql: do not use the getTimeSrv call (#74800)
* sql: eliminate the getTimeSrv call

* adjusted tests
2023-09-18 10:39:05 +02:00
Gábor FarkasandAdam Yeats 6e75c5d182 postgres/sql: fix imports (#74535)
* postgres/sql: fix imports

* nicer import

Co-authored-by: Adam Yeats <16296989+adamyeats@users.noreply.github.com>

---------

Co-authored-by: Adam Yeats <16296989+adamyeats@users.noreply.github.com>
2023-09-11 09:48:55 +02:00
Gábor Farkas ed46e3444c CODEOWNERS: handle shared sql code (#74170) 2023-09-05 08:10:54 +02:00
Gábor Farkas 1cc226e689 codeowners: reassing mysql/postgres (#72820) 2023-08-22 12:24:27 +02:00
Gábor Farkas ed9dc63326 loki: logs-context: handle sorting for dataplane frames (#72286)
loki: context: better dataframe sorting algo
2023-08-01 09:38:41 +02:00
Gábor Farkas f63d829bf6 loki: tests: better nanosecond representation (#72456)
* logs: tests: test for nanosecond-only differences

* add nanos
2023-07-27 17:06:56 +03:00
Gábor Farkas e56f97ec71 grafana-data: handle reordering of field.nanos (#72290)
* grafana-data: handle reordering of field.nanos

* do not add nanos:undefined
2023-07-26 14:17:02 +02:00
Gábor Farkas 0da199324a logs: log-details: handle dataplane-compliant dataframes (#71935)
* logs: log-details: handle dataplane-compliant dataframes

* lint fix, removed unused import
2023-07-26 10:56:26 +02:00
Gábor Farkas 63e0b927bd logs: context: various scrolling-fixes (#72271)
* logs: context: correctly append to the above&below arrays

* logs: context: on initial load always scroll to center

* logs: context: reset counts when context-query-ui changes
2023-07-25 14:34:02 +02:00
Gábor FarkasandIvana Huckova 8a796e39af docs: logs: update copy-link documentation (#71943)
* docs: logs: update copy-link documentation

* remove incorrect icon

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>

* better styling

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>

---------

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
2023-07-25 11:01:00 +02:00
Gábor Farkas 519aa96739 docs: logs: removed incorrect text (#72247) 2023-07-25 10:57:48 +02:00
Gábor Farkas f2f30caa73 logs: better unit tests (#72246) 2023-07-25 10:50:54 +02:00
Gábor Farkas 2c82a6b6c4 Traces: Enable showing trace ids (#71950)
* traces: enable showing trace ids by default

* removed unused imports
2023-07-20 07:59:38 +02:00
Gábor Farkas d4dcf9f9d2 logs: log-details: updated test for more complete mock data (#71941)
logs: updated test for more realistic mock data
2023-07-19 14:37:37 +02:00
Gábor Farkas 709e4de7c6 logs: log-details: test for datalink without field value (#71922)
* logs: log-details: test for datalink without field value

* added more test-cases
2023-07-19 14:12:49 +03:00
Gábor Farkas eaeeb5c698 logs: improved unit tests (#71840) 2023-07-19 11:42:23 +02:00
Gábor Farkas 9b6c7b74c7 logs: added test for parsing a dataplane-logs-frame (#71758)
logs: added tests for parsing a dataplane-logs-frame
2023-07-18 13:33:49 +02:00
Gábor Farkas d0351bac57 logs: restrict permalinks to datasources with id fields (#71729)
* logs: restrict permalinks to datasources with id fields

* simplified code

* more tests

* more test

* removed unnecessary comment

* fixed tests

* updated tests
2023-07-17 15:01:48 +02:00
Gábor Farkas ab58466d09 logs: improve logs-frame parsing (#71450)
* logs: improve logs-frame parsing

* renamed fields
2023-07-17 14:42:33 +02:00
Gábor Farkas 98f4bbf7fa logs: context small improvements (#71546)
adjusted page size
normalize logrow refid
add tracking
2023-07-13 12:18:26 +00:00
Gábor Farkas e045860fbf loki: generate dataplane-compliant logs dataframes (behind feature flag) (#69909)
* add feature flag

* prepare tests

* enable dataplane-format in loki-backend
2023-07-13 09:58:00 +02:00
Gábor Farkas 1f55003db2 logs: make sure log-row-react-keys are always unique (#71279) 2023-07-13 08:01:55 +02:00
Gábor Farkas fdb8257007 Elasticsearch: Fix histogram colors in backend mode (#71442)
elastic: backend-mode: fix histogram colors
2023-07-12 13:59:51 +02:00
Gábor Farkas e17540bdcd Elasticsearch: Fix using multiple indexes with comma separated string (#71284)
* Revert "Elasticsearch: Use array of strings as index in backend queries (#67276)"

This reverts commit d0ced39847.

* updated tests
2023-07-11 09:47:16 +02:00
Gábor FarkasandMatias Chomicki 8f2f6d63eb logs: scanning: add tracking (#71031)
* logs: scanning: add tracking

* only report start-click when it is really doing it

Co-authored-by: Matias Chomicki <matyax@gmail.com>

---------

Co-authored-by: Matias Chomicki <matyax@gmail.com>
2023-07-10 13:50:18 +02:00
Gábor Farkas a62ae10a02 logs: refactor: move logsModel to the logs folder (#70989)
* move files

* fixed imports in the moved files

* updated imports pointing to the moved files
2023-07-04 13:27:52 +02:00
Gábor Farkas 2084cc9955 Logs: Do not insert log-line into log-fields in json download (#70901)
* logs: do not insert log-line into log-fields in json download

* fixed test after merge
2023-06-30 09:37:32 +02:00
Gábor Farkas 4548b0d9fc logs: better nanosecond handling (#70878)
* logs: simplify code

* refactor

* handle nanoseconds
2023-06-29 15:33:41 +02:00
Gábor Farkas 890316c105 logs: add more tests (#70886) 2023-06-29 14:53:31 +02:00
Gábor Farkas 50ad099eab logs: refactor tests to make them smaller (#70824) 2023-06-28 16:19:34 +02:00
Gábor Farkas 3f44412bfd logs: more tests related to timestamp handling (#70819) 2023-06-28 13:50:29 +02:00
Gábor FarkasandSven Grossmann 9ca888527b Logs: Implement "infinite" scrolling in log context (#69459)
* logs: context: allow "infinite" scroll

* Log Context: Add visual changes to infinite scrolling (#70461)

* remove text showing how many log lines are loaded

* better positioning of loading indicators

* add border

* fix import

* better loading states

* improve corner cases

* increase page size 10 => 50

* updated unit test, simplified code

* fixed tests

* updated tests

* removed unused code

* fixed test

* improved refid-handling in loki

* removed unnecessary code

* better variable name

* refactor

* refactor

---------

Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>
2023-06-28 11:51:16 +03:00
Gábor Farkas ebe5e9c2e6 logs: removed unused code (#70758) 2023-06-28 08:35:51 +02:00
Gábor Farkas e9b9a08dd0 logs: handle dataplane-compatible logs-frames (#70318)
* logs: handle dataplane-compatible logs-frames

* simpler tests

* simpler code

* simpler code

* switch to null from undefined

* updated tests

* added test for simplest case

* more direct comparisons

* simplified code

* removed by-mistake added code
2023-06-27 14:50:36 +02:00
Gábor Farkas 8e9ec9dcef Elasticsearch: Make it compatible with the new log context functionality (#70697)
* elastic: make it work with the new logs-context

* add remaining fields

* lint fix
2023-06-27 14:04:29 +02:00
Gábor Farkas 271cdb4baa loki: rename experimental feature flag (#70306) 2023-06-19 10:03:51 +00:00
Gábor Farkas 9d72ed0875 grafana-data: Add frame type for logs dataframes (#69990)
grafana-data: added logs-frame-type
2023-06-16 10:12:46 +02:00
Gábor Farkas 6d82962edf logs: added more tests for logsModel (#69704)
* logs: added tests for logsModel

* renamed test file
2023-06-08 13:14:15 +03:00
Gábor Farkas 4cbe20ca5a logs: context: removed unused code (#69392) 2023-06-01 15:23:30 +00:00
Gábor Farkas e5ec8535ec logs: context: removed unused code (#69383) 2023-06-01 16:38:31 +02:00
Gábor Farkas feb2e8d773 datasource: do not send raw-range to server (#68601) 2023-05-29 15:34:09 +02:00
Gábor Farkas fcef387151 Elasticsearch: Handle no-index case in backend mode (#68534)
* elastic: backend migration: fix no-index case

* improved code
2023-05-17 15:24:46 +02:00
Gábor Farkas 6189f48be7 elastic: more tests (#68533)
* elastic: more tests

* fix lint error
2023-05-16 17:09:09 +02:00
Gábor Farkas 62a660c6f6 devenv:loki faster test-data generation (#68201) 2023-05-10 14:54:50 +03:00
Gábor FarkasandIvana Huckova 903cf3e30d elastic: refactor: simplify query-type handling (#67921)
* elastic: refactor: simplify query-type handling

* improved comment

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>

---------

Co-authored-by: Ivana Huckova <30407135+ivanahuckova@users.noreply.github.com>
2023-05-10 08:50:59 +02:00
Gábor Farkas 8779526f15 elasticsearch: improved deprecation warning (#67909)
* elasticsearch: improved deprecation warning

* adjusted warning-level
2023-05-09 04:42:37 -04:00
Gábor Farkas af9176b3a5 Elasticsearch: Improve query type selection (#63402)
* elastic: display query types explicitly

* fixed test

* fixed test

* updated test names

* fix react-key-issue
2023-05-05 15:00:39 +02:00
Gábor Farkas b10d415569 grafana-data: improved field-config docs (#67696) 2023-05-03 08:34:29 +00:00
Gábor Farkas 236862a07c loki: devenv: add test-data for regexes (#67476) 2023-04-28 09:48:18 +00:00
Gábor Farkas 9b3ddae424 Loki: Enable dataplane-compliant metric data by default (#67137)
loki: enable dataplane-compliant metric data by default
2023-04-25 13:46:07 +03:00
Gábor Farkas 2767d5b1c2 devenv: loki: improved fake data generation (#66966) 2023-04-24 07:50:39 +00:00
Gábor Farkas 53d5a996b8 Elasticsearch: Update required database version to 7.16 (#66928)
elasticsearch: update database requirements
2023-04-21 13:37:04 +02:00
Gábor Farkas 82ac2bae5f Elasticsearch: Handle multiple annotation structures (#66762)
elastic: fix annotation handling
2023-04-20 11:42:25 +02:00
Gábor Farkas bf3ac0ff18 loki: query splitting: labels-based frame matching (#66677) 2023-04-18 12:04:51 +02:00
Gábor Farkas b928fce070 Loki: Remove alpha feature toggle lokiDataframeApi (#65918)
loki: remove experimental feature-flag
2023-04-13 15:22:09 +02:00
Gábor Farkas 531caec602 Loki: Add feature flag to enable dataplane-compliant metric frames (#66017)
* loki: add feature flag to enable dataplane-compatible metric frames

* linter fix
2023-04-13 15:07:08 +02:00
Gábor Farkas 83289065f6 GrafanaData: Remove obsolete logs exports (#66271)
* grafana-data: removed obsolete logs exports

* updated betterer checksums
2023-04-13 13:32:09 +02:00
Gábor FarkasandKyle Brandt 8e03badfa2 Prometheus: Enable converter tests (#66378)
* converter: enable tests

* updated snapshot tests

---------

Co-authored-by: Kyle Brandt <kyle@grafana.com>
2023-04-13 09:10:04 +02:00
Gábor Farkas 18cb2ac9dd GrafanaUI: Remove obsolete logs exports (#66268)
* grafana-ui: removed obsolete logs exports

* updated betterer stats

* updated CODEOWNERS
2023-04-12 15:41:33 +02:00
Gábor Farkas d830591cdc Revert "Prometheus: Reduce allocations parsing exemplars" (#66367)
Revert "Prometheus: Reduce allocations parsing exemplars (#58959)"

This reverts commit a1f2d0e205.
2023-04-12 14:45:21 +02:00
Gábor Farkas 05f7ae6c69 prometheus: slightly different approach for dataplane compatibility (#65993) 2023-04-11 12:58:55 +02:00
Gábor Farkas c4c406aacd DataFrame: Handle nanosecond-precision timestamp fields (#64529)
handle nanosec-precision timestamps
2023-04-06 09:14:21 +02:00
Gábor FarkasandSven Grossmann 4ded937c79 Show traceids for failing and successful requests (#64903)
* tracing: show backend trace ids in frontend

* better trace id naming

Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>

* better trace id naming

Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>

* better trace id naming

Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>

* added feature flag

* bind functionality to the feature flag

* use non-generic name for traceid header

* fixed tests

* loki: do not create empty fields

* do not add empty fields

* fixed graphite test mock data

* added unit-tests to queryResponse

* added unit-tests for backend_srv

* more typescript-friendly check

* added unit-tests for runRequest

---------

Co-authored-by: Sven Grossmann <sven.grossmann@grafana.com>
2023-04-05 09:13:24 +02:00
Gábor Farkas 3ae39ff02b elasticsearch: removed code related to removed esVersion field (#65439)
elastic: remove code that references obsolete json field
2023-04-03 14:47:10 +02:00
Gábor Farkas 609a771874 Revert "elastic: remove most of xpack" (#65596)
Revert "elastic: remove most of xpack (#63460)"

This reverts commit 6cee0cdbad.
2023-03-30 05:30:05 -04:00
Gábor Farkas 0cff917f2a Elasticsearch: Removed reference to obsolete esVersion value (#65415)
* elastic: removed reference to obsolete esVersion value

* removed unused code

* cleaned up tests
2023-03-28 17:04:56 +03:00
Gábor Farkas d73fdcfc11 Elasticsearch: Detect Elasticsearch version (#63341)
* elasticsearch: detect database version

* more test-friendly code
2023-03-28 06:59:39 +00:00
Gábor Farkas 6559971c02 devenv: elastic: remove unnecessary console logging (#65160) 2023-03-22 11:50:45 +01:00
Gábor Farkas 6d5242e54c elasticsearch: backend: better timestamp parsing (#64681)
* elasticsearch: backend: better timestamp parsing

* refactor
2023-03-22 09:52:55 +01:00
Gábor Farkas 335bcd1e4e elasticsearch: more robust field order (#65102) 2023-03-21 12:44:10 +00:00
Gábor FarkasandTodd Treece e1321f8721 elasticsearch: more tests (#64971)
* elasticsearch: more tests

* fix issue with uppercase refID on linux

---------

Co-authored-by: Todd Treece <todd.treece@grafana.com>
2023-03-20 15:50:26 +02:00
Gábor FarkasandMatias Chomicki 5d8ec2756e loki: query chunking: better error handling (#64811)
* loki: query chunking: better error handling

* better comment text

Co-authored-by: Matias Chomicki <matyax@gmail.com>

* better comment text

Co-authored-by: Matias Chomicki <matyax@gmail.com>

* changed merge approach

* simplified code

* fixed test

* removed forgotten code

---------

Co-authored-by: Matias Chomicki <matyax@gmail.com>
2023-03-16 08:54:32 +01:00
Gábor Farkas f76d634ac6 devenv: loki: generate timestamps with various precision (#64509) 2023-03-10 15:09:59 +00:00
Gábor Farkas 3cbeace0ca logs: dedup strategy: fixed order (#64404) 2023-03-09 13:01:49 +01:00
Gábor Farkas 7aca818aae feature flags: assign flags to observability-logs squad (#64380) 2023-03-08 07:42:47 -05:00
Gábor Farkas 192308aac7 loki: query splitting: better stats (#64105) 2023-03-03 04:58:28 -05:00
Gábor Farkas fdc4973b77 loki: query chunking: consider refId when merging frames (#64103) 2023-03-03 10:06:25 +01:00