MustNewMetricWithExemplars is a version of NewMetricWithExemplars that panics where NewMetricWithExemplars would have returned an error.
(m Metric, exemplars ...Exemplar)
| 268 | // MustNewMetricWithExemplars is a version of NewMetricWithExemplars that panics where |
| 269 | // NewMetricWithExemplars would have returned an error. |
| 270 | func MustNewMetricWithExemplars(m Metric, exemplars ...Exemplar) Metric { |
| 271 | ret, err := NewMetricWithExemplars(m, exemplars...) |
| 272 | if err != nil { |
| 273 | panic(err) |
| 274 | } |
| 275 | return ret |
| 276 | } |