CIAO::DomainDataManager Class Reference

Responsible for maintaining the Domain Information. More...

#include <DomainDataManager.h>

Collaboration diagram for CIAO::DomainDataManager:

Collaboration graph
[legend]
List of all members.

Public Member Functions

int update_domain (const ::CORBA::StringSeq &elements, const ::Deployment::Domain &domainSubset,::Deployment::DomainUpdateKind updateKind)
 This function is called by the other classes to update current domain data.
::Deployment::Domainget_initial_domain ()
 This function is called from the Executor code to get the Original Domain data.
::Deployment::Domainget_current_domain ()
 This function is called from the Executor code to get the Current Domain data.
void commitResources (const ::Deployment::DeploymentPlan &plan)
 returns the sequence of node managers object reference
void releaseResources (const ::Deployment::DeploymentPlan &plan)
 The function releases the resources held by a plan.
void stop_monitors ()
 The function makes a call on the leaveDomain on the NodeManager.
void commitResourceAllocation (const ::Deployment::ResourceAllocations &resources)
 The function allocates resources specified in the parameter.
void releaseResourceAllocation (const ::Deployment::ResourceAllocations &resources)
 The function releases resources specified in the parameter.

Static Public Member Functions

static DomainDataManagercreate (CORBA::ORB_ptr orb,::Deployment::TargetManager_ptr target)
 This function is called to create the Datamanager.
static DomainDataManagerget_data_manager ()
 Returns the static pointer to the data manager.
static void delete_data_manger ()
 deletes the data manager

Private Types

 commit
 release
enum  Action { commit, release }
 The different actiona that can take place. More...

Private Member Functions

 DomainDataManager (CORBA::ORB_ptr orb,::Deployment::TargetManager_ptr target)
int readin_domain_data ()
 It will read the initial Domain data from XML files.
void match_requirement_resource (::Deployment::InstanceResourceDeploymentDescriptions deployed,::Deployment::Resources &available)
 Match the deployed resources to the available resource.
void match_properties (::Deployment::Properties deployed,::Deployment::SatisfierProperties &available)
 Match the properties of a Requirement to the properties of available resource.
void commit_release_resource (::Deployment::Property &deployed,::Deployment::SatisfierProperty &available)
 Either commits or releases the given resource based on the current Action set.
int call_all_node_managers ()
 This function calls all NM and gives them the sub-domain.
int add_to_domain (const ::Deployment::Domain &domain)
 This function add new elements to the already existing domain.
int delete_from_domain (const ::Deployment::Domain &domain)
 This function deletes elements from the domain.
int intimate_planner (const ::Deployment::Domain &domain)
 This function intimates the planner about a domain change.
bool find_in_initial_domain (const char *node_name,::Deployment::Node &node)
 This function finds a new node in the initial_domain.
bool find_in_provisioned_domain (const char *node_name,::Deployment::Node &node)
 This function finds a new node in the proviosiond_domain.
bool update_node_status ()
 updates the node status by reading it from a file
::Deployment::Resourcefind_resource (const ::Deployment::ResourceAllocation &resource)
 It finds the Resource structure which is respresents the ResourceAllocation.
int commit_release_RA (const ::Deployment::ResourceAllocations &resources)

Private Attributes

CORBA::ORB_var orb_
 The ORB pointer.
CIAO::Deployment_Configuration deployment_config_
 The Deployment Configuration.
::Deployment::Domain initial_domain_
::Deployment::Domain current_domain_
::Deployment::TargetManager_var target_mgr_
 The Target Manager Context.
::Deployment::Domain provisioned_data_
::Deployment::Domain temp_provisioned_data_
Action current_action_
 The current action.

Static Private Attributes

static DomainDataManagerglobal_data_manager_ = 0
 The staic data member , replacing a global variable.

Detailed Description

Responsible for maintaining the Domain Information.

It maintains both the Current Domain Information as well as the Initial domain at full capacity.


Member Enumeration Documentation

enum CIAO::DomainDataManager::Action [private]

The different actiona that can take place.

Enumerator:
commit 
release 


Constructor & Destructor Documentation

CIAO::DomainDataManager::DomainDataManager ( CORBA::ORB_ptr  orb,
::Deployment::TargetManager_ptr  target 
) [private]

The constructor made protected so that no one can create it.

Parameters:
orb The orb pointer
target The Target Manager Object Reference


Member Function Documentation

int CIAO::DomainDataManager::add_to_domain ( const ::Deployment::Domain domain  )  [private]

This function add new elements to the already existing domain.

Parameters:
domain Deployment::Domain contians the new elements

int CIAO::DomainDataManager::call_all_node_managers (  )  [private]

This function calls all NM and gives them the sub-domain.

int CIAO::DomainDataManager::commit_release_RA ( const ::Deployment::ResourceAllocations resources  )  [private]

void CIAO::DomainDataManager::commit_release_resource ( ::Deployment::Property deployed,
::Deployment::SatisfierProperty available 
) [private]

Either commits or releases the given resource based on the current Action set.

Parameters:
deployed Deployment::Property is the resource to be commited/released
available Deployment::SatisfierProperty is the available resource from which committed/released.
Exceptions:
Deployment::ResourceNotAvailable thrown when the deployed resources exceeds the available resource.

