Trace View: Remove "deployment.environment" default traces 2 logs tag (#74986)
* Remove deployment.environment default tag * format * remove mentions from docs
This commit is contained in:
@@ -110,16 +110,16 @@ To use a variable you need to wrap it in `${}`. For example: `${__span.name}`.
|
|||||||
|
|
||||||
The following table describes the ways in which you can configure your trace to logs settings:
|
The following table describes the ways in which you can configure your trace to logs settings:
|
||||||
|
|
||||||
| Setting name | Description |
|
| Setting name | Description |
|
||||||
| ------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
||||||
| **Data source** | Defines the target data source. You can select only Loki or Splunk \[logs\] data sources. |
|
| **Data source** | Defines the target data source. You can select only Loki or Splunk \[logs\] data sources. |
|
||||||
| **Span start time shift** | Shifts the start time for the logs query, based on the span's start time. You can use time units, such as `5s`, `1m`, `3h`. To extend the time to the past, use a negative value. Default: `0`. |
|
| **Span start time shift** | Shifts the start time for the logs query, based on the span's start time. You can use time units, such as `5s`, `1m`, `3h`. To extend the time to the past, use a negative value. Default: `0`. |
|
||||||
| **Span end time shift** | Shifts the end time for the logs query, based on the span's end time. You can use time units. Default: `0`. |
|
| **Span end time shift** | Shifts the end time for the logs query, based on the span's end time. You can use time units. Default: `0`. |
|
||||||
| **Tags** | Defines the tags to use in the logs query. Default: `cluster`, `hostname`, `namespace`, `pod`, `service.name`, `service.namespace`, `deployment.environment`. You can change the tag name for example to remove dots from the name if they are not allowed in the target data source. For example, map `http.status` to `http_status`. |
|
| **Tags** | Defines the tags to use in the logs query. Default: `cluster`, `hostname`, `namespace`, `pod`, `service.name`, `service.namespace`. You can change the tag name for example to remove dots from the name if they are not allowed in the target data source. For example, map `http.status` to `http_status`. |
|
||||||
| **Filter by trace ID** | Toggles whether to append the trace ID to the logs query. |
|
| **Filter by trace ID** | Toggles whether to append the trace ID to the logs query. |
|
||||||
| **Filter by span ID** | Toggles whether to append the span ID to the logs query. |
|
| **Filter by span ID** | Toggles whether to append the span ID to the logs query. |
|
||||||
| **Use custom query** | Toggles use of custom query with interpolation. |
|
| **Use custom query** | Toggles use of custom query with interpolation. |
|
||||||
| **Query** | Input to write custom query. Use variable interpolation to customize it with variables from span. |
|
| **Query** | Input to write custom query. Use variable interpolation to customize it with variables from span. |
|
||||||
|
|
||||||
### Trace to metrics
|
### Trace to metrics
|
||||||
|
|
||||||
|
|||||||
@@ -93,16 +93,16 @@ To use a variable you need to wrap it in `${}`. For example `${__span.name}`.
|
|||||||
|
|
||||||
The following table describes the ways in which you can configure your trace to logs settings:
|
The following table describes the ways in which you can configure your trace to logs settings:
|
||||||
|
|
||||||
| Setting name | Description |
|
| Setting name | Description |
|
||||||
| ------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
||||||
| **Data source** | Defines the target data source. You can select only Loki or Splunk \[logs\] data sources. |
|
| **Data source** | Defines the target data source. You can select only Loki or Splunk \[logs\] data sources. |
|
||||||
| **Span start time shift** | Shifts the start time for the logs query, based on the span's start time. You can use time units, such as `5s`, `1m`, `3h`. To extend the time to the past, use a negative value. Default: `0`. |
|
| **Span start time shift** | Shifts the start time for the logs query, based on the span's start time. You can use time units, such as `5s`, `1m`, `3h`. To extend the time to the past, use a negative value. Default: `0`. |
|
||||||
| **Span end time shift** | Shifts the end time for the logs query, based on the span's end time. You can use time units. Default: `0`. |
|
| **Span end time shift** | Shifts the end time for the logs query, based on the span's end time. You can use time units. Default: `0`. |
|
||||||
| **Tags** | Defines the tags to use in the logs query. Default: `cluster`, `hostname`, `namespace`, `pod`, `service.name`, `service.namespace`, `deployment.environment`. You can change the tag name for example to remove dots from the name if they are not allowed in the target data source. For example, map `http.status` to `http_status`. |
|
| **Tags** | Defines the tags to use in the logs query. Default: `cluster`, `hostname`, `namespace`, `pod`, `service.name`, `service.namespace`. You can change the tag name for example to remove dots from the name if they are not allowed in the target data source. For example, map `http.status` to `http_status`. |
|
||||||
| **Filter by trace ID** | Toggles whether to append the trace ID to the logs query. |
|
| **Filter by trace ID** | Toggles whether to append the trace ID to the logs query. |
|
||||||
| **Filter by span ID** | Toggles whether to append the span ID to the logs query. |
|
| **Filter by span ID** | Toggles whether to append the span ID to the logs query. |
|
||||||
| **Use custom query** | Toggles use of custom query with interpolation. |
|
| **Use custom query** | Toggles use of custom query with interpolation. |
|
||||||
| **Query** | Input to write custom query. Use variable interpolation to customize it with variables from span. |
|
| **Query** | Input to write custom query. Use variable interpolation to customize it with variables from span. |
|
||||||
|
|
||||||
## Trace to metrics
|
## Trace to metrics
|
||||||
|
|
||||||
|
|||||||
@@ -108,16 +108,16 @@ To use a variable you need to wrap it in `${}`. For example `${__span.name}`.
|
|||||||
|
|
||||||
The following table describes the ways in which you can configure your trace to logs settings:
|
The following table describes the ways in which you can configure your trace to logs settings:
|
||||||
|
|
||||||
| Setting name | Description |
|
| Setting name | Description |
|
||||||
| ------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
| ------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
||||||
| **Data source** | Defines the target data source. You can select only Loki or Splunk \[logs\] data sources. |
|
| **Data source** | Defines the target data source. You can select only Loki or Splunk \[logs\] data sources. |
|
||||||
| **Span start time shift** | Shifts the start time for the logs query, based on the span's start time. You can use time units, such as `5s`, `1m`, `3h`. To extend the time to the past, use a negative value. Default: `0`. |
|
| **Span start time shift** | Shifts the start time for the logs query, based on the span's start time. You can use time units, such as `5s`, `1m`, `3h`. To extend the time to the past, use a negative value. Default: `0`. |
|
||||||
| **Span end time shift** | Shifts the end time for the logs query, based on the span's end time. You can use time units. Default: `0`. |
|
| **Span end time shift** | Shifts the end time for the logs query, based on the span's end time. You can use time units. Default: `0`. |
|
||||||
| **Tags** | Defines the tags to use in the logs query. Default: `cluster`, `hostname`, `namespace`, `pod`, `service.name`, `service.namespace`, `deployment.environment`. You can change the tag name for example to remove dots from the name if they are not allowed in the target data source. For example, map `http.status` to `http_status`. |
|
| **Tags** | Defines the tags to use in the logs query. Default: `cluster`, `hostname`, `namespace`, `pod`, `service.name`, `service.namespace`. You can change the tag name for example to remove dots from the name if they are not allowed in the target data source. For example, map `http.status` to `http_status`. |
|
||||||
| **Filter by trace ID** | Toggles whether to append the trace ID to the logs query. |
|
| **Filter by trace ID** | Toggles whether to append the trace ID to the logs query. |
|
||||||
| **Filter by span ID** | Toggles whether to append the span ID to the logs query. |
|
| **Filter by span ID** | Toggles whether to append the span ID to the logs query. |
|
||||||
| **Use custom query** | Toggles use of custom query with interpolation. |
|
| **Use custom query** | Toggles use of custom query with interpolation. |
|
||||||
| **Query** | Input to write custom query. Use variable interpolation to customize it with variables from span. |
|
| **Query** | Input to write custom query. Use variable interpolation to customize it with variables from span. |
|
||||||
|
|
||||||
### Trace to metrics
|
### Trace to metrics
|
||||||
|
|
||||||
|
|||||||
@@ -156,7 +156,7 @@ export function TraceToLogsSettings({ options, onOptionsChange }: Props) {
|
|||||||
|
|
||||||
<InlineFieldRow>
|
<InlineFieldRow>
|
||||||
<InlineField
|
<InlineField
|
||||||
tooltip="Tags that will be used in the query. Default tags: 'cluster', 'hostname', 'namespace', 'pod', 'service.name', 'service.namespace', 'deployment.environment'"
|
tooltip="Tags that will be used in the query. Default tags: 'cluster', 'hostname', 'namespace', 'pod', 'service.name', 'service.namespace'"
|
||||||
label="Tags"
|
label="Tags"
|
||||||
labelWidth={26}
|
labelWidth={26}
|
||||||
>
|
>
|
||||||
|
|||||||
@@ -115,15 +115,7 @@ export function createSpanLinkFactory({
|
|||||||
/**
|
/**
|
||||||
* Default keys to use when there are no configured tags.
|
* Default keys to use when there are no configured tags.
|
||||||
*/
|
*/
|
||||||
const defaultKeys = [
|
const defaultKeys = ['cluster', 'hostname', 'namespace', 'pod', 'service.name', 'service.namespace'].map((k) => ({
|
||||||
'cluster',
|
|
||||||
'hostname',
|
|
||||||
'namespace',
|
|
||||||
'pod',
|
|
||||||
'service.name',
|
|
||||||
'service.namespace',
|
|
||||||
'deployment.environment',
|
|
||||||
].map((k) => ({
|
|
||||||
key: k,
|
key: k,
|
||||||
value: k.includes('.') ? k.replace('.', '_') : undefined,
|
value: k.includes('.') ? k.replace('.', '_') : undefined,
|
||||||
}));
|
}));
|
||||||
|
|||||||
Reference in New Issue
Block a user