Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.
Sign upmetrics labels can Support Chinese? #1988
Comments
This comment has been minimized.
This comment has been minimized.
songjiayang
commented
Sep 14, 2016
|
check your db charset ? |
This comment has been minimized.
This comment has been minimized.
|
utf-8 |
This comment has been minimized.
This comment has been minimized.
|
Label values fully support UTF-8. If you run into any issues, a detailed error report would be very helpful. |
This comment has been minimized.
This comment has been minimized.
aecolley
commented
Sep 18, 2016
|
Github comments seem to support 正體字 / 简化字, but the text in the There's always the possibility that the characters being replaced by I notice that a bare request to Prometheus's own |
This comment has been minimized.
This comment has been minimized.
That's a good point. If the text format is used, we should definitely specify the charset in the content type. I filed prometheus/docs#557 about it. However, in this particular case, I don't think it explains the issue. First, a charset header is not required by the protobuf format. If the UTF-8 string makes it onto the Pushgateway, it will be scraped correctly by the Prometheus server (as it uses the protobuf format). Second, if I'm not missing anything, the Prometheus server will always interpret the payload of an HTTP request as UTF-8, no matter what might or might not be in the header. Perhaps the problem happens in the last step, namely delivering the query result via the HTTP API? |
This comment has been minimized.
This comment has been minimized.
|
@najun79 can you confirm if the issue is only in the HTTP API? |
This comment has been minimized.
This comment has been minimized.
|
No response, presuming this issue isn't with Prometheus. |
brian-brazil
closed this
Feb 13, 2017
This comment has been minimized.
This comment has been minimized.
codwu
commented
Apr 6, 2017
|
if label value is chinese, prometheus give an error message: invalid label value "\xd5\xd7\xcd\xf8\xc2" |
This comment has been minimized.
This comment has been minimized.
|
This is not valid utf-8: https://play.golang.org/p/NAcJaCo7Pu |
This comment has been minimized.
This comment has been minimized.
lock
bot
commented
Mar 23, 2019
|
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
najun79 commentedSep 14, 2016
takeout_requests_total{instance="",job="takeout_requests_total",mealscount="0",mealsname="��������",userid="user",username="������"} 3
takeout_requests_total{instance="",job="takeout_requests_total",mealscount="0",mealsname="�ϱ���ը����",userid="user",username="������"} 3
takeout_requests_total{instance="",job="takeout_requests_total",mealscount="1",mealsname="��������",userid="user",username="������"} 3
takeout_requests_total{instance="",job="takeout_requests_total",mealscount="1",mealsname="�ϱ���ը����",userid="user",username="������"} 6
labels mealsname is Chinese(utf8),takeout_requests_total can be send to pushgateway and Correctly received,but prom/Prometheus can not pull it.metrics labels can Support Chinese?