title: Promotheus - query to get increase percentage of events
body: <p>I have an histogram of requests with path and status codes...How can I alert if the errors are increasing with 20% in the last hour compared with the hour before?</p>
  
  <p>one metric sample:</p>
  
  <pre><code>{instance="someIp",instance_hostname="someHost",job="someAppName",le="+Inf",method="GET",path="somePath",status_code="500"} 
  </code></pre>
  
  <p>I should rely on rate function? something like:</p>
  
  <pre><code>rate(http_request_duration_seconds{job="someProject", status_code="500"}[60m])
  </code></pre>