instrument_registry (instrument v1.0.0)

View Source

Summary

Functions

Returns the number of label sets dropped into the overflow bucket for Name since the registry started (or the metric was last registered).

Returns the overflow sentinel metric for Name, creating it on the first call. Also increments the dropped-cardinality counter for Name. Returns undefined if the parent metric does not exist.

Returns the number of distinct label sets currently cached for Name.

Returns the cached overflow sentinel metric for Name if one has been created, undefined otherwise.

Functions

cache_label(Name, LabelValues, Metric)

-spec cache_label(term(),
                  list(),
                  #metric{name :: term(),
                          handle :: term(),
                          collect :: tuple(),
                          description :: binary() | undefined,
                          unit :: binary() | undefined,
                          meter :: binary() | undefined,
                          attributes :: map()}) ->
                     ok.

cardinality_dropped(Name)

-spec cardinality_dropped(term()) -> non_neg_integer().

Returns the number of label sets dropped into the overflow bucket for Name since the registry started (or the metric was last registered).

clear_labels(Name)

code_change(OldVsn, State, Extra)

collect_all()

-spec collect_all() -> [map()].

create_vector_metric(Name, Label)

get_or_create_overflow(Name)

-spec get_or_create_overflow(term()) ->
                                #metric{name :: term(),
                                        handle :: term(),
                                        collect :: tuple(),
                                        description :: binary() | undefined,
                                        unit :: binary() | undefined,
                                        meter :: binary() | undefined,
                                        attributes :: map()} |
                                undefined.

Returns the overflow sentinel metric for Name, creating it on the first call. Also increments the dropped-cardinality counter for Name. Returns undefined if the parent metric does not exist.

handle_call(Req, From, State)

handle_cast(Msg, State)

handle_info(Info, State)

init(_)

label_count(Name)

-spec label_count(term()) -> non_neg_integer().

Returns the number of distinct label sets currently cached for Name.

lookup(Name)

-spec lookup(term()) ->
                #metric{name :: term(),
                        handle :: term(),
                        collect :: tuple(),
                        description :: binary() | undefined,
                        unit :: binary() | undefined,
                        meter :: binary() | undefined,
                        attributes :: map()} |
                undefined.

lookup_label(Name, LabelValues)

-spec lookup_label(term(), list()) ->
                      #metric{name :: term(),
                              handle :: term(),
                              collect :: tuple(),
                              description :: binary() | undefined,
                              unit :: binary() | undefined,
                              meter :: binary() | undefined,
                              attributes :: map()} |
                      undefined.

overflow_sentinel(Name)

-spec overflow_sentinel(term()) ->
                           #metric{name :: term(),
                                   handle :: term(),
                                   collect :: tuple(),
                                   description :: binary() | undefined,
                                   unit :: binary() | undefined,
                                   meter :: binary() | undefined,
                                   attributes :: map()} |
                           undefined.

Returns the cached overflow sentinel metric for Name if one has been created, undefined otherwise.

register(Metric)

remove_label(Name, Label)

start_link()

terminate(Reason, State)

unregister(Name)

unregister_all()

with(Metric, Fun)