mirror of
https://github.com/netsampler/goflow2.git
synced 2024-05-06 15:54:52 +00:00
bug: fix double count of NetFlow metric (#302)
This commit is contained in:
@ -86,12 +86,6 @@ func PromDecoderWrapper(wrapped utils.DecoderFunc, name string) utils.DecoderFun
|
|||||||
|
|
||||||
func recordCommonNetFlowMetrics(version uint16, key string, flowSets []interface{}) {
|
func recordCommonNetFlowMetrics(version uint16, key string, flowSets []interface{}) {
|
||||||
versionStr := fmt.Sprintf("%d", version)
|
versionStr := fmt.Sprintf("%d", version)
|
||||||
NetFlowStats.With(
|
|
||||||
prometheus.Labels{
|
|
||||||
"router": key,
|
|
||||||
"version": versionStr,
|
|
||||||
}).
|
|
||||||
Inc()
|
|
||||||
|
|
||||||
for _, fs := range flowSets {
|
for _, fs := range flowSets {
|
||||||
switch fsConv := fs.(type) {
|
switch fsConv := fs.(type) {
|
||||||
|
Reference in New Issue
Block a user