Class PropertiesManager
java.lang.Object
com.atlassian.jira.config.properties.PropertiesManager
This class has undergone significant change in 4.4 to support the new in line database functionality. The 1st page of
setup may have no database - if that is the case you need to store properties in memory When the database is loaded
the properties from page 1 (primarily language) are cloned to a PropertySet that is backed by the DB. From that
point on any new PropertiesManager instances injected by the component container will be backed by database property
sets. The onDataBaseConfigured method is the entry point to indicate the database setup is complete.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncom.opensymphony.module.propertyset.PropertySet
Supplier<? extends com.opensymphony.module.propertyset.PropertySet>
Get a reference for when you need to look at the properties for a longer period of time.void
Called to indicate the database has been set up this causes the switch to a db-backed PropertySetvoid
refresh()
Refresh the properties from the database.
-
Constructor Details
-
PropertiesManager
-
-
Method Details
-
getPropertySet
public com.opensymphony.module.propertyset.PropertySet getPropertySet() -
getPropertySetReference
public Supplier<? extends com.opensymphony.module.propertyset.PropertySet> getPropertySetReference()Get a reference for when you need to look at the properties for a longer period of time.- Returns:
- a resettable reference to the global properties
-
refresh
public void refresh()Refresh the properties from the database. If called after creation and write operations called on the PropertySet yet before db setup, writes will be lost! -
onDatabaseConfigured
public void onDatabaseConfigured()Called to indicate the database has been set up this causes the switch to a db-backed PropertySet
-