jiangzho opened a new pull request, #171:
URL: https://github.com/apache/spark-kubernetes-operator/pull/171

   ### What changes were proposed in this pull request?
   
   This PR sets Content-Type header for Prometheus handler to make it 
compatible with Prometheus v3
   
   ### Why are the changes needed?
   
   Prometheus v3 will fail the scrape if the Content-Type header is not present 
in response and the fallback scrape protocol is not configured. Therefore we'd 
configure the headers properly.
   
   Please also refer 
https://prometheus.io/docs/prometheus/latest/migration/#scrape-protocols
   
   ### Does this PR introduce any user-facing change?
   
   No
   
   ### How was this patch tested?
   
   Tested via CI and local set up for Prometheus v3, via steps:
   
   * Deploy Prometheus v3 in k8s cluster, with default configuration (no 
fallback_scrape_protocol configured)
   * Deploy Spark Operator in cluster
   * Prometheus v3 is able to successfully scrape operator metrics
   
   ### Was this patch authored or co-authored using generative AI tooling?
   
   No
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to