Logo ROOT   6.10/09
Reference Guide
List of all members | Public Member Functions | Private Attributes | List of all members
XrdProofdClient Class Reference

Definition at line 43 of file XrdProofdClient.h.

Public Member Functions

 XrdProofdClient (XrdProofUI ui, bool master, bool changeown, XrdSysError *edest, const char *tmp, int rtime)
 Constructor. More...
 
virtual ~XrdProofdClient ()
 Destructor. More...
 
const char * AdminPath () const
 
void Broadcast (const char *msg)
 Broadcast message 'msg' to the connected clients. More...
 
void EraseServer (int psid)
 Erase server with id psid from the list. More...
 
XrdOucString ExportSessions (XrdOucString &emsg, XrdProofdResponse *r=0)
 Return a string describing the existing sessions. More...
 
int GetClientID (XrdProofdProtocol *p)
 Get next free client ID. More...
 
XrdProofdProofServGetFreeServObj ()
 Get next free server ID. More...
 
XrdProofdProtocolGetProtocol (int ic)
 Return protocol attached to client slot at 'ic'. More...
 
XrdProofdProofServGetServer (int psid)
 Get from the vector server instance with ID psid. More...
 
XrdProofdProofServGetServer (XrdProofdProtocol *p)
 Get server instance connected via 'p'. More...
 
XrdProofdProofServGetServObj (int id)
 Get server at 'id'. If needed, increase the vector size. More...
 
int GetTopServers ()
 Return the number of valid proofserv topmaster sessions in the list. More...
 
const char * Group () const
 
bool IsValid () const
 
bool Match (const char *usr, const char *grp=0)
 return TRUE if this instance matches 'id' (and 'grp', if defined) More...
 
XrdSysRecMutexMutex () const
 
int ReserveClientID (int cid)
 Reserve a client ID. More...
 
int ResetClientSlot (int ic)
 Reset slot at 'ic'. More...
 
void ResetSessions ()
 Reset this instance. More...
 
XrdROOTROOT () const
 
XrdProofdSandboxSandbox () const
 
int SetClientID (int cid, XrdProofdProtocol *p)
 Set slot cid to instance 'p'. More...
 
void SetGroup (const char *g)
 
void SetROOT (XrdROOT *r)
 
void SetValid (bool valid=1)
 
int Size () const
 
void SkipSessionsCheck (std::list< XrdProofdProofServ *> *active, XrdOucString &emsg, XrdProofdResponse *r=0)
 Skip the next sessions status check. More...
 
void TerminateSessions (int srvtype, XrdProofdProofServ *ref, const char *msg, XrdProofdPipe *pipe, bool changeown)
 Terminate client sessions; IDs of signalled processes are added to sigpid. More...
 
int Touch (bool reset=0)
 Send a touch the connected clients: this will remotely touch the associated TSocket instance and schedule an asynchronous touch of the client admin file. More...
 
int TrimSessionDirs ()
 
XrdProofUI UI () const
 
const char * User () const
 
bool VerifySession (XrdProofdProofServ *xps, XrdProofdResponse *r=0)
 Quick verification of session 'xps' to avoid attaching clients to non responding sessions. More...
 

Private Attributes

XrdOucString fAdminPath
 
bool fAskedToTouch
 
bool fChangeOwn
 
std::vector< XrdClientID * > fClients
 
bool fIsValid
 
XrdSysRecMutex fMutex
 
std::vector< XrdProofdProofServ * > fProofServs
 
int fReconnectTimeOut
 
XrdROOTfROOT
 
XrdProofdSandbox fSandbox
 
XrdProofUI fUI
 

#include <XrdProofdClient.h>

Constructor & Destructor Documentation

◆ XrdProofdClient()

XrdProofdClient::XrdProofdClient ( XrdProofUI  ui,
bool  master,
bool  changeown,
XrdSysError edest,
const char *  tmp,
int  rtime 
)

Constructor.

Definition at line 37 of file XrdProofdClient.cxx.

◆ ~XrdProofdClient()

XrdProofdClient::~XrdProofdClient ( )
virtual

Destructor.

Definition at line 71 of file XrdProofdClient.cxx.

Member Function Documentation

