-
Notifications
You must be signed in to change notification settings - Fork 84
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
(cherry picked from commit 10e3a0a) Co-authored-by: Lisa Cawley <lcawley@elastic.co>
- Loading branch information
1 parent
9ed4eec
commit b4a73f1
Showing
14 changed files
with
616 additions
and
77 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
65 changes: 65 additions & 0 deletions
65
..._structure/find_field_structure/examples/response/FindFieldStructureResponseExample1.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
# summary: | ||
description: A successful response from `GET _text_structure/find_field_structure?index=test-logs&field=message`. | ||
# type: response | ||
# response_code: '' | ||
value: | ||
"{\n \"num_lines_analyzed\" : 22,\n \"num_messages_analyzed\" : 22,\n \"\ | ||
sample_start\" : \"[2024-03-05T10:52:36,256][INFO ][o.a.l.u.VectorUtilPanamaProvider]\ | ||
\ [laptop] Java vector incubator API enabled; uses preferredBitSize=128\\n[2024-03-05T10:52:41,038][INFO\ | ||
\ ][o.e.p.PluginsService ] [laptop] loaded module [repository-url]\\n\",\n \ | ||
\ \"charset\" : \"UTF-8\",\n \"format\" : \"semi_structured_text\",\n \"multiline_start_pattern\"\ | ||
\ : \"^\\\\[\\\\b\\\\d{4}-\\\\d{2}-\\\\d{2}[T ]\\\\d{2}:\\\\d{2}\",\n \"grok_pattern\"\ | ||
\ : \"\\\\[%{TIMESTAMP_ISO8601:timestamp}\\\\]\\\\[%{LOGLEVEL:loglevel} \\\\]\\\\\ | ||
[.*\",\n \"ecs_compatibility\" : \"disabled\",\n \"timestamp_field\" : \"timestamp\"\ | ||
,\n \"joda_timestamp_formats\" : [\n \"ISO8601\"\n ],\n \"java_timestamp_formats\"\ | ||
\ : [\n \"ISO8601\"\n ],\n \"need_client_timezone\" : true,\n \"mappings\"\ | ||
\ : {\n \"properties\" : {\n \"@timestamp\" : {\n \"type\" : \"date\"\ | ||
\n },\n \"loglevel\" : {\n \"type\" : \"keyword\"\n },\n \ | ||
\ \"message\" : {\n \"type\" : \"text\"\n }\n }\n },\n \"ingest_pipeline\"\ | ||
\ : {\n \"description\" : \"Ingest pipeline created by text structure finder\"\ | ||
,\n \"processors\" : [\n {\n \"grok\" : {\n \"field\" :\ | ||
\ \"message\",\n \"patterns\" : [\n \"\\\\[%{TIMESTAMP_ISO8601:timestamp}\\\ | ||
\\]\\\\[%{LOGLEVEL:loglevel} \\\\]\\\\[.*\"\n ],\n \"ecs_compatibility\"\ | ||
\ : \"disabled\"\n }\n },\n {\n \"date\" : {\n \ | ||
\ \"field\" : \"timestamp\",\n \"timezone\" : \"{{ event.timezone }}\"\ | ||
,\n \"formats\" : [\n \"ISO8601\"\n ]\n }\n\ | ||
\ },\n {\n \"remove\" : {\n \"field\" : \"timestamp\"\n\ | ||
\ }\n }\n ]\n },\n \"field_stats\" : {\n \"loglevel\" : {\n\ | ||
\ \"count\" : 22,\n \"cardinality\" : 1,\n \"top_hits\" : [\n \ | ||
\ {\n \"value\" : \"INFO\",\n \"count\" : 22\n }\n\ | ||
\ ]\n },\n \"message\" : {\n \"count\" : 22,\n \"cardinality\"\ | ||
\ : 22,\n \"top_hits\" : [\n {\n \"value\" : \"[2024-03-05T10:52:36,256][INFO\ | ||
\ ][o.a.l.u.VectorUtilPanamaProvider] [laptop] Java vector incubator API enabled;\ | ||
\ uses preferredBitSize=128\",\n \"count\" : 1\n },\n {\n\ | ||
\ \"value\" : \"[2024-03-05T10:52:41,038][INFO ][o.e.p.PluginsService \ | ||
\ ] [laptop] loaded module [repository-url]\",\n \"count\" : 1\n \ | ||
\ },\n {\n \"value\" : \"[2024-03-05T10:52:41,042][INFO ][o.e.p.PluginsService\ | ||
\ ] [laptop] loaded module [rest-root]\",\n \"count\" : 1\n \ | ||
\ },\n {\n \"value\" : \"[2024-03-05T10:52:41,043][INFO ][o.e.p.PluginsService\ | ||
\ ] [laptop] loaded module [ingest-user-agent]\",\n \"count\" : 1\n\ | ||
\ },\n {\n \"value\" : \"[2024-03-05T10:52:41,043][INFO ][o.e.p.PluginsService\ | ||
\ ] [laptop] loaded module [x-pack-core]\",\n \"count\" : 1\n \ | ||
\ },\n {\n \"value\" : \"[2024-03-05T10:52:41,043][INFO ][o.e.p.PluginsService\ | ||
\ ] [laptop] loaded module [x-pack-redact]\",\n \"count\" : 1\n \ | ||
\ },\n {\n \"value\" : \"[2024-03-05T10:52:41,044][INFO ][o.e.p.PluginsService\ | ||
\ ] [laptop] loaded module [lang-painless]]\",\n \"count\" : 1\n \ | ||
\ },\n {\n \"value\" : \"[2024-03-05T10:52:41,044][INFO ][o.e.p.PluginsService\ | ||
\ ] [laptop] loaded module [repository-s3]\",\n \"count\" : 1\n \ | ||
\ },\n {\n \"value\" : \"[2024-03-05T10:52:41,044][INFO ][o.e.p.PluginsService\ | ||
\ ] [laptop] loaded module [x-pack-analytics]\",\n \"count\" : 1\n\ | ||
\ },\n {\n \"value\" : \"[2024-03-05T10:52:41,044][INFO ][o.e.p.PluginsService\ | ||
\ ] [laptop] loaded module [x-pack-autoscaling]\",\n \"count\" : 1\n\ | ||
\ }\n ]\n },\n \"timestamp\" : {\n \"count\" : 22,\n \ | ||
\ \"cardinality\" : 14,\n \"earliest\" : \"2024-03-05T10:52:36,256\",\n \ | ||
\ \"latest\" : \"2024-03-05T10:52:49,199\",\n \"top_hits\" : [\n \ | ||
\ {\n \"value\" : \"2024-03-05T10:52:41,044\",\n \"count\" : 6\n\ | ||
\ },\n {\n \"value\" : \"2024-03-05T10:52:41,043\",\n \ | ||
\ \"count\" : 3\n },\n {\n \"value\" : \"2024-03-05T10:52:41,059\"\ | ||
,\n \"count\" : 2\n },\n {\n \"value\" : \"2024-03-05T10:52:36,256\"\ | ||
,\n \"count\" : 1\n },\n {\n \"value\" : \"2024-03-05T10:52:41,038\"\ | ||
,\n \"count\" : 1\n },\n {\n \"value\" : \"2024-03-05T10:52:41,042\"\ | ||
,\n \"count\" : 1\n },\n {\n \"value\" : \"2024-03-05T10:52:43,291\"\ | ||
,\n \"count\" : 1\n },\n {\n \"value\" : \"2024-03-05T10:52:46,098\"\ | ||
,\n \"count\" : 1\n },\n {\n \"value\" : \"2024-03-05T10:52:47,227\"\ | ||
,\n \"count\" : 1\n },\n {\n \"value\" : \"2024-03-05T10:52:47,259\"\ | ||
,\n \"count\" : 1\n }\n ]\n }\n }\n}" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
36 changes: 36 additions & 0 deletions
36
...tructure/find_message_structure/examples/request/FindMessageStructureRequestExample1.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# summary: | ||
# method_request: POST _text_structure/find_message_structure | ||
description: > | ||
Run `POST _text_structure/find_message_structure` to analyze Elasticsearch log files. | ||
# type: request | ||
value: | ||
"{\n \"messages\": [\n \"[2024-03-05T10:52:36,256][INFO ][o.a.l.u.VectorUtilPanamaProvider]\ | ||
\ [laptop] Java vector incubator API enabled; uses preferredBitSize=128\",\n \ | ||
\ \"[2024-03-05T10:52:41,038][INFO ][o.e.p.PluginsService ] [laptop] loaded\ | ||
\ module [repository-url]\",\n \"[2024-03-05T10:52:41,042][INFO ][o.e.p.PluginsService\ | ||
\ ] [laptop] loaded module [rest-root]\",\n \"[2024-03-05T10:52:41,043][INFO\ | ||
\ ][o.e.p.PluginsService ] [laptop] loaded module [x-pack-core]\",\n \"[2024-03-05T10:52:41,043][INFO\ | ||
\ ][o.e.p.PluginsService ] [laptop] loaded module [x-pack-redact]\",\n \"\ | ||
[2024-03-05T10:52:41,043][INFO ][o.e.p.PluginsService ] [laptop] loaded module\ | ||
\ [ingest-user-agent]\",\n \"[2024-03-05T10:52:41,044][INFO ][o.e.p.PluginsService\ | ||
\ ] [laptop] loaded module [x-pack-monitoring]\",\n \"[2024-03-05T10:52:41,044][INFO\ | ||
\ ][o.e.p.PluginsService ] [laptop] loaded module [repository-s3]\",\n \"\ | ||
[2024-03-05T10:52:41,044][INFO ][o.e.p.PluginsService ] [laptop] loaded module\ | ||
\ [x-pack-analytics]\",\n \"[2024-03-05T10:52:41,044][INFO ][o.e.p.PluginsService\ | ||
\ ] [laptop] loaded module [x-pack-ent-search]\",\n \"[2024-03-05T10:52:41,044][INFO\ | ||
\ ][o.e.p.PluginsService ] [laptop] loaded module [x-pack-autoscaling]\",\n\ | ||
\ \"[2024-03-05T10:52:41,044][INFO ][o.e.p.PluginsService ] [laptop] loaded\ | ||
\ module [lang-painless]]\",\n \"[2024-03-05T10:52:41,059][INFO ][o.e.p.PluginsService\ | ||
\ ] [laptop] loaded module [lang-expression]\",\n \"[2024-03-05T10:52:41,059][INFO\ | ||
\ ][o.e.p.PluginsService ] [laptop] loaded module [x-pack-eql]\",\n \"[2024-03-05T10:52:43,291][INFO\ | ||
\ ][o.e.e.NodeEnvironment ] [laptop] heap size [16gb], compressed ordinary object\ | ||
\ pointers [true]\",\n \"[2024-03-05T10:52:46,098][INFO ][o.e.x.s.Security \ | ||
\ ] [laptop] Security is enabled\",\n \"[2024-03-05T10:52:47,227][INFO\ | ||
\ ][o.e.x.p.ProfilingPlugin ] [laptop] Profiling is enabled\",\n \"[2024-03-05T10:52:47,259][INFO\ | ||
\ ][o.e.x.p.ProfilingPlugin ] [laptop] profiling index templates will not be installed\ | ||
\ or reinstalled\",\n \"[2024-03-05T10:52:47,755][INFO ][o.e.i.r.RecoverySettings\ | ||
\ ] [laptop] using rate limit [40mb] with [default=40mb, read=0b, write=0b, max=0b]\"\ | ||
,\n \"[2024-03-05T10:52:47,787][INFO ][o.e.d.DiscoveryModule ] [laptop] using\ | ||
\ discovery type [multi-node] and seed hosts providers [settings]\",\n \"[2024-03-05T10:52:49,188][INFO\ | ||
\ ][o.e.n.Node ] [laptop] initialized\",\n \"[2024-03-05T10:52:49,199][INFO\ | ||
\ ][o.e.n.Node ] [laptop] starting ...\"\n ]\n}" |
65 changes: 65 additions & 0 deletions
65
...ucture/find_message_structure/examples/response/FindMessageStructureResponseExample1.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,65 @@ | ||
# summary: | ||
description: A successful response from `POST _text_structure/find_message_structure`. | ||
# type: response | ||
# response_code: '' | ||
value: | ||
"{\n \"num_lines_analyzed\" : 22,\n \"num_messages_analyzed\" : 22,\n \"\ | ||
sample_start\" : \"[2024-03-05T10:52:36,256][INFO ][o.a.l.u.VectorUtilPanamaProvider]\ | ||
\ [laptop] Java vector incubator API enabled; uses preferredBitSize=128\\n[2024-03-05T10:52:41,038][INFO\ | ||
\ ][o.e.p.PluginsService ] [laptop] loaded module [repository-url]\\n\",\n \ | ||
\ \"charset\" : \"UTF-8\",\n \"format\" : \"semi_structured_text\",\n \"multiline_start_pattern\"\ | ||
\ : \"^\\\\[\\\\b\\\\d{4}-\\\\d{2}-\\\\d{2}[T ]\\\\d{2}:\\\\d{2}\",\n \"grok_pattern\"\ | ||
\ : \"\\\\[%{TIMESTAMP_ISO8601:timestamp}\\\\]\\\\[%{LOGLEVEL:loglevel} \\\\]\\\\\ | ||
[.*\",\n \"ecs_compatibility\" : \"disabled\",\n \"timestamp_field\" : \"timestamp\"\ | ||
,\n \"joda_timestamp_formats\" : [\n \"ISO8601\"\n ],\n \"java_timestamp_formats\"\ | ||
\ : [\n \"ISO8601\"\n ],\n \"need_client_timezone\" : true,\n \"mappings\"\ | ||
\ : {\n \"properties\" : {\n \"@timestamp\" : {\n \"type\" : \"date\"\ | ||
\n },\n \"loglevel\" : {\n \"type\" : \"keyword\"\n },\n \ | ||
\ \"message\" : {\n \"type\" : \"text\"\n }\n }\n },\n \"ingest_pipeline\"\ | ||
\ : {\n \"description\" : \"Ingest pipeline created by text structure finder\"\ | ||
,\n \"processors\" : [\n {\n \"grok\" : {\n \"field\" :\ | ||
\ \"message\",\n \"patterns\" : [\n \"\\\\[%{TIMESTAMP_ISO8601:timestamp}\\\ | ||
\\]\\\\[%{LOGLEVEL:loglevel} \\\\]\\\\[.*\"\n ],\n \"ecs_compatibility\"\ | ||
\ : \"disabled\"\n }\n },\n {\n \"date\" : {\n \ | ||
\ \"field\" : \"timestamp\",\n \"timezone\" : \"{{ event.timezone }}\"\ | ||
,\n \"formats\" : [\n \"ISO8601\"\n ]\n }\n\ | ||
\ },\n {\n \"remove\" : {\n \"field\" : \"timestamp\"\n\ | ||
\ }\n }\n ]\n },\n \"field_stats\" : {\n \"loglevel\" : {\n\ | ||
\ \"count\" : 22,\n \"cardinality\" : 1,\n \"top_hits\" : [\n \ | ||
\ {\n \"value\" : \"INFO\",\n \"count\" : 22\n }\n\ | ||
\ ]\n },\n \"message\" : {\n \"count\" : 22,\n \"cardinality\"\ | ||
\ : 22,\n \"top_hits\" : [\n {\n \"value\" : \"[2024-03-05T10:52:36,256][INFO\ | ||
\ ][o.a.l.u.VectorUtilPanamaProvider] [laptop] Java vector incubator API enabled;\ | ||
\ uses preferredBitSize=128\",\n \"count\" : 1\n },\n {\n\ | ||
\ \"value\" : \"[2024-03-05T10:52:41,038][INFO ][o.e.p.PluginsService \ | ||
\ ] [laptop] loaded module [repository-url]\",\n \"count\" : 1\n \ | ||
\ },\n {\n \"value\" : \"[2024-03-05T10:52:41,042][INFO ][o.e.p.PluginsService\ | ||
\ ] [laptop] loaded module [rest-root]\",\n \"count\" : 1\n \ | ||
\ },\n {\n \"value\" : \"[2024-03-05T10:52:41,043][INFO ][o.e.p.PluginsService\ | ||
\ ] [laptop] loaded module [ingest-user-agent]\",\n \"count\" : 1\n\ | ||
\ },\n {\n \"value\" : \"[2024-03-05T10:52:41,043][INFO ][o.e.p.PluginsService\ | ||
\ ] [laptop] loaded module [x-pack-core]\",\n \"count\" : 1\n \ | ||
\ },\n {\n \"value\" : \"[2024-03-05T10:52:41,043][INFO ][o.e.p.PluginsService\ | ||
\ ] [laptop] loaded module [x-pack-redact]\",\n \"count\" : 1\n \ | ||
\ },\n {\n \"value\" : \"[2024-03-05T10:52:41,044][INFO ][o.e.p.PluginsService\ | ||
\ ] [laptop] loaded module [lang-painless]]\",\n \"count\" : 1\n \ | ||
\ },\n {\n \"value\" : \"[2024-03-05T10:52:41,044][INFO ][o.e.p.PluginsService\ | ||
\ ] [laptop] loaded module [repository-s3]\",\n \"count\" : 1\n \ | ||
\ },\n {\n \"value\" : \"[2024-03-05T10:52:41,044][INFO ][o.e.p.PluginsService\ | ||
\ ] [laptop] loaded module [x-pack-analytics]\",\n \"count\" : 1\n\ | ||
\ },\n {\n \"value\" : \"[2024-03-05T10:52:41,044][INFO ][o.e.p.PluginsService\ | ||
\ ] [laptop] loaded module [x-pack-autoscaling]\",\n \"count\" : 1\n\ | ||
\ }\n ]\n },\n \"timestamp\" : {\n \"count\" : 22,\n \ | ||
\ \"cardinality\" : 14,\n \"earliest\" : \"2024-03-05T10:52:36,256\",\n \ | ||
\ \"latest\" : \"2024-03-05T10:52:49,199\",\n \"top_hits\" : [\n \ | ||
\ {\n \"value\" : \"2024-03-05T10:52:41,044\",\n \"count\" : 6\n\ | ||
\ },\n {\n \"value\" : \"2024-03-05T10:52:41,043\",\n \ | ||
\ \"count\" : 3\n },\n {\n \"value\" : \"2024-03-05T10:52:41,059\"\ | ||
,\n \"count\" : 2\n },\n {\n \"value\" : \"2024-03-05T10:52:36,256\"\ | ||
,\n \"count\" : 1\n },\n {\n \"value\" : \"2024-03-05T10:52:41,038\"\ | ||
,\n \"count\" : 1\n },\n {\n \"value\" : \"2024-03-05T10:52:41,042\"\ | ||
,\n \"count\" : 1\n },\n {\n \"value\" : \"2024-03-05T10:52:43,291\"\ | ||
,\n \"count\" : 1\n },\n {\n \"value\" : \"2024-03-05T10:52:46,098\"\ | ||
,\n \"count\" : 1\n },\n {\n \"value\" : \"2024-03-05T10:52:47,227\"\ | ||
,\n \"count\" : 1\n },\n {\n \"value\" : \"2024-03-05T10:52:47,259\"\ | ||
,\n \"count\" : 1\n }\n ]\n }\n }\n}" |
Oops, something went wrong.