Skip to content

Commit 40e6eec

Browse files
authored
Fix code example for YourCustomCollector in README (#572)
In order to run the example, this method must have public visibility. Signed-off-by: Charney Kaye <[email protected]>
1 parent c41bef4 commit 40e6eec

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -629,7 +629,7 @@ To do so you need to create a custom collector (which will need to be registered
629629

630630
```java
631631
class YourCustomCollector extends Collector {
632-
List<MetricFamilySamples> collect() {
632+
public List<MetricFamilySamples> collect() {
633633
List<MetricFamilySamples> mfs = new ArrayList<MetricFamilySamples>();
634634
// With no labels.
635635
mfs.add(new GaugeMetricFamily("my_gauge", "help", 42));

0 commit comments

Comments
 (0)