GoogleCloudPlatform / run-gmp-sidecar

Apache License 2.0
8 stars 7 forks source link

Support OTel config such as use_start_time_metric #21

Open arabian9ts opened 7 months ago

arabian9ts commented 7 months ago

Hello,

I'm attempting to run the gmp sidecar on Cloud Run and am encountering logs similar to those in https://github.com/GoogleCloudPlatform/run-gmp-sidecar/issues/4. Requests are reaching the metrics endpoint, and I confirmed that some metrics are exported. However, the fastly-exporter I'm using does not support exporting start_time metric. Even if I contribute to it, I believe the metric would be named something like fastly_process_start_time_seconds with the fastly namespace attached. Therefore, I need an option to use start_time_metric_regex or to set use_start_time_metric to false.

I've forked this repository and tried the implementation. Then, tested it with the gmp sidecar and it's working well. I would like to commit it into the main branch if possible. May I create a PR?

The implementation is here. https://github.com/arabian9ts/run-gmp-sidecar/commit/26ed57aa40d8d787b72b3262f87249b58b00e88c