public class BackupXmlConfigurationPersister extends XmlConfigurationPersister
ConfigurationPersister.PersistenceResource, ConfigurationPersister.SnapshotInfoNULL_SNAPSHOT_INFO| Constructor and Description |
|---|
BackupXmlConfigurationPersister(ConfigurationFile file,
QName rootElement,
org.jboss.staxmapper.XMLElementReader<List<org.jboss.dmr.ModelNode>> rootParser,
org.jboss.staxmapper.XMLElementWriter<ModelMarshallingContext> rootDeparser)
Construct a new instance.
|
BackupXmlConfigurationPersister(ConfigurationFile file,
QName rootElement,
org.jboss.staxmapper.XMLElementReader<List<org.jboss.dmr.ModelNode>> rootParser,
org.jboss.staxmapper.XMLElementWriter<ModelMarshallingContext> rootDeparser,
boolean reload,
boolean allowEmpty)
Construct a new instance.
|
| Modifier and Type | Method and Description |
|---|---|
void |
deleteSnapshot(String name)
Deletes a snapshot using its name.
|
ConfigurationPersister.SnapshotInfo |
listSnapshots()
Gets the names of the snapshots in the snapshots directory
|
void |
registerAdditionalRootElement(QName anotherRoot,
org.jboss.staxmapper.XMLElementReader<List<org.jboss.dmr.ModelNode>> parser) |
String |
snapshot()
Take a snapshot of the current configuration
|
ConfigurationPersister.PersistenceResource |
store(org.jboss.dmr.ModelNode model,
Set<PathAddress> affectedAddresses)
Persist the given configuration model.
|
void |
successfulBoot()
Called once the xml has been successfully parsed, translated into updates, executed in the target controller
and all services have started successfully
|
load, successfulBootmarshallAsXml, registerSubsystemWriter, unregisterSubsystemWriterpublic BackupXmlConfigurationPersister(ConfigurationFile file, QName rootElement, org.jboss.staxmapper.XMLElementReader<List<org.jboss.dmr.ModelNode>> rootParser, org.jboss.staxmapper.XMLElementWriter<ModelMarshallingContext> rootDeparser)
file - the configuration base filerootElement - the root element of the configuration filerootParser - the root model parserrootDeparser - the root model deparserpublic BackupXmlConfigurationPersister(ConfigurationFile file, QName rootElement, org.jboss.staxmapper.XMLElementReader<List<org.jboss.dmr.ModelNode>> rootParser, org.jboss.staxmapper.XMLElementWriter<ModelMarshallingContext> rootDeparser, boolean reload, boolean allowEmpty)
file - the configuration base filerootElement - the root element of the configuration filerootParser - the root model parserrootDeparser - the root model deparserreload - true if this is a reloadallowEmpty - true if it is ok if ConfigurationFile.getBootFile() points to an empty filepublic void registerAdditionalRootElement(QName anotherRoot, org.jboss.staxmapper.XMLElementReader<List<org.jboss.dmr.ModelNode>> parser)
registerAdditionalRootElement in class XmlConfigurationPersisterpublic void successfulBoot()
throws ConfigurationPersistenceException
ConfigurationPersistersuccessfulBoot in interface ConfigurationPersistersuccessfulBoot in class AbstractConfigurationPersisterConfigurationPersistenceExceptionpublic ConfigurationPersister.PersistenceResource store(org.jboss.dmr.ModelNode model, Set<PathAddress> affectedAddresses) throws ConfigurationPersistenceException
XmlConfigurationPersisterstore in interface ConfigurationPersisterstore in class XmlConfigurationPersistermodel - the model to persistConfigurationPersistenceExceptionpublic String snapshot() throws ConfigurationPersistenceException
ConfigurationPersistersnapshot in interface ConfigurationPersistersnapshot in class XmlConfigurationPersisterConfigurationPersistenceException - if a problem happened when creating the snapshotpublic ConfigurationPersister.SnapshotInfo listSnapshots()
ConfigurationPersisterlistSnapshots in interface ConfigurationPersisterlistSnapshots in class AbstractConfigurationPersisterpublic void deleteSnapshot(String name)
ConfigurationPersisterdeleteSnapshot in interface ConfigurationPersisterdeleteSnapshot in class AbstractConfigurationPersistername - the name of the snapshot (as returned by ConfigurationPersister.SnapshotInfo.names() returned from ConfigurationPersister.listSnapshots(). The whole name is not
needed, just enough to uniquely identify it.Copyright © 2017 JBoss by Red Hat. All rights reserved.