#include <XrdOfsEvs.hh>
Public Types | |
| enum | Event |
Public Member Functions | |
| int | Enabled (Event theEvents) |
| int | maxSmsg () |
| int | maxLmsg () |
| void | Notify (Event eNum, XrdOfsEvsInfo &Info) |
| const char * | Prog () |
| void | sendEvents (void) |
| int | Start (XrdSysError *eobj) |
| XrdOfsEvs (Event theEvents, const char *Target, int minq=90, int maxq=10) | |
| ~XrdOfsEvs () | |
Static Public Member Functions | |
| static int | Parse (XrdSysError &Eroute, Event eNum, char *mText) |
Static Public Attributes | |
| static const int | minMsgSize = 1360 |
| static const int | maxMsgSize = 2384 |
Private Member Functions | |
| const char * | eName (int eNum) |
| int | Feed (const char *data, int dlen) |
| XrdOfsEvsMsg * | getMsg (int bigmsg) |
| void | retMsg (XrdOfsEvsMsg *tp) |
Private Attributes | |
| pthread_t | tid |
| char * | theTarget |
| Event | enEvents |
| XrdSysError * | eDest |
| XrdOucProg * | theProg |
| XrdSysMutex | qMut |
| XrdSysSemaphore | qSem |
| XrdOfsEvsMsg * | msgFirst |
| XrdOfsEvsMsg * | msgLast |
| XrdSysMutex | fMut |
| XrdOfsEvsMsg * | msgFreeMax |
| XrdOfsEvsMsg * | msgFreeMin |
| int | endIT |
| int | msgFD |
| int | numMax |
| int | maxMax |
| int | numMin |
| int | maxMin |
Static Private Attributes | |
| static XrdOfsEvsFormat | MsgFmt [XrdOfsEvs::nCount] |
Definition at line 102 of file XrdOfsEvs.hh.
| enum XrdOfsEvs::Event |
Definition at line 106 of file XrdOfsEvs.hh.
| XrdOfsEvs::XrdOfsEvs | ( | Event | theEvents, | |
| const char * | Target, | |||
| int | minq = 90, |
|||
| int | maxq = 10 | |||
| ) |
Definition at line 102 of file XrdOfsEvs.cc.
References Chmod, Closer, Closew, Create, XrdOfsEvsFormat::cvtFSize, XrdOfsEvsFormat::cvtMode, XrdOfsEvsFormat::Def(), eDest, endIT, enEvents, enMask, XrdOfsEvsInfo::evFMODE, XrdOfsEvsInfo::evFSIZE, XrdOfsEvsInfo::evLFN1, XrdOfsEvsInfo::evLFN2, XrdOfsEvsInfo::evTID, Fwrite, Mask, maxMax, maxMin, Mkdir, msgFD, msgFirst, MsgFmt, msgFreeMax, msgFreeMin, msgLast, Mv, XrdOfsEvsFormat::Null, numMax, numMin, Openr, Openw, Rm, Rmdir, theProg, theTarget, tid, and Trunc.
| XrdOfsEvs::~XrdOfsEvs | ( | ) |
Definition at line 186 of file XrdOfsEvs.cc.
References close, endIT, fMut, free(), XrdSysThread::Kill(), XrdSysMutex::Lock(), msgFD, msgFirst, msgFreeMax, msgFreeMin, XrdOfsEvsMsg::next, qMut, theProg, theTarget, tid, and XrdSysMutex::UnLock().
| int XrdOfsEvs::Enabled | ( | Event | theEvents | ) | [inline] |
Definition at line 121 of file XrdOfsEvs.hh.
References enEvents.
Referenced by XrdOfs::chmod(), XrdOfsFile::close(), XrdOfs::Config_Display(), XrdOfs::mkdir(), XrdOfsFile::open(), XrdOfs::remove(), XrdOfs::rename(), XrdOfsFile::truncate(), XrdOfs::truncate(), XrdOfs::Unpersist(), and XrdOfsFile::write().
| int XrdOfsEvs::maxSmsg | ( | ) | [inline] |
Definition at line 123 of file XrdOfsEvs.hh.
References maxMin.
Referenced by XrdOfs::Config_Display().
| int XrdOfsEvs::maxLmsg | ( | ) | [inline] |
Definition at line 124 of file XrdOfsEvs.hh.
References maxMax.
Referenced by XrdOfs::Config_Display().
| void XrdOfsEvs::Notify | ( | Event | eNum, | |
| XrdOfsEvsInfo & | Info | |||
| ) |
Definition at line 218 of file XrdOfsEvs.cc.
References XrdOfsEvsFormat::cvtFSize, XrdOfsEvsFormat::cvtMode, eDest, XrdSysError::Emsg(), eName(), XrdOfsEvsInfo::evFMODE, XrdOfsEvsInfo::evFSIZE, XrdOfsEvsFormat::Flags, getMsg(), Info, XrdSysMutex::Lock(), Mask, maxMsgSize, minMsgSize, msgFirst, MsgFmt, msgLast, Mv, nCount, XrdOfsEvsMsg::next, XrdSysSemaphore::Post(), qMut, qSem, S_IAMB, XrdOfsEvsFormat::SNP(), sprintf(), XrdOfsEvsMsg::text, XrdOfsEvsMsg::tlen, and XrdSysMutex::UnLock().
Referenced by XrdOfs::chmod(), XrdOfsFile::close(), XrdOfsFile::GenFWEvent(), XrdOfs::mkdir(), XrdOfsFile::open(), XrdOfs::remove(), XrdOfs::rename(), XrdOfs::truncate(), and XrdOfs::Unpersist().
| int XrdOfsEvs::Parse | ( | XrdSysError & | Eroute, | |
| Event | eNum, | |||
| char * | mText | |||
| ) | [static] |
Definition at line 270 of file XrdOfsEvs.cc.
References XrdOfsEvsFormat::cvtFSize, XrdOfsEvsFormat::cvtMode, XrdSysError::Emsg(), XrdOfsEvsInfo::evARGS, XrdOfsEvsInfo::evCGI1, XrdOfsEvsInfo::evCGI2, XrdOfsEvsInfo::evFMODE, XrdOfsEvsInfo::evFSIZE, XrdOfsEvsInfo::evLFN1, XrdOfsEvsInfo::evLFN2, XrdOfsEvsInfo::evTID, XrdOfsEvsFormat::freeFmt, i, j, Mask, MsgFmt, XrdOfsEvsFormat::Null, XrdSysError::Say(), XrdOfsEvsFormat::Set(), and strcpy().
Referenced by XrdOfs::xnmsg().
| const char* XrdOfsEvs::Prog | ( | ) | [inline] |
Definition at line 130 of file XrdOfsEvs.hh.
References theTarget.
Referenced by XrdOfs::Config_Display().
| void XrdOfsEvs::sendEvents | ( | void | ) |
Definition at line 346 of file XrdOfsEvs.cc.
References endIT, XrdOucProg::Feed(), Feed(), XrdSysMutex::Lock(), msgFirst, msgLast, XrdOfsEvsMsg::next, qMut, qSem, retMsg(), XrdOfsEvsMsg::text, theProg, XrdOfsEvsMsg::tlen, XrdSysMutex::UnLock(), and XrdSysSemaphore::Wait().
Referenced by XrdOfsEvsSend().
| int XrdOfsEvs::Start | ( | XrdSysError * | eobj | ) |
Definition at line 377 of file XrdOfsEvs.cc.
References XrdNetSocket::Create(), XrdNetSocket::Detach(), eDest, XrdSysError::Emsg(), msgFD, XrdSysThread::Run(), XrdOucProg::Setup(), XrdOucProg::Start(), theProg, theTarget, tid, XRDNET_FIFO, and XrdOfsEvsSend().
Referenced by XrdOfs::Configure().
| const char * XrdOfsEvs::eName | ( | int | eNum | ) | [private] |
| int XrdOfsEvs::Feed | ( | const char * | data, | |
| int | dlen | |||
| ) | [private] |
Definition at line 442 of file XrdOfsEvs.cc.
References eDest, XrdSysError::Emsg(), msgFD, size_t, theTarget, and write.
Referenced by sendEvents().
| XrdOfsEvsMsg * XrdOfsEvs::getMsg | ( | int | bigmsg | ) | [private] |
Definition at line 464 of file XrdOfsEvs.cc.
References fMut, XrdSysMutex::Lock(), malloc(), maxMax, maxMin, maxMsgSize, minMsgSize, msgFreeMax, msgFreeMin, XrdOfsEvsMsg::next, numMax, numMin, XrdOfsEvsMsg::text, and XrdSysMutex::UnLock().
Referenced by Notify().
| void XrdOfsEvs::retMsg | ( | XrdOfsEvsMsg * | tp | ) | [private] |
Definition at line 501 of file XrdOfsEvs.cc.
References fMut, XrdOfsEvsMsg::isBig, XrdSysMutex::Lock(), maxMax, maxMin, msgFreeMax, msgFreeMin, XrdOfsEvsMsg::next, numMax, numMin, and XrdSysMutex::UnLock().
Referenced by sendEvents().
const int XrdOfsEvs::minMsgSize = 1360 [static] |
const int XrdOfsEvs::maxMsgSize = 2384 [static] |
XrdOfsEvsFormat XrdOfsEvs::MsgFmt [static, private] |
pthread_t XrdOfsEvs::tid [private] |
char* XrdOfsEvs::theTarget [private] |
Definition at line 148 of file XrdOfsEvs.hh.
Referenced by Feed(), Prog(), Start(), XrdOfsEvs(), and ~XrdOfsEvs().
Event XrdOfsEvs::enEvents [private] |
XrdSysError* XrdOfsEvs::eDest [private] |
Definition at line 150 of file XrdOfsEvs.hh.
Referenced by Feed(), Notify(), Start(), and XrdOfsEvs().
XrdOucProg* XrdOfsEvs::theProg [private] |
Definition at line 151 of file XrdOfsEvs.hh.
Referenced by sendEvents(), Start(), XrdOfsEvs(), and ~XrdOfsEvs().
XrdSysMutex XrdOfsEvs::qMut [private] |
Definition at line 152 of file XrdOfsEvs.hh.
Referenced by Notify(), sendEvents(), and ~XrdOfsEvs().
XrdSysSemaphore XrdOfsEvs::qSem [private] |
XrdOfsEvsMsg* XrdOfsEvs::msgFirst [private] |
Definition at line 154 of file XrdOfsEvs.hh.
Referenced by Notify(), sendEvents(), XrdOfsEvs(), and ~XrdOfsEvs().
XrdOfsEvsMsg* XrdOfsEvs::msgLast [private] |
XrdSysMutex XrdOfsEvs::fMut [private] |
XrdOfsEvsMsg* XrdOfsEvs::msgFreeMax [private] |
Definition at line 157 of file XrdOfsEvs.hh.
Referenced by getMsg(), retMsg(), XrdOfsEvs(), and ~XrdOfsEvs().
XrdOfsEvsMsg* XrdOfsEvs::msgFreeMin [private] |
Definition at line 158 of file XrdOfsEvs.hh.
Referenced by getMsg(), retMsg(), XrdOfsEvs(), and ~XrdOfsEvs().
int XrdOfsEvs::endIT [private] |
Definition at line 159 of file XrdOfsEvs.hh.
Referenced by sendEvents(), XrdOfsEvs(), and ~XrdOfsEvs().
int XrdOfsEvs::msgFD [private] |
Definition at line 160 of file XrdOfsEvs.hh.
Referenced by Feed(), Start(), XrdOfsEvs(), and ~XrdOfsEvs().
int XrdOfsEvs::numMax [private] |
int XrdOfsEvs::maxMax [private] |
Definition at line 162 of file XrdOfsEvs.hh.
Referenced by getMsg(), maxLmsg(), retMsg(), and XrdOfsEvs().
int XrdOfsEvs::numMin [private] |
int XrdOfsEvs::maxMin [private] |
Definition at line 164 of file XrdOfsEvs.hh.
Referenced by getMsg(), maxSmsg(), retMsg(), and XrdOfsEvs().
1.5.1