Open andrejbaran opened 1 year ago
Can not understand... )) Who does not need such a useful thing?
Can not understand... )) Who does not need such a useful thing?
We are open to a PR here :) It should be a relatively straight-forward change to expose.
We are open to a PR here :) It should be a relatively straight-forward change to expose.
I decided to use vector in one of my projects... And rested on the fact that I canβt do it because of this thing. Now looking for alternative solutions... Maybe fluentd, haven't decided yet. But as soon as this thing appears, you will definitely pass on it. Pretty cool product. Taking off my hat. Thank you.
P.S. If today it was added, I would build vector from the source. ))
@jszwedko great. I will find some time to implement it. Sorry for the late reply.
@jszwedko which solution of those mentioned would you guys prefer?
@jszwedko which solution of those mentioned would you guys prefer?
Is it common to only want certain messages to be persistent? If it is, than the template approach makes sense. Otherwise I would say just go with a boolean.
I would not go with the third approach since we don't have any precedent for that pattern in Vector at the moment.
Is it common to only want certain messages to be persistent? If it is, than the template approach makes sense. Otherwise I would say just go with a boolean.
Well, that depends I guess. I'd say it could be a valid scenario, where for example you absolutely don't want to loose audit log messages or certain levels of but you don't mind if you loose some extent of others (e.g. some levels of infrastructure or application logs)
I don't think there is a "common theme" here since that might vary a lot π€· so I would say the template way is "safer" ?
@jszwedko Now that I think of it I would go for the simple boolean. One can always create separate sinks (with same/similar configuration) and route logs to respective sinks if needed.
Since there wasn't a real need for this feature anyway (4 π including mine π ) I will go for the boolean.
A note for the community
π I am more than happy to work on this as it seems to be an easy task to do and since no one else (to my knowledge) raised this "issue" yet
Use Cases
In order to ensure logs really make it to processing/end storage while using AMQP sinks it would be really great to have an option to mark the message as persistent. This way logs (marked as such, like audit logs for instance) would survive restart of AMQP component (e.g. RabbitMQ).
Attempted Solutions
Unfortunately persistence in RabbitMQ can be setup only at the producer level and not via policies so there is really no other option how to achieve this than adding this to vector itself in one way or another.
Proposal
There are several approaches to tackle this:
Add an optional AMQP sink configuration field (like
mark_persistent
for instance)true
orfalse
true
orfalse
(like:%amqp.persistent
)References
No response
Version
vector 0.28.1 (x86_64-unknown-linux-musl ff15924 2023-03-06)