Package flumotion :: Package manager :: Module component :: Class ComponentHeaven
[show private | hide private]
[frames | no frames]

Class ComponentHeaven

             Loggable --+    
                        |    
Jellyable --+           |    
            |           |    
 Serializable --+       |    
                |       |    
    Referenceable --+   |    
                    |   |    
                 Root --+    
                        |    
            ManagerHeaven --+
                            |
                           ComponentHeaven


I handle all registered components and provide avatars for them.
Method Summary
  __init__(self, vishnu)
  checkComponentStart(self, readiness, componentAvatar)
Check if the component can start up, and start it if it can.
  loadConfiguration(self, filename, string)
  registerComponent(self, componentAvatar)
This function registers a component in the heaven.
  removeComponent(self, componentAvatar)
Remove a component avatar from the heaven.
  setFeederReadiness(self, componentAvatar, feedName, readiness)
Tell the feeder set that the given feed on the given component is ready.
  unregisterComponent(self, componentAvatar)
This function unregisters a component in the heaven.
  _componentIsLocal(self, componentAvatar)
tuple with 3 items _getComponentEatersData(self, componentAvatar)
Retrieve the information about the feeders this component's eaters are eating from.
tuple of doubles _getComponentFeedersData(self, componentAvatar)
Retrieves the data of feeders (feed producer elements) for a component.
  _getFeederSet(self, componentAvatar)
  _startComponent(self, componentAvatar)
    Inherited from ManagerHeaven
flumotion.manager.admin.AdminAvatar createAvatar(self, avatarId)
Create a new administration avatar and manage it.
ManagerAvatar getAvatar(self, avatarId)
Get the avatar with the given id.
list of ManagerAvatar getAvatars(self)
Get all avatars in this heaven.
boolean hasAvatar(self, avatarId)
Check if a component with that name is registered.
  removeAvatar(self, avatarId)
Stop managing the given avatar.
    Inherited from Root
  rootObject(self, broker)
A pb.BrokerFactory is requesting to publish me as a root object.
    Inherited from Referenceable
  jellyFor(self, jellier)
(internal)
  remoteMessageReceived(self, broker, message, args, kw)
A remote message has been received.
    Inherited from Serializable
  processUniqueID(self)
Return an ID which uniquely represents this object for this process.
    Inherited from Jellyable
  getStateFor(self, jellier)
    Inherited from Loggable
  debug(self, *args)
Log a debug message.
  error(self, *args)
Log an error.
  info(self, *args)
Log an informational message.
  log(self, *args)
Log a log message.
  logFunction(self, message)
Overridable log function.
  logObjectName(self)
Overridable object name function.
  warning(self, *args)
Log a warning.
  warningFailure(self, failure)
Log a warning about a Failure.

Class Variable Summary
MetaInterface __implements__ = flumotion.common.interfaces.IHeaven
classobj avatarClass = flumotion.manager.component.ComponentAvatar
str logCategory: Implementors can provide a category to log their messages under.
    Inherited from Referenceable
NoneType perspective = None                                                                  

Method Details

__init__(self, vishnu)
(Constructor)

Parameters:
vishnu - the Vishnu object this heaven belongs to
           (type=flumotion.manager.manager.Vishnu)
Overrides:
flumotion.manager.base.ManagerHeaven.__init__

checkComponentStart(self, readiness, componentAvatar)

Check if the component can start up, and start it if it can. This depends on whether the components and feeders it depends on have started.

registerComponent(self, componentAvatar)

This function registers a component in the heaven. It is triggered when the mind is attached.
Parameters:
componentAvatar
           (type=flumotion.manager.component.ComponentAvatar)

removeComponent(self, componentAvatar)

Remove a component avatar from the heaven.
Parameters:
componentAvatar - the component
           (type=flumotion.manager.component.ComponentAvatar)

setFeederReadiness(self, componentAvatar, feedName, readiness)

Tell the feeder set that the given feed on the given component is ready.
Parameters:
componentAvatar - the component containing the feed
           (type=string)
feedName - the feed set to ready
           (type=string)
readiness
           (type=boolean)

unregisterComponent(self, componentAvatar)

This function unregisters a component in the heaven. It is triggered when the mind is detached.
Parameters:
componentAvatar
           (type=flumotion.manager.component.ComponentAvatar)

_getComponentEatersData(self, componentAvatar)

Retrieve the information about the feeders this component's eaters are eating from.
Parameters:
componentAvatar - the component
           (type=flumotion.manager.component.ComponentAvatar)
Returns:
tuple of feeder name, host name and port, or None
           (type=tuple with 3 items)

_getComponentFeedersData(self, componentAvatar)

Retrieves the data of feeders (feed producer elements) for a component.
Parameters:
componentAvatar - the component
           (type=flumotion.manager.component.ComponentAvatar)
Returns:
tuple of (name, host) for each feeder
           (type=tuple of doubles)

Class Variable Details

logCategory

Implementors can provide a category to log their messages under.
Type:
str
Value:
'comp-heaven'                                                          

Generated by Epydoc 2.1 on Tue Dec 20 15:33:10 2005 http://epydoc.sf.net