|
xrootd
|
#include <XrdCmsState.hh>

Public Types | |
| enum | StateType { Active = 0, Counts, FrontEnd, Space, Stage } |
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 |
| XrdCmsState::XrdCmsState | ( | ) |
References minNodeCnt, numActive, numStaging, currState, All_NoStage, All_Suspend, prevState, Suspended, NoStaging, feOK, noSpace, adminNoStage, adminSuspend, NoStageFile, SuspendFile, isMan, dataPort, and Enabled.
| XrdCmsState::~XrdCmsState | ( | ) | [inline] |
| void XrdCmsState::Enable | ( | ) |
References stat(), Update(), Stage, NoStageFile, Active, SuspendFile, myMutex, XrdSysMutex::Lock(), Enabled, prevState, currState, mySemaphore, XrdSysSemaphore::Post(), and XrdSysMutex::UnLock().
Referenced by XrdCmsConfig::DoIt().
| void * XrdCmsState::Monitor | ( | ) |
References XrdCms::kYR_status, mySemaphore, XrdSysSemaphore::Wait(), myMutex, XrdSysMutex::Lock(), currState, prevState, dataPort, XrdSysMutex::UnLock(), XrdCms::CmsStatusRequest::Hdr, XrdCms::CmsRRHdr::modifier, Status(), XrdCms::CmsRRHdr::streamid, isMan, SRV_Suspend, XrdCms::RTable, XrdCmsRTable::Send(), XrdCms::Manager, and XrdCmsManager::Inform().
Referenced by XrdCmsStartMonStat().
| int XrdCmsState::Port | ( | ) |
References myMutex, XrdSysMutex::Lock(), dataPort, and XrdSysMutex::UnLock().
Referenced by XrdCmsProtocol::Pander().
| void XrdCmsState::sendState | ( | XrdLink * | Link | ) |
References XrdCms::kYR_status, myMutex, XrdSysMutex::Lock(), XrdCms::CmsStatusRequest::Hdr, XrdCms::CmsRRHdr::modifier, Suspended, NoStaging, XrdLink::Send(), and XrdSysMutex::UnLock().
Referenced by XrdCmsNode::do_Update().
| void XrdCmsState::Set | ( | int | ncount | ) |
References myMutex, XrdSysMutex::Lock(), minNodeCnt, and XrdSysMutex::UnLock().
Referenced by XrdCmsCluster::Add(), and XrdCmsConfig::Configure2().
| void XrdCmsState::Set | ( | int | ncount, |
| int | isman, | ||
| const char * | AdminPath | ||
| ) |
References minNodeCnt, isMan, NoStageFile, and SuspendFile.
| unsigned char XrdCmsState::Status | ( | int | Changes, |
| int | theState | ||
| ) | [private] |
References All_Suspend, All_NoStage, and Say.
Referenced by Monitor().
| void XrdCmsState::Update | ( | StateType | StateT, |
| int | ActivVal, | ||
| int | StageVal = 0 |
||
| ) |
References EPNAME, myMutex, XrdSysMutex::Lock(), Active, adminSuspend, unlink(), SuspendFile, close, open(), S_IRUSR, S_IWUSR, Counts, numStaging, numActive, FrontEnd, feOK, dataPort, Space, noSpace, Stage, adminNoStage, NoStageFile, Say, DEBUG, currState, minNodeCnt, SRV_Suspend, All_NoStage, FES_Suspend, Suspended, All_Suspend, NoStaging, prevState, Enabled, mySemaphore, XrdSysSemaphore::Post(), and XrdSysMutex::UnLock().
Referenced by XrdCmsAdmin::Login(), XrdCmsAdmin::Notes(), XrdCmsAdmin::do_Login(), XrdCmsCluster::Add(), XrdCmsCluster::Remove(), XrdCmsConfig::Configure2(), XrdCmsConfig::DoIt(), XrdCmsConfig::MergeP(), XrdCmsMeter::Init(), XrdCmsMeter::RunFS(), XrdCmsNode::do_Status(), and Enable().
char XrdCmsState::adminNoStage [private] |
Referenced by XrdCmsState(), and Update().
char XrdCmsState::adminSuspend [private] |
Referenced by XrdCmsState(), and Update().
const char XrdCmsState::All_NoStage = 4 [static] |
Referenced by XrdCmsState(), Status(), and Update().
const char XrdCmsState::All_Suspend = 3 [static] |
Referenced by XrdCmsState(), Status(), and Update().
char XrdCmsState::currState [private] |
Referenced by XrdCmsState(), Enable(), Monitor(), and Update().
int XrdCmsState::dataPort [private] |
Referenced by XrdCmsState(), Monitor(), Port(), and Update().
char XrdCmsState::Enabled [private] |
Referenced by XrdCmsState(), Enable(), and Update().
char XrdCmsState::feOK [private] |
Referenced by XrdCmsState(), and Update().
const char XrdCmsState::FES_Suspend = 2 [static] |
Referenced by Update().
char XrdCmsState::isMan [private] |
Referenced by XrdCmsState(), Monitor(), and Set().
int XrdCmsState::minNodeCnt [private] |
Referenced by XrdCmsState(), Set(), and Update().
XrdSysMutex XrdCmsState::myMutex [private] |
XrdSysSemaphore XrdCmsState::mySemaphore [private] |
char XrdCmsState::noSpace [private] |
Referenced by XrdCmsState(), and Update().
const char* XrdCmsState::NoStageFile [private] |
Referenced by XrdCmsState(), Enable(), Set(), and Update().
Referenced by XrdCmsProtocol::Pander(), XrdCmsState(), sendState(), and Update().
int XrdCmsState::numActive [private] |
Referenced by XrdCmsState(), and Update().
int XrdCmsState::numStaging [private] |
Referenced by XrdCmsState(), and Update().
char XrdCmsState::prevState [private] |
Referenced by XrdCmsState(), Enable(), Monitor(), and Update().
const char XrdCmsState::SRV_Suspend = 1 [static] |
const char* XrdCmsState::SuspendFile [private] |
Referenced by XrdCmsState(), Enable(), Set(), and Update().
1.7.5