vectordotdev / vectordotdev/vector
Filters/macros/function for Vector's template syntax
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 22.6k
- Forks
- 2.3k
- Avg merge
- 1d 7h
- Merged PRs (30d)
- 146
Description
This has been discussed in a variety of issues (...), but we don't have an actual issue open for this work.
Motivation
Our template syntax is very limited in its current form and we've had a number of customers request ways to extend this (#1846, #1692, #1440, https://github.com/timberio/vector/issues/1926#issuecomment-599076830)
Prior Art
Proposal
We should support "modifiers" or "filters" within our template syntax. For example:
[sinks.archive]
type = "aws_s3"
key_prefix = "{{ timestamp | date: "%Y-%m-%d" }}"
Filters
We can use the prior art as a basis, but at the very least we should have:
- default
- strptime
- capitalize
- downcase
- truncate
- upcase
These are most useful for dynamic partitioning.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating Vector's existing template-syntax entry point and reviewing the Liquid and Jinja filter references linked in the issue. Define the supported filter behavior and integration scope; the work is done when the proposed default, strptime, capitalize, downcase, truncate, and upcase filters are supported.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- backend
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100