You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Can anyone suggest ways that vector can increment a counter each time it receives an event from a file source (i.e. a new line is written), and this counter be available to be used in transforms/sinks and also be persisted, so that when vector is restarted, the counter doesn't reset to 0.
Bonus question, a specific counter value will be needed for associated events (logs written to a different file) that might happen minutes/hours after the initial event that caused the counter to increment, so the same counter value for the initial event needs to be shared for these subsequent log lines.
Hope it makes sense, and thanks in advance for any ideas.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hi,
Can anyone suggest ways that vector can increment a counter each time it receives an event from a file source (i.e. a new line is written), and this counter be available to be used in transforms/sinks and also be persisted, so that when vector is restarted, the counter doesn't reset to 0.
Bonus question, a specific counter value will be needed for associated events (logs written to a different file) that might happen minutes/hours after the initial event that caused the counter to increment, so the same counter value for the initial event needs to be shared for these subsequent log lines.
Hope it makes sense, and thanks in advance for any ideas.
Beta Was this translation helpful? Give feedback.
All reactions