Skip to content
This repository has been archived by the owner on Oct 3, 2023. It is now read-only.

Commit

Permalink
Fix slice allocation (#197)
Browse files Browse the repository at this point in the history
  • Loading branch information
songy23 committed Sep 5, 2019
1 parent 0a55998 commit b183b1e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion metrics_batcher.go
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ func (mb *metricsBatcher) addTimeSeries(ts *monitoringpb.TimeSeries) {
Name: monitoring.MetricProjectPath(mb.projectID),
TimeSeries: mb.allTss,
})
mb.allTss = make([]*monitoringpb.TimeSeries, maxTimeSeriesPerUpload)
mb.allTss = make([]*monitoringpb.TimeSeries, 0, maxTimeSeriesPerUpload)
}
}

Expand Down

0 comments on commit b183b1e

Please sign in to comment.