func (a *Agent) FlushSync() {
	if !a.conf.SynchronousFlushing {
		log.Critical("(*Agent).FlushSync called without apm_conf.sync_flushing enabled. No data was sent to Datadog.")
		return
	}

	if err := a.StatsWriter.FlushSync(); err != nil {
		log.Errorf("Error flushing stats: %s", err.Error())
		return
	}
	if err := a.TraceWriter.FlushSync(); err != nil {
		log.Errorf("Error flushing traces: %s", err.Error())
		return
	}
}
// FlushSync flushes traces sychronously. This method only works when the agent is configured in synchronous flushing
// mode via the apm_config.sync_flush option.
FlushSync flushes traces sychronously. This method only works when the agent is configured in synchronous flushing
mode via the apm_config.sync_flush option.
// FlushSync flushes traces sychronously . This method only works when the agent is configured in synchronous flushing // mode via the apm_config . sync_flush option .
func (a *Agent) FlushSync() {
	if !a.conf.SynchronousFlushing {
		log.Critical("(*Agent).FlushSync called without apm_conf.sync_flushing enabled. No data was sent to Datadog.")
		return
	}
	if err := a.StatsWriter.FlushSync(); err != nil {
		log.Errorf("Error flushing stats: %s", err.Error())
		return
	}
	if err := a.TraceWriter.FlushSync(); err != nil {
		log.Errorf("Error flushing traces: %s", err.Error())
		return
	}
}
func ( a * Agent ) FlushSync ( ) { if ! a . conf . SynchronousFlushing { log . Critical ( " " ) return } if err := a . StatsWriter . FlushSync ( ) ; err != nil { log . Errorf ( " " , err . Error ( ) ) return } if err := a . TraceWriter . FlushSync ( ) ; err != nil { log . Errorf ( " " , err . Error ( ) ) return } }
FlushSync flushes traces sychronously.
FlushSync flushes traces sychronously .