void CIAO::DomainDataManager::commitResourceAllocation ( const ::Deployment::ResourceAllocations resources  ) 

The function allocates resources specified in the parameter.

This function is for the ResourceCommitmentManager

void CIAO::DomainDataManager::commitResources ( const ::Deployment::DeploymentPlan plan  ) 

returns the sequence of node managers object reference

CIAO::DomainDataManager * CIAO::DomainDataManager::create ( CORBA::ORB_ptr  orb,
::Deployment::TargetManager_ptr  target 
) [static]

This function is called to create the Datamanager.

This function calls the constructor of the class Domain Data Manager

Parameters:
orb The orb pointer
target The Target Manager Object Reference

void CIAO::DomainDataManager::delete_data_manger (  )  [static]

deletes the data manager

int CIAO::DomainDataManager::delete_from_domain ( const ::Deployment::Domain domain  )  [private]

This function deletes elements from the domain.

Parameters:
domain Deployment::Domain contains the new elements in the domain

bool CIAO::DomainDataManager::find_in_initial_domain ( const char *  node_name,
::Deployment::Node node 
) [private]

This function finds a new node in the initial_domain.

Parameters:
node The name of the node which is to be searched

bool CIAO::DomainDataManager::find_in_provisioned_domain ( const char *  node_name,
::Deployment::Node node 
) [private]

This function finds a new node in the proviosiond_domain.

Parameters:
node The name of the node which is to be searched

Deployment::Resource & CIAO::DomainDataManager::find_resource ( const ::Deployment::ResourceAllocation resource  )  [private]

It finds the Resource structure which is respresents the ResourceAllocation.

find_resource

Deployment::Domain * CIAO::DomainDataManager::get_current_domain (  ) 

This function is called from the Executor code to get the Current Domain data.

Returns:
Domain* The Current Domain

CIAO::DomainDataManager * CIAO::DomainDataManager::get_data_manager (  )  [static]

Returns the static pointer to the data manager.

Returns:
DomainDataManager* The staic get_data_manger function returning the data_manager pointer

Deployment::Domain * CIAO::DomainDataManager::get_initial_domain (  ) 

This function is called from the Executor code to get the Original Domain data.

Returns:
Domain* The Initial Domain

int CIAO::DomainDataManager::intimate_planner ( const ::Deployment::Domain domain  )  [private]

This function intimates the planner about a domain change.

Parameters:
domain Deployment::Domain contains the new elements in the domain

void CIAO::DomainDataManager::match_properties ( ::Deployment::Properties  deployed,
::Deployment::SatisfierProperties available 
) [private]

Match the properties of a Requirement to the properties of available resource.

Parameters:
deployed The deployed Properties
available The available Properties

void CIAO::DomainDataManager::match_requirement_resource ( ::Deployment::InstanceResourceDeploymentDescriptions  deployed,
::Deployment::Resources available 
) [private]

Match the deployed resources to the available resource.

int CIAO::DomainDataManager::readin_domain_data (  )  [private]

It will read the initial Domain data from XML files.

void CIAO::DomainDataManager::releaseResourceAllocation ( const ::Deployment::ResourceAllocations resources  ) 

The function releases resources specified in the parameter.

This function is for the ResourceCommitmentManager

void CIAO::DomainDataManager::releaseResources ( const ::Deployment::DeploymentPlan plan  ) 

The function releases the resources held by a plan.

Parameters:
plan Deployment::DeploymentPlan the plan whose resources are to be released

void CIAO::DomainDataManager::stop_monitors (  ) 

The function makes a call on the leaveDomain on the NodeManager.

The node manager in turn stops the monitor

int CIAO::DomainDataManager::update_domain ( const ::CORBA::StringSeq &  elements,
const ::Deployment::Domain domainSubset,
::Deployment::DomainUpdateKind  updateKind 
)

This function is called by the other classes to update current domain data.

Parameters:
elements The string sequence of elements being updated
domainSubset The subset of the actual Domain to be updated
updateKind Specifies the update type eg. add, delete, update

bool CIAO::DomainDataManager::update_node_status (  )  [private]

updates the node status by reading it from a file


Member Data Documentation

Action CIAO::DomainDataManager::current_action_ [private]

The current action.

::Deployment::Domain CIAO::DomainDataManager::current_domain_ [private]

The Current Domain - contains resources at current capacity

CIAO::Deployment_Configuration CIAO::DomainDataManager::deployment_config_ [private]

The Deployment Configuration.

CIAO::DomainDataManager * CIAO::DomainDataManager::global_data_manager_ = 0 [static, private]

The staic data member , replacing a global variable.

::Deployment::Domain CIAO::DomainDataManager::initial_domain_ [private]

The Initial Domain - contains resources at total capacity

CORBA::ORB_var CIAO::DomainDataManager::orb_ [private]

The ORB pointer.

::Deployment::Domain CIAO::DomainDataManager::provisioned_data_ [private]

The static provisioned Domain data

::Deployment::TargetManager_var CIAO::DomainDataManager::target_mgr_ [private]

The Target Manager Context.

::Deployment::Domain CIAO::DomainDataManager::temp_provisioned_data_ [private]

temporary domain used in commit/release to guard against exceptions


The documentation for this class was generated from the following files:
Generated on Mon Apr 30 23:47:04 2007 for DAnCE by  doxygen 1.4.7-1