|
xrootd
|
#include <XrdCmsFinder.hh>


Public Member Functions | |
| void | Added (const char *path, int Pend=0) |
| int | Configure (const char *cfn, char *Args, XrdOucEnv *EnvInfo) |
| int | Forward (XrdOucErrInfo &Resp, const char *cmd, const char *arg1=0, const char *arg2=0, XrdOucEnv *Env1=0, XrdOucEnv *Env2=0) |
| int | Locate (XrdOucErrInfo &Resp, const char *path, int flags, XrdOucEnv *Info=0) |
| XrdOucTList * | Managers () |
| int | Prepare (XrdOucErrInfo &Resp, XrdSfsPrep &pargs, XrdOucEnv *Info=0) |
| void | Removed (const char *path) |
| void | setSS (XrdOss *thess) |
| int | Space (XrdOucErrInfo &Resp, const char *path, XrdOucEnv *Info=0) |
| XrdCmsFinderRMT (XrdSysLogger *lp, int whoami=0, int Port=0) | |
| ~XrdCmsFinderRMT () | |
Public Member Functions inherited from XrdCmsClient | |
| virtual int | isRemote () |
| virtual void | Resume (int Perm=1) |
| virtual void | Suspend (int Perm=1) |
| virtual int | Resource (int n) |
| virtual int | Reserve (int n=1) |
| virtual int | Release (int n=1) |
| XrdCmsClient (Persona acting) | |
| virtual | ~XrdCmsClient () |
| Destructor. More... | |
Static Public Member Functions | |
| static bool | VCheck (XrdVersionInfo &urVersion) |
Static Public Attributes | |
| static const int | MaxMan = 15 |
Private Member Functions | |
| int | Decode (char **resp) |
| void | Inform (XrdCmsClientMan *xman, struct iovec xmsg[], int xnum) |
| XrdCmsClientMan * | SelectManager (XrdOucErrInfo &Resp, const char *path) |
| void | SelectManFail (XrdOucErrInfo &Resp) |
| int | send2Man (XrdOucErrInfo &, const char *, struct iovec *, int) |
| int | StartManagers (XrdOucTList *) |
Private Attributes | |
| XrdCmsClientMan * | myManTable [MaxMan] |
| XrdCmsClientMan * | myManagers |
| XrdOucTList * | myManList |
| int | myManCount |
| XrdSysMutex | myData |
| char * | CMSPath |
| int | ConWait |
| int | RepDelay |
| int | RepNone |
| int | RepWait |
| int | FwdWait |
| int | PrepWait |
| int | isMeta |
| int | isProxy |
| int | isTarget |
| int | myPort |
| unsigned char | SMode |
| unsigned char | sendID |
| unsigned char | savePath |
Additional Inherited Members | |
Public Types inherited from XrdCmsClient | |
| enum | Persona { amLocal, amRemote, amTarget } |
Protected Attributes inherited from XrdCmsClient | |
| Persona | myPersona |
| XrdCmsFinderRMT::XrdCmsFinderRMT | ( | XrdSysLogger * | lp, |
| int | whoami = 0, |
||
| int | Port = 0 |
||
| ) |
References isMeta, XrdCms::IsMeta, isProxy, XrdCms::IsProxy, isTarget, XrdCms::IsTarget, myManagers, myManCount, myPort, savePath, Say, sendID, and SMode.
| XrdCmsFinderRMT::~XrdCmsFinderRMT | ( | ) |
References myManagers, and XrdCmsClientMan::nextManager().
|
inlinevirtual |
Notify the cms of a newly added file or a file whose state has changed on a data server node.
| path | The logical file name. |
| Pend | When true, the file is scheduled to be present in the future (e.g. copied in). |
Reimplemented from XrdCmsClient.
|
virtual |
Configure the client object.
| cfn | The configuration file name. |
| Parms | Any parameters specified in the cmslib directive. If none, the pointer may be null. |
| EnvInfo | Environmental information of the caller. |
Implements XrdCmsClient.
References XrdCmsClientConfig::CMSPath, CMSPath, XrdCmsClientConfig::configMan, XrdCmsClientConfig::configMeta, XrdCmsClientConfig::configNorm, XrdCmsClientConfig::configProxy, XrdCmsClientConfig::configSuper, XrdCmsClientConfig::Configure(), XrdCmsClientConfig::ConWait, ConWait, XrdCmsClientConfig::FwdWait, FwdWait, XrdOucEnv::GetPtr(), XrdCmsClientConfig::haveMeta, isMeta, isProxy, XrdCms::IsProxy, XrdCms::IsRedir, isTarget, XrdCmsClientConfig::ManList, myPort, XrdCmsClientConfig::PanList, XrdCmsClientConfig::PrepWait, PrepWait, QTRACE, XrdCmsClientConfig::RepDelay, RepDelay, XrdCmsClientConfig::RepNone, RepNone, XrdCmsClientConfig::RepWait, RepWait, XrdCmsFinderTRG::RunAdmin(), savePath, Say, XrdCmsClientMan::setConfig(), XrdCmsClientMan::setNetwork(), XrdCmsSecurity::setSecFunc(), XrdCmsClientConfig::SMode, SMode, XrdCmsClientConfig::SModeP, and StartManagers().
|
private |
|
virtual |
Relay a meta-operation to all nodes in the cluster.
This method is only used on manager nodes and is enabled by the ofs.forward directive.
| Resp | Object where messages are to be returned. |
| cmd | The operation being performed (see table below). If it starts with a '+' then a response (2way) is needed. Otherwise, a best-effort is all that is all that is required and success can always be returned. |
| arg1 | 1st argument to cmd. |
| arg2 | 2nd argument to cmd, which may be null if none exists. |
| Env1 | Associated environmental information for arg1 (e.g., cgi info which can be retrieved by Env1->Env(<len>)). |
| Env2 | Associated environmental information for arg2 (e.g., cgi info which can be retrieved by Env1->Env(<len>)). |
cmd arg1 arg2 cmd arg1 arg2
[+]chmod <path> <mode o> [+]rmdir <path> 0 [+]mkdir <path> <mode o> [+]mv <oldp> <newp> [+]mkpath <path> <mode o> [+]trunc <path> <size lld> [+]rm <path> 0
: As explained under "return conventions".
Reimplemented from XrdCmsClient.
References ConWait, XrdCmsClientMan::doDebug, XrdOucEnv::Env(), FwdWait, XrdOucErrInfo::getErrUser(), XrdCmsRRData::Ident, Inform(), XrdCms::kYR_chmod, XrdCms::kYR_dnf, XrdCms::kYR_mkdir, XrdCms::kYR_mkpath, XrdCms::kYR_mv, XrdCms::kYR_rm, XrdCms::kYR_rmdir, XrdCms::kYR_trunc, XrdSysMutex::Lock(), XrdCmsRRData::Mode, XrdCms::CmsRRHdr::modifier, XrdCmsRRData::Opaque, XrdCmsRRData::Opaque2, XrdCmsParser::Pack(), XrdCms::Parser, XrdCmsRRData::Path, XrdCmsRRData::Path2, RepDelay, XrdCmsRRData::Request, XrdCms::CmsRRHdr::rrCode, Say, SelectManager(), XrdCmsClientMan::Send(), send2Man(), XrdOucErrInfo::setErrInfo(), SFS_ERROR, XrdCms::CmsRRHdr::streamid, XrdSysMutex::UnLock(), and XrdSysTimer::Wait().
|
private |
References XrdCmsClientMan::isActive(), myManagers, XrdCmsClientMan::nextManager(), Say, and XrdCmsClientMan::Send().
Referenced by Forward().
|
virtual |
Retrieve file location information.
| Resp | Object where message or response is to be returned. |
| path | The logical path whise location is wanted. |
| flags | One or more of the following: SFS_O_LOCATE - return the list of servers that have the file.
Otherwise, redirect to the best server for the file.
SFS_O_NOWAIT - w/ SFS_O_LOCATE return readily available info.
Otherwise, select online files only.
SFS_O_CREAT - file will be created.
SFS_O_NOWAIT - select server if file is online.
SFS_O_REPLICA - a replica of the file will be made.
SFS_O_STAT - only stat() information wanted.
SFS_O_TRUNC - file will be truncated.
For any the the above, additional flags are passed:
SFS_O_META - data will not change (inode operation only)
SFS_O_RESET - reset cached info and recaculate the location(s).
SFS_O_WRONLY - file will be only written (o/w RDWR or RDONLY).
SFS_O_RDWR - file may be read and written (o/w WRONLY or RDONLY).
|
| Info | Associated environmental information for arg2 (e.g., cgi info which can be retrieved by Env1->Env(<len>)). |
Implements XrdCmsClient.
References XrdCmsRRData::Avoid, XrdCmsClientMan::doDebug, XrdOucEnv::Env(), XrdOucEnv::Get(), XrdOucErrInfo::getErrUser(), XrdCmsRRData::Ident, XrdCms::kYR_locate, XrdCms::kYR_select, XrdCms::kYR_trunc, XrdCms::CmsRRHdr::modifier, XrdCmsRRData::Opaque, XrdCmsRRData::Opts, XrdCmsParser::Pack(), XrdCms::Parser, XrdCmsRRData::Path, XrdCmsRRData::Request, XrdCms::CmsRRHdr::rrCode, send2Man(), XrdOucErrInfo::setErrInfo(), SFS_ERROR, SFS_O_CREAT, SFS_O_LOCATE, SFS_O_META, SFS_O_NOWAIT, SFS_O_RDWR, SFS_O_REPLICA, SFS_O_RESET, SFS_O_STAT, SFS_O_TRUNC, SFS_O_WRONLY, and XrdCms::CmsRRHdr::streamid.
|
inlinevirtual |
Obtain the list of cmsd's being used by a manager node along with their associated index numbers, origin 1.
Reimplemented from XrdCmsClient.
References myManList.
|
virtual |
Start the preparation of a file for future processing.
| Resp | Object where message or response is to be returned. |
| pargs | Information on which and how to prepare the file. |
| Info | Associated environmental information. |
Reimplemented from XrdCmsClient.
References ConWait, DEBUG, XrdCmsClientMan::doDebug, EPNAME, XrdOucErrInfo::getErrUser(), XrdCmsRRData::Ident, XrdCms::kYR_prepadd, XrdCms::kYR_prepdel, XrdSysMutex::Lock(), XrdCmsRRData::Mode, XrdCms::CmsRRHdr::modifier, XrdCmsClientMan::Name(), XrdOucTList::next, XrdCmsRRData::Notify, XrdSfsPrep::notify, XrdSfsPrep::oinfo, XrdCmsRRData::Opaque, XrdSfsPrep::opts, XrdCmsParser::Pack(), XrdCms::Parser, XrdCmsRRData::Path, XrdSfsPrep::paths, Prep_COLOC, Prep_FRESH, Prep_PMASK, Prep_SENDACK, Prep_SENDERR, Prep_STAGE, Prep_WMODE, PrepWait, XrdCmsRRData::Prty, RepDelay, XrdCmsRRData::Reqid, XrdSfsPrep::reqid, XrdCmsRRData::Request, XrdCms::CmsRRHdr::rrCode, Say, SelectManager(), XrdCmsClientMan::Send(), XrdOucErrInfo::setErrInfo(), SFS_ERROR, XrdCms::CmsRRHdr::streamid, strlcpy(), XrdOucTList::text, XrdSysMutex::UnLock(), XrdOucTList::val, and XrdSysTimer::Wait().
|
inlinevirtual |
Notify the cmsd that a file or directory has been deleted. It is only called called on a data server node.
| path | The logical file name that was removed. |
Reimplemented from XrdCmsClient.
|
private |
References ConWait, XrdOucReqID::Index(), XrdCmsClientMan::isActive(), myManagers, myManCount, myManTable, XrdCmsClientMan::nextManager(), XrdCmsClientConfig::RoundRob, Say, SelectManFail(), XrdOucErrInfo::setErrInfo(), SMode, and XrdCmsClientMan::Suspended().
Referenced by Forward(), Prepare(), and send2Man().
|
private |
References ConWait, EPNAME, XrdOucErrInfo::getErrUser(), XrdSysMutex::Lock(), myData, Say, XrdOucErrInfo::setErrInfo(), TRACE, and XrdSysMutex::UnLock().
Referenced by SelectManager().
|
private |
References XrdCmsClientMsg::Alloc(), ConWait, XrdCmsClientMan::delayResp(), EPNAME, XrdOucErrInfo::getErrInfo(), XrdOucErrInfo::getErrUser(), XrdCmsClientMsg::getResult(), XrdCmsClientMsg::ID(), XrdCmsClientMsg::Recycle(), RepDelay, savePath, SelectManager(), XrdCmsClientMan::Send(), XrdOucErrInfo::setErrData(), XrdOucErrInfo::setErrInfo(), SFS_STALL, SFS_STARTED, XrdCmsClientMan::Suspended(), TRACE, XrdCmsClientMsg::Wait4Reply(), XrdCmsClientMan::waitTime(), and XrdCmsClientMan::whatsUp().
|
inline |
|
virtual |
Obtain the overall space usage of a cluster. Called only on manager nodes.
| Resp | Object to hold response or error message. |
| path | Associated logical path for the space request. |
| Info | Associated cgi information for path. |
Implements XrdCmsClient.
References XrdCmsClientMan::doDebug, XrdOucErrInfo::getErrUser(), XrdCmsRRData::Ident, XrdCms::kYR_statfs, XrdCms::CmsRRHdr::modifier, XrdCmsParser::Pack(), XrdCms::Parser, XrdCmsRRData::Path, XrdCmsRRData::Request, XrdCms::CmsRRHdr::rrCode, send2Man(), XrdOucErrInfo::setErrInfo(), SFS_ERROR, and XrdCms::CmsRRHdr::streamid.
|
private |
References ConWait, MaxMan, myManagers, myManCount, myManTable, XrdCmsClientMan::Name(), XrdOucTList::next, RepDelay, RepNone, RepWait, XrdSysThread::Run(), Say, XrdCmsClientMan::setNext(), XrdOucTList::text, XrdOucTList::val, XrdCmsStartManager(), and XrdCmsStartResp().
Referenced by Configure().
|
static |
References XrdSysPlugin::VerCmp().
Referenced by XrdOfs::ConfigRedir().
|
private |
Referenced by Configure().
|
private |
Referenced by Configure(), Forward(), Prepare(), SelectManager(), SelectManFail(), send2Man(), and StartManagers().
|
private |
Referenced by Configure(), and Forward().
|
private |
Referenced by Configure(), and XrdCmsFinderRMT().
|
private |
Referenced by Configure(), and XrdCmsFinderRMT().
|
private |
Referenced by Configure(), and XrdCmsFinderRMT().
|
static |
Referenced by StartManagers().
|
private |
Referenced by SelectManFail().
|
private |
Referenced by Inform(), SelectManager(), StartManagers(), XrdCmsFinderRMT(), and ~XrdCmsFinderRMT().
|
private |
Referenced by SelectManager(), StartManagers(), and XrdCmsFinderRMT().
|
private |
Referenced by Managers().
|
private |
Referenced by SelectManager(), and StartManagers().
|
private |
Referenced by Configure(), and XrdCmsFinderRMT().
|
private |
Referenced by Configure(), and Prepare().
|
private |
Referenced by Configure(), Forward(), Prepare(), send2Man(), and StartManagers().
|
private |
Referenced by Configure(), and StartManagers().
|
private |
Referenced by Configure(), and StartManagers().
|
private |
Referenced by Configure(), send2Man(), and XrdCmsFinderRMT().
|
private |
Referenced by XrdCmsFinderRMT().
|
private |
Referenced by Configure(), SelectManager(), and XrdCmsFinderRMT().
1.8.3.1