Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions src/Prometheus/CollectorRegistry.php
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ public function registerGauge(string $namespace, string $name, string $help, arr
{
$metricIdentifier = self::metricIdentifier($namespace, $name);
if (isset($this->gauges[$metricIdentifier])) {
throw new MetricsRegistrationException("Metric already registered");
throw new MetricsRegistrationException("Metric ` . $metricIdentifier . ` already registered");
}
$this->gauges[$metricIdentifier] = new Gauge(
$this->storageAdapter,
Expand Down Expand Up @@ -159,7 +159,7 @@ public function registerCounter(string $namespace, string $name, string $help, a
{
$metricIdentifier = self::metricIdentifier($namespace, $name);
if (isset($this->counters[$metricIdentifier])) {
throw new MetricsRegistrationException("Metric already registered");
throw new MetricsRegistrationException("Metric ` . $metricIdentifier . ` already registered");
}
$this->counters[$metricIdentifier] = new Counter(
$this->storageAdapter,
Expand Down Expand Up @@ -225,7 +225,7 @@ public function registerHistogram(
): Histogram {
$metricIdentifier = self::metricIdentifier($namespace, $name);
if (isset($this->histograms[$metricIdentifier])) {
throw new MetricsRegistrationException("Metric already registered");
throw new MetricsRegistrationException("Metric ` . $metricIdentifier . ` already registered");
}
$this->histograms[$metricIdentifier] = new Histogram(
$this->storageAdapter,
Expand Down Expand Up @@ -301,7 +301,7 @@ public function registerSummary(
): Summary {
$metricIdentifier = self::metricIdentifier($namespace, $name);
if (isset($this->summaries[$metricIdentifier])) {
throw new MetricsRegistrationException("Metric already registered");
throw new MetricsRegistrationException("Metric ` . $metricIdentifier . ` already registered");
}
$this->summaries[$metricIdentifier] = new Summary(
$this->storageAdapter,
Expand Down