You are here

function radioactivity_process_memcached_entries in Radioactivity 6

Same name and namespace in other branches
  1. 5 radioactivity.module \radioactivity_process_memcached_entries()
1 call to radioactivity_process_memcached_entries()
radioactivity_cron in ./radioactivity.module

File

./radioactivity.module, line 254

Code

function radioactivity_process_memcached_entries() {
  list($start_entry_id, $stop_entry_id) = radioactivity_memcache_get_unprocessed_range();
  $combined = radioactivity_group_memcache_entries($start_entry_id, $stop_entry_id);

  // execute combined
  foreach ($combined as $oid => $rest1) {
    foreach ($rest1 as $oclass => $rest2) {
      foreach ($rest2 as $source => $times) {
        _radioactivity_add_energy_internal($oid, $oclass, $source, $times);
      }
    }
  }
  dmemcache_set('entry_id_processed', $stop_entry_id, 0, 'radioactivity');
}