def populate_site_daily_metrics(**kwargs): '''Populate a SiteDailyMetrics record ''' logger.debug("populate_site_daily_metrics called") SiteDailyMetricsLoader().load( date_for=kwargs.get('date_for', None), force_update=kwargs.get('force_update', False), ) logger.debug('done running populate_site_daily_metrics')
def populate_site_daily_metrics(site_id, **kwargs): '''Populate a SiteDailyMetrics record ''' logger.debug( 'populate_site_daily_metrics called for site_id={}'.format(site_id)) SiteDailyMetricsLoader().load( site=Site.objects.get(id=site_id), date_for=kwargs.get('date_for', None), force_update=kwargs.get('force_update', False), ) logger.debug( 'done running populate_site_daily_metrics for site_id={}"'.format( site_id))
def populate_single_sdm(site_id, date_for, force_update=False): """Populate a SiteDailyMetrics record This is simply a Celery task wrapper around the call to collect data into the SiteDailyMetrics record for the given site and date_for. """ logger.debug('populate_single_sdm: site_id={}'.format(site_id)) SiteDailyMetricsLoader().load(site=Site.objects.get(id=site_id), date_for=date_for, force_update=force_update) logger.debug( 'done running populate_site_daily_metrics for site_id={}'.format(site_id))