Skip to content
This repository has been archived by the owner on Jan 22, 2024. It is now read-only.

[Feature request] set additional labels per log entry #4

Open
yacut opened this issue Jan 11, 2021 · 3 comments
Open

[Feature request] set additional labels per log entry #4

yacut opened this issue Jan 11, 2021 · 3 comments

Comments

@yacut
Copy link

yacut commented Jan 11, 2021

Right now, labels can only be set during client initialization. It would be very useful if you could set additional labels to individual messages. e.g.:

loki.InfoWithLabelf("{worker_id=\"123\"}", "source = %s, time = %s, i = %d\n", source_name, tstamp, i)
@afiskon
Copy link
Owner

afiskon commented Jan 11, 2021

Hi @yacut

Many thanks for the suggestion and also for the interest to the project.

Unfortunately currently I'm a little short on spare time to implement this feature, but I will be happy to merge a corresponding pull request.

@gatlee21
Copy link

Commenting in 2022 to say that this is still a relevant feature request. Thanks

@laikee99
Copy link

laikee99 commented Jun 5, 2022

I just submit a pr that allow pass a parameter to change label every time.
Please check that and thank you so much.
#6

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants