Skip to content

Commit

Permalink
Gracefully handle null readers in MetricExportAutoConfiguration
Browse files Browse the repository at this point in the history
  • Loading branch information
wilkinsona committed May 18, 2015
1 parent d8af798 commit 54b0613
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -69,8 +69,8 @@ public SchedulingConfigurer metricWritersMetricExporter() {

Map<String, MetricWriter> writers = new HashMap<String, MetricWriter>();

MetricReader reader = endpointReader;
if (reader == null && !this.readers.isEmpty()) {
MetricReader reader = this.endpointReader;
if (reader == null && this.readers != null && !this.readers.isEmpty()) {
reader = new CompositeMetricReader(this.readers.toArray(new MetricReader[0]));
}

Expand Down

0 comments on commit 54b0613

Please sign in to comment.