eXo JCR :: Component :: Extension Service 1.16.0-CR2

org.exoplatform.services.jcr.ext.backup.impl
Class AbstractIncrementalBackupJob

java.lang.Object
  extended by org.exoplatform.services.jcr.ext.backup.impl.AbstractBackupJob
      extended by org.exoplatform.services.jcr.ext.backup.impl.AbstractIncrementalBackupJob
All Implemented Interfaces:
Runnable, ItemsPersistenceListener, BackupJob
Direct Known Subclasses:
IncrementalBackupJob

public abstract class AbstractIncrementalBackupJob
extends AbstractBackupJob
implements ItemsPersistenceListener

Created by The eXo Platform SARL .

Version:
$Id: $
Author:
Gennady Azarenkov

Field Summary
protected  CountDownLatch latcher
          Allows to make all threads waiting.
protected  List<ItemStateChangesLog> suspendBuffer
          Should be synchronized collection.
protected  AtomicInteger workingThreads
          The amount of current working threads.
 
Fields inherited from class org.exoplatform.services.jcr.ext.backup.impl.AbstractBackupJob
config, id, repository, state, timeStamp, url, workspaceName
 
Fields inherited from interface org.exoplatform.services.jcr.ext.backup.BackupJob
FINISHED, FULL, INCREMENTAL, STARTING, WAITING, WORKING
 
Constructor Summary
AbstractIncrementalBackupJob()
           
 
Method Summary
 int getType()
          Getting the type of job.
 void onSaveItems(ItemStateChangesLog chlog)
          
 URL resume()
           
 void run()
           
protected abstract  void save(ItemStateChangesLog log)
          Implementation specific saving
 void suspend()
           
 
Methods inherited from class org.exoplatform.services.jcr.ext.backup.impl.AbstractBackupJob
addListener, createStorage, getId, getState, getStorageURL, notifyError, notifyListeners, removeListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.exoplatform.services.jcr.dataflow.persistent.ItemsPersistenceListener
isTXAware
 
Methods inherited from interface org.exoplatform.services.jcr.ext.backup.BackupJob
init, stop
 

Field Detail

suspendBuffer

protected final List<ItemStateChangesLog> suspendBuffer
Should be synchronized collection.


workingThreads

protected AtomicInteger workingThreads
The amount of current working threads.


latcher

protected CountDownLatch latcher
Allows to make all threads waiting.

Constructor Detail

AbstractIncrementalBackupJob

public AbstractIncrementalBackupJob()
Method Detail

getType

public final int getType()
Description copied from interface: BackupJob
Getting the type of job.

Specified by:
getType in interface BackupJob
Returns:
int return the type of job

onSaveItems

public void onSaveItems(ItemStateChangesLog chlog)

Specified by:
onSaveItems in interface ItemsPersistenceListener

run

public final void run()
Specified by:
run in interface Runnable
See Also:
Runnable.run()

suspend

public final void suspend()

resume

public final URL resume()

save

protected abstract void save(ItemStateChangesLog log)
                      throws IOException
Implementation specific saving

Parameters:
log -
Throws:
IOException

eXo JCR :: Component :: Extension Service 1.16.0-CR2

Copyright © 2014 eXo Platform SAS. All Rights Reserved.