boundary / folsom_webmachine

folsom based metrics via HTTP and JSON
37 stars 21 forks source link

No metrics? #6

Open building39 opened 9 years ago

building39 commented 9 years ago

I've added folsom and folsom_cowboy to my application. Both are running, but I get no metrics, except for the vm metrics - they all seem to work. No metrics for pooler, either.

sys.config:

%%% --erlang-- [ {nebula2, [ {cdmi_bootstrap, true}, {cdmi_location, "US-TX"}, {cdmi_metadata_module, nebula2_riak} ] }, {lager, [ {log_root, "/var/log/nebula2"}, {handlers, [ {lager_console_backend, info, {colored, true}}, {lager_file_backend, [{file, "error.log"}, {level, error}]}, {lager_file_backend, [{file, "debug.log"}, {level, debug}]}, {lager_file_backend, [{file, "console.log"}, {level, info}]} ] } ] }, {folsom_cowboy, [ {transport, cowboy_tcp_transport}, {transport_options, [{ip, {127, 0, 0, 1}}]} ] }, {pooler, [ {pools, [ [ {name, riak_pool}, {group, riak}, {max_count, 500}, {init_count, 20}, {start_mfa, {riakc_pb_socket, start_link, ["nebriak1", 8087]}}, %% if you want to enable metrics, set this to a module with %% an API conformant to the folsom_metrics module. %% If this config is missing, then no metrics are sent. {metrics_module, folsom_metrics} ] ] } ] } ].

{application, nebula2, [ {description, "Nebula 2 CDMI Server"}, {vsn, "0.1.0"}, {id, "git"}, {modules, []}, {registered, []}, {applications, [ lager, kernel, stdlib, inets, riakc, crc16, uuid, jsx, folsom, cowboy, folsom_cowboy ]}, {included_applications, [pooler, mcd]}, {mod, {nebula2_app, []}}, {env, []} ]}.

joewilliams commented 9 years ago

Great, the vm metrics are built in. You'll need to add metrics to your application code, for instance folsom_metrics:new_counter(Name). to add a counter.

Please note that all folsom related projects have moved to https://github.com/folsom-project