hi, sorry, I can't share exact problem I'm solving and I need to solve it 
in the way I'm trying to do it.



On Sunday, May 10, 2020 at 6:08:55 PM UTC+3, sayf eddine Hammemi wrote:
>
> Hi, preventing an XY problem, can you explain what do you want to achieve 
> by enriching the time series ? Maybe it is done easily with another way
>
> On Sun, May 10, 2020, 16:45 DanQ wrote:
>
>> I installed Prometheus 2 on my machine and using this configuration to 
>> publish metrics to another service
>>
>> remote_write:
>>     - url: http://localhost:8080/api/prom/push
>>       basic_auth: 
>>
>>
>> Another service is in Java, should intercept and enrich Prometheus 
>> metrics and after that forward them to another Prometheus. 
>>
>> Prometheus publishes traffic with Content-Encoding: snappy, Content-Type: 
>> application/x-protobu, X-Prometheus-Remote-Write: 0.1.0 headers
>>
>> In my service I generated proto java classes against this definition
>>
>> https://github.com/cortexproject/cortex/blob/master/pkg/ingester/client/cortex.proto#L30
>>
>> and I'm trying to parse incoming Prometheus bytes like 
>> this WriteRequest.parseFrom(input.getBytes()) and it fails with 
>> *com.google.protobuf.InvalidProtocolBufferException$InvalidWireTypeException:
>>  
>> Protocol message tag had invalid wire type.*
>>
>> when I try to parse with firstly decoding with Snappy
>> WriteRequest.parseFrom(Snappy.uncompress(input.getBytes()))
>>
>> I get error that it is not possible to decompress the message. What am I 
>> doing wrong and how to parse Prometheus Protobufs messages properly?
>>
>> Thanks.
>>
>> -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Prometheus Users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to [email protected] <javascript:>.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/prometheus-users/435695ae-277f-4b64-8ff7-af7db4843edf%40googlegroups.com
>>  
>> <https://groups.google.com/d/msgid/prometheus-users/435695ae-277f-4b64-8ff7-af7db4843edf%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Prometheus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/prometheus-users/5c0fe168-5ce3-4e5d-acea-3f53fd59939e%40googlegroups.com.

Reply via email to