public class RestorePluginStateStoreTransactionCallbackDecorator extends Object implements org.springframework.transaction.support.TransactionCallback
PluginPersistentStateStorebefore execution and restore it after execution.
The assumption here is that the given callback is performing a site import which leads to
BackupImporter.deleteAllDatabaseContent() thus deleting the persisted state of the implementation. The
restoration has to be performed before any
#doImportInternal upgrades are performed, as any state changes in
the plugin system would cause the
MemoryPluginPersistentStateStore from the
to be synchronised. Thus an implementation like this is necessary instead of implementing the
or reacting on
ImportFinishedEvent as they happen after the upgrades have been performed.
|Constructor and Description|
|Modifier and Type||Method and Description|
public RestorePluginStateStoreTransactionCallbackDecorator(com.atlassian.plugin.manager.PluginPersistentStateStore pluginStateStore, org.springframework.transaction.support.TransactionCallback delegate)
public Object doInTransaction(org.springframework.transaction.TransactionStatus status)
Copyright © 2003–2016 Atlassian. All rights reserved.