From 1938e1a62d2dbb4539df6c4f8594bd0c028fbd3a Mon Sep 17 00:00:00 2001 From: "Thibault \"bui\" Koechlin" Date: Fri, 19 Mar 2021 16:33:10 +0100 Subject: [PATCH] clarify doc on onsuccess in parsers + add new date formats for dateparse (#703) --- docs/v1.X/docs/references/parsers.md | 2 +- pkg/parser/enrich.go | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/docs/v1.X/docs/references/parsers.md b/docs/v1.X/docs/references/parsers.md index ff139129c..fbac6f324 100644 --- a/docs/v1.X/docs/references/parsers.md +++ b/docs/v1.X/docs/references/parsers.md @@ -243,7 +243,7 @@ onsuccess: next_stage|continue _default: continue_ -if set to `next_stage` and the node is considered successful, the {{v1X.event.name}} will be moved directly to next stage without processing other nodes in the current stage. +if set to `next_stage` and the node is considered successful, the {{v1X.event.name}} will be moved directly to the next stage without processing other nodes in the current stage. _note: if it's a parser tree, and a "leaf" node succeeds, it is the parent's "onsuccess" that is evaluated._ ### `pattern_syntax` diff --git a/pkg/parser/enrich.go b/pkg/parser/enrich.go index 4aa8a343c..76641ac71 100644 --- a/pkg/parser/enrich.go +++ b/pkg/parser/enrich.go @@ -66,6 +66,8 @@ func GenDateParse(date string) (string, time.Time) { "2006/01/02 15:04", "2006-01-02", "2006-01-02 15:04", + "2006/01/02 15:04:05", + "2006-01-02 15:04:05", } for _, dateFormat := range layouts {