diff --git a/core/CronArchive.php b/core/CronArchive.php index 6375b232db81e52c526c3245e6a2351e43fc501f..5c6d9fe7b2dcfe261b38eaed3eb65929027acb15 100644 --- a/core/CronArchive.php +++ b/core/CronArchive.php @@ -672,7 +672,7 @@ class CronArchive $date = $this->getApiDateParameter($idSite, "day", $processDaysSince); $url = $this->getVisitsRequestUrl($idSite, "day", $date); - $this->logArchiveWebsite($idSite, "day"); + $this->logArchiveWebsite($idSite, "day", $date); $content = $this->request($url); $daysResponse = @unserialize($content); @@ -763,7 +763,7 @@ class CronArchive // already processed above for "day" if ($period != "day") { $urls[] = $url; - $this->logArchiveWebsite($idSite, $period); + $this->logArchiveWebsite($idSite, $period, $date); } $segmentRequestsCount = 0; @@ -1507,12 +1507,13 @@ class CronArchive * @param $idSite * @param $period */ - private function logArchiveWebsite($idSite, $period) + private function logArchiveWebsite($idSite, $period, $date) { $this->logger->info(sprintf( - "Will pre-process for website id = %s, %s period", + "Will pre-process for website id = %s, period = %s, date = %s", $idSite, - $period + $period, + $date )); $this->logger->info('- pre-processing all visits'); } diff --git a/tests/PHPUnit/Integration/CronArchiveTest.php b/tests/PHPUnit/Integration/CronArchiveTest.php index 888ebb292a5076fc5666db017d3e0d1516bb7e5a..394b70f046c7304de2c4687ce74d559edd21c397 100644 --- a/tests/PHPUnit/Integration/CronArchiveTest.php +++ b/tests/PHPUnit/Integration/CronArchiveTest.php @@ -101,22 +101,22 @@ NOTES --------------------------- START Starting Piwik reports archiving... -Will pre-process for website id = 1, day period +Will pre-process for website id = 1, period = day, date = last52 - pre-processing all visits - skipping segment archiving for 'actions>=4'. - pre-processing segment 1/1 actions>=2 Archived website id = 1, period = day, 1 segments, 0 visits in last %s days, 0 visits today, Time elapsed: %s -Will pre-process for website id = 1, week period +Will pre-process for website id = 1, period = week, date = last198 - pre-processing all visits - skipping segment archiving for 'actions>=4'. - pre-processing segment 1/1 actions>=2 Archived website id = 1, period = week, 1 segments, 1 visits in last %s weeks, 1 visits this week, Time elapsed: %s -Will pre-process for website id = 1, month period +Will pre-process for website id = 1, period = month, date = last52 - pre-processing all visits - skipping segment archiving for 'actions>=4'. - pre-processing segment 1/1 actions>=2 Archived website id = 1, period = month, 1 segments, 1 visits in last %s months, 1 visits this month, Time elapsed: %s -Will pre-process for website id = 1, year period +Will pre-process for website id = 1, period = year, date = last7 - pre-processing all visits - skipping segment archiving for 'actions>=4'. - pre-processing segment 1/1 actions>=2