com.atlassian.confluence.plugin
Class ConfluencePluginManager

java.lang.Object
  extended by com.atlassian.plugin.DefaultPluginManager
      extended by com.atlassian.confluence.plugin.ConfluencePluginManager
All Implemented Interfaces:
com.atlassian.plugin.PluginAccessor, com.atlassian.plugin.PluginController, com.atlassian.plugin.PluginManager, java.util.EventListener, org.springframework.context.ApplicationListener
Direct Known Subclasses:
BootstrapPluginManager

public class ConfluencePluginManager
extends com.atlassian.plugin.DefaultPluginManager
implements org.springframework.context.ApplicationListener

Extension of DefaultPluginManager which listens for plugin events fired on other nodes.


Field Summary
 
Fields inherited from interface com.atlassian.plugin.PluginManager
PLUGIN_DESCRIPTOR_FILENAME
 
Constructor Summary
ConfluencePluginManager(com.atlassian.plugin.PluginStateStore pluginStateStore, java.util.List pluginLoaders, com.atlassian.plugin.ModuleDescriptorFactory moduleDescriptorFactory, BootstrapManager bootstrapManager, boolean extractBundledPlugins)
          If you pass a String in the list of pluginLoaders, it will automagically be converted into a SinglePluginLoader for a file with that string's name.
 
Method Summary
protected  java.util.List getContentsOfBundledPluginsDir()
           
protected  com.atlassian.plugin.PluginStateStore getLocalPluginStateStore()
           
protected  com.atlassian.plugin.PluginManagerState getState()
           
 void init()
           
protected  void notifyModuleDisabled(com.atlassian.plugin.ModuleDescriptor module)
           
protected  void notifyModuleEnabled(com.atlassian.plugin.ModuleDescriptor module)
           
protected  void notifyPluginDisabled(com.atlassian.plugin.Plugin plugin)
           
protected  void notifyPluginEnabled(com.atlassian.plugin.Plugin plugin)
           
protected  void notifyUninstallPlugin(com.atlassian.plugin.Plugin plugin)
           
 void onApplicationEvent(org.springframework.context.ApplicationEvent event)
          Initialised the plugin system on receipt of a ConfluenceReadyEvent and update local plugin state on clustered plugin events
 void setUberClassLoader(DynamicMultiDelegationClassLoader uberClassLoader)
           
 
Methods inherited from class com.atlassian.plugin.DefaultPluginManager
addPlugin, disablePlugin, disablePluginModule, disablePluginModuleState, disablePluginState, enablePlugin, enablePluginModule, enablePluginModuleState, enablePluginState, getDynamicResourceAsStream, getEnabledModuleDescriptorsByClass, getEnabledModuleDescriptorsByType, getEnabledModulesByClass, getEnabledModulesByClassAndDescriptor, getEnabledModulesByClassAndDescriptor, getEnabledPlugin, getEnabledPluginModule, getEnabledPlugins, getEnabledStateAwareModuleKeys, getModuleDescriptors, getModules, getPlugin, getPluginModule, getPluginResourceAsStream, getPlugins, getPlugins, getStore, installPlugin, isPluginEnabled, isPluginModuleEnabled, isSystemPlugin, removeStateFromStore, scanForNewPlugins, setDescriptorParserFactory, setPluginInstaller, uninstall, unloadPlugin, updatePlugin
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ConfluencePluginManager

public ConfluencePluginManager(com.atlassian.plugin.PluginStateStore pluginStateStore,
                               java.util.List pluginLoaders,
                               com.atlassian.plugin.ModuleDescriptorFactory moduleDescriptorFactory,
                               BootstrapManager bootstrapManager,
                               boolean extractBundledPlugins)
If you pass a String in the list of pluginLoaders, it will automagically be converted into a SinglePluginLoader for a file with that string's name.

Method Detail

getLocalPluginStateStore

protected com.atlassian.plugin.PluginStateStore getLocalPluginStateStore()
Returns:
a writable memory implementation for storing local plugin state independent of other nodes in the cluster.

getState

protected com.atlassian.plugin.PluginManagerState getState()
Overrides:
getState in class com.atlassian.plugin.DefaultPluginManager

notifyPluginEnabled

protected void notifyPluginEnabled(com.atlassian.plugin.Plugin plugin)
Overrides:
notifyPluginEnabled in class com.atlassian.plugin.DefaultPluginManager

notifyModuleDisabled

protected void notifyModuleDisabled(com.atlassian.plugin.ModuleDescriptor module)
Overrides:
notifyModuleDisabled in class com.atlassian.plugin.DefaultPluginManager

notifyPluginDisabled

protected void notifyPluginDisabled(com.atlassian.plugin.Plugin plugin)
Overrides:
notifyPluginDisabled in class com.atlassian.plugin.DefaultPluginManager

notifyModuleEnabled

protected void notifyModuleEnabled(com.atlassian.plugin.ModuleDescriptor module)
Overrides:
notifyModuleEnabled in class com.atlassian.plugin.DefaultPluginManager

notifyUninstallPlugin

protected void notifyUninstallPlugin(com.atlassian.plugin.Plugin plugin)
Overrides:
notifyUninstallPlugin in class com.atlassian.plugin.DefaultPluginManager

init

public void init()
          throws com.atlassian.plugin.PluginParseException
Specified by:
init in interface com.atlassian.plugin.PluginManager
Overrides:
init in class com.atlassian.plugin.DefaultPluginManager
Throws:
com.atlassian.plugin.PluginParseException

onApplicationEvent

public void onApplicationEvent(org.springframework.context.ApplicationEvent event)
Initialised the plugin system on receipt of a ConfluenceReadyEvent and update local plugin state on clustered plugin events

Specified by:
onApplicationEvent in interface org.springframework.context.ApplicationListener
Parameters:
event -

getContentsOfBundledPluginsDir

protected java.util.List getContentsOfBundledPluginsDir()

setUberClassLoader

public void setUberClassLoader(DynamicMultiDelegationClassLoader uberClassLoader)


Copyright © 2003-2008 Atlassian Pty Ltd. All Rights Reserved.