Logo ROOT   6.12/07
Reference Guide
List of all members | Public Member Functions | Private Member Functions | Private Attributes | List of all members
XrdProofdAdmin Class Reference

Definition at line 49 of file XrdProofdAdmin.h.

Public Member Functions

 XrdProofdAdmin (XrdProofdManager *mgr, XrdProtocol_Config *pi, XrdSysError *e)
 Constructor. More...
 
virtual ~XrdProofdAdmin ()
 
int CleanupSessions (XrdProofdProtocol *p)
 Handle request of. More...
 
int Config (bool rcf=0)
 Run configuration and parse the entered config directives. More...
 
int CpFile (XrdProofdProtocol *p)
 Handle request for copy files from / to the sandbox. More...
 
int DoDirective (XrdProofdDirective *d, char *val, XrdOucStream *cfg, bool rcf)
 Update the priorities of the active sessions. More...
 
int Exec (XrdProofdProtocol *p)
 Handle request of cleaning parts of the sandbox. More...
 
int GetFile (XrdProofdProtocol *p)
 Handle request for sending a file. More...
 
int GetWorkers (XrdProofdProtocol *p)
 Handle request for getting the best set of workers. More...
 
int Process (XrdProofdProtocol *p, int type)
 Process admin request. More...
 
int PutFile (XrdProofdProtocol *p)
 Handle request for recieving a file. More...
 
int QueryLogPaths (XrdProofdProtocol *p)
 Handle request for log paths. More...
 
int QueryMssUrl (XrdProofdProtocol *p)
 Handle request for the URL to the MSS attached to the cluster. More...
 
int QueryROOTVersions (XrdProofdProtocol *p)
 Handle request for list of ROOT versions. More...
 
int QuerySessions (XrdProofdProtocol *p)
 Handle request for list of sessions. More...
 
int QueryWorkers (XrdProofdProtocol *p)
 Handle request for getting the list of potential workers. More...
 
int ReleaseWorker (XrdProofdProtocol *p)
 Handle request for releasing a worker. More...
 
int SendMsgToUser (XrdProofdProtocol *p)
 Handle request for sending a message to a user. More...
 
int SetGroupProperties (XrdProofdProtocol *p)
 Handle request for setting group properties. More...
 
int SetROOTVersion (XrdProofdProtocol *p)
 Handle request for changing the default ROOT version. More...
 
int SetSessionAlias (XrdProofdProtocol *p)
 Handle request for setting the session alias. More...
 
int SetSessionTag (XrdProofdProtocol *p)
 Handle request for setting the session tag. More...
 
- Public Member Functions inherited from XrdProofdConfig
 XrdProofdConfig (const char *cfg=0, XrdSysError *edest=0)
 Main constructor. More...
 
virtual ~XrdProofdConfig ()
 
const char * CfgFile () const
 
void SetCfgEDest (const char *cfg, XrdSysError *edest)
 Set config file and error handler. More...
 

Private Member Functions

int CheckForbiddenChars (const char *s)
 Check is 's' contains any of the forbidden chars '(){};' Return 0 if OK (no forbidden chars), -1 in not OK. More...
 
int CheckPath (bool superuser, const char *sbdir, XrdOucString &fullpath, int check, bool &sandbox, struct stat *st, XrdOucString &emsg)
 Handle request for sending a file. More...
 
int DoDirectiveCpCmd (char *, XrdOucStream *, bool)
 Process 'cpcmd' directives eg: xpd.cpcmd alien aliencp fmt:"%s %s" put:0. More...
 
int DoDirectiveExportPath (char *, XrdOucStream *, bool)
 Process 'exportpath' directives eg: xpd.exportpath /tmp/data /data2/data. More...
 
int ExecCmd (XrdProofdProtocol *p, XrdProofdResponse *r, int action, const char *cmd, XrdOucString &emsg)
 Low-level execution handler. More...
 
void RegisterDirectives ()
 Register directives for configuration. More...
 
int Send (XrdProofdResponse *r, const char *msg)
 

Private Attributes

XrdOucHash< XpdAdminCpCmdfAllowedCpCmds
 
XrdOucString fCpCmds
 
std::list< XrdOucString > fExportPaths
 
XrdProofdManagerfMgr
 

Additional Inherited Members

