Exemplo n.º 1
0
 /** {@inheritDoc} */
 public void run() {
   try {
     INSTANCES.cleanUp();
     rotatingWriter.writeAll(tcStore.getLocalKeys());
     onSnapshot();
   } catch (Throwable e) {
     LOG.error("Couldn't snapshot local keySet for Cache {}", cacheName, e);
   }
 }
Exemplo n.º 2
0
 /**
  * Calling this method will result in a snapshot being taken or wait for the one in progress to
  * finish
  *
  * @throws IOException On exception being thrown while doing the snapshot
  */
 void doSnapshot() throws IOException {
   rotatingWriter.snapshotNowOrWaitForCurrentToFinish(tcStore.getLocalKeys());
   onSnapshot();
 }