@ParametersAreNonnullByDefault public class ApplicationConfigurationLicenseStore extends Object implements LicenseStore, ConfluenceBootstrapConstants
ATLASSIAN_LICENSE_KEY, ATTACHMENTS_DIR_PROP, CONFLUENCE_HOME_CONSTANT, CONFLUENCE_LOCAL_HOME_CONSTANT, DEFAULT_LICENSE_REGISTRY_KEY, GLOBAL_PLUGIN_STATE, INSTALLATION_DATE_KEY, LICENSE_HASH_KEY, LICENSE_MESSAGE_KEY, LUCENE_INDEX_DIR_PROP, TEMP_DIR_PROP, WEBAPP_CONTEXT_PATH_KEY| Constructor and Description |
|---|
ApplicationConfigurationLicenseStore(com.atlassian.config.ApplicationConfiguration store,
com.atlassian.extras.api.LicenseManager manager) |
| Modifier and Type | Method and Description |
|---|---|
void |
clearLicenseFromMemory()
Clears the currently installed from memory, causing it to be re-read from persistent the next time
LicenseStore.retrieve() is called. |
void |
install(String licenseString)
This delegates to
ApplicationConfiguration.setProperty(Object, Object) but the underlying code does not
call ApplicationConfiguration.save() and is thus only in memory for the time being. |
void |
installTransiently(String licenseString)
Attempts to install the given license transiently.
|
void |
onRemoteEvent(ClusterEventWrapper wrapper) |
com.atlassian.extras.api.AtlassianLicense |
retrieve()
Retrieves the currently installed license.
|
public ApplicationConfigurationLicenseStore(com.atlassian.config.ApplicationConfiguration store,
com.atlassian.extras.api.LicenseManager manager)
public void install(String licenseString)
ApplicationConfiguration.setProperty(Object, Object) but the underlying code does not
call ApplicationConfiguration.save() and is thus only in memory for the time being.
This method does not allow concurrent invocation, thus escaping if one was detected. The reason being is that a concurrent license installation could lead to unexpected behaviour, thus we let the first invocation win and encourage the second one to be re-evaluated before being attempted again.
install in interface LicenseStorelicenseString - the encrypted licenseLicenseService.validate(String)public void installTransiently(String licenseString)
LicenseStoreinstallTransiently in interface LicenseStorepublic void clearLicenseFromMemory()
LicenseStoreLicenseStore.retrieve() is called. It is provided for testing purposes only.clearLicenseFromMemory in interface LicenseStore@Nonnull public com.atlassian.extras.api.AtlassianLicense retrieve()
LicenseStoreretrieve in interface LicenseStore@EventListener public void onRemoteEvent(ClusterEventWrapper wrapper)
Copyright © 2003–2016 Atlassian. All rights reserved.