XrdCmsState Class Reference

#include <XrdCmsState.hh>

List of all members.

Public Types

enum  StateType

Public Member Functions

void Enable ()
void * Monitor ()
int Port ()
void sendState (XrdLink *Link)
void Set (int ncount)
void Set (int ncount, int isman, const char *AdminPath)
void Update (StateType StateT, int ActivVal, int StageVal=0)
 XrdCmsState ()
 ~XrdCmsState ()

Public Attributes

int Suspended
int NoStaging

Static Public Attributes

static const char SRV_Suspend = 1
static const char FES_Suspend = 2
static const char All_Suspend = 3
static const char All_NoStage = 4

Private Member Functions

unsigned char Status (int Changes, int theState)

Private Attributes

XrdSysSemaphore mySemaphore
XrdSysMutex myMutex
const char * NoStageFile
const char * SuspendFile
int minNodeCnt
int numActive
int numStaging
int dataPort
char currState
char prevState
char feOK
char noSpace
char adminSuspend
char adminNoStage
char isMan
char Enabled


Detailed Description

Definition at line 20 of file XrdCmsState.hh.


Member Enumeration Documentation

enum XrdCmsState::StateType

Definition at line 38 of file XrdCmsState.hh.


Constructor & Destructor Documentation

XrdCmsState::XrdCmsState (  ) 

Definition at line 47 of file XrdCmsState.cc.

References adminNoStage, adminSuspend, All_NoStage, All_Suspend, currState, dataPort, Enabled, feOK, isMan, minNodeCnt, noSpace, NoStageFile, NoStaging, numActive, numStaging, prevState, Suspended, and SuspendFile.

XrdCmsState::~XrdCmsState (  )  [inline]

Definition at line 43 of file XrdCmsState.hh.


Member Function Documentation

void XrdCmsState::Enable (  ) 

Definition at line 71 of file XrdCmsState.cc.

References Active, currState, Enabled, XrdSysMutex::Lock(), myMutex, mySemaphore, NoStageFile, XrdSysSemaphore::Post(), prevState, Stage, stat, SuspendFile, XrdSysMutex::UnLock(), and Update().

Referenced by XrdCmsConfig::DoIt().

void * XrdCmsState::Monitor (  ) 

Definition at line 97 of file XrdCmsState.cc.

References currState, dataPort, XrdCms::CmsStatusRequest::Hdr, XrdCmsManager::Inform(), isMan, XrdCms::kYR_status, XrdSysMutex::Lock(), XrdCms::Manager, XrdCms::CmsRRHdr::modifier, myMutex, mySemaphore, prevState, XrdCms::RTable, XrdCmsRTable::Send(), SRV_Suspend, Status(), XrdCms::CmsRRHdr::streamid, XrdSysMutex::UnLock(), and XrdSysSemaphore::Wait().

Referenced by XrdCmsStartMonStat().

int XrdCmsState::Port (  ) 

Definition at line 133 of file XrdCmsState.cc.

References dataPort, XrdSysMutex::Lock(), myMutex, and XrdSysMutex::UnLock().

Referenced by XrdCmsProtocol::Pander().

void XrdCmsState::sendState ( XrdLink Link  ) 

Definition at line 147 of file XrdCmsState.cc.

References XrdCms::CmsStatusRequest::Hdr, XrdCms::kYR_status, XrdSysMutex::Lock(), XrdCms::CmsRRHdr::modifier, myMutex, NoStaging, XrdLink::Send(), Suspended, and XrdSysMutex::UnLock().

Referenced by XrdCmsNode::do_Update().

void XrdCmsState::Set ( int  ncount  ) 

Definition at line 168 of file XrdCmsState.cc.

References XrdSysMutex::Lock(), minNodeCnt, myMutex, and XrdSysMutex::UnLock().

Referenced by XrdCmsCluster::Add(), and XrdCmsConfig::Configure2().

void XrdCmsState::Set ( int  ncount,
int  isman,
const char *  AdminPath 
)

Definition at line 180 of file XrdCmsState.cc.

References i, isMan, minNodeCnt, NoStageFile, strcpy(), and SuspendFile.

void XrdCmsState::Update ( StateType  StateT,
int  ActivVal,
int  StageVal = 0 
)

Definition at line 244 of file XrdCmsState.cc.

References Active, adminNoStage, adminSuspend, All_NoStage, All_Suspend, close, Counts, currState, dataPort, DEBUG, XrdSysError::Emsg(), Enabled, EPNAME, feOK, FES_Suspend, FrontEnd, XrdSysMutex::Lock(), minNodeCnt, myMutex, mySemaphore, noSpace, NoStageFile, NoStaging, numActive, numStaging, open, XrdSysSemaphore::Post(), prevState, S_IRUSR, S_IWUSR, XrdFrm::Say(), Space, SRV_Suspend, Stage, Suspended, SuspendFile, unlink, XrdSysMutex::UnLock(), and RooFit::What().

