From fa9c19b831ac6449fec95ea8a158f1b2b58564e9 Mon Sep 17 00:00:00 2001 From: "Grot (@grafanabot)" <43478413+grafanabot@users.noreply.github.com> Date: Thu, 26 May 2022 05:38:04 -0400 Subject: [PATCH] loki: better unpack handling (#49074) (#49673) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit (cherry picked from commit b54817033a4e0942f4c3fb82220da49612d8be1a) Co-authored-by: Gábor Farkas --- public/app/plugins/datasource/loki/syntax.ts | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/public/app/plugins/datasource/loki/syntax.ts b/public/app/plugins/datasource/loki/syntax.ts index 94a5e54dab4..013d7046f5d 100644 --- a/public/app/plugins/datasource/loki/syntax.ts +++ b/public/app/plugins/datasource/loki/syntax.ts @@ -72,6 +72,13 @@ export const PIPE_PARSERS: CompletionItem[] = [ insertText: 'pattern', documentation: 'Extracting labels from the log line using pattern parser. Only available in Loki 2.3+.', }, + { + label: 'unpack', + insertText: 'unpack', + detail: 'unpack identifier', + documentation: + 'Parses a JSON log line, unpacking all embedded labels in the pack stage. A special property "_entry" will also be used to replace the original log line. Only available in Loki 2.2+.', + }, ]; export const PIPE_OPERATORS: CompletionItem[] = [ @@ -82,13 +89,6 @@ export const PIPE_OPERATORS: CompletionItem[] = [ documentation: 'Take labels and use the values as sample data for metric aggregations. Only available in Loki 2.0+.', }, - { - label: 'unpack', - insertText: 'unpack', - detail: 'unpack identifier', - documentation: - 'Parses a JSON log line, unpacking all embedded labels in the pack stage. A special property "_entry" will also be used to replace the original log line. Only available in Loki 2.0+.', - }, { label: 'label_format', insertText: 'label_format',