Graphite Metrics Reporter in config.yml is unable to be parsed

245 views
Skip to first unread message

lbecke...@gmail.com

unread,
Nov 19, 2015, 7:00:54 PM11/19/15
to dropwizard-user
I tried to configure my dropwizard metrics in my config.yml file:

metrics:

   reporters:

     - type: graphite

       host: my.graphite.host.com

       port: 2003

       prefix: my.prefix


I have listed both dropwizard-metrics and metrics-graphite as dependencies in pom.xml.

When I run my application with this config.yml, I get the following error:

config.yml has an error:


  * Failed to parse configuration at: metrics.reporters; Could not resolve type id 'graphite'into a subtype of [simple type, class io.dropwizard.metrics.ReporterFactory]: known type ids =[ReporterFactory, console, csv, log]

 at [Source: N/A; line: -1, column: -1] (through reference chain:com.example.MyConfiguration["metrics"]->io.dropwizard.metrics.MetricsFactory["reporters"])


Why is this happening? Thanks in advance!

Tim Bart

unread,
Nov 20, 2015, 2:47:58 PM11/20/15
to dropwizard-user
Could you list the versions of dropwizard , metrics and graphite reporter you are using?

lbecke...@gmail.com

unread,
Nov 20, 2015, 3:42:35 PM11/20/15
to dropwizard-user
I am no longer receiving this error. It seemed that the Dropwizard Metrics Getting Started (with Graphite) is missing a key module to add as a dependency. I now have 3 dependencies listed in my pom.xml: io.dropwizard.metrics metrics-core 3.1.2, io.dropwizard.metrics metrics-graphite 3.1.2, and io.dropwizard dropwizard-metrics-graphite 0.9.1. I am using Dropwizard version 0.9.0. By adding dropwizard-metrics-graphite, the GraphiteReporterFactory was able to parse the type: graphite in my config.yml file.

Now, when I run my application, I get a validation error from the "minimal hibernate" that's been added to DW validation. Please see my other post
Reply all
Reply to author
Forward
0 new messages