I have a spring boot application with spring boot version 2.7.6 which I have recently upgraded to 3.0.6
I had one Rest API for which I was getting Prometheus metric like below,
http_server_requests_seconds_count{error="none",exception="none",method="GET",outcome="SUCCESS",status="2xx",uri="/mock-api/{response-code}/{sleep-time}",} 4.0
But after this upgrade I am getting metric like below,
http_server_requests_seconds_count{error="none",exception="none",method="GET",outcome="SUCCESS",status="200",uri="/mock-api/{response-code}/{sleep-time}",} 3.0
http_server_requests_seconds_count{error="none",exception="none",method="GET",outcome="SUCCESS",status="201",uri="/mock-api/{response-code}/{sleep-time}",} 1.0
'2xx' vs '200'
I think it has happened due to springboot version upgrade. Is there a way to still get '2xx' instead of '200'? Reason why I need it as coz my application is already there on production for a very long time and there are n-number of grafana dashboards on it. Due to this change in metric value, I am seeing issues there. I want to avoid any impact on grafana dashboards.
Please guide if anyone has faced this.