Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Index pattern #2078

Closed
wants to merge 2 commits into from
Closed

Index pattern #2078

wants to merge 2 commits into from

Conversation

tsg
Copy link
Contributor

@tsg tsg commented Jul 21, 2016

This transforms the fixed index into a pattern, somehow similar to how
Logstash is doing it. However, logstash is using the Joda format, for which
we don't have Go libraries. So instead of writing filebeat-%{+YYYY.MM.dd} you
would need to write filebeat-%{+2006.01.02} (i.e. layout by example).

Because the Go layouts don't support ISO 8601 weeks, in order to support weekly
indices, the special isoweek keyword was introduced, which is the equivalent
of Joda xxxx.ww. The layout filebeat-%{+isoweek} results in filebeat-2016.29
for today.

Part of #2074. Closes #921.

Also, depends on #2077.

The "index" setting name has historical reasons, from the times that
all outputs shared the same configuration options. Since the meaning and
contents of the "index" setting are starting to vary per output, it's time
to clean this up. The Redis "index" is now called "key".

Before this change, the index was still somehow special, since it was set to
the beatName outside of the output. This removes this hack, and sets index to
beatName only in the Elasticsearch and Logstash modules.

This also removes the `index` setting for the file output, but that was never
documented.

Part of elastic#2074.
@tsg tsg added in progress Pull request is currently in progress. discuss Issue needs further discussion. review labels Jul 21, 2016
This transforms the fixed index into a pattern, somehow similar to how
Logstash is doing it. However, logstash is using the Joda format, for which
we don't have Go libraries. So instead of writing `filebeat-%{+YYYY.MM.dd}` you
would need to write `filebeat-%{+2006.01.02}` (i.e. layout by example).

Because the Go layouts don't support ISO 8601 weeks, in order to support weekly
indices, the special `isoweek` keyword was introduced, which is the equivalent
of Joda `xxxx.ww`. The layout `filebeat-%{+isoweek}` results in `filebeat-2016.29`
for today.

Part of elastic#2074. Closes elastic#921.
@tsg
Copy link
Contributor Author

tsg commented Jul 27, 2016

Closing, to be reimplemented on top of the format string support, which already supports timestamps.

@tsg tsg closed this Jul 27, 2016
@tsg tsg deleted the index_pattern branch August 25, 2016 10:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
discuss Issue needs further discussion. in progress Pull request is currently in progress. review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Allow configurable time for ES output
1 participant