Open eproxus opened 8 years ago
@eproxus The MFA should be a tuple instead of simple values in the list. Try
{exometer_core, [
{predefined, {apply, stats, entries, []},
{report, [
{reporters, [
{exometer_report_librato, [...]}
]},
{subscribers, [{apply, {stats, subscribers, []}}]}
]}
]}.
Ok, that works. :smile:
Two things: in predefined entries, the format is {apply, M, F, A}
which is confusing, and I think invalid subscription formats should be rejected (although in this case it matches the {Reporter, Metric, DataPoint, Interval}
pattern, so I'm not sure what would be the best way).
Also, the documentation says directly after the correct description:
In the case of {apply, M, F, A}, the result of apply(M, F, A) must be a list of subscribers tuples.
It is confusing, I agree. I guess it would be best to change how apply works for predefined entries to be in sync with how it works for subscriptions.
The following configuration works:
Result:
The following does not:
Result:
Implementation of
stats.erl
: