public class MediationPersistenceManager extends Object
| Constructor and Description |
|---|
MediationPersistenceManager(String configPath,
org.apache.synapse.config.SynapseConfiguration synapseConfiguration,
long interval,
String configName)
Initialize the mediation persistence manager instance and start accepting
and processing persistence requests.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addCAppArtifactsAfterPersist(org.apache.synapse.config.SynapseConfiguration synapseConfiguration,
org.apache.synapse.config.SynapseConfiguration cAppConfig)
Add the CApp artifact configuration to the current configuration, after persist the other artifacts into the default location
|
void |
deleteItem(String name,
String fileName,
int itemType)
Delete a particular item in the saved mediation configuration.
|
void |
destroy() |
protected Lock |
getLock(org.apache.axis2.engine.AxisConfiguration axisConfig) |
boolean |
isInitialized() |
org.apache.synapse.config.SynapseConfiguration |
removeCAppArtifactsBeforePersist(org.apache.synapse.config.SynapseConfiguration synapseConfiguration) |
void |
saveFullConfiguration(boolean registryOnly)
Make a request to save the complete mediation configuration (the entire
SynapseConfiguration) to be saved to the file system and the registry.
|
void |
saveItem(String name,
int itemType)
Save changes made to a particular item of the mediation configuration.
|
public MediationPersistenceManager(String configPath, org.apache.synapse.config.SynapseConfiguration synapseConfiguration, long interval, String configName)
configPath - Path to the file/directory where configuration should be saved insynapseConfiguration - synapse configuration to be usedinterval - The wait time for the mediation persistence worker threadconfigName - Name of the configuration to be usedpublic void destroy()
public boolean isInitialized()
public void saveItem(String name, int itemType)
name - Name/ID of the configuration itemitemType - type of the configuration itempublic void deleteItem(String name, String fileName, int itemType)
name - Name/ID of the configuration itemfileName - Name of the file where the item is currently saved initemType - Type of the configuration itempublic void saveFullConfiguration(boolean registryOnly)
registryOnly - Whether or not to save the configuration to the registry onlypublic void addCAppArtifactsAfterPersist(org.apache.synapse.config.SynapseConfiguration synapseConfiguration,
org.apache.synapse.config.SynapseConfiguration cAppConfig)
synapseConfiguration - Current ConfigurationcAppConfig - CApp artifact configurationpublic org.apache.synapse.config.SynapseConfiguration removeCAppArtifactsBeforePersist(org.apache.synapse.config.SynapseConfiguration synapseConfiguration)
synapseConfiguration - Contains all the configuration includes CApp artifact configsprotected Lock getLock(org.apache.axis2.engine.AxisConfiguration axisConfig)
Copyright © 2019 WSO2. All rights reserved.