Referenced by XrdCmsCluster::Add(), XrdCmsConfig::Configure2(), XrdCmsAdmin::do_Login(), XrdCmsNode::do_Status(), XrdCmsConfig::DoIt(), Enable(), XrdCmsMeter::Init(), XrdCmsAdmin::Login(), XrdCmsConfig::MergeP(), XrdCmsAdmin::Notes(), XrdCmsCluster::Remove(), and XrdCmsMeter::RunFS().

unsigned char XrdCmsState::Status ( int  Changes,
int  theState 
) [private]

Definition at line 202 of file XrdCmsState.cc.

References All_NoStage, All_Suspend, XrdSysError::Emsg(), and XrdFrm::Say().

Referenced by Monitor().


Member Data Documentation

int XrdCmsState::Suspended

Definition at line 24 of file XrdCmsState.hh.

Referenced by XrdCmsProtocol::Admit(), XrdCmsProtocol::Admit_Redirector(), XrdCmsProtocol::Execute(), XrdCmsProtocol::Pander(), sendState(), Update(), and XrdCmsState().

int XrdCmsState::NoStaging

Definition at line 25 of file XrdCmsState.hh.

Referenced by XrdCmsProtocol::Pander(), sendState(), Update(), and XrdCmsState().

const char XrdCmsState::SRV_Suspend = 1 [static]

Definition at line 45 of file XrdCmsState.hh.

Referenced by Monitor(), and Update().

const char XrdCmsState::FES_Suspend = 2 [static]

Definition at line 46 of file XrdCmsState.hh.

Referenced by XrdCmsProtocol::Pander(), and Update().

const char XrdCmsState::All_Suspend = 3 [static]

Definition at line 47 of file XrdCmsState.hh.

Referenced by XrdCmsProtocol::Pander(), Status(), Update(), and XrdCmsState().

const char XrdCmsState::All_NoStage = 4 [static]

Definition at line 48 of file XrdCmsState.hh.

Referenced by Status(), Update(), and XrdCmsState().

XrdSysSemaphore XrdCmsState::mySemaphore [private]

Definition at line 53 of file XrdCmsState.hh.

Referenced by Enable(), Monitor(), and Update().

XrdSysMutex XrdCmsState::myMutex [private]

Definition at line 54 of file XrdCmsState.hh.

Referenced by Enable(), Monitor(), Port(), sendState(), Set(), and Update().

const char* XrdCmsState::NoStageFile [private]

Definition at line 56 of file XrdCmsState.hh.

Referenced by Enable(), Set(), Update(), and XrdCmsState().

const char* XrdCmsState::SuspendFile [private]

Definition at line 57 of file XrdCmsState.hh.

Referenced by Enable(), Set(), Update(), and XrdCmsState().

int XrdCmsState::minNodeCnt [private]

Definition at line 59 of file XrdCmsState.hh.

Referenced by Set(), Update(), and XrdCmsState().

int XrdCmsState::numActive [private]

Definition at line 60 of file XrdCmsState.hh.

Referenced by Update(), and XrdCmsState().

int XrdCmsState::numStaging [private]

Definition at line 61 of file XrdCmsState.hh.

Referenced by Update(), and XrdCmsState().

int XrdCmsState::dataPort [private]

Definition at line 62 of file XrdCmsState.hh.

Referenced by Monitor(), Port(), Update(), and XrdCmsState().

char XrdCmsState::currState [private]

Definition at line 64 of file XrdCmsState.hh.

Referenced by Enable(), Monitor(), Update(), and XrdCmsState().

char XrdCmsState::prevState [private]

Definition at line 65 of file XrdCmsState.hh.

Referenced by Enable(), Monitor(), Update(), and XrdCmsState().

char XrdCmsState::feOK [private]

Definition at line 66 of file XrdCmsState.hh.

Referenced by Update(), and XrdCmsState().

char XrdCmsState::noSpace [private]

Definition at line 67 of file XrdCmsState.hh.

Referenced by Update(), and XrdCmsState().

char XrdCmsState::adminSuspend [private]

Definition at line 68 of file XrdCmsState.hh.

Referenced by Update(), and XrdCmsState().

char XrdCmsState::adminNoStage [private]

Definition at line 69 of file XrdCmsState.hh.

Referenced by Update(), and XrdCmsState().

char XrdCmsState::isMan [private]

Definition at line 70 of file XrdCmsState.hh.

Referenced by Monitor(), Set(), and XrdCmsState().

char XrdCmsState::Enabled [private]

Definition at line 71 of file XrdCmsState.hh.

Referenced by Enable(), Update(), and XrdCmsState().


The documentation for this class was generated from the following files:
Generated on Tue Jul 5 16:50:21 2011 for ROOT_528-00b_version by  doxygen 1.5.1