◆ AdminPath()

const char* XrdProofdClient::AdminPath ( ) const
inline

Definition at line 96 of file XrdProofdClient.h.

◆ Broadcast()

void XrdProofdClient::Broadcast ( const char *  msg)

Broadcast message 'msg' to the connected clients.

Definition at line 448 of file XrdProofdClient.cxx.

◆ EraseServer()

void XrdProofdClient::EraseServer ( int  psid)

Erase server with id psid from the list.

Definition at line 332 of file XrdProofdClient.cxx.

◆ ExportSessions()

XrdOucString XrdProofdClient::ExportSessions ( XrdOucString &  emsg,
XrdProofdResponse r = 0 
)

Return a string describing the existing sessions.

Definition at line 619 of file XrdProofdClient.cxx.

◆ GetClientID()

int XrdProofdClient::GetClientID ( XrdProofdProtocol p)

Get next free client ID.

If none is found, increase the vector size and get the first new one

Definition at line 93 of file XrdProofdClient.cxx.

◆ GetFreeServObj()

XrdProofdProofServ * XrdProofdClient::GetFreeServObj ( )

Get next free server ID.

If none is found, increase the vector size and get the first new one

Definition at line 182 of file XrdProofdClient.cxx.

◆ GetProtocol()

XrdProofdProtocol * XrdProofdClient::GetProtocol ( int  ic)

Return protocol attached to client slot at 'ic'.

Definition at line 400 of file XrdProofdClient.cxx.

◆ GetServer() [1/2]

XrdProofdProofServ * XrdProofdClient::GetServer ( int  psid)

Get from the vector server instance with ID psid.

Definition at line 320 of file XrdProofdClient.cxx.

◆ GetServer() [2/2]

XrdProofdProofServ * XrdProofdClient::GetServer ( XrdProofdProtocol p)

Get server instance connected via 'p'.

Definition at line 296 of file XrdProofdClient.cxx.

◆ GetServObj()

XrdProofdProofServ * XrdProofdClient::GetServObj ( int  id)

Get server at 'id'. If needed, increase the vector size.

Definition at line 234 of file XrdProofdClient.cxx.

◆ GetTopServers()

int XrdProofdClient::GetTopServers ( )

Return the number of valid proofserv topmaster sessions in the list.

Definition at line 356 of file XrdProofdClient.cxx.

◆ Group()

const char* XrdProofdClient::Group ( ) const
inline

Definition at line 51 of file XrdProofdClient.h.

◆ IsValid()

bool XrdProofdClient::IsValid ( ) const
inline

Definition at line 53 of file XrdProofdClient.h.

◆ Match()

bool XrdProofdClient::Match ( const char *  usr,
const char *  grp = 0 
)

return TRUE if this instance matches 'id' (and 'grp', if defined)

Definition at line 78 of file XrdProofdClient.cxx.

◆ Mutex()

XrdSysRecMutex* XrdProofdClient::Mutex ( ) const
inline

Definition at line 55 of file XrdProofdClient.h.

◆ ReserveClientID()

int XrdProofdClient::ReserveClientID ( int  cid)

Reserve a client ID.

If none is found, increase the vector size and performe the needed initializations

Definition at line 145 of file XrdProofdClient.cxx.

◆ ResetClientSlot()

int XrdProofdClient::ResetClientSlot ( int  ic)

Reset slot at 'ic'.

Definition at line 380 of file XrdProofdClient.cxx.

◆ ResetSessions()

void XrdProofdClient::ResetSessions ( )

Reset this instance.

Definition at line 693 of file XrdProofdClient.cxx.

◆ ROOT()

XrdROOT* XrdProofdClient::ROOT ( ) const
inline

Definition at line 56 of file XrdProofdClient.h.

◆ Sandbox()

XrdProofdSandbox* XrdProofdClient::Sandbox ( ) const
inline

Definition at line 57 of file XrdProofdClient.h.

◆ SetClientID()

int XrdProofdClient::SetClientID ( int  cid,
XrdProofdProtocol p 
)

Set slot cid to instance 'p'.

Definition at line 421 of file XrdProofdClient.cxx.

◆ SetGroup()

