Ejemplo n.º 1
0
 public static void load(
     final Iterator<ProcedureWALFile> logs,
     final ProcedureStoreTracker tracker,
     final Loader loader)
     throws IOException {
   ProcedureWALFormatReader reader = new ProcedureWALFormatReader(tracker);
   tracker.setKeepDeletes(true);
   try {
     while (logs.hasNext()) {
       ProcedureWALFile log = logs.next();
       log.open();
       try {
         reader.read(log, loader);
       } finally {
         log.close();
       }
     }
     reader.finalize(loader);
     // The tracker is now updated with all the procedures read from the logs
     tracker.setPartialFlag(false);
     tracker.resetUpdates();
   } finally {
     tracker.setKeepDeletes(false);
   }
 }