Class PropertiesFileCacheSettingsManager

    • Constructor Detail

      • PropertiesFileCacheSettingsManager

        public PropertiesFileCacheSettingsManager​(com.atlassian.dc.filestore.api.FileStore.Path settingsFile,
                                                  com.atlassian.beehive.ClusterLockService clusterLockService)
    • Method Detail

      • changeMaxEntries

        public Optional<Integer> changeMaxEntries​(@NonNull String name,
                                                  int newValue)
        Description copied from interface: CacheSettingsManager
        Persists updates to the max entries settings for the specified cache.

        Specified by:
        changeMaxEntries in interface CacheSettingsManager
        Parameters:
        name - the name of the cache to update
        Returns:
        the previous value of the specified max entries if any have
      • saveSettings

        public boolean saveSettings()
        Description copied from interface: CacheSettingsManager
        Persists all changes made so far by update* methods.

        Specified by:
        saveSettings in interface CacheSettingsManager
        Returns:
        true if changes were persisted successfully
      • getDefaults

        public @NonNull com.atlassian.cache.CacheSettings getDefaults​(@NonNull String cacheName)
        Specified by:
        getDefaults in interface com.atlassian.cache.CacheSettingsDefaultsProvider