Ejemplo n.º 1
0
 /**
  * Update the cache on the database
  * @return int The number of new event saved
  */
 public static function updateCache()
 {
     $startTime = microtime(true);
     $lastDate = CacheService::fetchLastDate();
     $events = CacheService::getEvents($lastDate);
     CacheService::putEvents($events);
     $endTime = microtime(true);
     Logger::log("Tempo di fetch dei log:", $endTime - $startTime);
     return count($events);
 }