code: func (cs *clientServer) publishMetricsOnce() error {
  	// Get the list of objects to send to backend.
  	requests, err := cs.metricsToPublishMetricRequests()
  	if err != nil {
  		return err
  	}
  
  	// Make the publish metrics request to the backend.
  	for _, request := range requests {
  		err = cs.MakeRequest(request)
  		if err != nil {
  			return err
  		}
  	}
  	return nil
  }
docs: // publishMetricsOnce is invoked by the ticker to periodically publish metrics to backend.