- Protected Member Functions inherited from XrdProofdConfig
int ParseFile (bool rcf=false)
 Parse config file for the registered directives. More...
 
bool ReadFile (bool update=true)
 Return true if the file has never been read or did change since last reading, false otherwise. More...
 
void Register (const char *dname, XrdProofdDirective *d)
 
- Protected Attributes inherited from XrdProofdConfig
XrdSysErrorfEDest
 

#include <XrdProofdAdmin.h>

Inheritance diagram for XrdProofdAdmin:
[legend]

Constructor & Destructor Documentation

◆ XrdProofdAdmin()

XrdProofdAdmin::XrdProofdAdmin ( XrdProofdManager mgr,
XrdProtocol_Config *  pi,
XrdSysError e 
)

Constructor.

Definition at line 73 of file XrdProofdAdmin.cxx.

◆ ~XrdProofdAdmin()

virtual XrdProofdAdmin::~XrdProofdAdmin ( )
inlinevirtual

Definition at line 69 of file XrdProofdAdmin.h.

Member Function Documentation

◆ CheckForbiddenChars()

int XrdProofdAdmin::CheckForbiddenChars ( const char *  s)
private

Check is 's' contains any of the forbidden chars '(){};' Return 0 if OK (no forbidden chars), -1 in not OK.

Definition at line 1179 of file XrdProofdAdmin.cxx.

◆ CheckPath()

int XrdProofdAdmin::CheckPath ( bool  superuser,
const char *  sbdir,
XrdOucString &  fullpath,
int  check,
bool &  sandbox,
struct stat *  st,
XrdOucString &  emsg 
)
private

Handle request for sending a file.

Definition at line 1715 of file XrdProofdAdmin.cxx.

◆ CleanupSessions()

int XrdProofdAdmin::CleanupSessions ( XrdProofdProtocol p)

Handle request of.

Definition at line 936 of file XrdProofdAdmin.cxx.

◆ Config()

int XrdProofdAdmin::Config ( bool  rcf = 0)
virtual

Run configuration and parse the entered config directives.

Return 0 on success, -1 on error

Reimplemented from XrdProofdConfig.

Definition at line 172 of file XrdProofdAdmin.cxx.

◆ CpFile()

int XrdProofdAdmin::CpFile ( XrdProofdProtocol p)

Handle request for copy files from / to the sandbox.

Definition at line 2238 of file XrdProofdAdmin.cxx.

◆ DoDirective()

int XrdProofdAdmin::DoDirective ( XrdProofdDirective d,
char *  val,
XrdOucStream *  cfg,
bool  rcf 
)
virtual

Update the priorities of the active sessions.

Reimplemented from XrdProofdConfig.

Definition at line 202 of file XrdProofdAdmin.cxx.

◆ DoDirectiveCpCmd()

int XrdProofdAdmin::DoDirectiveCpCmd ( char *  val,
XrdOucStream *  cfg,
bool   
)
private

Process 'cpcmd' directives eg: xpd.cpcmd alien aliencp fmt:"%s %s" put:0.

Definition at line 251 of file XrdProofdAdmin.cxx.

◆ DoDirectiveExportPath()

int XrdProofdAdmin::DoDirectiveExportPath ( char *  val,
XrdOucStream *  cfg,
bool   
)
private

Process 'exportpath' directives eg: xpd.exportpath /tmp/data /data2/data.

Definition at line 224 of file XrdProofdAdmin.cxx.

◆ Exec()

int XrdProofdAdmin::Exec ( XrdProofdProtocol p)

Handle request of cleaning parts of the sandbox.

Definition at line 1198 of file XrdProofdAdmin.cxx.

◆ ExecCmd()

int XrdProofdAdmin::ExecCmd ( XrdProofdProtocol p,
XrdProofdResponse r,
int  action,
const char *  cmd,
XrdOucString &  emsg 
)
private

Low-level execution handler.

The commands must be executed in user space. We do that by forking and logging as user in the forked instance. The parent will just send over te messages received from the user-child via the pipe. Return 0 on success, -1 on error

Definition at line 1493 of file XrdProofdAdmin.cxx.

◆ GetFile()

int XrdProofdAdmin::GetFile ( XrdProofdProtocol p)

Handle request for sending a file.

