func (m *ModuleMonitor) Heartbeat(modules ...string) {
	enabled, err := m.enabled(modules)
	if err != nil || len(enabled) == 0 {
		return
	}

	metricNames := make([]string, 0, len(enabled))
	for _, moduleName := range enabled {
		metricNames = append(metricNames, m.metricNameFn(moduleName))
	}

	m.flusher.Flush(metricNames, time.Now())
}
// Heartbeat emits one heartbeat metric for each system-probe module that is
// enabled.  The argument `modules` filters which heartbeats should be
// emitted. If no argument is given all enabled modules are reported.
Heartbeat emits one heartbeat metric for each system-probe module that is
enabled.  The argument `modules` filters which heartbeats should be
emitted. If no argument is given all enabled modules are reported.
// Heartbeat emits one heartbeat metric for each system - probe module that is // enabled . The argument ` modules ` filters which heartbeats should be // emitted . If no argument is given all enabled modules are reported .
func (m *ModuleMonitor) Heartbeat(modules ...string) {
	enabled, err := m.enabled(modules)
	if err != nil || len(enabled) == 0 {
		return
	}
	metricNames := make([]string, 0, len(enabled))
	for _, moduleName := range enabled {
		metricNames = append(metricNames, m.metricNameFn(moduleName))
	}
	m.flusher.Flush(metricNames, time.Now())
}
func ( m * ModuleMonitor ) Heartbeat ( modules ... string ) { enabled , err := m . enabled ( modules ) if err != nil || len ( enabled ) == 0 { return } metricNames := make ( [ ] string , 0 , len ( enabled ) ) for _ , moduleName := range enabled { metricNames = append ( metricNames , m . metricNameFn ( moduleName ) ) } m . flusher . Flush ( metricNames , time . Now ( ) ) }
Heartbeat emits one heartbeat metric for each system-probe module that is
enabled.
Heartbeat emits one heartbeat metric for each system - probe module that is enabled .