grafana/pkg/tsdb/azuremonitor/testdata/traces/1-traces-multiple-table.json.multi-trace-as-trace-format.golden.jsonc

559 lines
32 KiB
Plaintext
Raw Normal View History

AzureMonitor: Application Insights Traces (#64859) * Build out barebones Traces editor - Add Traces query type and operation ID prop to query type - Add necessary header types - Update resource picker to appropriately work with traces query type - Build out TracesQueryEditor component - Include logic to retrieve operationId's for AI Workspaces - Add backend route mapping - Update macro to use timestamp as default time field for traces * AzureMonitor: Traces - Response parsing (#65442) * Update FormatAsField component - Add trace ResultFormat type - Generalise FormatAsField component - Add component to TracesQueryEditor - Remove duplicate code in setQueryValue * Add custom filter function to improve performance * Add basic conversion for logs to trace - Add serviceTags converter - Pass through required parameters (queryType and resultFormat) - Appropriately set visualisation * Update parsing to also fill trace tags - Add constant values for each table schema (include legacy mapping for now if needed) - Add constant for list of table tags - Set the foundation for dynamic query building - Update query to build tags value - Appropriately set operationName - Update tagsConverter to filter empty values * Fix lint and test issues * AzureMonitor: Traces - Data links (#65566) * Add portal link for traces - Pull out necessary values (itemId and itemType) - Appropriately construct - Fix ordering * Set default format as value - Also set default visualisation * Fix event schema * Set default formatAsField value * Include logs link on traces results - Adapt config links to allow custom title to be set * Correctly set operationId for query * Update backend types - Include OperationID in query - Pass forward datasource name and UID * Ensure setTime doesn't consistently get called if operationID is defined * Add explore link - Update util functions to allow setting custom datalinks * Fix tests * AzureMonitor: Traces - Query and Editor updates (#66076) * Add initial query - Will query the resource as soon as a resource has been selected - Updates the data links for the query without operationId - Remove initial operationId query and timeRange dependency - Update query building * Add entirely separate traces query property - Update shared types (also including future types for Azure traces) - Update backend log analytics datasource to accept both azureLogAnalytics and azureTraces queries - Update backend specific types - Update frontend datasource for new properties - Update mock query * Update FormatAsField to be entirely generic * Update query building to be done in backend - Add required mappings in backend - Update frontend querying * Fix query and explore data link * Add trace type selection * Better method for setting explore link * Fix operationId updating * Run go mod tidy * Unnecessary changes * Fix tests * AzureMonitor: Traces - Add correlation API support (#65855) Add correlation API support - Add necessary types - Add correlation API request when conditions are met - Update query * Fix property from merge * AzureMonitor: Traces - Filtering (#66303) * Add initial query - Will query the resource as soon as a resource has been selected - Updates the data links for the query without operationId - Remove initial operationId query and timeRange dependency - Update query building * Add entirely separate traces query property - Update shared types (also including future types for Azure traces) - Update backend log analytics datasource to accept both azureLogAnalytics and azureTraces queries - Update backend specific types - Update frontend datasource for new properties - Update mock query * Update FormatAsField to be entirely generic * Update query building to be done in backend - Add required mappings in backend - Update frontend querying * Fix query and explore data link * Add trace type selection * Better method for setting explore link * Fix operationId updating * Run go mod tidy * Unnecessary changes * Fix tests * Start building out Filters component - Configure component to query for Filter property values when a filter property is set - Add setFilters function - Add typing to tablesSchema - Use component in TracesQueryEditor * Update Filters - Asynchronously pull property options - Setup list of Filter components * Update filters component - Remove unused imports - Have local filters state and query filters - Correctly set filters values - Don't update query every time a filter property changes (not performant) * Update properties query - Use current timeRange - Get count to provide informative labels * Reset map when time changes * Add operation selection * Reset filters when property changes * Appropriate label name for empty values * Add filtering to query * Update filter components - Fix rendering issue - Correctly compare and update timeRange - Split out files for simplicity * Add checkbox option to multiselect - Add custom option component - Correctly call onChange - Add variableOptionGroup for template variable selection * Fix adding template vars * Improve labels and refresh labels on query prop changes * AzureMonitor: Traces - Testing (#66474) * Select ds for template variable interpolation * Update az logs ds tests - Add templateVariables test - Add filter test - Update mock - Remove anys * Update QueryEditor test - Update mocks with timeSrv for log analytics datasource - Fix query mock - Use appropriate and consistent selectors * Add TracesQueryEditor test - Update resourcePickerRows mock to include app insights resources - Remove comments and extra new line * Add FormatAsField test - Remove unneeded condition * Update resourcePicker utils test * Don't hide selected options in filters * Fix multi-selection on filters * Add TraceTypeField test - Add test file - Update selectors (remove copy/paste mistake) - Update placeholder text for select and add label * Add basic filters test * Begin filters test * Update filters test * Add final tests and simplify/generalise addFilter helper * Minor update to datasource test * Update macros test * Update selectors in tests * Add response-table-frame tests * Add datasource tests - Use sorting where JSON models are inconsistent - Update filters clause - Dedupe tags - Correct operationId conditions * Don't set a default value for blurInputOnSelect * Simplify datasource test * Update to use CheckGoldenJSON utils - Update with generated frame files - Remove redundant expected frame code - Update all usages * Fix lint * AzureMonitor: Traces feedback (#67292) * Filter traces if the visualisation is set to trace - Update build query logic - Added additional test cases - Return an error if the traces type is set by itself with the trace visualisation - Add descriptions to event types - Update tests * Fix bug for error displaying traces * Update mappings and add error field - Update tests - Remove unnecessary comments * Switch location of Operation ID field * Re-order fields * Update link title * Update label for event type selection * Update correct link title * Update logs datalink to link to Azure Logs in explore * Fix lint
2023-04-27 14:24:11 -05:00
// 🌟 This was machine generated. Do not edit. 🌟
//
// Frame[0] {
// "typeVersion": [
// 0,
// 0
// ],
// "custom": {
// "azureColumnTypes": [
// "string",
// "string",
// "string",
// "real",
// "string",
// "string",
// "datetime",
// "dynamic",
// "dynamic",
// "string",
// "string"
// ]
// }
// }
// Name:
// Dimensions: 11 Fields by 3 Rows
// +----------------------------------+-----------------------------------------+------------------------------------+------------------+-------------------------------------+-------------------------------------+-----------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------+-----------------+
// | Name: traceID | Name: spanID | Name: parentSpanID | Name: duration | Name: serviceName | Name: operationName | Name: startTime | Name: serviceTags | Name: tags | Name: itemId | Name: itemType |
// | Labels: | Labels: | Labels: | Labels: | Labels: | Labels: | Labels: | Labels: | Labels: | Labels: | Labels: |
// | Type: []*string | Type: []*string | Type: []*string | Type: []*float64 | Type: []*string | Type: []*string | Type: []*time.Time | Type: []*json.RawMessage | Type: []*json.RawMessage | Type: []*string | Type: []*string |
// +----------------------------------+-----------------------------------------+------------------------------------+------------------+-------------------------------------+-------------------------------------+-----------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------+-----------------+
// | cfae497bfd7a44169f35643940820938 | b52403c5-5b27-43a8-9bc6-5938667a4470 | |cfae497bfd7a44169f35643940820938. | 0 | | GET /github/grafana/grafana/commits | 2023-04-17 14:58:10.176 +0000 UTC | [{"value":"5000","key":"limit"},{"value":"4351","key":"remaining"},{"value":"1681746512","key":"reset"},{"value":"github-test-data","key":"service"},{"value":"2023-04-17T14:58:10.0000000Z","key":"timestamp"},{"value":"649","key":"used"}] | [{"value":"4ad5a808-11f7-49d5-9713-f6ede83141e4","key":"appId"},{"value":"test-app","key":"appName"},{"value":"1.0.0","key":"application_Version"},{"value":"Dublin","key":"client_City"},{"value":"Ireland","key":"client_CountryOrRegion"},{"value":"0.0.0.0","key":"client_IP"},{"value":"Linux 5.4.0-1036-azure","key":"client_OS"},{"value":"Dublin","key":"client_StateOrProvince"},{"value":"PC","key":"client_Type"},{"value":"test-vm","key":"cloud_RoleInstance"},{"value":"Web","key":"cloud_RoleName"},{"value":{"limit":"5000","remaining":"4351","reset":"1681746512","service":"github-test-data","timestamp":"2023-04-17T14:58:10.0000000Z","used":"649"},"key":"customDimensions"},{"value":0,"key":"duration"},{"value":"195b4fe4-7b01-4814-abca-ffceb1f62c8f","key":"iKey"},{"value":1,"key":"itemCount"},{"value":"65863e6b-dd30-11ed-a808-002248268105","key":"itemId"},{"value":"trace","key":"itemType"},{"value":"github commits rate limiting info","key":"message"},{"value":"cfae497bfd7a44169f35643940820938","key":"operation_Id"},{"value":"GET /github/grafana/grafana/commits","key":"operation_Name"},{"value":"|cfae497bfd7a44169f35643940820938.","key":"operation_ParentId"},{"value":"node:1.8.9","key":"sdkVersion"},{"value":1,"key":"severityLevel"},{"value":"2023-04-17T14:58:10.1760000Z","key":"timestamp"}] | 65863e6b-dd30-11ed-a808-002248268105 | trace |
// | e766f18a0adc49418d297b1a244f1bfb | |e766f18a0adc49418d297b1a244f1bfb.1901. | |e766f18a0adc49418d297b1a244f1bfb. | 330 | GET /repos/grafana/grafana/commits | GET /github/grafana/grafana/commits | 2023-04-17 14:58:10.764 +0000 UTC | null | [{"value":"4ad5a808-11f7-49d5-9713-f6ede83141e4","key":"appId"},{"value":"test-app","key":"appName"},{"value":"1.0.0","key":"application_Version"},{"value":"Dublin","key":"client_City"},{"value":"Ireland","key":"client_CountryOrRegion"},{"value":"0.0.0.0","key":"client_IP"},{"value":"Linux 5.4.0-1036-azure","key":"client_OS"},{"value":"Dublin","key":"client_StateOrProvince"},{"value":"PC","key":"client_Type"},{"value":"test-vm","key":"cloud_RoleInstance"},{"value":"Web","key":"cloud_RoleName"},{"value":"https://api.github.com/repos/grafana/grafana/commits","key":"data"},{"value":330,"key":"duration"},{"value":"195b4fe4-7b01-4814-abca-ffceb1f62c8f","key":"iKey"},{"value":"|e766f18a0adc49418d297b1a244f1bfb.1901.","key":"id"},{"value":1,"key":"itemCount"},{"value":"78c1bcf4-dd30-11ed-a808-0022481f7f28","key":"itemId"},{"value":"dependency","key":"itemType"},{"value":"GET /repos/grafana/grafana/commits","key":"name"},{"value":"e766f18a0adc49418d297b1a244f1bfb","key":"operation_Id"},{"value":"GET /github/grafana/grafana/commits","key":"operation_Name"},{"value":"|e766f18a0adc49418d297b1a244f1bfb.","key":"operation_ParentId"},{"value":"250ms-500ms","key":"performanceBucket"},{"value":"200","key":"resultCode"},{"value":"node:1.8.9","key":"sdkVersion"},{"value":"True","key":"success"},{"value":"api.github.com","key":"target"},{"value":"2023-04-17T14:58:10.7640000Z","key":"timestamp"},{"value":"HTTP","key":"type"}] | 78c1bcf4-dd30-11ed-a808-0022481f7f28 | dependency |
// | b1f0047386554fa59b7c5330560a0799 | |b1f0047386554fa59b7c5330560a0799. | b1f0047386554fa59b7c5330560a0799 | 352 | GET /github/grafana/grafana/commits | GET /github/grafana/grafana/commits | 2023-04-17 14:58:11.579 +0000 UTC | null | [{"value":"4ad5a808-11f7-49d5-9713-f6ede83141e4","key":"appId"},{"value":"test-app","key":"appName"},{"value":"1.0.0","key":"application_Version"},{"value":"0.0.0.0","key":"client_IP"},{"value":"Linux 5.4.0-1036-azure","key":"client_OS"},{"value":"PC","key":"client_Type"},{"value":"test-vm","key":"cloud_RoleInstance"},{"value":"Web","key":"cloud_RoleName"},{"value":352,"key":"duration"},{"value":"195b4fe4-7b01-4814-abca-ffceb1f62c8f","key":"iKey"},{"value":"|b1f0047386554fa59b7c5330560a0799.","key":"id"},{"value":1,"key":"itemCount"},{"value":"5c126241-dd30-11ed-a80a-00224826882d","key":"itemId"},{"value":"request","key":"itemType"},{"value":"GET /github/grafana/grafana/commits","key":"name"},{"value":"b1f0047386554fa59b7c5330560a0799","key":"operation_Id"},{"value":"GET /github/grafana/grafana/commits","key":"operation_Name"},{"value":"b1f0047386554fa59b7c5330560a0799","key":"operation_ParentId"},{"value":"250ms-500ms","key":"performanceBucket"},{"value":"200","key":"resultCode"},{"value":"node:1.8.9","key":"sdkVersion"},{"value":"True","key":"success"},{"value":"2023-04-17T14:58:11.5790000Z","key":"timestamp"},{"value":"test-url","key":"url"}] | 5c126241-dd30-11ed-a80a-00224826882d | request |
// +----------------------------------+-----------------------------------------+------------------------------------+------------------+-------------------------------------+-------------------------------------+-----------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+--------------------------------------+-----------------+
//
//
// 🌟 This was machine generated. Do not edit. 🌟
{
"status": 200,
"frames": [
{
"schema": {
"meta": {
"typeVersion": [
0,
0
],
"custom": {
"azureColumnTypes": [
"string",
"string",
"string",
"real",
"string",
"string",
"datetime",
"dynamic",
"dynamic",
"string",
"string"
]
}
},
"fields": [
{
"name": "traceID",
"type": "string",
"typeInfo": {
"frame": "string",
"nullable": true
}
},
{
"name": "spanID",
"type": "string",
"typeInfo": {
"frame": "string",
"nullable": true
}
},
{
"name": "parentSpanID",
"type": "string",
"typeInfo": {
"frame": "string",
"nullable": true
}
},
{
"name": "duration",
"type": "number",
"typeInfo": {
"frame": "float64",
"nullable": true
}
},
{
"name": "serviceName",
"type": "string",
"typeInfo": {
"frame": "string",
"nullable": true
}
},
{
"name": "operationName",
"type": "string",
"typeInfo": {
"frame": "string",
"nullable": true
}
},
{
"name": "startTime",
"type": "time",
"typeInfo": {
"frame": "time.Time",
"nullable": true
}
},
{
"name": "serviceTags",
"type": "other",
"typeInfo": {
"frame": "json.RawMessage",
"nullable": true
}
},
{
"name": "tags",
"type": "other",
"typeInfo": {
"frame": "json.RawMessage",
"nullable": true
}
},
{
"name": "itemId",
"type": "string",
"typeInfo": {
"frame": "string",
"nullable": true
}
},
{
"name": "itemType",
"type": "string",
"typeInfo": {
"frame": "string",
"nullable": true
}
}
]
},
"data": {
"values": [
[
"cfae497bfd7a44169f35643940820938",
"e766f18a0adc49418d297b1a244f1bfb",
"b1f0047386554fa59b7c5330560a0799"
],
[
"b52403c5-5b27-43a8-9bc6-5938667a4470",
"|e766f18a0adc49418d297b1a244f1bfb.1901.",
"|b1f0047386554fa59b7c5330560a0799."
],
[
"|cfae497bfd7a44169f35643940820938.",
"|e766f18a0adc49418d297b1a244f1bfb.",
"b1f0047386554fa59b7c5330560a0799"
],
[
0,
330,
352
],
[
"",
"GET /repos/grafana/grafana/commits",
"GET /github/grafana/grafana/commits"
],
[
"GET /github/grafana/grafana/commits",
"GET /github/grafana/grafana/commits",
"GET /github/grafana/grafana/commits"
],
[
1681743490176,
1681743490764,
1681743491579
],
[
[
{
"value": "5000",
"key": "limit"
},
{
"value": "4351",
"key": "remaining"
},
{
"value": "1681746512",
"key": "reset"
},
{
"value": "github-test-data",
"key": "service"
},
{
"value": "2023-04-17T14:58:10.0000000Z",
"key": "timestamp"
},
{
"value": "649",
"key": "used"
}
],
null,
null
],
[
[
{
"value": "4ad5a808-11f7-49d5-9713-f6ede83141e4",
"key": "appId"
},
{
"value": "test-app",
"key": "appName"
},
{
"value": "1.0.0",
"key": "application_Version"
},
{
"value": "Dublin",
"key": "client_City"
},
{
"value": "Ireland",
"key": "client_CountryOrRegion"
},
{
"value": "0.0.0.0",
"key": "client_IP"
},
{
"value": "Linux 5.4.0-1036-azure",
"key": "client_OS"
},
{
"value": "Dublin",
"key": "client_StateOrProvince"
},
{
"value": "PC",
"key": "client_Type"
},
{
"value": "test-vm",
"key": "cloud_RoleInstance"
},
{
"value": "Web",
"key": "cloud_RoleName"
},
{
"value": {
"limit": "5000",
"remaining": "4351",
"reset": "1681746512",
"service": "github-test-data",
"timestamp": "2023-04-17T14:58:10.0000000Z",
"used": "649"
},
"key": "customDimensions"
},
{
"value": 0,
"key": "duration"
},
{
"value": "195b4fe4-7b01-4814-abca-ffceb1f62c8f",
"key": "iKey"
},
{
"value": 1,
"key": "itemCount"
},
{
"value": "65863e6b-dd30-11ed-a808-002248268105",
"key": "itemId"
},
{
"value": "trace",
"key": "itemType"
},
{
"value": "github commits rate limiting info",
"key": "message"
},
{
"value": "cfae497bfd7a44169f35643940820938",
"key": "operation_Id"
},
{
"value": "GET /github/grafana/grafana/commits",
"key": "operation_Name"
},
{
"value": "|cfae497bfd7a44169f35643940820938.",
"key": "operation_ParentId"
},
{
"value": "node:1.8.9",
"key": "sdkVersion"
},
{
"value": 1,
"key": "severityLevel"
},
{
"value": "2023-04-17T14:58:10.1760000Z",
"key": "timestamp"
}
],
[
{
"value": "4ad5a808-11f7-49d5-9713-f6ede83141e4",
"key": "appId"
},
{
"value": "test-app",
"key": "appName"
},
{
"value": "1.0.0",
"key": "application_Version"
},
{
"value": "Dublin",
"key": "client_City"
},
{
"value": "Ireland",
"key": "client_CountryOrRegion"
},
{
"value": "0.0.0.0",
"key": "client_IP"
},
{
"value": "Linux 5.4.0-1036-azure",
"key": "client_OS"
},
{
"value": "Dublin",
"key": "client_StateOrProvince"
},
{
"value": "PC",
"key": "client_Type"
},
{
"value": "test-vm",
"key": "cloud_RoleInstance"
},
{
"value": "Web",
"key": "cloud_RoleName"
},
{
"value": "https://api.github.com/repos/grafana/grafana/commits",
"key": "data"
},
{
"value": 330,
"key": "duration"
},
{
"value": "195b4fe4-7b01-4814-abca-ffceb1f62c8f",
"key": "iKey"
},
{
"value": "|e766f18a0adc49418d297b1a244f1bfb.1901.",
"key": "id"
},
{
"value": 1,
"key": "itemCount"
},
{
"value": "78c1bcf4-dd30-11ed-a808-0022481f7f28",
"key": "itemId"
},
{
"value": "dependency",
"key": "itemType"
},
{
"value": "GET /repos/grafana/grafana/commits",
"key": "name"
},
{
"value": "e766f18a0adc49418d297b1a244f1bfb",
"key": "operation_Id"
},
{
"value": "GET /github/grafana/grafana/commits",
"key": "operation_Name"
},
{
"value": "|e766f18a0adc49418d297b1a244f1bfb.",
"key": "operation_ParentId"
},
{
"value": "250ms-500ms",
"key": "performanceBucket"
},
{
"value": "200",
"key": "resultCode"
},
{
"value": "node:1.8.9",
"key": "sdkVersion"
},
{
"value": "True",
"key": "success"
},
{
"value": "api.github.com",
"key": "target"
},
{
"value": "2023-04-17T14:58:10.7640000Z",
"key": "timestamp"
},
{
"value": "HTTP",
"key": "type"
}
],
[
{
"value": "4ad5a808-11f7-49d5-9713-f6ede83141e4",
"key": "appId"
},
{
"value": "test-app",
"key": "appName"
},
{
"value": "1.0.0",
"key": "application_Version"
},
{
"value": "0.0.0.0",
"key": "client_IP"
},
{
"value": "Linux 5.4.0-1036-azure",
"key": "client_OS"
},
{
"value": "PC",
"key": "client_Type"
},
{
"value": "test-vm",
"key": "cloud_RoleInstance"
},
{
"value": "Web",
"key": "cloud_RoleName"
},
{
"value": 352,
"key": "duration"
},
{
"value": "195b4fe4-7b01-4814-abca-ffceb1f62c8f",
"key": "iKey"
},
{
"value": "|b1f0047386554fa59b7c5330560a0799.",
"key": "id"
},
{
"value": 1,
"key": "itemCount"
},
{
"value": "5c126241-dd30-11ed-a80a-00224826882d",
"key": "itemId"
},
{
"value": "request",
"key": "itemType"
},
{
"value": "GET /github/grafana/grafana/commits",
"key": "name"
},
{
"value": "b1f0047386554fa59b7c5330560a0799",
"key": "operation_Id"
},
{
"value": "GET /github/grafana/grafana/commits",
"key": "operation_Name"
},
{
"value": "b1f0047386554fa59b7c5330560a0799",
"key": "operation_ParentId"
},
{
"value": "250ms-500ms",
"key": "performanceBucket"
},
{
"value": "200",
"key": "resultCode"
},
{
"value": "node:1.8.9",
"key": "sdkVersion"
},
{
"value": "True",
"key": "success"
},
{
"value": "2023-04-17T14:58:11.5790000Z",
"key": "timestamp"
},
{
"value": "test-url",
"key": "url"
}
]
],
[
"65863e6b-dd30-11ed-a808-002248268105",
"78c1bcf4-dd30-11ed-a808-0022481f7f28",
"5c126241-dd30-11ed-a80a-00224826882d"
],
[
"trace",
"dependency",
"request"
]
]
}
}
]
}