Definition at line 1779 of file XrdProofdAdmin.cxx.

◆ GetWorkers()

int XrdProofdAdmin::GetWorkers ( XrdProofdProtocol p)

Handle request for getting the best set of workers.

Definition at line 490 of file XrdProofdAdmin.cxx.

◆ Process()

int XrdProofdAdmin::Process ( XrdProofdProtocol p,
int  type 
)

Process admin request.

Definition at line 109 of file XrdProofdAdmin.cxx.

◆ PutFile()

int XrdProofdAdmin::PutFile ( XrdProofdProtocol p)

Handle request for recieving a file.

Definition at line 1990 of file XrdProofdAdmin.cxx.

◆ QueryLogPaths()

int XrdProofdAdmin::QueryLogPaths ( XrdProofdProtocol p)

Handle request for log paths.

Definition at line 719 of file XrdProofdAdmin.cxx.

◆ QueryMssUrl()

int XrdProofdAdmin::QueryMssUrl ( XrdProofdProtocol p)

Handle request for the URL to the MSS attached to the cluster.

The reply contains also the namespace, i.e. proto://host:port//namespace

Definition at line 312 of file XrdProofdAdmin.cxx.

◆ QueryROOTVersions()

int XrdProofdAdmin::QueryROOTVersions ( XrdProofdProtocol p)

Handle request for list of ROOT versions.

Definition at line 335 of file XrdProofdAdmin.cxx.

◆ QuerySessions()

int XrdProofdAdmin::QuerySessions ( XrdProofdProtocol p)

Handle request for list of sessions.

Definition at line 689 of file XrdProofdAdmin.cxx.

◆ QueryWorkers()

int XrdProofdAdmin::QueryWorkers ( XrdProofdProtocol p)

Handle request for getting the list of potential workers.

Definition at line 464 of file XrdProofdAdmin.cxx.

◆ RegisterDirectives()

void XrdProofdAdmin::RegisterDirectives ( )
privatevirtual

Register directives for configuration.

Reimplemented from XrdProofdConfig.

Definition at line 100 of file XrdProofdAdmin.cxx.

◆ ReleaseWorker()

int XrdProofdAdmin::ReleaseWorker ( XrdProofdProtocol p)

Handle request for releasing a worker.

Definition at line 1139 of file XrdProofdAdmin.cxx.

◆ Send()

int XrdProofdAdmin::Send ( XrdProofdResponse r,
const char *  msg 
)
private

◆ SendMsgToUser()

int XrdProofdAdmin::SendMsgToUser ( XrdProofdProtocol p)

Handle request for sending a message to a user.

Definition at line 601 of file XrdProofdAdmin.cxx.

◆ SetGroupProperties()

int XrdProofdAdmin::SetGroupProperties ( XrdProofdProtocol p)

Handle request for setting group properties.

Definition at line 546 of file XrdProofdAdmin.cxx.

◆ SetROOTVersion()

int XrdProofdAdmin::SetROOTVersion ( XrdProofdProtocol p)

Handle request for changing the default ROOT version.

Definition at line 356 of file XrdProofdAdmin.cxx.

◆ SetSessionAlias()

int XrdProofdAdmin::SetSessionAlias ( XrdProofdProtocol p)

Handle request for setting the session alias.

Definition at line 1056 of file XrdProofdAdmin.cxx.

◆ SetSessionTag()

int XrdProofdAdmin::SetSessionTag ( XrdProofdProtocol p)

Handle request for setting the session tag.

Definition at line 1098 of file XrdProofdAdmin.cxx.

Member Data Documentation

◆ fAllowedCpCmds

XrdOucHash<XpdAdminCpCmd> XrdProofdAdmin::fAllowedCpCmds
private

Definition at line 53 of file XrdProofdAdmin.h.

◆ fCpCmds

XrdOucString XrdProofdAdmin::fCpCmds
private

Definition at line 54 of file XrdProofdAdmin.h.

◆ fExportPaths

std::list<XrdOucString> XrdProofdAdmin::fExportPaths
private

Definition at line 52 of file XrdProofdAdmin.h.

◆ fMgr

XrdProofdManager* XrdProofdAdmin::fMgr
private

Definition at line 51 of file XrdProofdAdmin.h.

Libraries for XrdProofdAdmin:
[legend]

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