void XrdProofdClient::SetGroup ( const char *  g)
inline

Definition at line 85 of file XrdProofdClient.h.

◆ SetROOT()

void XrdProofdClient::SetROOT ( XrdROOT r)
inline

Definition at line 86 of file XrdProofdClient.h.

◆ SetValid()

void XrdProofdClient::SetValid ( bool  valid = 1)
inline

Definition at line 88 of file XrdProofdClient.h.

◆ Size()

int XrdProofdClient::Size ( ) const
inline

Definition at line 90 of file XrdProofdClient.h.

◆ SkipSessionsCheck()

void XrdProofdClient::SkipSessionsCheck ( std::list< XrdProofdProofServ *> *  active,
XrdOucString &  emsg,
XrdProofdResponse r = 0 
)

Skip the next sessions status check.

This is used, for example, when somebody has shown interest in these sessions to give more time for the reconnection. If active is defined, the list of active sessions is filled.

Definition at line 585 of file XrdProofdClient.cxx.

◆ TerminateSessions()

void XrdProofdClient::TerminateSessions ( int  srvtype,
XrdProofdProofServ ref,
const char *  msg,
XrdProofdPipe pipe,
bool  changeown 
)

Terminate client sessions; IDs of signalled processes are added to sigpid.

Definition at line 646 of file XrdProofdClient.cxx.

◆ Touch()

int XrdProofdClient::Touch ( bool  reset = 0)

Send a touch the connected clients: this will remotely touch the associated TSocket instance and schedule an asynchronous touch of the client admin file.

This request is only sent once per client: this is controlled by the flag fAskedToTouch, whcih can reset to FALSE by calling this function with reset TRUE. Return 0 if the request is sent or if asked to reset. Retunn 1 if the request was already sent.

Definition at line 482 of file XrdProofdClient.cxx.

◆ TrimSessionDirs()

int XrdProofdClient::TrimSessionDirs ( )
inline

Definition at line 94 of file XrdProofdClient.h.

◆ UI()

XrdProofUI XrdProofdClient::UI ( ) const
inline

Definition at line 58 of file XrdProofdClient.h.

◆ User()

const char* XrdProofdClient::User ( ) const
inline

Definition at line 52 of file XrdProofdClient.h.

◆ VerifySession()

bool XrdProofdClient::VerifySession ( XrdProofdProofServ xps,
XrdProofdResponse r = 0 
)

Quick verification of session 'xps' to avoid attaching clients to non responding sessions.

We do here a sort of loose ping. Return true is responding, false otherwise.

Definition at line 517 of file XrdProofdClient.cxx.

Member Data Documentation

◆ fAdminPath

XrdOucString XrdProofdClient::fAdminPath
private

Definition at line 112 of file XrdProofdClient.h.

◆ fAskedToTouch

bool XrdProofdClient::fAskedToTouch
private

Definition at line 104 of file XrdProofdClient.h.

◆ fChangeOwn

bool XrdProofdClient::fChangeOwn
private

Definition at line 102 of file XrdProofdClient.h.

◆ fClients

std::vector<XrdClientID *> XrdProofdClient::fClients
private

Definition at line 115 of file XrdProofdClient.h.

◆ fIsValid

bool XrdProofdClient::fIsValid
private

Definition at line 103 of file XrdProofdClient.h.

◆ fMutex

XrdSysRecMutex XrdProofdClient::fMutex
private

Definition at line 100 of file XrdProofdClient.h.

◆ fProofServs

std::vector<XrdProofdProofServ *> XrdProofdClient::fProofServs
private

Definition at line 114 of file XrdProofdClient.h.

◆ fReconnectTimeOut

int XrdProofdClient::fReconnectTimeOut
private

Definition at line 105 of file XrdProofdClient.h.

◆ fROOT

XrdROOT* XrdProofdClient::fROOT
private

Definition at line 108 of file XrdProofdClient.h.

◆ fSandbox

XrdProofdSandbox XrdProofdClient::fSandbox
private

Definition at line 110 of file XrdProofdClient.h.

◆ fUI

XrdProofUI XrdProofdClient::fUI
private

Definition at line 107 of file XrdProofdClient.h.


The documentation for this class was generated from the following files: